Rev 734 | Rev 762 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 734 | Rev 761 | ||
---|---|---|---|
Line 36... | Line 36... | ||
36 | typedef struct { |
36 | typedef struct { |
37 | uint8_t Digital[2]; |
37 | uint8_t Digital[2]; |
38 | uint16_t Analog[32]; // Debugvalues |
38 | uint16_t Analog[32]; // Debugvalues |
39 | } __attribute__((packed)) DebugOut_t; |
39 | } __attribute__((packed)) DebugOut_t; |
Line 40... | Line -... | ||
40 | - | ||
41 | 40 | ||
42 | typedef struct { |
41 | typedef struct { |
43 | unsigned char SWMajor; |
42 | unsigned char SWMajor; |
44 | unsigned char SWMinor; |
43 | unsigned char SWMinor; |
45 | unsigned char ProtoMajor; |
44 | unsigned char ProtoMajor; |
46 | unsigned char ProtoMinor; |
45 | unsigned char ProtoMinor; |
47 | unsigned char SWPatch; |
46 | unsigned char SWPatch; |
48 | unsigned char Reserved[5]; |
47 | unsigned char Reserved[5]; |
Line 49... | Line -... | ||
49 | } str_VersionInfo; |
- | |
50 | 48 | } str_VersionInfo; |
|
51 | 49 | ||
52 | /* |
50 | /* |
53 | * NaviCtrl OSD Structs |
51 | * NaviCtrl OSD Structs |
54 | * portions taken and adapted from |
52 | * portions taken and adapted from |
55 | * http://svn.mikrokopter.de/mikrowebsvn/filedetails.php?repname=NaviCtrl&path=%2Ftags%2FV0.18c%2Fuart1.h |
53 | * http://svn.mikrokopter.de/mikrowebsvn/filedetails.php?repname=NaviCtrl&path=%2Ftags%2FV0.18c%2Fuart1.h |
56 | */ |
54 | */ |
57 | typedef struct { |
55 | typedef struct { |
58 | s32 Longitude; // in 1E-7 deg |
56 | s32 Longitude; // in 1E-7 deg |
59 | s32 Latitude; // in 1E-7 deg |
57 | s32 Latitude; // in 1E-7 deg |
60 | s32 Altitude; // in mm |
58 | s32 Altitude; // in mm |
61 | u8 Status; // validity of data |
59 | u8 Status; // validity of data |
62 | } __attribute__((packed)) GPS_Pos_t; |
60 | } __attribute__((packed)) GPS_Pos_t; |
63 | #define INVALID 0x00 |
61 | #define INVALID 0x00 |
Line 64... | Line -... | ||
64 | #define NEWDATA 0x01 |
- | |
- | 62 | #define NEWDATA 0x01 |
|
65 | #define PROCESSED 0x02 |
63 | #define PROCESSED 0x02 |
66 | 64 | ||
67 | 65 | typedef struct { |
|
Line 68... | Line 66... | ||
68 | typedef struct { |
66 | u16 Distance; // distance to target in cm |
69 | u16 Distance; // distance to target in cm |
67 | s16 Bearing; // course to target in deg |
70 | s16 Bearing; // course to target in deg |
68 | } __attribute__((packed)) GPS_PosDev_t; |
71 | } __attribute__((packed)) GPS_PosDev_t; |
69 | |
72 | 70 | typedef struct { |
|
73 | typedef struct { |
71 | u8 Version; // version of the data structure |
74 | u8 Version; // version of the data structure |
72 | GPS_Pos_t CurrentPosition; // see ubx.h for details |
75 | GPS_Pos_t CurrentPosition; // see ubx.h for details |
73 | GPS_Pos_t TargetPosition; |
76 | GPS_Pos_t TargetPosition; |
74 | GPS_PosDev_t TargetPositionDeviation; |
77 | GPS_PosDev_t TargetPositionDeviation; |
75 | GPS_Pos_t HomePosition; |
78 | GPS_Pos_t HomePosition; |
76 | GPS_PosDev_t HomePositionDeviation; |
79 | GPS_PosDev_t HomePositionDeviation; |
77 | u8 WaypointIndex; // index of current waypoints running from 0 to WaypointNumber-1 |
80 | u8 WaypointIndex; // index of current waypoints running from 0 to WaypointNumber-1 |
78 | u8 WaypointNumber; // number of stored waypoints |
81 | u8 WaypointNumber; // number of stored waypoints |
79 | u8 SatsInUse; // number of satellites used for position solution |
82 | u8 SatsInUse; // number of satellites used for position solution |
80 | s16 Altimeter; // hight according to air pressure |
83 | s16 Altimeter; // hight according to air pressure |
81 | s16 Variometer; // climb(+) and sink(-) rate |
84 | s16 Variometer; // climb(+) and sink(-) rate |
82 | u16 FlyingTime; // in seconds |
85 | u16 FlyingTime; // in seconds |
83 | u8 UBat; // Battery Voltage in 0.1 Volts |
86 | u8 UBat; // Battery Voltage in 0.1 Volts |
84 | u16 GroundSpeed; // speed over ground in cm/s (2D) |
87 | u16 GroundSpeed; // speed over ground in cm/s (2D) |
85 | s16 Heading; // current flight direction in � as angle to north |
88 | s16 Heading; // current flight direction in � as angle to north |
86 | s16 CompassHeading; // current compass value in � |
89 | s16 CompassHeading; // current compass value in � |
87 | s8 AngleNick; // current Nick angle in 1� |
90 | s8 AngleNick; // current Nick angle in 1� |
88 | s8 AngleRoll; // current Rick angle in 1� |
91 | s8 AngleRoll; // current Rick angle in 1� |
89 | u8 RC_Quality; // RC_Quality |
92 | u8 RC_Quality; // RC_Quality |
90 | u8 FCFlags; // Flags from FC |
93 | u8 FCFlags; // Flags from FC |
91 | u8 NCFlags; // Flags from NC |
94 | u8 NCFlags; // Flags from NC |
92 | u8 Errorcode; // 0 --> okay |
95 | u8 Errorcode; // 0 --> okay |
93 | u8 OperatingRadius; // current operation radius around the Home Position in m |
96 | u8 OperatingRadius; // current operation radius around the Home Position in m |
94 | s16 TopSpeed; // velocity in vertical direction in cm/s |
97 | s16 TopSpeed; // velocity in vertical direction in cm/s |
95 | u8 TargetHoldTime; // time in s to stay at the given target, counts down to 0 if target has been reached |
98 | u8 TargetHoldTime; // time in s to stay at the given target, counts down to 0 if target has been reached |
96 | u8 RC_RSSI; // Receiver signal strength (since version 2 added) |
99 | u8 RC_RSSI; // Receiver signal strength (since version 2 added) |
97 | s16 SetpointAltitude; // setpoint for altitude |
Line 100... | Line 98... | ||
100 | s16 SetpointAltitude; // setpoint for altitude |
98 | u8 Gas; // for future use |
101 | u8 Gas; // for future use |
99 | u16 Current; // actual current in 0.1A steps |