add gps_venus
[protos/imu.git] / gps_venus.h
diff --git a/gps_venus.h b/gps_venus.h
new file mode 100644 (file)
index 0000000..18327c8
--- /dev/null
@@ -0,0 +1,40 @@
+#ifndef _GPS_VENUS_H
+#define _GPS_VENUS_H
+
+#include <stdint.h>
+
+/* A GPS position structure. It also contains some information about the number
+ * of seen satellites, the message ID, the date, .. */
+struct gps_pos {
+       uint8_t msg_id; /* */
+       uint8_t mode;
+       uint8_t sv_num;
+       uint16_t gps_week;
+       uint32_t tow;
+
+       int32_t latitude;
+       int32_t longitude;
+       uint32_t altitude;
+
+       uint32_t sea_altitude;
+
+       uint16_t gdop;
+       uint16_t pdop;
+       uint16_t hdop;
+       uint16_t vdop;
+       uint16_t tdop;
+
+       int32_t ecef_x;
+       int32_t ecef_y;
+       int32_t ecef_z;
+
+       int32_t ecef_vx;
+       int32_t ecef_vy;
+       int32_t ecef_vz;
+
+} __attribute__ ((packed));
+
+int gps_venus_init(void);
+int gps_loop(void);
+
+#endif