2 * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 * @file MDev_Gps_Mtrx.cpp
20 /*---------------------------------------------------------------------------*/
22 #include "MDev_Gps_Mtrx.h"
23 #include "positioning_def.h"
25 #include "MDev_Gps_Main.h"
26 #include "MDev_Gps_API.h"
27 #include "MDev_GpsRecv.h"
28 #include "MDev_Gps_Common.h"
29 #include "MDev_Gps_Nmea.h"
30 #include "MDev_Gps_TimerCtrl.h"
32 extern uint8_t g_gps_reset_cmd_sending;
33 /*---------------------------------------------------------------------------*/
36 /********************************************************************************
37 * MODULE : DEV_Gps_Nop
38 * ABSTRACT : No processing
39 * FUNCTION : NOP processing of the matrix
43 ********************************************************************************/
44 void DevGpsNop(void) {
48 /********************************************************************************
49 * MODULE : DEV_Gps_InitStart_SendReq
50 * ABSTRACT : Startup confirmation - Transmit request reception matrix function
55 ********************************************************************************/
56 void DevGpsInitStartSendReq(void) {
57 /** Send Request Receive Common Processing Call */
63 /********************************************************************************
64 * MODULE : DEV_Gps_InitStart_GPSResetReq
65 * ABSTRACT : Startup confirmation - GPS reset request reception matrix function
70 ********************************************************************************/
71 void DevGpsInitStartGPSResetReq(void) {
72 /** Reset request reception common processing call */
73 GPSResetReqGpsCommon();
77 /********************************************************************************
78 * MODULE : DEV_Gps_InitStart_RcvCyclCmd
79 * ABSTRACT : Startup confirmation - Cyclic receive command receive matrix function
84 ********************************************************************************/
85 void DevGpsInitStartRcvCyclCmd(void) {
86 BOOL* pb_rcverr = &(g_gps_mngr.rcv_err_flag); /* GSP receiver error detection status */
88 /* Stop start confirmation monitoring timer */
89 (void)DevGpsTimeStop(GPS_STARTUP_TIMER); /* Ignore -> MISRA-C:2004 Rule 16.10 */ /* QAC 3200 */
91 /* GPS receiver anomaly detection timer stopped */
92 (void)DevGpsTimeStop(GPS_RECEIVERERR_TIMER);
94 /* State transition processing(in operation) */
95 ChangeStatusGpsCommon(GPS_STS_NORMAL);
97 // Send NAV-TIMEUTC sentence addition requests
98 DevGpsNavTimeUTCAddReq();
100 DevGpsWknRolloverGetReq();
102 /* Receive command analysis(u-blox) */
103 if (g_gps_reset_cmd_sending == FALSE) {
107 /* If a GPS receiver error is detected, the diagnosis code (current) is deleted. */
108 if (*pb_rcverr == TRUE) {
110 DevSendGpsConnectError(FALSE);
113 /* Reset retry counter */
116 /* Sending pending commands */
117 SendSaveCmdGpsCommon(); /* State transition if pending commands exist( -> Sending) */
119 /* Cyclic reception data monitoring timer setting */
120 (void)DevGpsTimeSet(GPS_CYCL_TIMER); /* Ignore -> MISRA-C:2004 Rule 16.10 */ /* QAC 3200 */
122 /* GPS receiver anomaly detection timer setting */
123 (void)DevGpsTimeSet(GPS_RECEIVERERR_TIMER);
129 /********************************************************************************
130 * MODULE : DEV_Gps_InitStart_CyclDataTimeOut
131 * ABSTRACT : Startup confirmation - Reception cycle data monitoring timeout matrix function
136 ********************************************************************************/
137 void DevGpsInitStartCyclDataTimeOut(void) {
138 uint8_t ret = RETRY_OFF;
140 POSITIONING_LOG("DEV_Gps_InitStart_CyclDataTimeOut");
142 g_wcnct_err++; /* Count number of connection errors */
144 /* Stop all timers */
145 DevGpsTimeStop(GPS_STARTUP_TIMER);
147 DevGpsTimeStop(GPS_CYCL_TIMER);
149 DevGpsTimeStop(GPS_RECV_ACK_TIMER);
151 /* Hard reset judgment processing */
152 ret = HardResetChkGpsCommon();
153 if (RETRY_ON == ret) {
154 DevGpsResetReq(PNO_NONE, 0);
156 SendSaveCmdGpsCommon(); /* State transition if pending commands exist( -> Sending) */
157 } else if (RETRY_OFF == ret) {
158 /* Fixed number of hard resets completed */
160 /* Retrying(with hard reset) */
162 /* Clear cyclic receive data up to now */
163 DevGpsCycleDataClear();
164 /* Start confirmation monitoring timer setting */
165 DevGpsTimeSet(GPS_STARTUP_TIMER);
169 /******************************************************************************
170 @brief DEV_Gps_InitStart_NaviDataTimeOut<BR>
171 Startup confirmation - Navigation providing data monitoring timeout matrix function
172 @outline Navigation providing data monitoring timeout matrix processing during startup confirmation
177 *******************************************************************************/
178 void DevGpsInitStartNaviDataTimeOut(void) {
181 /******************************************************************************
182 @brief DEV_Gps_InitStart_DiagClkGuardTimeOut<BR>
183 Startup confirmation - Time guard monitoring timeout matrix functions provided by diagnosis
184 @outline Diagnosis provision time guard monitoring timeout matrix process during startup checking
189 *******************************************************************************/
190 void DevGpsInitStartDiagClkGuardTimeOut(void) {
193 /********************************************************************************
194 * MODULE : DEV_Gps_InitStart_AccOffStart
195 * ABSTRACT : Startup confirmation - Feature ACC-OFF instruction matrix functions
200 ********************************************************************************/
201 void DevGpsInitStartAccOffStart(void) {
204 /******************************************************************************
205 @brief DEV_Gps_InitStart_NaviInfoDeliver<BR>
206 Startup confirmation - Navigation information provision matrix processing
207 @outline Navigation information provision matrix processing during startup confirmation
212 *******************************************************************************/
213 void DevGpsInitStartNaviInfoDeliver(void) {
216 /******************************************************************************
217 @brief DEV_Gps_InitStart_NaviSpeedDeliver<BR>
218 Startup confirmation - Navigation vehicle speed information provision matrix processing
219 @outline Navigation speed information provision matrix processing during startup confirmation
224 *******************************************************************************/
225 void DevGpsInitStartNaviSpeedDeliver(void) {
228 /******************************************************************************
229 @brief DEV_Gps_InitStart_SettingTime<BR>
230 Startup confirmation - GPS time setting matrix processing
231 @outline GPS time setting matrix process during startup confirmation
236 *******************************************************************************/
237 void DevGpsInitStartSettingTime(void) {
238 POSITIONING_LOG("DEV_Gps_InitStart_SettingTime\n");
239 DevGpsCommSettingTime();
243 /* start #GPF_60_109 */
244 /******************************************************************************
245 @brief DEV_Gps_InitStart_NmeaDataGuardTimeOut<BR>
246 Startup confirmation - NMEA monitoring timeout matrix processing
247 @outline NMEA data-providing guard monitoring timeout process during startup checking
252 *******************************************************************************/
253 void DevGpsInitStartNmeaDataGuardTimeOut(void) {
258 * Startup confirmation - Backup memory read request matrix processing
260 void DevGpsInitStartBackupDataLoadReq(void) {
261 POS_DATETIME st_date_time;
262 memset(&st_date_time, 0x00, sizeof(st_date_time));
263 /* Import GPS date and time settings */
264 DevGpsReadGpsTime(&st_date_time);
265 // Todo For Test don't need gstGpsFixCnt??
266 // DEV_Gps_ReadGpsFixCnt(); /* Read GPS fix count */
267 if (g_is_gpstime_sts == TRUE) {
268 DevGpsSettingTime(&st_date_time); /* Time setting */
275 * Startup confirmation - Thread stop request matrix processing
277 void DevGpsInitStartStopReq(void) {
278 /* Thread stop processing */
279 StopThreadGpsCommon();
286 * Startup confirmation - GPS week adjustment counter notification process
288 void DevGpsInitStartGpsweekcorcntNtf(void) {
289 DevGpsSetGpsweekcorcnt();
295 * Startup confirmation - GPS recovery timeout process
297 void DevGpsInitStartRecoveryTimeOut(void) {
303 * Startup confirmation - GPS receiver anomaly detection timeout processing
305 void DevGpsInitStartGpsReceiverErrTimeOut(void) {
306 BOOL* pb_rcverr = &(g_gps_mngr.rcv_err_flag); /* GSP receiver error detection status */
309 DevSendGpsConnectError(TRUE);
313 /********************************************************************************
314 * MODULE : DEV_Gps_Normal_SendReq
315 * ABSTRACT : In operation - Transmit request reception matrix function
320 ********************************************************************************/
321 void DevGpsNormalSendReq(void) {
322 /** Store in a pending buffer #GPF_60_040 */
325 /** Send the command #GPF_60_040 */
326 SendSaveCmdGpsCommon();
330 /********************************************************************************
331 * MODULE : DEV_Gps_Normal_GPSResetReq
332 * ABSTRACT : In operation - GPS reset request reception matrix function
337 ********************************************************************************/
338 void DevGpsNormalGPSResetReq(void) {
339 /** Store in a pending buffer #GPF_60_040 */
340 GPSResetReqGpsCommon();
342 /** Send the command #GPF_60_040 */
343 SendSaveCmdGpsCommon();
347 /********************************************************************************
348 * MODULE : DEV_Gps_Normal_RcvCyclCmd_Nmea
349 * ABSTRACT : In operation - Cyclic receive command receive matrix function
354 ********************************************************************************/
355 void DevGpsNormalRcvCyclCmd(void) {
356 /* Cyclic reception data monitoring timer stopped */
357 (void)DevGpsTimeStop(GPS_CYCL_TIMER);
358 /* GPS receiver anomaly detection timer stopped */
359 (void)DevGpsTimeStop(GPS_RECEIVERERR_TIMER);
361 /* Notify Vehicle Sensor */
362 if (g_gps_reset_cmd_sending == FALSE) {
366 /* Reset retry counter */
369 /* Cyclic reception data monitoring timer setting */
370 (void)DevGpsTimeSet(GPS_CYCL_TIMER); /* Ignore -> MISRA-C:2004 Rule 16.10 */ /* QAC 3200 */
372 /* GPS receiver anomaly detection timer setting */
373 (void)DevGpsTimeSet(GPS_RECEIVERERR_TIMER);
378 /********************************************************************************
379 * MODULE : DEV_Gps_Normal_CyclDataTimeOut
380 * ABSTRACT : In operation - Reception cycle data monitoring timeout matrix function
385 ********************************************************************************/
386 void DevGpsNormalCyclDataTimeOut(void) {
387 /* Cyclic reception timeout common processing call */
388 CyclDataTimeOutGpsCommon();
391 /******************************************************************************
392 @brief DEV_Gps_Normal_NaviDataTimeOut<BR>
393 In operation - Navigation providing data monitoring timeout matrix function
394 @outline Navigation providing data monitoring timeout matrix processing during operation
399 *******************************************************************************/
400 void DevGpsNormalNaviDataTimeOut(void) {
403 /******************************************************************************
404 @brief DEV_Gps_Normal_DiagClkGuardTimeOut<BR>
405 In operation - Time guard monitoring timeout matrix functions provided by diagnosis
406 @outline Diagnosis provision time guard monitoring timeout matrix process during operation
411 *******************************************************************************/
412 void DevGpsNormalDiagClkGuardTimeOut(void) {
415 /********************************************************************************
416 * MODULE : DEV_Gps_Normal_AccOffStart
417 * ABSTRACT : Startup confirmation - Feature ACC-OFF instruction matrix functions
422 ********************************************************************************/
423 void DevGpsNormalAccOffStart(void) {
426 /******************************************************************************
427 @brief DEV_Gps_Normal_NaviInfoDeliver<BR>
428 In operation - Navigation information provision matrix processing
429 @outline Navigation information provision matrix processing during operation
434 *******************************************************************************/
435 void DevGpsNormalNaviInfoDeliver(void) {
438 /******************************************************************************
439 @brief DEV_Gps_Normal_NaviSpeedDeliver<BR>
440 In operation - Navigation vehicle speed information provision matrix processing
441 @outline Navigation vehicle speed information provision matrix processing during operation
446 *******************************************************************************/
447 void DevGpsNormalNaviSpeedDeliver(void) {
450 /******************************************************************************
451 @brief DEV_Gps_Normal_SettingTime<BR>
452 In operation - GPS time setting matrix processing
453 @outline GPS time setting matrix processing during operation
458 *******************************************************************************/
459 void DevGpsNormalSettingTime(void) {
460 POSITIONING_LOG("DEV_Gps_Normal_SettingTime");
461 DevGpsCommSettingTime();
462 /** Send the command */
463 SendSaveCmdGpsCommon();
468 /* start #GPF_60_109 */
469 /******************************************************************************
470 @brief DEV_Gps_Normal_NmeaDataGuardTimeOut<BR>
471 In operation - NMEA monitoring timeout matrix processing
472 @outline NMEA data-providing guard monitoring timeout process during operation
477 *******************************************************************************/
478 void DevGpsNormalNmeaDataGuardTimeOut(void) {
483 * In operation - Backup memory read request matrix processing
485 void DevGpsNormalBackupDataLoadReq(void) {
486 POS_DATETIME st_date_time;
487 memset(&st_date_time, 0x00, sizeof(st_date_time));
488 /* Import GPS date and time settings */
489 DevGpsReadGpsTime(&st_date_time);
490 // Todo For test don't need gstGpsFixCnt??
491 // DEV_Gps_ReadGpsFixCnt(); /* Read GPS fix count */
492 if (g_is_gpstime_sts == TRUE) {
493 DevGpsSettingTime(&st_date_time); /* Time setting */
500 * In operation - Thread stop request matrix processing
502 void DevGpsNormalStopReq(void) {
503 /* Thread stop processing */
504 StopThreadGpsCommon();
511 * In operation - GPS week adjustment counter notification process
513 void DevGpsNormalGpsweekcorcntNtf(void) {
514 DevGpsSetGpsweekcorcnt();
520 * In operation - GPS recovery timeout processing
522 void DevGpsNormalRecoveryTimeOut(void) {
527 * In operation - GPS receiver anomaly detection timeout processing
529 void DevGpsNormalGpsReceiverErrTimeOut(void) {
530 BOOL* pb_rcverr = &(g_gps_mngr.rcv_err_flag); /* GSP receiver error detection status */
533 DevSendGpsConnectError(TRUE);
538 /******************************************************************************
539 @brief DEV_Gps_Send_SendReq<BR>
540 Sending - Transmit request reception matrix function
541 @outline Processing for receiving a transmission request during transmission
546 *******************************************************************************/
547 void DevGpsSendSendReq(void) {
552 /******************************************************************************
553 @brief DEV_Gps_Send_GPSResetReq<BR>
554 Sending - GPS reset request reception matrix function
555 @outline Processing when receiving a GPS reset request during transmission
560 *******************************************************************************/
561 void DevGpsSendGPSResetReq(void) {
562 GPSResetReqGpsCommon();
566 /******************************************************************************
567 @brief DEV_Gps_Send_RcvCyclCmd<BR>
568 Sending - Cyclic receive command receive matrix function
569 @outline Processing at the reception of cyclic reception command during transmission
574 *******************************************************************************/
575 void DevGpsSendRcvCyclCmd(void) {
576 /* Cyclic reception data monitoring timer stopped */
577 DevGpsTimeStop(GPS_CYCL_TIMER);
579 /* GPS receiver anomaly detection timer stopped */
580 DevGpsTimeStop(GPS_RECEIVERERR_TIMER);
582 /* Notify Vehicle Sensor */
583 if (g_gps_reset_cmd_sending == FALSE) {
587 /* Reset retry counter */
590 /* Cyclic reception data monitoring timer setting */
591 (void)DevGpsTimeSet(GPS_CYCL_TIMER);
593 (void)DevGpsTimeSet(GPS_RECEIVERERR_TIMER);
598 /******************************************************************************
599 @brief DEV_Gps_Send_RcvRspCmd<BR>
600 Sending - Response command reception matrix function
601 @outline Processing when receiving a response command during transmission
606 *******************************************************************************/
607 void DevGpsSendRcvRspCmd(void) {
608 TG_GPS_OUTPUT_FORMAT rcv_cmd = g_gps_mngr.rcv_cmd;
609 BOOL b_snd_flag = TRUE;
611 /** Check whether the command matches the command being monitored. */
612 if (rcv_cmd == g_gps_mngr.resp_cmd) {
613 /** When the command being monitored is a cold start request */
614 if (g_gps_mngr.resp_rst_flag == GPS_CMD_RESET) {
615 POSITIONING_LOG("GPS_CMD_RESET\n");
616 b_snd_flag = DevGpsRcvProcGpsResetResp(reinterpret_cast<TG_GPS_RCV_DATA*>
617 (reinterpret_cast<void*>(g_gps_msg_rcvr.msgdat)));
618 } else if (g_gps_mngr.resp_rst_flag == GPS_CMD_TIMESET) {
619 POSITIONING_LOG("GPS_CMD_TIMESET\n");
620 DevGpsRcvProcTimeSetResp(reinterpret_cast<TG_GPS_RCV_DATA*>
621 (reinterpret_cast<void*>(g_gps_msg_rcvr.msgdat)));
622 } else if (g_gps_mngr.resp_rst_flag == GPS_CMD_SENTENCEADD_NAVTIMEUTC) {
623 POSITIONING_LOG("GPS_CMD_SENTENCEADD_NAVTIMEUTC\n");
624 DevGpsRcvProcNavSvinfoAddResp(reinterpret_cast<TG_GPS_RCV_DATA*>
625 (reinterpret_cast<void*>(g_gps_msg_rcvr.msgdat)));
626 } else if ( g_gps_mngr.resp_rst_flag == GPS_CMD_WKNROLLOVER ) {
627 POSITIONING_LOG("GPS_CMD_WKNROLLOVER\n");
628 DevGpsRcvProcWknRolloverGetResp(reinterpret_cast<TG_GPS_RCV_DATA*>
629 (reinterpret_cast<void*>(g_gps_msg_rcvr.msgdat)));
631 POSITIONING_LOG("g_gps_mngr.resp_rst_flag INVALID!! [resp_rst_flag = %d]", g_gps_mngr.resp_rst_flag);
634 if (b_snd_flag == TRUE) {
635 /** Stop ACK monitoring timer */
636 DevGpsTimeStop(GPS_RECV_ACK_TIMER);
637 /* State transition processing(in operation) */
638 ChangeStatusGpsCommon(GPS_STS_NORMAL);
639 /** Reset retry counter */
640 SendRtyResetGpsCommon();
641 /** Delete command from pending buffer */
642 DeleteSaveCmdGpsCommon();
643 /* Sending pending commands */
644 SendSaveCmdGpsCommon();
652 /******************************************************************************
653 @brief DEV_Gps_Send_RspDataTimeOut<BR>
654 Sending - Response monitoring timeout reception matrix function
655 @outline Processing at reception of response monitoring timeout during transmission
660 *******************************************************************************/
661 void DevGpsSendRspDataTimeOut(void) {
662 DevGpsTimeStop(GPS_RECV_ACK_TIMER);
663 /** Send retry count */
666 /** Retry judgment */
667 if (g_gps_mngr.sndcnt == SNDNG_MAX) {
668 /** At the time of retry */
669 POSITIONING_LOG("GPS Hw Reset : sndcnt[%d]", g_gps_mngr.sndcnt);
671 /** When the command being monitored is a cold start request */
672 if (g_gps_mngr.resp_rst_flag == GPS_CMD_RESET) {
673 POSITIONING_LOG("g_gps_mngr.sndcnt == SNDNG_MAX (GPS_CMD_RESET)");
674 /** Send Reset ResponseCommunication error */
675 DevGpsRstAnsSend(g_gps_mngr.resp_pno, g_gps_mngr.resp_rid, GPS_SENDNG);
676 g_gps_reset_cmd_sending = FALSE;
678 } else if (g_gps_mngr.resp_rst_flag == GPS_CMD_TIMESET) {
679 POSITIONING_LOG("g_gps_mngr.sndcnt == SNDNG_MAX (GPS_CMD_TIMESET)");
680 DevGpsTimesetAnsSend(g_gps_mngr.resp_pno, g_gps_mngr.resp_rid, GPS_SENDNG);
681 } else if (g_gps_mngr.resp_rst_flag == GPS_CMD_SENTENCEADD_NAVTIMEUTC) {
682 POSITIONING_LOG("g_gps_mngr.sndcnt == SNDNG_MAX (GPS_CMD_SENTENCEADD_NAVTIMEUTC)");
683 DevGpsNavTimeUTCAddReq(); /* Retransmission of requests to add NAV-SVINFO commands */
684 } else if (g_gps_mngr.resp_rst_flag == GPS_CMD_WKNROLLOVER) { /* GPS rollover reference date acquisition response */
685 POSITIONING_LOG("g_gps_mngr.sndcnt == SNDNG_MAX (GPS_CMD_WKNROLLOVER)");
686 DevGpsWknRolloverGetReq(); /* GPS rollover standard week number acquisition request retransmission */
688 POSITIONING_LOG("g_gps_mngr.resp_rst_flag INVALID!! [resp_rst_flag = %d]", g_gps_mngr.resp_rst_flag);
691 DeleteSaveCmdGpsCommon();
693 ChangeStatusGpsCommon(GPS_STS_NORMAL);
695 SendSaveCmdGpsCommon();
696 /** Reset retry counter */
697 SendRtyResetGpsCommon();
699 POSITIONING_LOG("GPS Send Retry : sndcnt[%d]", g_gps_mngr.sndcnt);
700 /** Retransmission of pending command */
701 SendSaveCmdGpsCommon();
707 /******************************************************************************
708 @brief DEV_Gps_Send_CyclDataTimeOut<BR>
709 Sending - Reception cycle data monitoring timeout matrix function
710 @outline Processing when receiving periodic reception data monitoring timeout during transmission
715 *******************************************************************************/
716 void DevGpsSendCyclDataTimeOut(void) {
717 CyclDataTimeOutGpsCommon();
720 /******************************************************************************
721 @brief DEV_Gps_Send_NaviDataTimeOut<BR>
722 Sending - Navigation providing data monitoring timeout matrix function
723 @outline Navigation providing data monitoring timeout matrix processing during transmission
728 *******************************************************************************/
729 void DevGpsSendNaviDataTimeOut(void) {
732 /******************************************************************************
733 @brief DEV_Gps_Send_DiagClkGuardTimeOut<BR>
734 Sending - Time guard monitoring timeout matrix functions provided by diagnosis
735 @outline Diagnosis providing time guard monitoring timeout matrix process during sending
740 *******************************************************************************/
741 void DevGpsSendDiagClkGuardTimeOut(void) {
744 /******************************************************************************
745 @brief DEV_Gps_Send_AccOffStart<BR>
746 Sending - Feature ACC-OFF instruction reception matrix functions
747 @outline Processing when receiving ACC-OFF instruction in function being transmitted
752 *******************************************************************************/
753 void DevGpsSendAccOffStart(void) {
756 /******************************************************************************
757 @brief DEV_Gps_Send_NaviInfoDeliver<BR>
758 Sending - Navigation information provision matrix processing
759 @outline Navigation information provision matrix processing during transmission
764 *******************************************************************************/
765 void DevGpsSendNaviInfoDeliver(void) {
768 /******************************************************************************
769 @brief DEV_Gps_Send_NaviSpeedDeliver<BR>
770 Sending - Navigation vehicle speed information provision matrix processing
771 @outline Navigation vehicle speed information provision matrix processing during transmission
776 *******************************************************************************/
777 void DevGpsSendNaviSpeedDeliver(void) {
780 /******************************************************************************
781 @brief DEV_Gps_Send_SettingTime<BR>
782 Sending - GPS time setting matrix processing
783 @outline GPS time setting matrix processing during transmission
788 *******************************************************************************/
789 void DevGpsSendSettingTime(void) {
790 DevGpsCommSettingTime();
794 /* start #GPF_60_109 */
795 /******************************************************************************
796 @brief DEV_Gps_Send_NmeaDataGuardTimeOut<BR>
797 Sending - NMEA monitoring timeout matrix processing
798 @outline Sending NMEA monitoring timeouts
803 *******************************************************************************/
804 void DevGpsSendNmeaDataGuardTimeOut(void) {
809 * Sending - Backup memory read request matrix processing
811 void DevGpsSendBackupDataLoadReq(void) {
812 POS_DATETIME st_date_time;
814 memset(&st_date_time, 0x00, sizeof(st_date_time));
815 /* Import GPS date and time settings */
816 DevGpsReadGpsTime(&st_date_time);
817 // Todo For test don't need gstGpsFixCnt??
818 // DEV_Gps_ReadGpsFixCnt(); /* Read GPS fix count */
819 if (g_is_gpstime_sts == TRUE) {
820 DevGpsSettingTime(&st_date_time); /* Time setting */
828 * Sending - Thread stop request matrix processing
830 void DevGpsSendStopReq(void) {
831 /* Thread stop processing */
832 StopThreadGpsCommon();
838 * Sending - GPS week adjustment counter notification process
840 void DevGpsSendGpsweekcorcntNtf(void) {
841 DevGpsSetGpsweekcorcnt();
847 * Sending - GPS recovery timeout processing
849 void DevGpsSendRecoveryTimeOut(void) {
855 * Sending - GPS receiver anomaly detection timeout processing
857 void DevGpsSendGpsReceiverErrTimeOut(void) {
858 BOOL* pb_rcverr = &(g_gps_mngr.rcv_err_flag); /* GSP receiver error detection status */
861 DevSendGpsConnectError(TRUE);
865 /*---------------------------------------------------------------------------*/