![]() |
Paparazzi UAS v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
|
Driver for the ADS1220 24-bits ADC from TI SPI communication. More...
#include "peripherals/ads1220.h"
Go to the source code of this file.
Macros | |
#define | ADS1220_WREG(_reg, _nb) ((1<<6)|(_reg<<2)|(_nb-1)) |
#define | ADS1220_RREG(_reg, _nb) ((1<<5)|(_reg<<2)|(_nb-1)) |
#define | ADS1220_RESET 0x06 |
#define | ADS1220_START_SYNC 0x08 |
#define | ADS1220_POWERDOWN 0x02 |
#define | ADS1220_RDATA 0x10 |
#define | ADS1220_CONF0 0x0 |
#define | ADS1220_CONF1 0x1 |
#define | ADS1220_CONF2 0x2 |
#define | ADS1220_CONF3 0x3 |
Functions | |
void | ads1220_init (struct Ads1220 *ads, struct spi_periph *spi_p, uint8_t slave_idx) |
static void | ads1220_send_config (struct Ads1220 *ads) |
void | ads1220_configure (struct Ads1220 *ads) |
void | ads1220_read (struct Ads1220 *ads) |
void | ads1220_event (struct Ads1220 *ads) |
Driver for the ADS1220 24-bits ADC from TI SPI communication.
Definition in file ads1220.c.
Definition at line 102 of file ads1220.c.
References ADS1220_INITIALIZING, ADS1220_RESET, ads1220_send_config(), ADS1220_SEND_RESET, ADS1220_UNINIT, foo, spi_submit(), SPITransDone, and SPITransSuccess.
Referenced by ads1220_periodic().
Definition at line 130 of file ads1220.c.
References ADS1220_INITIALIZED, ADS1220_INITIALIZING, ADS1220_SEND_RESET, ADS1220_UNINIT, foo, SPITransDone, SPITransFailed, and SPITransSuccess.
Referenced by meteo_stick_event().
void ads1220_init | ( | struct Ads1220 * | ads, |
struct spi_periph * | spi_p, | ||
uint8_t | slave_idx | ||
) |
Definition at line 49 of file ads1220.c.
References ADS1220_UNINIT, foo, SPICphaEdge2, SPICpolIdleLow, SPIDiv128, SPIDss8bit, SPIMSBFirst, SPISelectUnselect, SPITransDone, and spi_periph::status.
Referenced by meteo_stick_init().
Definition at line 120 of file ads1220.c.
References ADS1220_INITIALIZED, foo, spi_submit(), and SPITransDone.
Referenced by ads1220_periodic().
Definition at line 80 of file ads1220.c.
References ADS1220_CONF0, ADS1220_WREG, foo, and spi_submit().
Referenced by ads1220_configure().