struct i2c_ans_imuboard_status {
struct i2c_cmd_hdr hdr;
-#define IMUBOARD_STATUS_GPS_OK 0x01
-#define IMUBOARD_STATUS_IMU_OK 0x02
+#define I2C_IMUBOARD_STATUS_GPS_OK 0x01
+#define I2C_IMUBOARD_STATUS_IMU_OK 0x02
uint8_t flags;
int32_t latitude; /* between -90e7 and 90e7, in 1/1e-7 degrees,
ans.flags = 0;
if (gps_pos_valid(&gps_pos)) {
- ans.flags |= IMUBOARD_STATUS_GPS_OK;
+ ans.flags |= I2C_IMUBOARD_STATUS_GPS_OK;
ans.latitude = gps_pos.latitude;
ans.longitude = gps_pos.longitude;
ans.altitude = gps_pos.altitude;
memcpy(&imu, &imuboard_status, sizeof(imu));
IRQ_UNLOCK(irq_flags);
- if (imu.flags & IMUBOARD_STATUS_GPS_OK) {
+ if (imu.flags & I2C_IMUBOARD_STATUS_GPS_OK) {
printf_P(PSTR("GPS lat=%"PRIi32" long=%"PRIi32
" alt=%"PRIi32"\n"),
imu.latitude, imu.longitude, imu.altitude);
memcpy(&imuboard_status, ans, sizeof(imuboard_status));
if (gps_ok == 0 &&
- (imuboard_status.flags & IMUBOARD_STATUS_GPS_OK)) {
+ (imuboard_status.flags & I2C_IMUBOARD_STATUS_GPS_OK)) {
gps_ok = 1;
beep(0, 1, 1);
beep(0, 1, 1);