84 } __attribute__((packed));
105 #define NAVDATA_PACKET_SIZE 60
106 #define NAVDATA_START_BYTE 0x3A
107 #define NAVDATA_CMD_START 0x01
108 #define NAVDATA_CMD_STOP 0x02
109 #define NAVDATA_CMD_BARO_CALIB 0x17
111 #define ARDRONE_GPIO_PORT 0x32524
112 #define ARDRONE_GPIO_PIN_NAVDATA 177
bool is_initialized
Check if the navdata board is initialized.
struct bmp180_calib_t bmp180_calib
BMP180 calibration receieved from navboard.
int16_t navdata_height(void)
struct navdata_measure_t measure
Main navdata packet receieved from navboard.
bool navdata_init(void)
Initialize the navdata board.
uint16_t temperature_gyro
uint16_t temperature_pressure
Main navdata structure from the navdata board This is received from the navdata board at ~200Hz...
bool baro_calibrated
Whenever the baro is calibrated.
ssize_t full_write(int fd, const uint8_t *buf, size_t count)
Write to fd even while being interrupted.
uint16_t us_association_echo
ssize_t full_read(int fd, uint8_t *buf, size_t count)
Read from fd even while being interrupted.
bool imu_lost
Whenever the imu is lost.
int fd
The navdata file pointer.
uint16_t us_distance_echo
bool baro_available
Whenever the baro is available.
void navdata_update(void)
Update the navdata (event loop)
uint16_t last_packet_number