nRF Connect SDK API 3.4.99
Loading...
Searching...
No Matches
SAADC + TIMER (SAADCT)

Timer-triggered SAADC sampling on Nordic nRF devices. More...

Data Structures

struct  saadct_config
 

Macros

#define SAADCT_MEAS_BLOCK_HEADER_SIZE   sizeof(void *)
 
#define SAADCT_MEAS_BLOCK_SIZE(num_meas, num_channels)
 

Enumerations

enum  saadct_mode_t { saadct_mode_one_shot , saadct_mode_continuous }
 

Functions

int saadct_configure (const struct device *dev, const struct saadct_config *cfg)
 Configure timer-triggered SAADC sampling.
 
int saadct_start (const struct device *dev, struct k_mem_slab *slab)
 Start timer-triggered SAADC sampling.
 
int saadct_stop (const struct device *dev, bool immediate)
 Stop timer-triggered SAADC sampling.
 
int saadct_get (const struct device *dev, nrf_saadc_value_t **data, k_timeout_t timeout)
 Read a completed measurement series.
 
void saadct_put (const struct device *dev, nrf_saadc_value_t *data)
 Release a measurement buffer.
 
uint32_t saadct_pending (const struct device *dev)
 Get the number of completed series waiting to be read.
 

Detailed Description

Timer-triggered SAADC sampling on Nordic nRF devices.

SAADCT uses an external TIMER instance and GPPI to trigger the SAADC sample task at a configured rate. Measurement results are delivered as series of interleaved channel samples stored in memory slabs.