15 #ifndef SENSOR_SYNC_SEND
16 #warning set SENSOR_SYNC_SEND to use baro_scp
21 #define STA_INITIALISING 1
31 static void EXTINT_ISR(
void) __attribute__((naked));
32 static
void SPI1_ISR(
void) __attribute__((naked));
43 #define SSP_CLOCK 468750
46 #define SSP_DDS 0x07 << 0
47 #define SSP_FRF 0x00 << 4
48 #define SSP_CPOL 0x00 << 6
49 #define SSP_CPHA 0x00 << 7
50 #define SSP_SCR 0x0F << 8
53 #define SSP_LBM 0x00 << 0
54 #define SSP_SSE 0x00 << 1
55 #define SSP_MS 0x00 << 2
56 #define SSP_SOD 0x00 << 3
59 #define SS_IODIR IO0DIR
60 #define SS_IOSET IO0SET
61 #define SS_IOCLR IO0CLR
63 #define ScpSelect() SetBit(SS_IOCLR,SS_PIN)
64 #define ScpUnselect() SetBit(SS_IOSET,SS_PIN)
66 #warning "This driver should be updated to use the new SPI peripheral"
69 #define SPI1_VIC_SLOT 7
75 PINSEL1 |= 2 << 2 | 2 << 4 | 2 << 6;
161 uint8_t cmd = 0x03 << 2 | 0x02;
193 #ifdef SENSOR_SYNC_SEND
#define SPI1_DRDY_PINSEL_VAL
static void baro_scp_start_high_res_measurement(void)
arch independent UART (Universal Asynchronous Receiver/Transmitter) API
static void SpiClearRti(struct spi_periph *p)
Main include for ABI (AirBorneInterface).
static void baro_scp_read(void)
uint32_t baro_scp_pressure
static void SpiEnableRti(struct spi_periph *p)
void baro_scp_event(void)
Architecture independent SPI (Serial Peripheral Interface) API.
static void SPI1_ISR(void)
#define BARO_SCP_SENDER_ID
Architecture independent timing functions.
uint16_t baro_scp_temperature
#define DefaultChannel
SITL.
Arch independent mcu ( Micro Controller Unit ) utilities.
volatile uint32_t nb_sec
full seconds since startup
void baro_scp_periodic(void)
bool_t baro_scp_available
Common code for AP and FBW telemetry.
arch independent LED (Light Emitting Diodes) API
#define SPI1_DRDY_PINSEL_BIT
static void EXTINT_ISR(void)