File tree Expand file tree Collapse file tree 3 files changed +27
-31
lines changed
Expand file tree Collapse file tree 3 files changed +27
-31
lines changed Original file line number Diff line number Diff line change @@ -229,5 +229,7 @@ const char * sempNmeaGetStateName(const SEMP_PARSE_STATE *parse)
229229 return " sempNmeaChecksumByte2" ;
230230 if (parse->state == sempNmeaLineTermination)
231231 return " sempNmeaLineTermination" ;
232+ if (parse->state == sempNmeaHashPreamble)
233+ return " sempNmeaHashPreamble" ;
232234 return nullptr ;
233235}
Original file line number Diff line number Diff line change @@ -15,37 +15,6 @@ should need to be listed in SparkFun_Extensible_Message_Parser.h.
1515#include " SparkFun_Extensible_Message_Parser.h"
1616#include " semp_crc32.h"
1717
18- // ----------------------------------------
19- // Constants
20- // ----------------------------------------
21-
22- #define UNICORE_HEADER_LENGTH ((uint16_t )24 )
23- #define UNICORE_OFFSET_HEADER_MESSAGE_LENGTH ((uint16_t )6 )
24-
25- // ----------------------------------------
26- // Structure definitions
27- // ----------------------------------------
28-
29- typedef struct _SEMP_UNICORE_HEADER
30- {
31- uint8_t syncA; // 0xaa
32- uint8_t syncB; // 0x44
33- uint8_t syncC; // 0xb5
34- uint8_t cpuIdlePercent; // CPU Idle Percentage 0-100
35- uint16_t messageId; // Message ID
36- uint16_t messageLength; // Message Length
37- uint8_t referenceTime; // Reference time(GPST or BDST)
38- uint8_t timeStatus; // Time status
39- uint16_t weekNumber; // Reference week number
40- uint32_t secondsOfWeek; // GPS seconds from the beginning of the
41- // reference week, accurate to the millisecond
42- uint32_t RESERVED;
43-
44- uint8_t releasedVersion; // Release version
45- uint8_t leapSeconds; // Leap sec
46- uint16_t outputDelayMSec; // Output delay time, ms
47- } SEMP_UNICORE_HEADER;
48-
4918// ----------------------------------------
5019// Support routines
5120// ----------------------------------------
Original file line number Diff line number Diff line change @@ -115,6 +115,31 @@ typedef struct _SEMP_PARSE_STATE
115115 // parserCount means searching for preamble
116116} SEMP_PARSE_STATE ;
117117
118+ //----------------------------------------
119+ // Protocol specific types
120+ //----------------------------------------
121+
122+ // Define the Unicore message header
123+ typedef struct _SEMP_UNICORE_HEADER
124+ {
125+ uint8_t syncA ; // 0xaa
126+ uint8_t syncB ; // 0x44
127+ uint8_t syncC ; // 0xb5
128+ uint8_t cpuIdlePercent ; // CPU Idle Percentage 0-100
129+ uint16_t messageId ; // Message ID
130+ uint16_t messageLength ; // Message Length
131+ uint8_t referenceTime ; // Reference time(GPST or BDST)
132+ uint8_t timeStatus ; // Time status
133+ uint16_t weekNumber ; // Reference week number
134+ uint32_t secondsOfWeek ; // GPS seconds from the beginning of the
135+ // reference week, accurate to the millisecond
136+ uint32_t RESERVED ;
137+
138+ uint8_t releasedVersion ; // Release version
139+ uint8_t leapSeconds ; // Leap sec
140+ uint16_t outputDelayMSec ; // Output delay time, ms
141+ } SEMP_UNICORE_HEADER ;
142+
118143//----------------------------------------
119144// Support routines
120145//----------------------------------------
You can’t perform that action at this time.
0 commit comments