Paparazzi UAS  v5.8.2_stable-0-g6260b7c
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
gps_i2c.c File Reference
#include "modules/gps/gps_i2c.h"
#include "mcu_periph/i2c.h"
#include "subsystems/gps.h"
+ Include dependency graph for gps_i2c.c:

Go to the source code of this file.

Macros

#define GPS_I2C_ADDR_NB_AVAIL_BYTES   0xFD
 
#define GPS_I2C_ADDR_DATA   0xFF
 
#define GPS_I2C_STATUS_IDLE   0
 
#define GPS_I2C_STATUS_ASKING_DATA   1
 
#define GPS_I2C_STATUS_ASKING_NB_AVAIL_BYTES   2
 
#define GPS_I2C_STATUS_READING_NB_AVAIL_BYTES   3
 
#define GPS_I2C_STATUS_READING_DATA   4
 
#define gps_i2c_AddCharToRxBuf(_x)
 

Functions

void gps_i2c_init (void)
 
void gps_i2c_periodic (void)
 
void gps_i2c_event (void)
 

Variables

struct i2c_transaction i2c_gps_trans
 
uint8_t gps_i2c_rx_buf [GPS_I2C_BUF_SIZE]
 
uint8_t gps_i2c_rx_insert_idx
 
uint8_t gps_i2c_rx_extract_idx
 
uint8_t gps_i2c_tx_buf [GPS_I2C_BUF_SIZE]
 
uint8_t gps_i2c_tx_insert_idx
 
uint8_t gps_i2c_tx_extract_idx
 
bool_t gps_i2c_done
 
bool_t gps_i2c_data_ready_to_transmit
 
static uint8_t gps_i2c_status
 

Macro Definition Documentation

#define gps_i2c_AddCharToRxBuf (   _x)
Value:
{ \
gps_i2c_rx_insert_idx++; /* size=256, No check for buf overflow */ \
}
uint8_t gps_i2c_rx_insert_idx
Definition: gps_i2c.c:31
uint8_t gps_i2c_rx_buf[GPS_I2C_BUF_SIZE]
Definition: gps_i2c.c:30

Definition at line 46 of file gps_i2c.c.

#define GPS_I2C_ADDR_DATA   0xFF

Definition at line 38 of file gps_i2c.c.

#define GPS_I2C_ADDR_NB_AVAIL_BYTES   0xFD

Definition at line 37 of file gps_i2c.c.

#define GPS_I2C_STATUS_ASKING_DATA   1

Definition at line 41 of file gps_i2c.c.

#define GPS_I2C_STATUS_ASKING_NB_AVAIL_BYTES   2

Definition at line 42 of file gps_i2c.c.

#define GPS_I2C_STATUS_IDLE   0

Definition at line 40 of file gps_i2c.c.

Referenced by gps_i2c_init().

#define GPS_I2C_STATUS_READING_DATA   4

Definition at line 44 of file gps_i2c.c.

#define GPS_I2C_STATUS_READING_NB_AVAIL_BYTES   3

Definition at line 43 of file gps_i2c.c.

Function Documentation

void gps_i2c_event ( void  )

Definition at line 82 of file gps_i2c.c.

void gps_i2c_periodic ( void  )

Definition at line 69 of file gps_i2c.c.

Variable Documentation

bool_t gps_i2c_data_ready_to_transmit

Definition at line 34 of file gps_i2c.c.

Referenced by gps_i2c_init().

bool_t gps_i2c_done

Definition at line 34 of file gps_i2c.c.

Referenced by gps_i2c_init().

uint8_t gps_i2c_rx_buf[GPS_I2C_BUF_SIZE]

Definition at line 30 of file gps_i2c.c.

uint8_t gps_i2c_rx_extract_idx

Definition at line 31 of file gps_i2c.c.

Referenced by gps_i2c_init().

uint8_t gps_i2c_rx_insert_idx

Definition at line 31 of file gps_i2c.c.

Referenced by gps_i2c_init().

uint8_t gps_i2c_status
static

Definition at line 51 of file gps_i2c.c.

Referenced by gps_i2c_init().

uint8_t gps_i2c_tx_buf[GPS_I2C_BUF_SIZE]

Definition at line 32 of file gps_i2c.c.

uint8_t gps_i2c_tx_extract_idx

Definition at line 33 of file gps_i2c.c.

uint8_t gps_i2c_tx_insert_idx

Definition at line 33 of file gps_i2c.c.

Referenced by gps_i2c_init().

struct i2c_transaction i2c_gps_trans

Definition at line 27 of file gps_i2c.c.