Rev 41 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 41 | Rev 52 | ||
---|---|---|---|
Line 12... | Line 12... | ||
12 | #define FLAG_GPSFIXOK 0x01 // (i.e. within DOP & ACC Masks) |
12 | #define FLAG_GPSFIXOK 0x01 // (i.e. within DOP & ACC Masks) |
13 | #define FLAG_DIFFSOLN 0x02 // (is DGPS used) |
13 | #define FLAG_DIFFSOLN 0x02 // (is DGPS used) |
14 | #define FLAG_WKNSET 0x04 // (is Week Number valid) |
14 | #define FLAG_WKNSET 0x04 // (is Week Number valid) |
15 | #define FLAG_TOWSET 0x08 // (is Time of Week valid) |
15 | #define FLAG_TOWSET 0x08 // (is Time of Week valid) |
Line 16... | Line -... | ||
16 | - | ||
17 | typedef enum |
- | |
18 | { |
16 | |
19 | INVALID = 0, |
17 | #define INVALID 0x00 |
20 | NEWDATA = 1, |
18 | #define NEWDATA 0x01 |
21 | PROCESSED = 2 |
- | |
Line 22... | Line 19... | ||
22 | } Status_t; |
19 | #define PROCESSED 0x02 |
23 | 20 | ||
24 | typedef struct |
21 | typedef struct |
25 | { |
22 | { |
26 | s32 Longitude; // in 1E-7 deg |
23 | s32 Longitude; // in 1E-7 deg |
27 | s32 Latitude; // in 1E-7 deg |
24 | s32 Latitude; // in 1E-7 deg |
28 | s32 Altitude; // in mm |
25 | s32 Altitude; // in mm |
Line 29... | Line 26... | ||
29 | Status_t Status;// validity of data |
26 | u8 Status;// validity of data |
30 | } __attribute__((packed)) GPS_Pos_t; |
27 | } __attribute__((packed)) GPS_Pos_t; |
Line 41... | Line 38... | ||
41 | s32 Speed_East; // in cm/s |
38 | s32 Speed_East; // in cm/s |
42 | s32 Speed_Top; // in cm/s |
39 | s32 Speed_Top; // in cm/s |
43 | u32 Speed_Ground; // 2D ground speed in cm/s |
40 | u32 Speed_Ground; // 2D ground speed in cm/s |
44 | s32 Heading; // 1e-05 deg Heading 2-D (curent flight direction) |
41 | s32 Heading; // 1e-05 deg Heading 2-D (curent flight direction) |
45 | u32 Speed_Accuracy; // in cm/s 3d velocity accuracy |
42 | u32 Speed_Accuracy; // in cm/s 3d velocity accuracy |
46 | Status_t Status; // status of data |
43 | u8 Status; // status of data |
47 | } __attribute__((packed)) gps_data_t; |
44 | } __attribute__((packed)) gps_data_t; |
Line 48... | Line 45... | ||
48 | 45 | ||
49 | // The data are valid if the GPSData.Status is NEWDATA or PROCESSED. |
46 | // The data are valid if the GPSData.Status is NEWDATA or PROCESSED. |
50 | // To achieve new data after reading the GPSData.Status should be set to PROCESSED. |
47 | // To achieve new data after reading the GPSData.Status should be set to PROCESSED. |