summaryrefslogtreecommitdiffstats
path: root/vehicleservice/positioning
diff options
context:
space:
mode:
Diffstat (limited to 'vehicleservice/positioning')
-rwxr-xr-xvehicleservice/positioning/LICENSE177
-rwxr-xr-xvehicleservice/positioning/Makefile.client20
-rwxr-xr-xvehicleservice/positioning/Makefile.server20
-rwxr-xr-xvehicleservice/positioning/client/Makefile31
-rwxr-xr-xvehicleservice/positioning/client/include/CanInput_API.h98
-rwxr-xr-xvehicleservice/positioning/client/include/CanInput_API_private.h68
-rwxr-xr-xvehicleservice/positioning/client/include/Clock_API.h258
-rwxr-xr-xvehicleservice/positioning/client/include/CommonDefine.h72
-rwxr-xr-xvehicleservice/positioning/client/include/DR_API.h148
-rwxr-xr-xvehicleservice/positioning/client/include/DeadReckoning_DbgLogSim.h50
-rwxr-xr-xvehicleservice/positioning/client/include/Dead_Reckoning_API.h229
-rwxr-xr-xvehicleservice/positioning/client/include/Dead_Reckoning_Local_Api.h147
-rwxr-xr-xvehicleservice/positioning/client/include/Gps_API_private.h64
-rwxr-xr-xvehicleservice/positioning/client/include/INI_API.h259
-rwxr-xr-xvehicleservice/positioning/client/include/Naviinfo_API.h110
-rwxr-xr-xvehicleservice/positioning/client/include/POS_common_private.h62
-rwxr-xr-xvehicleservice/positioning/client/include/POS_private.h981
-rwxr-xr-xvehicleservice/positioning/client/include/POS_sensor_private.h163
-rwxr-xr-xvehicleservice/positioning/client/include/SensorLocation_API.h124
-rwxr-xr-xvehicleservice/positioning/client/include/SensorLocation_API_private.h39
-rwxr-xr-xvehicleservice/positioning/client/include/SensorMotion_API.h178
-rwxr-xr-xvehicleservice/positioning/client/include/Sensor_API.h36
-rwxr-xr-xvehicleservice/positioning/client/include/Sensor_API_private.h174
-rwxr-xr-xvehicleservice/positioning/client/include/Sensor_Common_API.h193
-rwxr-xr-xvehicleservice/positioning/client/include/VehicleDebug_API.h110
-rwxr-xr-xvehicleservice/positioning/client/include/Vehicle_API.h115
-rwxr-xr-xvehicleservice/positioning/client/include/Vehicle_API_Dummy.h142
-rwxr-xr-xvehicleservice/positioning/client/include/Vehicle_API_private.h129
-rwxr-xr-xvehicleservice/positioning/client/include/vehicle_service/POS_common_API.h1663
-rwxr-xr-xvehicleservice/positioning/client/include/vehicle_service/POS_define.h134
-rwxr-xr-xvehicleservice/positioning/client/include/vehicle_service/POS_gps_API.h1135
-rwxr-xr-xvehicleservice/positioning/client/include/vehicle_service/POS_sensor_API.h716
-rwxr-xr-xvehicleservice/positioning/client/include/vehicle_service/positioning.h46
-rwxr-xr-xvehicleservice/positioning/client/src/POS_common_API/Common_API.cpp889
-rwxr-xr-xvehicleservice/positioning/client/src/POS_common_API/Makefile47
-rwxr-xr-xvehicleservice/positioning/client/src/POS_common_API/libPOS_common_API.ver37
-rwxr-xr-xvehicleservice/positioning/client/src/POS_gps_API/Gps_API.cpp456
-rwxr-xr-xvehicleservice/positioning/client/src/POS_gps_API/Makefile51
-rwxr-xr-xvehicleservice/positioning/client/src/POS_gps_API/Naviinfo_API.cpp404
-rwxr-xr-xvehicleservice/positioning/client/src/POS_gps_API/libPOS_gps_API.ver34
-rwxr-xr-xvehicleservice/positioning/client/src/POS_sensor_API/Makefile48
-rwxr-xr-xvehicleservice/positioning/client/src/POS_sensor_API/Sensor_API.cpp784
-rwxr-xr-xvehicleservice/positioning/client/src/POS_sensor_API/Vehicle_API.cpp292
-rwxr-xr-xvehicleservice/positioning/client/src/POS_sensor_API/libPOS_sensor_API.ver32
-rwxr-xr-xvehicleservice/positioning/server/Makefile22
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/ClockDataMng.h100
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/ClockGPS_Process_Proto.h37
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/ClockUtility.h46
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/ClockUtility_private.h49
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/DeadReckoning_Common.h84
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/DeadReckoning_DataMaster.h127
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/DeadReckoning_DeliveryCtrl.h137
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/DeadReckoning_main.h146
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/GpsInt.h68
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/SensorLog.h114
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/VehicleSens_Common.h131
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/VehicleSens_DataMaster.h1091
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/VehicleSens_DeliveryCtrl.h253
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/VehicleSens_FromAccess.h69
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/VehicleSens_SelectionItemList.h116
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/VehicleSens_SharedMemory.h48
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/VehicleSens_Thread.h185
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/VehicleSensor_Thread.h33
-rwxr-xr-xvehicleservice/positioning/server/include/Sensor/VehicleUtility.h128
-rwxr-xr-xvehicleservice/positioning/server/include/ServiceInterface/BackupMgrIf.h65
-rwxr-xr-xvehicleservice/positioning/server/include/ServiceInterface/ClockIf.h61
-rwxr-xr-xvehicleservice/positioning/server/include/ServiceInterface/CommUsbIf.h64
-rwxr-xr-xvehicleservice/positioning/server/include/ServiceInterface/DevDetectSrvIf.h69
-rwxr-xr-xvehicleservice/positioning/server/include/ServiceInterface/DiagSrvIf.h55
-rwxr-xr-xvehicleservice/positioning/server/include/ServiceInterface/PSMShadowIf.h58
-rwxr-xr-xvehicleservice/positioning/server/include/ServiceInterface/VehicleIf.h82
-rwxr-xr-xvehicleservice/positioning/server/include/ServiceInterface/ps_psmshadow_notifications.h62
-rwxr-xr-xvehicleservice/positioning/server/include/ServiceInterface/ps_version.h45
-rwxr-xr-xvehicleservice/positioning/server/include/nsfw/positioning_common.h90
-rwxr-xr-xvehicleservice/positioning/server/include/nsfw/vehicle_version.h29
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/ClockUtility.cpp414
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Common.cpp127
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_DataMasterMain.cpp298
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_DeliveryCtrl.cpp835
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Altitude_dr.cpp106
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroOffset_dr.cpp115
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroScaleFactorLevel_dr.cpp115
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroScaleFactor_dr.cpp115
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Heading_dr.cpp106
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Latitude_dr.cpp105
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Longitude_dr.cpp105
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SnsCounter.cpp103
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SpeedPulseScaleFactorLevel_dr.cpp116
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SpeedPulseScaleFactor_dr.cpp115
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Speed_dr.cpp105
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/DeadReckoning_main.cpp1086
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/GpsInt.cpp171
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/Makefile181
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/SensorLog.cpp1307
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_CanDeliveryEntry.cpp47
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Common.cpp429
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_DataMasterMain.cpp1880
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_DeliveryCtrl.cpp2243
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GPSInterruptFlag.cpp105
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntenna.cpp58
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntennaStatus.cpp112
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntenna_l.cpp97
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockDrift.cpp51
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockDrift_g.cpp102
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockFreq.cpp51
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockFreq_g.cpp102
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsCounter_g.cpp98
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsNmea_g.cpp89
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTime.cpp53
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTimeRaw.cpp51
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTimeRaw_g.cpp107
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTime_g.cpp102
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82_FullBinary_g.cpp99
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82_Nmea_g.cpp102
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82__CWORD44_Gp4_g.cpp101
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsX.cpp119
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsXExt_l.cpp145
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsXFst_l.cpp127
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsX_l.cpp98
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsY.cpp121
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsYExt_l.cpp145
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsYFst_l.cpp128
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsY_l.cpp99
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZ.cpp116
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZExt_l.cpp142
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZFst_l.cpp127
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZ_l.cpp97
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroConnectStatus.cpp110
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroExt_l.cpp257
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTemp.cpp114
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTempExt_l.cpp140
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTempFst_l.cpp128
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTemp_l.cpp95
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTrouble.cpp121
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroX.cpp145
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroXFst_l.cpp176
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroX_l.cpp128
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroY.cpp113
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroYExt_l.cpp148
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroYFst_l.cpp169
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroY_l.cpp126
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZ.cpp113
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZExt_l.cpp148
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZFst_l.cpp169
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZ_l.cpp126
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude.cpp55
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude_g.cpp105
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude_n.cpp121
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationInfoNmea.cpp50
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationInfoNmea_n.cpp118
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat.cpp56
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat_g.cpp104
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat_n.cpp163
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MainGpsInterruptSignal.cpp132
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Mon_Hw_g.cpp104
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading.cpp55
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading_g.cpp105
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading_n.cpp162
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed.cpp57
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_g.cpp107
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_i.cpp103
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_n.cpp103
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Clock_g.cpp104
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Dop_g.cpp104
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Posllh_g.cpp104
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Status_g.cpp104
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_SvInfo_g.cpp108
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_TimeGps_g.cpp104
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_TimeUtc_g.cpp104
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Velned_g.cpp104
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_NaviinfoDiagGPS_g.cpp94
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTime.cpp115
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTimeExt_l.cpp143
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTime_l.cpp93
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Rev.cpp118
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_RevExt_l.cpp134
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_RevFst_l.cpp171
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Rev_l.cpp157
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SettingTime.cpp58
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SettingTime_clock.cpp116
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounter.cpp90
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounterExt_l.cpp155
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounter_l.cpp124
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedKmph.cpp57
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedKmph_l.cpp156
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulse.cpp117
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseExt_l.cpp150
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFlag.cpp133
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFlagFst_l.cpp91
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFst_l.cpp172
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulse_l.cpp128
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SysGpsInterruptSignal.cpp132
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_WknRollover.cpp51
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Did_WknRollover_g.cpp102
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_FromAccess.cpp319
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_SelectionItemList.cpp466
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_SharedMemory.cpp521
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleSens_Thread.cpp2144
-rwxr-xr-xvehicleservice/positioning/server/src/Sensor/VehicleUtility.cpp455
-rwxr-xr-xvehicleservice/positioning/server/src/ServiceInterface/BackupMgrIf.cpp211
-rwxr-xr-xvehicleservice/positioning/server/src/ServiceInterface/ClockIf.cpp138
-rwxr-xr-xvehicleservice/positioning/server/src/ServiceInterface/CommUsbIf.cpp147
-rwxr-xr-xvehicleservice/positioning/server/src/ServiceInterface/DevDetectSrvIf.cpp279
-rwxr-xr-xvehicleservice/positioning/server/src/ServiceInterface/DiagSrvIf.cpp64
-rwxr-xr-xvehicleservice/positioning/server/src/ServiceInterface/Makefile54
-rwxr-xr-xvehicleservice/positioning/server/src/ServiceInterface/PSMShadowIf.cpp102
-rwxr-xr-xvehicleservice/positioning/server/src/ServiceInterface/VehicleIf.cpp364
-rwxr-xr-xvehicleservice/positioning/server/src/nsfw/Makefile89
-rwxr-xr-xvehicleservice/positioning/server/src/nsfw/positioning_application.cpp2593
-rwxr-xr-xvehicleservice/positioning/server/src/nsfw/ps_main.cpp59
210 files changed, 0 insertions, 43721 deletions
diff --git a/vehicleservice/positioning/LICENSE b/vehicleservice/positioning/LICENSE
deleted file mode 100755
index f433b1a..0000000
--- a/vehicleservice/positioning/LICENSE
+++ /dev/null
@@ -1,177 +0,0 @@
-
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
diff --git a/vehicleservice/positioning/Makefile.client b/vehicleservice/positioning/Makefile.client
deleted file mode 100755
index 7236c74..0000000
--- a/vehicleservice/positioning/Makefile.client
+++ /dev/null
@@ -1,20 +0,0 @@
-#
-# @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-######### subdirectories #########
-SUBDIRS += client
-
-include ../vehicle_service.mk
diff --git a/vehicleservice/positioning/Makefile.server b/vehicleservice/positioning/Makefile.server
deleted file mode 100755
index d0fda9c..0000000
--- a/vehicleservice/positioning/Makefile.server
+++ /dev/null
@@ -1,20 +0,0 @@
-#
-# @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-######### subdirectories #########
-SUBDIRS += server
-
-include ../vehicle_service.mk
diff --git a/vehicleservice/positioning/client/Makefile b/vehicleservice/positioning/client/Makefile
deleted file mode 100755
index d7fce28..0000000
--- a/vehicleservice/positioning/client/Makefile
+++ /dev/null
@@ -1,31 +0,0 @@
-#
-# @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-######### installed header #########
-VPATH = ./include/$(COMPONENT_NAME)
-
-INST_HEADERS += POS_define.h
-INST_HEADERS += POS_sensor_API.h
-INST_HEADERS += POS_gps_API.h
-INST_HEADERS += POS_common_API.h
-INST_HEADERS += positioning.h
-
-######### subdirectories #########
-SUBDIRS += src/POS_common_API
-SUBDIRS += src/POS_gps_API
-SUBDIRS += src/POS_sensor_API
-
-include ../../vehicle_service.mk
diff --git a/vehicleservice/positioning/client/include/CanInput_API.h b/vehicleservice/positioning/client/include/CanInput_API.h
deleted file mode 100755
index 1449b25..0000000
--- a/vehicleservice/positioning/client/include/CanInput_API.h
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/******************************************************************************
- * File name : CanInput_API.h
- * System name : PastModel002
- * Sub System name : CanInput_API library
- ******************************************************************************/
-#ifndef POSITIONING_CLIENT_INCLUDE_CANINPUT_API_H_
-#define POSITIONING_CLIENT_INCLUDE_CANINPUT_API_H_
-
-/************************************************************************
- * Include *
- ***********************************************************************/
-#include <vehicle_service/positioning_base_library.h> /* for type definitions */
-
-/************************************************************************
-* Definition *
-************************************************************************/
-/*----------------------------------------------------------------------*
- * CAN_INPUT_RET_API Definition *
- *----------------------------------------------------------------------*/
-/* Normal */
-#define CAN_INPUT_RET_NORMAL 0 /* Successful completion */
-
-/* Abnormal */
-#define CAN_INPUT_RET_ERROR (-1) /* An error has occurred */
-#define CAN_INPUT_RET_ERROR_PARAM (-2) /* Parameter error */
-
-/*----------------------------------------------------------------------*
- * Message Definition *
- *----------------------------------------------------------------------*/
-/* Command ID */
-#define CANINPUT_CID_LOCALTIME_NOTIFICATION 0x0220
-
-/*----------------------------------------------------------------------*
- * Localtime status Definition *
- *----------------------------------------------------------------------*/
-#define CANINPUT_LOCALTIME_STATUS_INVALID 0U
-#define CANINPUT_LOCALTIME_STATUS_INIT 1U
-#define CANINPUT_LOCALTIME_STATUS_PLAUSIBLE 2U
-#define CANINPUT_LOCALTIME_STATUS_NEW 3U
-#define CANINPUT_LOCALTIME_STATUS_DIAG 4U
-#define CANINPUT_LOCALTIME_STATUS_INCOMPLETE 5U
-
-/************************************************************************
-* type Definition *
-************************************************************************/
-typedef RET_API CAN_INPUT_RET_API; /* API return value */
-
-/************************************************************************
-* struct Definition *
-************************************************************************/
-/************************************************************************
- * TAG : CANINPUT_MSG_LOCALTIMEINFO_DAT
- * ABSTRACT : Localtime data structure
- * NOTE :
- ************************************************************************/
-typedef struct {
- u_int8 status; /* status : Refer to Localtime status Definition */
- u_int8 year; /* year : 0..99 (FFh:invalid) */
- u_int8 month; /* month : 1..12 (FFh:invalid) */
- u_int8 date; /* date : 1..31 (FFh:invalid) */
- u_int8 hour; /* hour : 0..23 (FFh:invalid) */
- u_int8 minute; /* minute : 0..59 (FFh:invalid) */
- u_int8 second; /* second : 0..59 (FFh:invalid) */
- u_int8 reserve; /* reserve */
-} CANINPUT_MSG_LOCALTIMEINFO_DAT;
-
-/************************************************************************
- * Function prototypes *
- ************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*[CanInput_API Public API]*/
-CAN_INPUT_RET_API CanInputInitialize(void);
-CAN_INPUT_RET_API CanInputSndMsg(PNO pno, CID cid, u_int16 msg_len, const void *msg_data);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_CANINPUT_API_H_
diff --git a/vehicleservice/positioning/client/include/CanInput_API_private.h b/vehicleservice/positioning/client/include/CanInput_API_private.h
deleted file mode 100755
index d7c8e8e..0000000
--- a/vehicleservice/positioning/client/include/CanInput_API_private.h
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/******************************************************************************
- * File name : CanInput_API_private.h
- * System name : PastModel002
- * Sub System name : CanInput_API library
- ******************************************************************************/
-#ifndef POSITIONING_CLIENT_INCLUDE_CANINPUT_API_PRIVATE_H_
-#define POSITIONING_CLIENT_INCLUDE_CANINPUT_API_PRIVATE_H_
-
-/************************************************************************
- * Include *
- ***********************************************************************/
-
-/************************************************************************
-* Definition *
-************************************************************************/
-/*----------------------------------------------------------------------*
- * Message Definition *
- *----------------------------------------------------------------------*/
-/* Message body size (byte) */
-#define CANINPUT_MSGBUF_DSIZE 8 /* Maximum message body size */
-
-/************************************************************************
-* type Definition *
-************************************************************************/
-
-/************************************************************************
-* struct Definition *
-************************************************************************/
-/*****************************************************************************
- * TAG : CANINPUT_MSG_INFO
- * ABSTRACT : CanInput_API message structure
- * NOTE : Message structure
- *****************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- uint8_t data[CANINPUT_MSGBUF_DSIZE]; /* Message data (Localtime) */
-} CANINPUT_MSG_INFO;
-
-/************************************************************************
- * Function prototypes *
- ************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*[CanInput_API Private API]*/
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_CANINPUT_API_PRIVATE_H_
diff --git a/vehicleservice/positioning/client/include/Clock_API.h b/vehicleservice/positioning/client/include/Clock_API.h
deleted file mode 100755
index 1987999..0000000
--- a/vehicleservice/positioning/client/include/Clock_API.h
+++ /dev/null
@@ -1,258 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
-* $Header:: $
-* $Revision:: $
-*******************************************************************************/
-
-/******************************************************************************
-* File name :Clock_API.h
-* System name :_CWORD107__PND-A
-* Subsystem name :System common functions header file
-* Program name :
-* Publishing department
-****************************************************************************/
-#ifndef POSITIONING_CLIENT_INCLUDE_CLOCK_API_H_
-#define POSITIONING_CLIENT_INCLUDE_CLOCK_API_H_
-
-#include <vehicle_service/positioning_base_library.h>
-#include "CommonDefine.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*
- Macro definitions
-* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-/* For time calculation */
-#define CLOCK_TIMESTAMP_GETTIME(x) ((x) & (0x00FFFFFFU)) /* Macros that Get Time Counter Values */
-#define CLOCK_TIMESTAMP_GETFLAG(x) (((x) & (0xE0000000U)) >> (29U)) /* Macros that Get Your Own Count Values */
-#define CLOCK_TIMESTAMP_NORMAL (0U) /* Normal count */
-#define CLOCK_TIMESTAMP_INDIPENDENT (1U) /* Own count */
-
-#define CLOCK_TIMESTAMP_UNION(x, y) (((x) << (29U)) | (y)) /* Macro that combines the unique count value (x) and the time counter value (y) */
-
- /* Timestamp Shared Memory Related */
-#define TIMESTAMP_RETRY_COUNTE (10U) /* Number of time stamp retries */
-#define TIMESTAMP_RETRY_INTERVAL (10U) /* Time stamp retry interval(100[msec]) */
-
- /* Time Management Shared Memory Related */
-#define CLKMNG_RETRY_COUNTE (10U) /* Time management retries */
-#define CLKMNG_RETRY_INTERVAL (10U) /* Time Management Retry Interval(100[msec]) */
-
- /* Day of the week definition */
-#define CLKMNG_SUN (0U) /* Sunday */
-#define CLKMNG_MON (1U) /* Mondays */
-#define CLKMNG_TUE (2U) /* Tuesdays */
-#define CLKMNG_WED (3U) /* Wednesdays */
-#define CLKMNG_THU (4U) /* Thursdays */
-#define CLKMNG_FRI (5U) /* Fridays */
-#define CLKMNG_SAT (6U)
-
- /* Related to the accuracy of time */
-#define CLOCK_CORRECTED_TIME (0U) /* GPS corrected time completed */
-#define CLOCK_NOT_CORRECTED_TIME (1U) /* GPS uncorrected time */
-#define CLOCK_RTC_TIME (2U) /* GPS RTC time */
-#define CLOCK_INVALID_TIME (3U) /* GPS error time */
-
- /* Time Stamp Status Storage Data Module Related Definition */
-#define TIMESTAMPDM_NAME "TIMESTAMP_DATA" /* Name of time stamp status storage data module */
-#define TIMESTAMPDM_SEM_NAME "TIMESTAMP_SEM" /* Timestamp status storage data module semaphore name */
-
- /* Time Management Status Storage Data Module Related Definition */
-#define CLKMNG_DM_NAME "CLOCK_GPS_DATA" /* Name of time management status storage data module */
-#define CLKMNG_DM_SEM_NAME "CLOCK_GPS_SEM" /* Time management status storage data module semaphore name */
-
- /* Messaging communication */
-#define CLKMNG_MSG_BUF_SIZE (128U) /* Message communication buffer size */
-#define CLKMNG_SETTIME_MSGBODYSIZE (4U) /* Date/Time Setting Response Notification Data Size */
-#define CLKMNG_NOTIOBSERVERS_MSGSZ (4U) /* Time change notification data body size */
-#define CLKMNG_NOTIACCURACY_MSGSZ (4U) /* Change notification data body size from time accuracy */
-#define CLKMNG_NOTIOBSERVERS_ENTRY_MSGSZ (4U) /* Time change notification registration data body size */
-#define CLKMNG_NOTIACCURACY_ENTRY_MSGSZ (0U) /* Change Notification Stored Data Size from Time Accuracy */
-
- /* Semaphore Related Extensions */
-#define CLOCK_SEM_RETRY_INTERVAL (10) /* Retry interval for semaphore acquisition/release processing 10ms */
-
-/*
- Data typing
-* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-/* Time-stamped data */
-typedef struct TagTimestampData {
- u_int16 trip; /* Trip counters */
- u_int16 reserve; /* Reservation(Always 0) */
- u_int32 time; /* Time counter */
- u_int8 day; /* Number of days */
- u_int8 hour; /* Time */
- u_int8 min; /* Minutes */
- u_int8 sec; /* Second */
-} TimestampData;
-
-/* TIMESTAMP INTERNAL COUNTER MODULE STRUCTURE DEFINITION */
-typedef struct {
- u_int16 trip; /* Trip counters */
- u_int32 time; /* Time counter */
-} TIMESTAMP_CNT;
-
-/* Time management status storage area */
-typedef struct TagClockStatus {
- u_int8 status; /* GPS status */
- u_int8 hour; /* Time of final correction */
- u_int8 min; /* Minutes */
- u_int8 sec; /* Second */
-} ClockStatus;
-
-/* Status storage area for writing time management shared memory */
-typedef struct TagClkMngTimerSetTime {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- u_int8 reserve1[1]; /* (Not used) */
- u_int8 gps_timer_state; /* GPS time status */
- u_int16 year; /* Year */
- u_int8 month; /* Month */
- u_int8 day; /* Day */
- u_int8 hour; /* Hour */
- u_int8 min; /* Minutes */
- u_int8 sec; /* Second */
- u_int8 reserve2[3]; /* (Not used) */
-} CLKMNG_TIMER_SET_TIME;
-
-/* Existing sys_timerapi.h data */
-
-/* User time status */
-#define TIMEDATA_INVALID 0 /* Time invalid */
-#define TIMEDATA_VALID 1 /* Time valid */
-
-/* Time Definition AM/PM */
-#define CLOCK_AM 0
-#define CLOCK_PM 1
-/* Change to Enumeration */
-/* Time notification unit */
-typedef enum TagNotifyUnit {
- CLOCK_NOTIFY_SECOND = (1U), /* Second notifications */
- CLOCK_NOTIFY_MINUTE, /* Minute Notification */
- CLOCK_NOTIFY_HOUR /* Hourly notification */
-} NOTIFYUNIT;
-
-/* Return value definition */
-typedef enum TagClockReturn {
- CLOCK_OK, /* Normal completion */
- CLOCK_ERROR, /* ABENDs */
- CLOCK_ERROR_ARGUMENTS /* Invalid argument */
-} CLOCK_RETURN;
-
-/* Time Type Definition */
-typedef struct TagTimeData {
- u_int16 year; /* Year */
- u_int8 month; /* Month */
- u_int8 day; /* Day */
- u_int8 hour; /* Hour */
- u_int8 minute; /* Minutes */
- u_int8 second; /* Second */
-} TimeData;
-
-/* Offset time type definition */
-typedef struct TagOffsetData {
- BOOL sign; /* Operator */
- TimeData time; /* Date and time */
-} OffsetData;
-
-/* Data Definition for System Time Delivery Registration */
-typedef struct TagSystemTimeRegistData {
- NOTIFYUNIT unit; /* Notification unit(Hour,Minutes,One of the seconds) */
-} SYSTEMTIME_REGISTDATA;
-
-/* Data Definition for Setting User Time */
-typedef struct TagUserTimSetData {
- TimeData time; /* Time */
- u_int8 day_of_week; /* Day-of-week */
-} USERTIME_SETDATA;
-
-/* Data Definition for User Time Delivery Registration */
-typedef struct TagUserTimeRegistData {
- NOTIFYUNIT unit; /* Notification unit(Hour,Minutes,One of the seconds) */
-} USERTIME_REGISTDATA;
-
-
-/*
- Time Management Thread -> External Message Definition
-- - - - - - - - - - - - - - - - - - - - - - */
-/* Message data type */
-typedef struct TagClkMngRecMsg {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- u_int8 data[CLKMNG_MSG_BUF_SIZE];
-} CLKMNG_RCV_MSG;
-
-/* For time management Time Set Response Message */
-typedef struct TagClkMngRetTimeMsg { /* Time Set Response Message */
- T_APIMSG_MSGBUF_HEADER header; /* Message header */
- int8 result; /* Processing result */
- int8 dummy[3];
-} CLKMNG_RETTIME_MSG;
-
-/* Change Notification Message from Time for Time Management */
-typedef struct TagClkMngNotiAccuracyMsg {
- T_APIMSG_MSGBUF_HEADER header; /* Message header */
- u_int8 gps_status; /* GPS time status(Likelihood) */
- int8 dummy[3];
-} CLKMNG_NOTIACCURACY_MSG;
-
-/* Time change notification message for time management */
-typedef struct TagClkMngNotiObserversMsg {
- T_APIMSG_MSGBUF_HEADER header; /* Message header */
- u_int8 hour; /* Hour */
- u_int8 min; /* Minutes */
- u_int8 sec; /* Second */
- int8 dummy[1];
-} CLKMNG_NOTIOBSERVERS_MSG;
-
-/*
- Time Management API -> Time Management Thread Message Definition
-- - - - - - - - - - - - - - - - - - - - - - */
-/* Change Notification Registration Message from the Accuracy of Time for Time Management */
-typedef struct TagClkMngNotAccuracyEntryMsg {
- T_APIMSG_MSGBUF_HEADER header; /* Message header */
-} CLKMNG_NOTIACCURACY_ENTRY_MSG;
-
-/* Time change notification registration message for time management */
-typedef struct TagClkMngNotiObserversEntryMsg {
- T_APIMSG_MSGBUF_HEADER header; /* Message header */
- u_int8 notify_time; /* Notification unit (Hour,Minutes,One of the seconds) */
- int8 dummy[3];
-} CLKMNG_NOTIOBSERVERS_ENTRY_MSG;
-
-/*
- API Function Prototype Declaration
-* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-RET_API ClockInitApi(void); /* API initialization processing */
-RET_API ClockGetLocalTime(RealTimeData *real_time, TimestampData *timestamp); /* Current time reference processing */
-RET_API ClockGetLocalTimeBcd(RealTimeDataBcd *real_time_bcd, TimestampData *timestamp); /* Current time reference processing(BCD) */
-RET_API ClockGetUtcTime(RealTimeData* real_time, TimestampData *timestamp); /* Current UTC time reference processing */
-RET_API ClockCnvDateToSec(const LPSYSTEMTIME sys_time, u_int32* sec); /* Date and time,Total seconds conversion */
-RET_API ClockCnvSecToDate(const u_int32* sec, LPSYSTEMTIME sys_time); /* Total seconds,Date and time conversion */
-RET_API ClockGetAddOpeTime(u_int32 *ope_time); /* Accumulated operating time reference processing */
-RET_API ClockSetSystemTime(PNO snd_pno, const SysTimeData* sys_time, u_int8 gps_status); /* System time setting process */
-
-RET_API ClockNotifyObserversClock(PNO snd_pno, u_int8 rsc_id, u_int8 notify_time); /* Fixed period time change notification registration */
-RET_API ClockNotifyObserversAccuracy(PNO snd_pno, u_int8 rsc_id); /* Register change notification based on the time probability */
-RET_API ClockNotifyObserversAdjustClock(PNO snd_pno, u_int8 rsc_id); /* System time setting change notification registration */
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_CLOCK_API_H_
diff --git a/vehicleservice/positioning/client/include/CommonDefine.h b/vehicleservice/positioning/client/include/CommonDefine.h
deleted file mode 100755
index 2e9e3e6..0000000
--- a/vehicleservice/positioning/client/include/CommonDefine.h
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#ifndef POSITIONING_CLIENT_INCLUDE_COMMONDEFINE_H_
-#define POSITIONING_CLIENT_INCLUDE_COMMONDEFINE_H_
-
-/**
- * @file CommonDefine.h
- */
-
-/** @addtogroup vehicle_service
- * @{
- */
-/** @addtogroup positioning
- * @ingroup vehicle_service
- * @{
- */
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/POS_sensor_API.h>
-#include <vehicle_service/POS_define.h>
-#include <vehicle_service/pos_message_header.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-/* Date and Time Status Definition */
-#define NAVIINFO_NAVI_GPS_TD_STS_NOTFIX (0)
-//!< \~english time has not been adjusted after GPS receiver reset
-#define NAVIINFO_NAVI_GPS_TD_STS_RTCBACKUP (1) // !<\~english time output from RTC Backup(have time adjustment)
-#define NAVIINFO_NAVI_GPS_TD_STS_FIX (2) //!< \~english time adjustment completed
-
-/* Vehicle sensor data information */
-#define POS_SNS_CONNECTION (0x01U) //!< \~english connected
-#define POS_SNS_UNCONNECTION (0x00U) //!< \~english not connected
-#define POS_SNS_SHORT (0x02U) //!< \~english short
-#define POS_SNS_UNSPECIFIED (0x03U) //!< \~english not specified
-
-/* NMEA Receive Flag(_CWORD82_) */
-#define POS_SNS__CWORD82__DRMC (0x01U) //!< \~english DRMC sentence
-#define POS_SNS__CWORD82__GSA (0x02U) //!< \~english GSA sentence
-#define POS_SNS__CWORD82__GSV_1 (0x04U) //!< \~english GSV_1 sentence
-#define POS_SNS__CWORD82__GSV_2 (0x08U) //!< \~english GSV_2 sentence
-#define POS_SNS__CWORD82__GSV_3 (0x10U) //!< \~english GSV_3 sentence
-#define POS_SNS__CWORD82__PJRDC_GP_3 (0x20U) //!< \~english PJRDC_GP_3 sentence
-
-/* NMEA Receive Flag */
-#define POS_SNS_GPS_NMEA_PASCD (0x01000000U) //!< \~english pascd sentence
-
-typedef u_int16 PNO; //!< \~english PNo.
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-
-/** @}*/ // end of positioning
-/** @}*/ // end of vehicle_service
-#endif // POSITIONING_CLIENT_INCLUDE_COMMONDEFINE_H_
diff --git a/vehicleservice/positioning/client/include/DR_API.h b/vehicleservice/positioning/client/include/DR_API.h
deleted file mode 100755
index 6362f8c..0000000
--- a/vehicleservice/positioning/client/include/DR_API.h
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/******************************************************************************
-@file DR_API.h
-@detail DR_API external header file<BR>
- DR_API External public header
-******************************************************************************/
-#ifndef POSITIONING_CLIENT_INCLUDE_DR_API_H_
-#define POSITIONING_CLIENT_INCLUDE_DR_API_H_
-
-/*****************************************************************************
- * Include *
- *****************************************************************************/
-
-/*****************************************************************************
- * Define *
- *****************************************************************************/
-/* Command ID */
-#define CID_DR_MAP_MATCHING_DATA (0x0209)
-#define CID_DR_CLEAR_BACKUP_DATA (0x020F)
-
-/* DR_EXT_RET_API definition */
-#define DR_EXT_RET_NORMAL (0) /* Successful completion */
-#define DR_EXT_RET_ERROR (-1) /* Setup failure */
-
-/*****************************************************************************
- * Typedef *
- *****************************************************************************/
-typedef int32 DR_EXT_RET_API;
-
-/*****************************************************************************
- * Enumeration *
- *****************************************************************************/
-typedef enum {
- NAVI_DATA_STATUS_2D_FIX = 0x00,
- NAVI_DATA_STATUS_3D_FIX,
- NAVI_DATA_STATUS_DR_COMBINED,
- NAVI_DATA_STATUS_DR_ONLY,
- NAVI_DATA_STATUS_MAP_2D_GPS_FIX,
- NAVI_DATA_STATUS_MAP_3D_GPS_FIX,
- NAVI_DATA_STATUS_MAP_DR_COMBINED,
- NAVI_DATA_STATUS_MAP_DR_ONLY,
- NAVI_DATA_STATUS_MAP_NO_FIX,
- NAVI_DATA_STATUS_AWAITING_FIRST_FIX,
- NAVI_DATA_STATUS_DATA_INVALID,
- NAVI_DATA_STATUS_NO_FIX,
- NAVI_DATA_STATUS_TIME_ONLY_FIX
-} NAVI_DATA_STATUS;
-
-typedef enum {
- NAVI_DATA_INVALID = 0x00,
- NAVI_DATA_VALID
-} NAVI_DATA_AVAILABLE;
-
-/*****************************************************************************
- * Struct *
- *****************************************************************************/
-/*****************************************************************************
- * TAG : POSITION_INFO
- * ABSTRACT : Position information structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- int32 latitude; /* 10^-7deg North : plus, South : minus */
- int32 longitude; /* 10^-7deg East : plus, West : minus */
- NAVI_DATA_AVAILABLE status; /* Status of data */
-} POSITION_INFO;
-
-/*****************************************************************************
- * TAG : RATE_INFO
- * ABSTRACT : Rate information structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- u_int16 rate; /* 10^-2m/sec */
- u_int8 reserve[2]; /* reserve */
- NAVI_DATA_AVAILABLE status; /* Status of data */
-} RATE_INFO;
-
-/*****************************************************************************
- * TAG : ORIENT_INFO
- * ABSTRACT : Orient information structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- u_int16 orient; /* 10^-2deg N : 0, E : 90, S : 180, W : 270 */
- u_int8 reserve[2]; /* reserve */
- NAVI_DATA_AVAILABLE status; /* Status of data */
-} ORIENT_INFO;
-
-/*****************************************************************************
- * TAG : MAP_MATCHING_DATA
- * ABSTRACT : Map-Matching information data structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- POSITION_INFO position_info; /* Position information */
- RATE_INFO rate_info; /* Rate information */
- ORIENT_INFO orient_info; /* Orient information */
- NAVI_DATA_STATUS status; /* Status */
-} MAP_MATCHING_DATA;
-
-/*****************************************************************************
- * TAG : DR_MSG_MAP_MATCHING_DATA
- * ABSTRACT : Map-Matching information data message buffer structure
- * NOTE : Message structure(User -> VehicleSens)
- *****************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- MAP_MATCHING_DATA data; /* Message data (Map-Matching information) */
-} DR_MSG_MAP_MATCHING_DATA;
-
-/*****************************************************************************
- * TAG : DR_MSG_CLEAR_BACKUP_DATA
- * ABSTRACT : Clear backup data message buffer structure
- * NOTE : Message structure(User -> VehicleSens)
- *****************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
-} DR_MSG_CLEAR_BACKUP_DATA;
-
-/*****************************************************************************
-* Function prototypes *
-*****************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-extern DR_EXT_RET_API DrSetMapMatchingData(PNO pno, MAP_MATCHING_DATA* map_matching_data);
-extern DR_EXT_RET_API DrClearBackupData(PNO pno);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_DR_API_H_
diff --git a/vehicleservice/positioning/client/include/DeadReckoning_DbgLogSim.h b/vehicleservice/positioning/client/include/DeadReckoning_DbgLogSim.h
deleted file mode 100755
index bd57de7..0000000
--- a/vehicleservice/positioning/client/include/DeadReckoning_DbgLogSim.h
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_DEADRECKONING_DBGLOGSIM_H_
-#define POSITIONING_CLIENT_INCLUDE_DEADRECKONING_DBGLOGSIM_H_
-
-/*******************************************************************************
- FILE : DeadReckoning_DbgLogSim.h
- SYSTEM : _CWORD64_ platform development
- SUBSYSTEM : Log Simulator for Debugging
- PROGRAM : PastModel002*1 log read
- FUNC LIST :
---------------------------------------------------------------------------------
-
-*******************************************************************************/
-
-#include "Dead_Reckoning_API.h"
-
-#define DR_DBG_LOG_PACKET_HEAD_SIZE (4) /* DR_LOG_PACKET_HEAD_SIZE */
-#define DR_DBG_LOG_SIM_BUFF_SIZE (0x200)
-
-#define DR_DBG_LOG_SIM_DATA_NONE (-1)
-#define DR_DBG_LOG_SIM_DATA_GPS (1)
-#define DR_DBG_LOG_SIM_DATA_SENSOR (2)
-
-/*
- * prototype
- * public functions
- */
-
-void DeadReckoningDbgLogSimInit(void);
-void DeadReckoningDbgLogSimDispose(void);
-
-BOOL DeadReckoningDbgLogSimIsDbgLogSimMode(void);
-int DeadReckoningDbgLogSimReadPacket(u_int8 *, size_t, int16 *);
-
-#endif // POSITIONING_CLIENT_INCLUDE_DEADRECKONING_DBGLOGSIM_H_
diff --git a/vehicleservice/positioning/client/include/Dead_Reckoning_API.h b/vehicleservice/positioning/client/include/Dead_Reckoning_API.h
deleted file mode 100755
index bd2e031..0000000
--- a/vehicleservice/positioning/client/include/Dead_Reckoning_API.h
+++ /dev/null
@@ -1,229 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_DEAD_RECKONING_API_H_
-#define POSITIONING_CLIENT_INCLUDE_DEAD_RECKONING_API_H_
-/****************************************************************************
- * File name :Dead_Reckoning_API.h
- * System name :PastModel002
- * Subsystem name :
- ******************************************************************************/
-
-/*****************************************************************************
- * Include *
- *****************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "Sensor_Common_API.h"
-#include <native_service/frameworkunified_types.h>
-
-/*****************************************************************************
- * Define *
- *****************************************************************************/
-#define NUM_OF_100msData (10) /* Number of gyro data items delivered every 100 ms */
-
-/*****************************************************************************
- * Typedef *
- *****************************************************************************/
-typedef RET_API DR_RET_API;
-
-/*****************************************************************************
- * Enumeration *
- *****************************************************************************/
-/*******************************************************************************
- TAG : NAVI_MATCHING_STATUS
- ABSTRACT : Map matching data(Status)
- NOTE :
-*******************************************************************************/
-typedef enum NaviMatchingStatus {
- NAVI_MATCHING_STS_2D_FIX = 0x00,
- NAVI_MATCHING_STS_3D_FIX,
- NAVI_MATCHING_STS_DR_COMBINED,
- NAVI_MATCHING_STS_DR_ONLY,
- NAVI_MATCHING_STS_MAP_2D_GPS_FIX,
- NAVI_MATCHING_STS_MAP_3D_GPS_FIX,
- NAVI_MATCHING_STS_MAP_DR_COMBINED,
- NAVI_MATCHING_STS_MAP_DR_ONLY,
- NAVI_MATCHING_STS_MAP_NO_FIX,
- NAVI_MATCHING_STS_AWAITING_FIRST_FIX,
- NAVI_MATCHING_STS_DATA_INVALID,
- NAVI_MATCHING_STS_NO_FIX,
- NAVI_MATCHING_STS_TIME_ONLY_FIX
-} NAVI_MATCHING_STATUS;
-
-/*******************************************************************************
- TAG : NAVI_MATCHING_DATA_AVAILABLE
- ABSTRACT : Map matching data(Availability)
- NOTE :
-*******************************************************************************/
-typedef enum {
- NAVI_MATCHING_DATA_INVALID = 0x00,
- NAVI_MATCHING_DATA_VALID
-} NAVI_MATCHING_DATA_AVAILABLE;
-
-/*****************************************************************************
- * Struct *
- *****************************************************************************/
-/* Sensor data */
-/*******************************************************************************
- TAG : Struct_PulseRevTbl
- ABSTRACT : Vehicle speed/REV data table structure
- NOTE : 4byte
-*******************************************************************************/
-typedef struct {
- u_int8 reverse_flag; /* 0:Forward march 1:Backward 3:Disabled Reverse signal status */
- u_int8 pulse_flag; /* Vehicle speed pulse flag */
- /* 0:Enabled 1:Receive invalid value from CAN 2:Unable to receive at download timing */
- u_int16 pulse_sum_cyclic; /* Vehicle speed pulse counter value */
-} Struct_PulseRevTbl;
-/*******************************************************************************
- TAG : Struct_GyroTbl
- ABSTRACT : Gyro Data Table Structure
- NOTE : 20byte
-*******************************************************************************/
-typedef struct {
- u_int16 gyro_data[NUM_OF_100msData]; /* A/D-converted gyro data */
-} Struct_GyroTbl;
-/*******************************************************************************
- TAG : Struct_SensData
- ABSTRACT : Sensor data structure
- NOTE :
-*******************************************************************************/
-typedef struct {
- u_int8 sens_cnt_flag; /* Sensor data transmission counter flag */
- /* 0:Disabled(->Initial Sensor) 1:Enabled(->100 ms periodic transmission) */
- /* Set "0" for initial sensor transmission and "1" for periodic transmission. */
- u_int8 sens_cnt; /* Sensor data transmission counter value Set "0" at initial transmission of sensor */
- Struct_PulseRevTbl pulse_rev_tbl; /* Vehicle speed/REV Data table */
- Struct_GyroTbl gyro_x_tbl; /* Gyro(X axis) data table */
- Struct_GyroTbl gyro_y_tbl; /* Gyro(Y axis) data table */
- Struct_GyroTbl gyro_z_tbl; /* Gyro(Z axis) data table */
-} Struct_SensData;
-
-/* GPS data */
-/*******************************************************************************
- TAG : Struct_GpsData
- ABSTRACT : GPS data structure
- NOTE :
-*******************************************************************************/
-typedef struct {
- u_int8 sens_cnt; /* Sensor data transmission counter value */
- u_int8 sens_cnt_flag; /* Sensor data transmission counter flag */
- /* 0:Disabled(Incorrect GPS sensor counter) */
- /* 1:Enabled */
- u_int16 gps_data_size; /* GPS data storage area size */
- DID did; /* Data ID */
- const void* gps_data; /* GPS data storage area */
-} Struct_GpsData;
-
-/* Estimated Navigation Calculation Result */
-/*******************************************************************************
- TAG : Struct_DR_DATA
- ABSTRACT : Estimated Navigation Calculation Result
- NOTE :
-*******************************************************************************/
-typedef struct {
- int64_t latitude; /* Latitude(WGS-84) 10^-7deg */
- int64_t longitude; /* Longitude(WGS-84) 10^-7deg */
- int64_t altitude; /* Altitude 10^-2m */
- u_int16 rate; /* Speeds 10^-2m/sec */
- u_int16 heading; /* Orientation North-reference clockwise 10^-2deg */
- u_int16 reserve; /* RESERVE */
- u_int8 dr_status; /* DR calculation status */
- u_int8 positioning_time; /* Sensor Counter */
-} Struct_DR_DATA;
-
-/*******************************************************************************
- TAG : DR_CALC_INFO
- ABSTRACT : Estimated navigation information
- NOTE :
-*******************************************************************************/
-typedef struct {
- u_int16 gyro_offset; /* Correction coefficient:Gyro offset */
- u_int8 gyro_scale_factor; /* Correction coefficient:Gyro Sensitivity */
- u_int8 gyro_scale_factor_level; /* Learning Level(Gyro Sensitivity) */
- u_int16 speed_pulse_scale_factor; /* Correction coefficient:Vehicle speed factor */
- u_int8 speed_pulse_scale_factor_level; /* Learning Level(Vehicle speed factor) */
- u_int8 reserve; /* Reserve(1Byte) */
-} DR_CALC_INFO;
-
-/*******************************************************************************
- TAG : DR_POSITION_INFO
- ABSTRACT : Location information
- NOTE :
-*******************************************************************************/
-typedef struct {
- int64_t latitude;
- int64_t longitude;
- NAVI_MATCHING_DATA_AVAILABLE status;
-} DR_POSITION_INFO;
-
-/*******************************************************************************
- TAG : DR_RATE_INFO
- ABSTRACT : Location information
- NOTE :
-*******************************************************************************/
-typedef struct {
- u_int16 rate;
- u_int8 reserve[2];
- NAVI_MATCHING_DATA_AVAILABLE status;
-} DR_RATE_INFO;
-
-/*******************************************************************************
- TAG : DR_ORIENT_INFO
- ABSTRACT : Location information
- NOTE :
-*******************************************************************************/
-typedef struct {
- u_int16 orient;
- u_int8 reserve[2];
- NAVI_MATCHING_DATA_AVAILABLE status;
-} DR_ORIENT_INFO;
-
-/*******************************************************************************
- TAG : NAVI_MATCHING_DATA
- ABSTRACT : Map matching data
- NOTE :
-*******************************************************************************/
-typedef struct {
- DR_POSITION_INFO position_info;
- DR_RATE_INFO rate_info;
- DR_ORIENT_INFO orient_info;
- NAVI_MATCHING_STATUS status;
-} NAVI_MATCHING_DATA;
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-DR_RET_API DeadReckoningLibraryInit(void);
-DR_RET_API SetGpsData(Struct_GpsData *st_gps_data);
-DR_RET_API CalculateDeadReckoningData(Struct_SensData *st_sensor_data,
- Struct_DR_DATA *st_dr_data, DR_CALC_INFO *dr_calc_data);
-DR_RET_API SetMatchingData(NAVI_MATCHING_DATA *st_matching_data);
-
-DR_RET_API ClearBackupData(void); /* Clear DR backup data */
-/* BOOL Problem Avoidance */
-DR_RET_API GetLocationLogSetting(int *log_sw, unsigned char *severity); /* Location log output ON/OFF acquisition */
-DR_RET_API SetLocationLogStatus(int log_sw, unsigned char severity); /* Location log output ON/OFF setting */
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_DEAD_RECKONING_API_H_
diff --git a/vehicleservice/positioning/client/include/Dead_Reckoning_Local_Api.h b/vehicleservice/positioning/client/include/Dead_Reckoning_Local_Api.h
deleted file mode 100755
index c513e9b..0000000
--- a/vehicleservice/positioning/client/include/Dead_Reckoning_Local_Api.h
+++ /dev/null
@@ -1,147 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_DEAD_RECKONING_LOCAL_API_H_
-#define POSITIONING_CLIENT_INCLUDE_DEAD_RECKONING_LOCAL_API_H_
-/****************************************************************************
- * File name :Dead_Reckoning_Local_Api.h
- * System name :PastModel002
- * Subsystem name :
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "Sensor_Common_API.h"
-#include "SensorLocation_API.h"
-#include "SensorMotion_API.h"
-#include "DR_API.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-
-/*----------------------------------------------------------------------*
- * DEADRECKONING_RET_API define *
- *----------------------------------------------------------------------*/
-/* Normal system */
-#define DEAD_RECKONING_RET_NORMAL 0 /* Normal completion */
-/* Abnormal system */
-#define DEADRECKONING_RET_ERROR_PID (-1) /* Thread ID error */
-#define DEADRECKONING_RET_ERROR_DID (-2) /* Unregistered DID */
-#define DEADRECKONING_RET_ERROR_PARAM (-4) /* Parameter error */
-#define DEADRECKONING_RET_ERROR_BUFFULL (-5) /* FULL of registered numbers */
-#define DEADRECKONING_RET_ERROR_CREATE_EVENT (-6) /* Event generation failure */
-#define DEADRECKONING_RET_ERROR_OUTOF_MEMORY (-8) /* Shared memory allocation failed */
-#define DEADRECKONING_RET_ERROR_SIZE (-9) /* Storage destination size error */
-#define DEADRECKONING_RET_ERROR_MIN (-10)
-
-/*----------------------------------------------------------------------*
- * DEADRECKONING delivery registry APIs *
- *----------------------------------------------------------------------*/
-/* Delivery control */
-#define DEADRECKONING_DELIVERY_REGIST 0x01 /* Delivery registration */
-
-/* Delivery timing */
-#define DEADRECKONING_DELIVERY_TIMING_UPDATE 0x01 /* Updating */
-
-/*----------------------------------------------------------------------*
- * Command ID *
- *----------------------------------------------------------------------*/
-/* Vehicle Sensor -> Vehicle Sensor(DR) */
-#define CID_DEAD_RECKONING_DELIVERY_ENTRY 0x0310 /* DR Transmission Registration Signal Notification */
-
-/* Vehicle Sensor -> Vehicle Sensor(DR) */
-#define CID_DEAD_RECKONING_SENS_DATA 0x0311 /* DR data signal notification */
-#define CID_DEAD_RECKONING_GPS_DATA 0x0312 /* DR data signal notification */
-#define CID_DEAD_RECKONING_SENS_FST_DATA 0x0313 /* DR data signal notification */
-
-/* Message Data Size(byte) */
-#define DEADRECKONING_MSGBUF_DSIZE 512 /* Message body MAX */
-
-/*----------------------------------------------------------------------*
- * Shared Memory Related Extensions *
- *----------------------------------------------------------------------*/
-/* Semaphore name(MAX 32Byte) Synchronize with VehicleDebug_API_private.h */
-#define SENSOR_LOG_SETTING_SEMAPHO_NAME ("SEBSIR_GET_LOG_SETTING_SEMAPHO")
-
-/* Shared memory name(MAX 32Byte) Synchronize with VehicleDebug_API_private */
-#define LOG_SETTING_SHARE_MEMORY_NAME ("LOG_SETTING_SHARE_MEMORY")
-
-/************************************************************************
-* typedef Definition *
-************************************************************************/
-typedef RET_API DEAD_RECKONING_RET_API; /* API return value */
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-
-/************************************************************************
-* TAG : DEADRECKONING_MSG_BUF
-* ABSTRACT : message buffer
-************************************************************************/
-
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- u_int8 data[DEADRECKONING_MSGBUF_DSIZE]; /* Message data */
-} DEADRECKONING_MSG_BUF;
-
-/************************************************************************
-* TAG : DEADRECKONING_MSG_DELIVERY_ENTRY
-* ABSTRACT : Registration message delivery vehicle sensor information(->Vehicle sensor)
-************************************************************************/
-typedef struct {
- DID did; /* ID data corresponding to the vehicle sensor information */
- PNO pno; /* Shipping addressPNO */
- u_int8 delivery_timing; /* Delivery opportunity */
- u_int8 ctrl_flg; /* Delivery control */
- EventID event_id; /* Event ID */
-} DEADRECKONING_MSG_DELIVERY_ENTRY_DAT;
-
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- DEADRECKONING_MSG_DELIVERY_ENTRY_DAT data; /* Message data */
-} DEADRECKONING_MSG_DELIVERY_ENTRY;
-
-/************************************************************************
-* TAG : DEADRECKONING_MSG_GET_DR_DATA
-* ABSTRACT : Vehicle sensor information acquisition message(->Vehicle sensor)
-************************************************************************/
-typedef struct {
- DID did; /* Data ID corresponding to vehicle sensor information */
- PNO pno; /* Destination PNO */
- u_int16 offset; /* Offset to shared memory storage area */
- u_int16 size; /* Size of shared memory storage area */
- u_int8 reserve[2];
- EventID event_id; /* Event ID */
-} DEADRECKONING_MSG_GET_DR_DATA_DAT;
-
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- DEADRECKONING_MSG_GET_DR_DATA_DAT data; /* Message data */
-} DEADRECKONING_MSG_GET_DR_DATA;
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_DEAD_RECKONING_LOCAL_API_H_
diff --git a/vehicleservice/positioning/client/include/Gps_API_private.h b/vehicleservice/positioning/client/include/Gps_API_private.h
deleted file mode 100755
index 7026ce9..0000000
--- a/vehicleservice/positioning/client/include/Gps_API_private.h
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Gps_API_private.h
- * @brief
- * Definition for GPS Internal I/F Liblary
- */
-#ifndef POSITIONING_CLIENT_INCLUDE_GPS_API_PRIVATE_H_
-#define POSITIONING_CLIENT_INCLUDE_GPS_API_PRIVATE_H_
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-/*--- for message ---*/
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-/*!
- @brief message delivery GPS reset information
- */
-typedef struct {
- uint8_t mode; /**< Reset mode */
- uint8_t reserve[3]; /**< reserve */
- PNO snd_pno; /**< Caller PNO */
- PNO res_pno; /**< Destination PNO */
-} POS_RESETINFO;
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_GPS_API_PRIVATE_H_
diff --git a/vehicleservice/positioning/client/include/INI_API.h b/vehicleservice/positioning/client/include/INI_API.h
deleted file mode 100755
index f16a4c6..0000000
--- a/vehicleservice/positioning/client/include/INI_API.h
+++ /dev/null
@@ -1,259 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/************************************************************************
-* File name : INI_API.h
-* System name : _CWORD107_
-* Subsystem name : Staged Start and Termination Framework
-* Title : Staged Start and End Framework API Header Files
-************************************************************************/
-
-#ifndef POSITIONING_CLIENT_INCLUDE_INI_API_H_
-#define POSITIONING_CLIENT_INCLUDE_INI_API_H_
-
-#include <vehicle_service/positioning_base_library.h>
-
-/*
-***** DEFINE *****
-*/
-
-#define INI_EXTMEM_DUM 0 /* Message buffer header extension member */
-
-/* Return value */
-#define INI_SUCCESS 0 /* Normal */
-#define INI_FALSE (-1) /* Fail */
-#define INI_ERRNOTRDY (-2) /* No destination process(Not wakeup) */
-
-/* Stage start completion notification ID related Note: ACC-OFF process completion notification is also used. */
-#define GINI_COMPID_INI 0x00000000 /* Initial value of completion notification ID */
-#define GINI_COMPID_MASK 0x80000000 /* Completion notification ID mask value(Startup completion or for event completion determination) */
-
-/* ID for Phase Start Event Completion Notification */
-
-#define INI_INITCOMP_BTCOM_PRT 0x80000001 /* BT Communication Protocol Thread Startup Complete */
-#define INI_INITCOMP_BTCOM_MNG 0x80000002 /* BT Communication Protocol Thread Startup Complete */
-#define INI_INITCOMP_BTCOM_RCV 0x80000004 /* BT Communication Protocol Thread Startup Complete */
-#define INI_INITCOMP_MC_UPCHK 0x80000008 /* To receive the confirmation notice of connection between microcomputers */
-
-/************************************************************************
- ID for Phase Start Event Completion Notification (For VUP)
- ************************************************************************/
-#define INI_FWRDCOMP__CWORD24_ 0x80000008 /* _CWORD24_ transmission completed */
-#define INI_FWRDCOMP_VUP 0x80000010 /* VUPLoader transmission completed */
-#define INI_INITCOMP_MFT 0x80000020 /* Module transfer thread start completion */
-#define INI_INITCOMP_UPCHK 0x80000040 /* Receive Start Type Confirmation Notification */
-
-/* ID for Phase ACC-OFF Event Completion Notification ID */
-
-/* Boot phase */
-/*************************************************************************
- Note: Maintenance Precautions*
- Initial only affects the addition and deletion of startup parameters.
- For addition or deletion of shared memory creation,The primary of each process is also affected
-*************************************************************************/
-/* --->CHG */
-enum IniStep {
- GINI_STEPFORK_INI = 0, /* Initial state */
- GINI_STEPFORK_COMMEM, /* Shared Memory Generation */
- GINI_STEPFORK_FIRST, /* First start */
- GINI_STEPFORK_SECOND, /* 2nd start */
- GINI_STEPFORK_THIRD, /* 3rd start */
- GINI_STEPFORK_FOURTH, /* 4th start */
- GINI_STEPFORK_BUPCHK, /* Backup Data Check/Initialization */
- GINI_STEPFORK_FIFTH, /* 5th start */
- GINI_STEPFORK_SIXTH, /* 6th start */
- GINI_STEPFORK_SEVENTH, /* 7th start */
- GINI_STEPFORK_EIGHTH, /* 8th start */
- GINI_STEPFORK_NINTH, /* 9th start */
- GINI_STEPFORK_TENTH, /* 10th start */
- GINI_STEPFORK_ELEVENTH, /* 11th start */
- GINI_STEPFORK_TWELFTH, /* 12th start */
- GINI_STEPFORK_THIRTEENTH, /* 13th start */
- GINI_STEPFORK_FOURTEENTH, /* 14th start */
- GINI_STEPFORK_FIFTEENTH, /* 15th Start */
- GINI_STEPFORK_SIXTEENTH, /* 16th start */
- GINI_STEPFORK_SEVENTEENTH, /* 17th Start */
- GINI_STEPFORK_EIGHTEENTH, /* 18th Start */
- GINI_STEPFORK_MAX /* Total number of startup phases */
-};
-/* <--- CHG */
-
-/* ACC-OFF phase */
-enum AccOffStep {
- GINI_ACCOFF_INI = 0, /* Early stage(Normal state) */
- GINI_ACCOFF_FIRST, /* Stage 1 */
- GINI_ACCOFF_SECOND, /* Step 2 */
- GINI_ACCOFF_THIRD, /* Step 3 */
- GINI_ACCOFF_FOURTH, /* Step 4 */
- GINI_ACCOFF_FIFTH, /* Step 5 */
- GINI_ACCOFF_MAX /* Total number of ACC-OFF steps */
-};
-
-/* Backup data check process type */
-enum IniDramBkup {
- INI_BUPCHK_SRAM_INIT = 0, /* Initialization of SRAM */
- INI_BUPCHK_SRAM_CHK, /* SRAM range-checking process */
- INI_BUPCHK_USER_INIT, /* Initialization of personal information */
- INI_BUPCHK_DRAM_INIT /* Initializing DRAM backups */
-};
-
-/* ---> */
-/*************************************************
- Startup identification
-*************************************************/
-enum {
- INI_CND_UNSET = 0, /* Startup identification value not set */
- INI_CND_UNKNOWN, /* Startup identification unknown */
- INI_CND_CLSTART, /* COLD START */
- INI_CND_HTSTART, /* HOT START */
- INI_CND_ERRRESET, /* Error Reset */
- INI_CND_USERCL /* User-specified COLD */
-};
-
-/*************************************************
- Startup Security State
-*************************************************/
-enum {
- INI_ANTITHEFT_UNSET = 0, /* Not set condition */
- INI_ANTITHEFT_UNLOCK, /* Unlocked status */
- INI_ANTITHEFT_LOCK, /* Lock state */
- INI_ANTITHEFT_INITIAL /* Initial state(Not used) */
-};
-
-/*************************************************
- Version upgrade completion information
-*************************************************/
-enum {
- INI_VUP_INFO_UNSET = 0, /* VUP information not set */
- INI_VUP_INFO_NORMAL, /* VUP Information Normal(VUP not executed) */
- INI_VUP_INFO_ERROR, /* VUP information error(VUP incomplete) */
- INI_VUP_INFO_VUPFIN /* Completion of VUP information */
-};
-
-/*************************************************
- +B Disconnect Information
-*************************************************/
-enum {
- INI_BATTERY_INFO_UNSET = 0, /* +B Information not set */
- INI_BATTERY_INFO_NORMAL, /* +B Information Normal(no disconnected) */
- INI_BATTERY_INFO_DISCON /* +B Information with disconnected */
-};
-
-/*************************************************
- User information initialization information
-*************************************************/
-enum {
- INI_INITUSERDAT_UNSET = 0, /* User information not set */
- INI_INITUSERDAT_ON, /* Personal Information Initialization Status Setting ON */
- INI_INITUSERDAT_OFF /* Personal information initialization status setting OFF */
-};
-
-/*************************************************
- DRAM back-up status at startup
-*************************************************/
-enum {
- INI_DRAMBKUP_UNSET = 0, /* DRAM back-up status not set */
- INI_DRAMBKUP_OK, /* DRAM back-up status OK */
- INI_DRAMBKUP_NG /* DRAM backup status NG */
-};
-
-/****** STRUCT ******/
-/*************************************************
- Startup system information
-*************************************************/
-typedef struct {
- u_int8 boot_type; /* Startup identification */
- u_int8 security_sts; /* Startup Security State */
- u_int8 vup_info; /* Version upgrade completion information */
- u_int8 battery_off_info; /* +B Disconnect Information */
- u_int8 usrdat_init_info; /* User data initialization information */
- u_int8 dram_bup_sts; /* DRAM back-up status */
- u_int8 reserve[2]; /* Reserved */
- u_int32 boot_time; /* Passed Time */
-} T_INI_BOOTINFO;
-
-/* <--- */
-
-/*
-***** STRUCTURE *****
-*/
-/******************************************************************************
-* TAG : T_PRIM_FORKCOMP
-* ABSTRACT : Stage-up completion notification structure
-* NOTE : Body portion of messages generated from API (Staged Start Completion Notification)
-******************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER head; /* Message buffer header */
- u_int32 id; /* ID for start phase completion notification */
-} T_PRIM_FORKCOMP;
-
-/******************************************************************************
-* TAG : T_PRIM_ACCOFFSTART
-* ABSTRACT : Structures for ACC-OFF Process Instructions
-* NOTE : Body of messages generated from API(ACC-OFF process instructions)
-******************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER head; /* Message buffer header */
- u_int32 id; /* ID for start phase completion notification */
-} T_PRIM_ACCOFFSTART;
-
-/******************************************************************************
-* TAG : T_PRIM_ACCOFFCOMP
-* ABSTRACT : Structures for notifying completion of ACC-OFF process
-* NOTE : Main body of messages generated from API(ACC-OFF process completion notification)
-******************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER head; /* Message buffer header */
- u_int32 id; /* Identifier for notifying completion of ACC-OFF process */
-} T_PRIM_ACCOFFCOMP;
-
-/******************************************************************************
-* TAG : T_PRIM_INTERNAL_ACCOFFSTART
-* ABSTRACT : Structures for in-function ACC-OFF indication
-* NOTE : Body portion of messages generated from API (notification of completion of ACC-OFF process in function)
-******************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER head; /* Message buffer header */
- u_int32 id; /* Identifier for notifying completion of ACC-OFF process */
-} T_PRIM_INTERNAL_ACCOFFSTART;
-
-/******************************************************************************
-* TAG : T_PRIM_INTERNAL_ACCOFFCOMP
-* ABSTRACT : Structures for notifying completion of ACC-OFF in functions
-* NOTE : Body portion of messages generated from NOTEAPI (notification of completion of ACC-OFF process in function)
-******************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER head; /* Message buffer header */
- u_int32 id; /* Identifier for notifying completion of ACC-OFF process */
-} T_PRIM_INTERNAL_ACCOFFCOMP;
-
-/*
-***** PROTOTYPE *****
-*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-int32 IniInternalAccOffComp(PNO pno , u_int32 id);
-void IniNotifyInit_CWORD69_Comp(void);
-void IniWaitInit_CWORD69_Comp(void);
-BOOL IniIsInit_CWORD69_Comp(void);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_INI_API_H_
diff --git a/vehicleservice/positioning/client/include/Naviinfo_API.h b/vehicleservice/positioning/client/include/Naviinfo_API.h
deleted file mode 100755
index 12caa84..0000000
--- a/vehicleservice/positioning/client/include/Naviinfo_API.h
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/******************************************************************************
-@file Naviinfo_API.h
-@detail Naviinfo_API external header file<BR>
- Naviinfo_API External Public Header
-******************************************************************************/
-#ifndef POSITIONING_CLIENT_INCLUDE_NAVIINFO_API_H_
-#define POSITIONING_CLIENT_INCLUDE_NAVIINFO_API_H_
-
-/*****************************************************************************
- * Include *
- *****************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "Sensor_Common_API.h"
-#include "Vehicle_API.h"
-#include "Sensor_API.h"
-#include <vehicle_service/POS_gps_API.h>
-
-/*****************************************************************************
- * Define *
- *****************************************************************************/
-/* Command ID Definition */
-#define CID_NAVIINFO_DELIVER (0x0205) /* Navigation information setting CID */
-#define CID_NAVIINFO_SPEED_DELIVER (0x0206) /* Vehicle speed setting CID */
-#define CID_NAVIINFO_SETGPSTIME (0x0207) /* GPS time delivery CID */
-
-/* Positioning Level/GPS Information Positioning Status Information Definition */
-#define NAVIINFO_DIAG_GPS_FIX_STS_NON (0) /* Not fix */
-#define NAVIINFO_DIAG_GPS_FIX_STS_2D (1) /* 2D positioning */
-#define NAVIINFO_DIAG_GPS_FIX_STS_3D (2) /* 3D positioning */
-
-/* Reception status definition */
-#define NAVIINFO_DIAG_GPS_RCV_STS_NOTUSE (0) /* Not used */
-#define NAVIINFO_DIAG_GPS_RCV_STS_SEARCHING (1) /* Searching */
-#define NAVIINFO_DIAG_GPS_RCV_STS_TRACHING (2) /* Tracking in progress */
-#define NAVIINFO_DIAG_GPS_RCV_STS_NOTUSEFIX (3) /* Positioning not used */
-#define NAVIINFO_DIAG_GPS_RCV_STS_USEFIX (4) /* Positioning use */
-
-/* Date and Time Status Definition */
-#define NAVIINFO_NAVI_GPS_TD_STS_NOTFIX (0)
-/* Time not calibrated after receiver reset */
-#define NAVIINFO_NAVI_GPS_TD_STS_RTCBACKUP (1)
-/* Time output by RTC backup(Time Calibration Result)*/
-#define NAVIINFO_NAVI_GPS_TD_STS_FIX (2) /* Time calibration completed */
-
-/* ++ Porting from PastModel002 enabled APIs */
-#define CID_VEHICLEIF_GET_VEHICLE_DATA 0x0102 /* Vehicle sensor information acquisition CID */
-#define CID_VEHICLEIF_COMM_WATCH 0x0103 /* Vehicle Sensor Information Disruption Monitoring CID */
-#define CID_SENSORIF__CWORD82__REQUEST 0x0800 /* Vehicle sensor information setting CID */
-
-#define VEHICLE_RET_ERROR_OUTOF_MEMORY (-8) /* Shared memory allocation failure */
-#define VEHICLE_RET_ERROR_INVALID (-10) /* CANID undetermined */
-
-/* -- Porting from PastModel002 enabled APIs */
-
-/*****************************************************************************
- * Typedef *
- *****************************************************************************/
-
-/*****************************************************************************
- * Struct *
- *****************************************************************************/
-/*****************************************************************************
- * TAG : NAVIINFO_DELIVER_MSG
- * ABSTRACT : Navigation information delivery message structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- NAVIINFO_ALL dat; /* Message data section */
-} NAVIINFO_DELIVER_MSG;
-
-/*****************************************************************************
- * TAG : NAVIINFO_SPEED_DELIVER_MSG
- * ABSTRACT : Navigation Information (Vehicle Speed) Delivery Message Structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- u_int16 navi_speed; /* Vehicle speed information */
- u_int8 reserve[2]; /* reserve */
-} NAVIINFO_SPEED_DELIVER_MSG;
-
-/*****************************************************************************
-* Function prototype *
-*****************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-extern int32 VehicleSetVehicleData(PNO pid, VEHICLE_MSG_SEND_DAT *p_data);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_NAVIINFO_API_H_
diff --git a/vehicleservice/positioning/client/include/POS_common_private.h b/vehicleservice/positioning/client/include/POS_common_private.h
deleted file mode 100755
index 4dd98a2..0000000
--- a/vehicleservice/positioning/client/include/POS_common_private.h
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * POS_common_private.h
- * @brief
- * Definition for Common Internal I/F Liblary
- */
-#ifndef POSITIONING_CLIENT_INCLUDE_POS_COMMON_PRIVATE_H_
-#define POSITIONING_CLIENT_INCLUDE_POS_COMMON_PRIVATE_H_
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-/*--- for message ---*/
-/*
- * Maximum receive message size
- * - Set the value based on the message receiving buffer size of the local thread
- */
-#define MAX_MSG_BUF_SIZE (4096)
-
-/* command ID */
-#define CID_POSIF_SET_DATA 0x0790 /* set data command ID */
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_POS_COMMON_PRIVATE_H_
diff --git a/vehicleservice/positioning/client/include/POS_private.h b/vehicleservice/positioning/client/include/POS_private.h
deleted file mode 100755
index 9f02202..0000000
--- a/vehicleservice/positioning/client/include/POS_private.h
+++ /dev/null
@@ -1,981 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * POS_private.h
- * @brief
- * Inner functions of Positoning API
- *
- */
-#ifndef POSITIONING_CLIENT_INCLUDE_POS_PRIVATE_H_
-#define POSITIONING_CLIENT_INCLUDE_POS_PRIVATE_H_
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include <vehicle_service/POS_define.h>
-#include "Vehicle_API_Dummy.h"
-#include "Vehicle_API_private.h"
-#include "Naviinfo_API.h"
-#include "POS_common_private.h"
-#include <asm/unistd.h>
-#include <other_service/VP_GetEnv.h>
-#include <other_service/env_vehicleparameterlibrary.h>
-#include "CommonDefine.h"
-/*---------------------------------------------------------------------------------*
- * Function Prototype *
- *---------------------------------------------------------------------------------*/
-/* Shared Library Value Area Check Function */
-inline UNIT_TYPE GetEnvSupportInfo(void);
-inline BOOL ChkUnitType(UNIT_TYPE type);
-inline RET_API MunMapDeviceIo(HANDLE dev, uint32_t map_size);
-inline RET_API MilliSecSleep(uint32_t mill_time);
-inline POS_RET_API PosChkParam8(int8_t data, int8_t min, int8_t max, const char* fn, int32_t line);
-inline POS_RET_API PosChkParam16(int16_t data, int16_t min, int16_t max, const char* fn, int32_t line);
-inline POS_RET_API PosChkParam32(int32_t data, int32_t min, int32_t max, const char* fn, int32_t line);
-inline POS_RET_API PosChkParamU8(uint8_t data, uint8_t min, uint8_t max, const char* fn, int32_t line);
-inline POS_RET_API PosChkParamU16(uint16_t data, uint16_t min, uint16_t max, const char* fn, int32_t line);
-inline POS_RET_API PosChkParamU32(uint32_t data, uint32_t min, uint32_t max, const char* fn, int32_t line);
-
-/* Shared Intra-Library Core Functions */
-inline POS_RET_API PosSetProc(DID did, void *p_data, uint16_t size, uint8_t is_event);
-inline POS_RET_API PosGetProc(DID did, void *p_data, uint16_t dest_size);
-inline SENSOR_RET_API PosRegisterListenerProc(PCSTR notify_name,
- DID did, u_int8 ctrl_flg, u_int8 delivery_timing);
-
-/* General Functions in Shared Libraries */
-inline EventID VehicleCreateEvent(PNO pno);
-inline RET_API VehicleDeleteEvent(EventID event_id);
-inline RET_API VehicleLinkShareData(void **share_top, uint32_t *share_size, uint16_t *offset);
-inline RET_API VehicleUnLinkShareData(VEHICLE_SHARE *share_top, uint16_t offset);
-inline RET_API VehicleSndMsg(PNO pno_src, PNO pno_dest, CID cid, uint16_t msg_len, const void *msg_data);
-inline BOOL VehicleGetResource(void);
-inline void VehicleReleaseResource(void);
-inline uint32_t GetTid(void);
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-#define POS_CHKPARAM8(data, min, max) PosChkParam8(data, min, max, __func__, __LINE__)
-#define POS_CHKPARAM16(data, min, max) PosChkParam16(data, min, max, __func__, __LINE__)
-#define POS_CHKPARAM32(data, min, max) PosChkParam32(data, min, max, __func__, __LINE__)
-#define POS_CHKPARAMU8(data, min, max) PosChkParamU8(data, min, max, __func__, __LINE__)
-#define POS_CHKPARAMU16(data, min, max) PosChkParamU16(data, min, max, __func__, __LINE__)
-#define POS_CHKPARAMU32(data, min, max) PosChkParamU32(data, min, max, __func__, __LINE__)
-#define POS_API_TIME_OUT_MS 5000 /* Timeout period(ms) */
-
-/*---------------------------------------------------------------------------------*
- * Inline Functions *
- *---------------------------------------------------------------------------------*/
-UNIT_TYPE GetEnvSupportInfo(void) {
- UNIT_TYPE ret_type = UNIT_TYPE_GRADE1;
-
- char env_area[VP_MAX_LENGTH];
- char env_grade[VP_MAX_LENGTH];
- char* p_env_grade = env_grade;
- char* p_env_area = env_area;
-
- /*
- * Note.
- * This feature branches processing depending on the area and grade type.
- */
-
- VP_GetEnv(VP_VEHICLEPARAMETERLIBRARY_AREA, p_env_area);
-
- if (0 == strcmp(p_env_area, "AREA1")) {
- ret_type = UNIT_TYPE_GRADE2;
- } else if (0 == strcmp(p_env_area, "AREA2")) {
- memset(&env_grade, 0x00, sizeof(env_grade));
- VP_GetEnv(VP_VEHICLEPARAMETERLIBRARY_GRADE, p_env_grade);
- if (0 == strcmp(p_env_grade, "_CWORD95_") ||
- 0 == strcmp(p_env_grade, "_CWORD101_") ||
- 0 == strcmp(p_env_grade, "_CWORD61_")) {
- ret_type = UNIT_TYPE_GRADE2;
- }
- } else {
- // NOP
- }
-
- return ret_type;
-}
-
-BOOL ChkUnitType(UNIT_TYPE type) {
- UNIT_TYPE type_temp;
- BOOL ret;
-
- type_temp = GetEnvSupportInfo();
- if ((type_temp & type) != 0) {
- ret = TRUE;
- } else {
- ret = FALSE;
- }
-
- return ret;
-}
-
-RET_API MunMapDeviceIo(HANDLE dev, uint32_t map_size) {
- return RET_NORMAL;
-}
-
-RET_API MilliSecSleep(uint32_t mill_time) {
- switch (mill_time) {
- case 0:
- {
- /* Discard the time slice */
- sched_yield();
- break;
- }
- case INFINITE:
- {
- /* Abort processing indefinitely */
- while (1) {
- sleep(INFINITE);
- }
- }
- default:
- /* Sleep for Specified Time */
- usleep(mill_time * 1000);
- break;
- }
-
- return RET_NORMAL;
-}
-
-/**
- * @brief
- * Data Valid Value Determination(int8)
- *
- * @param[in] date int8_t Object data
- * @param[in] min int8_t Target Data Valid Value Range(Minimum value)
- * @param[in] max int8_t Target Data Valid Value Range(Maximum value)
- * @param[in] fn const char* Pointer to the function name
- * @param[in] line int32_t Number of lines
- *
- * @return POS_RET_NORMAL Within the valid range<br>
- * POS_RET_ERROR Out of scope<br>
- * POS_RET_ERROR_PARAM Argument error
- */
-inline POS_RET_API PosChkParam8(int8_t data, int8_t min, int8_t max, const char* fn, int32_t line) {
- POS_RET_API ret = POS_RET_NORMAL;
-
- if (fn == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "Argument ERROR!! fn=%p", fn);
- ret = POS_RET_ERROR_PARAM;
- } else {
- if ((data < min) || (max < data)) {
- ret = POS_RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__,
- "%s/%d/Out of range!! data=%d[%d, %d]",
- fn, line, data, min, max);
- }
- }
-
- return ret;
-}
-
-/**
- * @brief
- * Data Valid Value Determination(int16)
- *
- * @param[in] date int16_t Object data
- * @param[in] min int16_t Target Data Valid Value Range(Minimum value)
- * @param[in] max int16_t Target Data Valid Value Range(Maximum value)
- * @param[in] fn const char* Pointer to the function name
- * @param[in] line int32_t Number of lines
- *
- * @return POS_RET_NORMAL Within the valid range<br>
- * POS_RET_ERROR Out of scope<br>
- * POS_RET_ERROR_PARAM Argument error
- */
-inline POS_RET_API PosChkParam16(int16_t data, int16_t min, int16_t max, const char* fn, int32_t line) {
- POS_RET_API ret = POS_RET_NORMAL;
-
- if (fn == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "Argument ERROR!! fn=%p", fn);
- ret = POS_RET_ERROR_PARAM;
- } else {
- if ((data < min) || (max < data)) {
- ret = POS_RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__,
- "%s/%d/Out of range!! data=%d[%d, %d]",
- fn, line, data, min, max);
- }
- }
-
- return ret;
-}
-
-/**
- * @brief
- * Data Valid Value Determination(int32)
- *
- * @param[in] date int32_t Object data
- * @param[in] min int32_t Target Data Valid Value Range(Minimum value)
- * @param[in] max int32_t Target Data Valid Value Range(Maximum value)
- * @param[in] fn const char* Pointer to the function name
- * @param[in] line int32_t Number of lines
- *
- * @return POS_RET_NORMAL Within the valid range<br>
- * POS_RET_ERROR Out of scope<br>
- * POS_RET_ERROR_PARAM Argument error
- */
-inline POS_RET_API PosChkParam32(int32_t data, int32_t min, int32_t max, const char* fn, int32_t line) {
- POS_RET_API ret = POS_RET_NORMAL;
-
- if (fn == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "Argument ERROR!! fn=%p", fn);
- ret = POS_RET_ERROR_PARAM;
- } else {
- if ((data < min) || (max < data)) {
- ret = POS_RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__,
- "%s/%d/Out of range!! data=%d[%d, %d]",
- fn, line, data, min, max);
- }
- }
-
- return ret;
-}
-
-/**
- * @brief
- * Data Valid Value Determination(unsigned int8)
- *
- * @param[in] date uint8_t Object data
- * @param[in] min uint8_t Target Data Valid Value Range(Minimum value)
- * @param[in] max uint8_t Target Data Valid Value Range(Maximum value)
- * @param[in] fn const char* Pointer to the function name
- * @param[in] line int32_t Number of lines
- *
- * @return POS_RET_NORMAL Within the valid range<br>
- * POS_RET_ERROR Out of scope<br>
- * POS_RET_ERROR_PARAM Argument error
- */
-inline POS_RET_API PosChkParamU8(uint8_t data, uint8_t min, uint8_t max, const char* fn, int32_t line) {
- POS_RET_API ret = POS_RET_NORMAL;
-
- if (fn == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "Argument ERROR!! fn=%p", fn);
- ret = POS_RET_ERROR_PARAM;
- } else {
- if ((data < min) || (max < data)) {
- ret = POS_RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__,
- "%s/%d/Out of range!! data=%u[%u, %u]",
- fn, line, data, min, max);
- }
- }
-
- return ret;
-}
-
-/**
- * @brief
- * Data Valid Value Determination(unsigned int16)
- *
- * @param[in] date uint16_t Object data
- * @param[in] min uint16_t Target Data Valid Value Range(Minimum value)
- * @param[in] max uint16_t Target Data Valid Value Range(Maximum value)
- * @param[in] fn const char* Pointer to the function name
- * @param[in] line int32_t Number of lines
- *
- * @return POS_RET_NORMAL Within the valid range<br>
- * POS_RET_ERROR Out of scope<br>
- * POS_RET_ERROR_PARAM Argument error
- */
-inline POS_RET_API PosChkParamU16(uint16_t data, uint16_t min, uint16_t max, const char* fn, int32_t line) {
- POS_RET_API ret = POS_RET_NORMAL;
-
- if (fn == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "Argument ERROR!! fn=%p", fn);
- ret = POS_RET_ERROR_PARAM;
- } else {
- if ((data < min) || (max < data)) {
- ret = POS_RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__,
- "%s/%d/Out of range!! data=%u[%u, %u]",
- fn, line, data, min, max);
- }
- }
-
- return ret;
-}
-
-/**
- * @brief
- * Data Valid Value Determination(unsigned int32)
- *
- * @param[in] date uint32_t Object data
- * @param[in] min uint32_t Target Data Valid Value Range(Minimum value)
- * @param[in] max uint32_t Target Data Valid Value Range(Maximum value)
- * @param[in] fn const char* Pointer to the function name
- * @param[in] line int32_t Number of lines
- *
- * @return POS_RET_NORMAL Within the valid range<br>
- * POS_RET_ERROR Out of scope<br>
- * POS_RET_ERROR_PARAM Argument error
- */
-inline POS_RET_API PosChkParamU32(uint32_t data, uint32_t min, uint32_t max, const char* fn, int32_t line) {
- POS_RET_API ret = POS_RET_NORMAL;
-
- if (fn == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "Argument ERROR!! fn=%p", fn);
- ret = POS_RET_ERROR_PARAM;
- } else {
- if ((data < min) || (max < data)) {
- ret = POS_RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__,
- "%s/%d/Out of range!! data=%u[%u, %u]",
- fn, line, data, min, max);
- }
- }
-
- return ret;
-}
-
-/**
- * @brief
- * Data setting process(Internal processing)
- *
- * Set the specified information
- *
- * @param[in] did DID - Data ID
- * @param[in] p_data void* - Configuration data
- * @param[in] size uint16_t - Setting data size
- * @param[in] is_event uint8_t - Event wait status(TRUE/FALSE)
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_INNER Internal error
- */
-inline POS_RET_API PosSetProc(DID did, void *p_data, uint16_t size, uint8_t is_event) {
- POS_RET_API ret = POS_RET_NORMAL; /* Return value of this function */
- RET_API ret_api = RET_NORMAL; /* API return value */
- POS_MSGINFO snd_msg; /* Message */
- EventID event_id; /* Event ID */
- int32_t event_val; /* Event value */
- PNO pno; /* Calling thread PNO */
- uint32_t pid; /* Process ID */
- uint32_t tid; /* Thread ID */
- char name[128];
-
- /* Data size check */
- if (POS_MSG_INFO_DSIZE < size) {
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Resource acquisition */
- if (VehicleGetResource() == TRUE) {
- /* Message data */
- /* _CWORD71_ processing speed(Memset modification) */
- /* Initialization of areas that do not contain values */
- snd_msg.pno = 0;
- snd_msg.rcv_flag = 0;
- snd_msg.reserve = 0;
-
- snd_msg.did = did;
- snd_msg.size = size;
- memcpy(snd_msg.data, p_data, size);
-
- if (TRUE == is_event) {
- /* After requesting data setting,Wait for the setting completion(Event Wait) */
-
- /* Event Generation */
- pid = static_cast<uint32_t>(getpid());
- tid = GetTid();
-
- snprintf(name, sizeof(name), "PS_p%u_t%u", pid, tid);
- pno = _pb_CnvName2Pno(name);
- event_id = VehicleCreateEvent(pno);
-
- /* Set the source Pno of message data */
- snd_msg.pno = pno;
-
- if (0 != event_id) {
- /* Successful event generation */
-
- /* Send NAVI Sensor Data Setting to Vehicle Sensor */
- ret_api = VehicleSndMsg(pno,
- PNO_VEHICLE_SENSOR,
- CID_POSIF_SET_DATA,
-
- (uint16_t)sizeof(POS_MSGINFO) - POS_MSG_INFO_DSIZE + snd_msg.size, /* variable length */
- (const void *)&snd_msg);
-
- if (RET_NORMAL == ret_api) {
- /* If the data setup process is successful,Wait for a completion event */
- ret_api = _pb_WaitEvent(event_id,
- SAPI_EVWAIT_VAL,
- VEHICLE_RET_ERROR_MIN,
- VEHICLE_RET_NORMAL, &event_val, POS_API_TIME_OUT_MS);
- if (RET_NORMAL != ret_api) {
- /* Return an internal error */
- ret = POS_RET_ERROR_INNER;
- } else {
- /* Return from Event Wait */
- /* Set event value (processing result) as return value */
- ret = (POS_RET_API)event_val;
- }
- } else {
- /* Message transmission processing failed */
- ret = POS_RET_ERROR_INNER;
- }
- /* Event deletion */
- ret_api = VehicleDeleteEvent(event_id);
- } else {
- /* Event generation failure */
- ret = POS_RET_ERROR_INNER;
- }
- } else {
- /* After setting data,Immediate termination */
-
- /* Send NAVI Sensor Data Setting to Vehicle Sensor */
- ret_api = _pb_SndMsg_Ext(POS_THREAD_NAME,
- CID_POSIF_SET_DATA,
- sizeof(POS_MSGINFO), reinterpret_cast<void*>(&snd_msg), 0);
- if (ret_api != RET_NORMAL) {
- /* Message transmission failure */
- ret = POS_RET_ERROR_INNER;
- }
- }
- } else {
- /* Insufficient resource */
- ret = POS_RET_ERROR_RESOURCE;
- }
- /* Resource release */
- VehicleReleaseResource();
- }
-
- return ret;
-}
-
-/**
- * @brief
- * Sensor information acquisition(Internal processing)
- *
- * @param[in] did DID - Data ID for vehicle information
- * @param[in] p_data void* - Pointer representing the storage destination of vehicle sensor information
- * @param[in] dest_size uint16_t - Storage destination size of vehicle sensor information(byte)
- *
- * @return 0 or more Stored data size(Include illegal)<br>
- * POS_RET_ERROR_CREATE_EVENT Event generation failure<br>
- * POS_RET_ERROR_OUTOF_MEMORY Shared memory allocation failed<br>
- * POS_RET_ERROR_SIZE Storage destination size error<br>
- * POS_RET_ERROR_DID Unregistered ID<br>
- */
-inline POS_RET_API PosGetProc(DID did, void *p_data, uint16_t dest_size) {
- POS_RET_API ret; /* Return value */
- RET_API ret_api; /* System API return value */
- EventID event_id; /* Event ID */
- int32_t event_val; /* Event value */
- void *share_top; /* Start address of shared memory */
- uint32_t share_size; /* Size of shared memory area */
- uint16_t offset; /* Offset to free shared memory area */
- VEHICLE_SHARE_BLOCK_DAT *share_dat; /* Address of free shared memory area */
- VEHICLE_MSG_GET_VEHICLE_DATA_DAT data; /* Message data */
- PNO pno; /* Calling thread PNO */
- uint32_t pid; /* Process ID */
- uint32_t tid; /* Thread ID */
- char name[128];
-
- /* Resource acquisition */
- if (VehicleGetResource() == TRUE) {
- /* Initialization */
- event_id = 0;
- event_val = 0;
- memset(reinterpret_cast<void *>(&data), 0, sizeof(VEHICLE_MSG_GET_VEHICLE_DATA_DAT));
-
- /* Event Generation */
- pid = static_cast<uint32_t>(getpid());
- tid = GetTid();
-
- snprintf(name, sizeof(name), "PG_p%u_t%u", pid, tid);
- pno = _pb_CnvName2Pno(name);
- event_id = VehicleCreateEvent(pno);
-
- if (0 != event_id) {
- /* Successful event generation */
-
- /* Allocate shared memory */
- ret_api = VehicleLinkShareData(reinterpret_cast<void **>(&share_top), &share_size, &offset);
- if (RET_NORMAL != ret_api) {
- /* Failed to allocate shared memory */
- ret = POS_RET_ERROR_OUTOF_MEMORY;
- } else { /* When the shared memory is allocated successfully */
- /* Calculate start address of free shared memory area */
- share_dat = reinterpret_cast<VEHICLE_SHARE_BLOCK_DAT *>(reinterpret_cast<u_int8 *>(share_top)
- + offset);
-
- /* Send vehicle sensor information acquisition message */
- data.did = did;
- data.pno = pno;
- data.offset = offset;
- data.size = VEHICLE_SHARE_BLOCK_DSIZE;
-
- /* Messaging */
- ret_api = VehicleSndMsg(pno,
- PNO_VEHICLE_SENSOR,
- CID_VEHICLEIF_GET_VEHICLE_DATA,
- sizeof(VEHICLE_MSG_GET_VEHICLE_DATA_DAT), (const void *)&data);
-
- /* Message transmission processing is successful */
- if (RET_NORMAL == ret_api) {
- /* Wait for completion event from vehicle sensor thread */
- ret_api = _pb_WaitEvent(event_id,
- SAPI_EVWAIT_VAL,
- VEHICLE_RET_ERROR_MIN,
- VEHICLE_RET_NORMAL, &event_val, POS_API_TIME_OUT_MS);
-
- if (RET_NORMAL != ret_api) {
- /* Return an internal error */
- ret = POS_RET_ERROR_INNER;
- } else { /* Return from Event Wait */
- /* Link to shared memory */
- ret_api = _pb_LinkShareData(const_cast<char *>(VEHICLE_SHARE_NAME),
- &share_top, &share_size);
-
- /* Calculate the address of the shared memory storage area. */
- share_dat = reinterpret_cast<VEHICLE_SHARE_BLOCK_DAT *>(reinterpret_cast<u_int8 *>(share_top)
- + offset);
-
- if (event_val < 0) {
- /* Vehicle sensor information acquisition failure */
- ret = (VEHICLE_RET_API)event_val;
- } else if (RET_NORMAL != ret_api) {
- /* Shared memory error */
- ret = POS_RET_ERROR_OUTOF_MEMORY;
- } else if (dest_size < share_dat->size) {
- /* Storage destination size error */
- ret = POS_RET_ERROR_SIZE;
- } else { /* Vehicle sensor information acquisition success */
- /* Copy from shared memory to user memory */
- memcpy(p_data, share_dat->data, (size_t)share_dat->size);
-
- /* Set Write Size to Return Value */
- ret = static_cast<int32>(share_dat->size);
- }
- }
- } else { /* Message transmission processing failed */
- /* Return an event generation failure */
- ret = POS_RET_ERROR_CREATE_EVENT;
- }
- /* Free shared memory */
- (void)VehicleUnLinkShareData(reinterpret_cast<VEHICLE_SHARE*>(share_top), offset);
- }
- /* Event deletion */
- ret_api = VehicleDeleteEvent(event_id);
- } else {
- /* Event generation failure */
- ret = POS_RET_ERROR_CREATE_EVENT;
- }
- } else {
- /* Insufficient resource */
- ret = POS_RET_ERROR_RESOURCE;
- }
- /* Resource release */
- VehicleReleaseResource();
-
- return ret;
-}
-
-/**
- * @brief
- * Delivery registration process(Internal processing)
- *
- * @param[in] notify_name Destination thread name
- * @param[in] did Pointer to an array of data IDs for vehicle information
- * @param[in] ctrl_flg Delivery control<br>
- * Delivery registration: SENSOR_DELIVERY_REGIST<br>
- * Delivery stop: SENSOR_DELIVERY_STOP (Note: Not mounted)<br>
- * Resume delivery: SENSOR_DELIVERY_RESTART (Note: Not mounted)
- * @param[in] delivery_timing Delivery timing<br>
- * Updating : SENSOR_DELIVERY_TIMING_UPDATE<br>
- * Changing : SENSOR_DELIVERY_TIMING_CHANGE
- *
- * @return SENSOR_RET_NORMAL Successful registration<br>
- * SENSOR_RET_ERROR_CREATE_EVENT Event generation failure<br>
- * SENSOR_RET_ERROR_PARAM Parameter error<br>
- * SENSOR_RET_ERROR_DID Unregistered ID<br>
- * SENSOR_RET_ERROR_BUFFULL FULL of delivery registers<br>
- * SENSOR_RET_ERROR_INNER Internal abnormality<br>
- */
-inline SENSOR_RET_API PosRegisterListenerProc(PCSTR notify_name, DID did, u_int8 ctrl_flg, u_int8 delivery_timing) {
- SENSOR_RET_API ret; /* Return value */
- RET_API ret_api; /* System API return value */
- EventID event_id; /* Event ID */
- int32 event_val; /* Event value */
- VEHICLE_MSG_DELIVERY_ENTRY_DAT data; /* Message data */
- PNO pno; /* Converted internal PNO */
-
- /* Resource acquisition */
- if (VehicleGetResource() == TRUE) {
- /* Initialization */
- event_id = 0;
- event_val = 0;
-
- /* Get PNO from Thread Name */
- pno = _pb_CnvName2Pno(notify_name);
-
- /* Event Generation */
- event_id = VehicleCreateEvent(pno);
-
- if (0 != event_id) {
- /* Successful event generation */
-
- /*--------------------------------------------------------------*
- * Send Vehicle Sensor Information Delivery Registration Message *
- *--------------------------------------------------------------*/
- /* Create Message Data */
- data.did = did;
- data.pno = pno;
- data.delivery_timing = delivery_timing;
- data.ctrl_flg = ctrl_flg;
- data.event_id = event_id;
-
- /* Messaging */
- ret_api = VehicleSndMsg(pno,
- PNO_VEHICLE_SENSOR,
- CID_VEHICLEIF_DELIVERY_ENTRY,
- (uint16_t)sizeof(VEHICLE_MSG_DELIVERY_ENTRY_DAT), (const void *)&data);
-
- if (RET_NORMAL == ret_api) {
- /* Message transmission processing is successful */
- /* Wait for completion event from vehicle sensor thread */
- ret_api = _pb_WaitEvent(event_id,
- SAPI_EVWAIT_VAL,
- VEHICLE_RET_ERROR_MIN,
- VEHICLE_RET_NORMAL, &event_val, POS_API_TIME_OUT_MS);
- if (RET_NORMAL != ret_api) {
- /* Return an internal error */
- ret = SENSOR_RET_ERROR_INNER;
- } else {
- /* Return from Event Wait */
- /* Set event value (processing result) as return value */
- ret = (SENSOR_RET_API)event_val;
- }
- } else {
- /* Message transmission processing failed */
- /* Return an internal error */
- ret = SENSOR_RET_ERROR_INNER;
- }
- /* Event deletion */
- ret_api = VehicleDeleteEvent(event_id);
- } else {
- /* Event generation failure */
- ret = SENSOR_RET_ERROR_CREATE_EVENT;
- }
- } else {
- /* Insufficient resource */
- ret = SENSOR_RET_ERROR_RESOURCE;
- }
- /* Resource release */
- VehicleReleaseResource();
-
- return ret;
-}
-
-/*******************************************************************************
- * MODULE : VehicleCreateEvent
- * ABSTRACT : Event creation process
- * FUNCTION : Generate an event
- * ARGUMENT : pno : Thread ID
- * NOTE :
- * RETURN : Non-zero : Event ID
- * : Zero : Event generation failure
- ******************************************************************************/
-inline EventID VehicleCreateEvent(PNO pno) {
- EventID event_id; /* Event ID */
- char event_name[32]; /* Event name character string buffer */
- RET_API ret_api; /* System API return value */
-
-
- /* Initialization of event name character string buffer */
- memset(reinterpret_cast<void *>(event_name), 0, sizeof(event_name));
- /* Event name creation */
- snprintf(event_name, sizeof(event_name), "VEHICLE_%X", pno);
-
- /* Event Generation */
- event_id = _pb_CreateEvent(FALSE, 0, event_name);
-
- if (0 != event_id) {
- /* For successful event generation */
-
- /* Initialize the event */
- ret_api = _pb_SetEvent(event_id, SAPI_EVSET_ABSOLUTE, VEHICLE_EVENT_VAL_INIT);
- if (RET_NORMAL != ret_api) {
- /* Event initialization failed */
- /* Delete Event and Return Event Generation Failed */
- ret_api = VehicleDeleteEvent(event_id);
- event_id = 0;
- }
- }
-
- return(event_id);
-}
-
-/*******************************************************************************
- * MODULE : VehicleDeleteEvent
- * ABSTRACT : Event deletion processing
- * FUNCTION : Delete events
- * ARGUMENT : event_id : Event ID of the event to delete
- * NOTE :
- * RETURN : RET_NORMAL : Normal completion
- * : RET_EV_NONE : Specified event does not exist
- ******************************************************************************/
-inline RET_API VehicleDeleteEvent(EventID event_id) {
- return(_pb_DeleteEvent(event_id));
-}
-
-/*******************************************************************************
- * MODULE : VehicleLinkShareData
- * ABSTRACT : Link to shared memory
- * FUNCTION : Link to shared memory
- * ARGUMENT : **share_top : Storage destination of shared memory top address
- * : *share_size : Storage destination of shared memory area size
- * : *offset : Offset storage destination to free shared memory area
- * NOTE :
- * RETURN : RET_NORMAL : Normal completion
- * : RET_ERROR : There is no shared memory area.
- ******************************************************************************/
-inline RET_API VehicleLinkShareData(void **share_top, uint32_t *share_size, uint16_t *offset) {
- RET_API ret_api; /* System API return value */
- SemID sem_id; /* Semaphore ID */
- VEHICLE_SHARE *share_top_tmp;
- int32 i;
-
- /* Initialization */
- ret_api = RET_ERROR;
-
- /* Create Semaphore */
- sem_id = _pb_CreateSemaphore(const_cast<char *>(VEHICLE_SEMAPHO_NAME));
- if (0 != sem_id) {
- /* Semaphore Lock */
- ret_api = _pb_SemLock(sem_id);
- if (RET_NORMAL == ret_api) {
- /* Link to shared memory */
- ret_api = _pb_LinkShareData(const_cast<char *>(VEHICLE_SHARE_NAME), share_top, share_size);
- if (RET_NORMAL == ret_api) {
- /* By searching the free shared memory area,Offset is calculated if there is free space. */
- share_top_tmp = reinterpret_cast<VEHICLE_SHARE *>(*share_top);
-
- /* Because the first block of the shared memory area is the control area,Loop from i = 1 */
- for (i = 1; i < VEHICLE_SHARE_BLOCK_NUM; i++) {
- if (VEHICLE_SHARE_UNLOCK == share_top_tmp->mng.lock_info[i]) {
- break;
- }
- }
- if (i < VEHICLE_SHARE_BLOCK_NUM) {
- /* Empty space */
- /* Lock the block */
- share_top_tmp->mng.lock_info[i] = VEHICLE_SHARE_LOCK;
-
- /* Calculate the offset to the block */
- *offset = static_cast<u_int16>(i * VEHICLE_SHARE_BLOCK_SIZE);
-
- /* Normal completion */
- ret_api = RET_NORMAL;
- } else {
- /* No free space */
- ret_api = RET_ERROR;
- }
- } else {
- /* Failed link to shared memory */
- ret_api = RET_ERROR;
- }
- /* Semaphore unlock */
- _pb_SemUnlock(sem_id);
- } else {
- /* Semaphore lock failed */
- ret_api = RET_ERROR;
- }
- } else {
- /* Semaphore creation failed */
- ret_api = RET_ERROR;
- }
-
- return(ret_api);
-}
-
-/*******************************************************************************
- * MODULE : VehicleUnLinkShareData
- * ABSTRACT : Unlinking shared memory
- * FUNCTION : Unlink shared memory
- * ARGUMENT : *share_top : Start address of shared memory
- * : offset : Offset to shared memory free area
- * NOTE :
- * RETURN : RET_NORMAL : Normal completion
- * : RET_ERROR : There is no shared memory area./semaphore error
- ******************************************************************************/
-inline RET_API VehicleUnLinkShareData(VEHICLE_SHARE *share_top, uint16_t offset) {
- RET_API ret_api; /* System API return value */
- SemID sem_id; /* Semaphore ID */
- int32 i;
-
- /* Initialization */
- ret_api = RET_ERROR;
-
- /* Create Semaphore */
- sem_id = _pb_CreateSemaphore(const_cast<char *>(VEHICLE_SEMAPHO_NAME));
- if (0 != sem_id) {
- /* Semaphore Lock */
- ret_api = _pb_SemLock(sem_id);
- if (RET_NORMAL == ret_api) {
- /* Unlock the block */
- i = static_cast<int32>(offset) / VEHICLE_SHARE_BLOCK_SIZE;
- share_top->mng.lock_info[i] = VEHICLE_SHARE_UNLOCK;
-
- /* Semaphore unlock */
- _pb_SemUnlock(sem_id);
-
- /* Normal completion */
- ret_api = RET_NORMAL;
- } else {
- /* Semaphore lock failed */
- ret_api = RET_ERROR;
- }
- } else {
- /* Semaphore creation failed */
- ret_api = RET_ERROR;
- }
-
- return(ret_api);
-}
-
-/*******************************************************************************
- * MODULE : VehicleSndMsg
- * ABSTRACT : Message transmission processing
- * FUNCTION : Send a message to the specified PNO
- * ARGUMENT : pno_src : Source PNO
- * : pno_dest : Destination PNO
- * : cid : Command ID
- * : msg_len : Message data body length
- * : *msg_data : Pointer to message data
- * NOTE :
- * RETURN : RET_NORMAL : Normal completion
- * : RET_ERRNOTRDY : Destination process is not wakeup
- * : RET_ERRMSGFULL : Message queue overflows
- * : RET_ERRPARAM : Buffer size error
- ******************************************************************************/
-inline RET_API VehicleSndMsg(PNO pno_src, PNO pno_dest, CID cid, uint16_t msg_len, const void *msg_data) {
- VEHICLE_MSG_BUF msg_buf; /* message buffer */
- T_APIMSG_MSGBUF_HEADER *msg_hdr; /* Pointer to the message header */
- RET_API ret_api; /* Return value */
- PCSTR thread_name; /* Destination thread name */
-
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__,
- "+ [pno_src = 0x%x, pno_dest = 0x%x]", pno_src, pno_dest);
-
- /* _CWORD71_ processing speed(Memset modification) */
- /* Initializing the header of the message buffer */
- memset(reinterpret_cast<void *>(&msg_buf.hdr), 0, sizeof(T_APIMSG_MSGBUF_HEADER));
-
- /* Get pointer to send buffer */
- msg_hdr = reinterpret_cast<T_APIMSG_MSGBUF_HEADER *>(reinterpret_cast<void *>(&msg_buf));
-
- /*--------------------------------------------------------------*
- * Create message headers *
- *--------------------------------------------------------------*/
- msg_hdr->hdr.sndpno = pno_src; /* Source PNO */
- msg_hdr->hdr.cid = cid; /* Command ID */
- msg_hdr->hdr.msgbodysize = msg_len; /* Message data body length */
-
- /*--------------------------------------------------------------*
- * Create message data *
- *--------------------------------------------------------------*/
- if ((0 != msg_data) && (0 != msg_len)) {
- /* Set the message data */
- memcpy(reinterpret_cast<void *>(msg_buf.data), msg_data, (size_t)msg_len);
- }
- /*--------------------------------------------------------------*
- * Send messages *
- *--------------------------------------------------------------*/
- /* Get Thread Name from PNO */
- if (pno_dest <= SYS_PNO_MAX) {
- thread_name = POS_THREAD_NAME;
- } else {
- thread_name = _pb_CnvPno2Name(pno_dest);
- }
-
- if ((pno_dest <= SYS_PNO_MAX) && (pno_src <= SYS_PNO_MAX)) {
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "[LOG pno_dest = 0x%x]", pno_dest);
-
- /* Internal Process Transmission and Reception Messages */
- ret_api = _pb_SndMsg(pno_dest,
- (uint16_t)(sizeof(T_APIMSG_MSGBUF_HEADER) + msg_len),
- reinterpret_cast<void *>(&msg_buf), 0);
- } else {
- /* External Process Transmission and Reception Messages */
- ret_api = _pb_SndMsg_Ext(thread_name,
- cid,
- (uint16_t)(msg_len), /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- reinterpret_cast<void *>(&(msg_buf.data)), 0);
- }
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "-");
-
- return(ret_api);
-}
-
-/**
- * @brief
- * Resource Acquisition Decision
- *
- * @param[in] none
- *
- * @return TRUE Normal<br>
- * FALSE Abnormality(Insufficient resource)
- */
-inline BOOL VehicleGetResource(void) {
- BOOL ret[4] = {TRUE, TRUE, TRUE, TRUE};
- uint8_t idx;
-
- ret[1] = _pb_GetMsgResource();
- ret[2] = _pb_GetMutexResource();
- ret[3] = _pb_GetOtherResource();
-
- for (idx = 1; idx < 4; idx++) {
- if (ret[idx] == FALSE) {
- ret[0] = FALSE;
- }
- }
-
- return ret[0];
-}
-
-/**
- * @brief
- * Resource release
- *
- * @param[in] none
- *
- * @return none
- */
-inline void VehicleReleaseResource(void) {
- _pb_ReleaseMsgResource();
- _pb_ReleaseMutexResource();
- _pb_ReleaseOtherResource();
-
- return;
-}
-
-inline uint32_t GetTid(void) {
- return (uint32_t)syscall(__NR_gettid);
-}
-
-
-#endif // POSITIONING_CLIENT_INCLUDE_POS_PRIVATE_H_
diff --git a/vehicleservice/positioning/client/include/POS_sensor_private.h b/vehicleservice/positioning/client/include/POS_sensor_private.h
deleted file mode 100755
index 1e1497f..0000000
--- a/vehicleservice/positioning/client/include/POS_sensor_private.h
+++ /dev/null
@@ -1,163 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_POS_SENSOR_PRIVATE_H_
-#define POSITIONING_CLIENT_INCLUDE_POS_SENSOR_PRIVATE_H_
-/******************************************************************************
- * file name :POS_sensor_private.h
- * system name :Positioning
- * sub system name :Positioning internal interface library
- ******************************************************************************/
-
-#include <vehicle_service/POS_sensor_API.h>
-#include <vehicle_service/pos_message_header.h>
-#include <native_service/frameworkunified_types.h>
-/************************************************************************
-* definition *
-************************************************************************/
-/*----------------------------------------------------------------------*
- * for message *
- *----------------------------------------------------------------------*/
-/* command ID */
-#define CID_SENSOR_PKG_INFO 0x0700 /* vehicle sensor package notification ID */
-
-/*----------------------------------------------------------------------*
- * definition for GPS response *
- *----------------------------------------------------------------------*/
-#define GPS_BUFFERFUL 2 /* transmit buffer full(rejection) */
-#define GPS_INITIAL 3 /* initialization state(rejection) */
-#define GPS_CONNECTNG 4 /* connection error(rejection) */
-
-/*----------------------------------------------------------------------*
- * definition clock status *
- *----------------------------------------------------------------------*/
-#define CLOCK_VALID (1U)
-#define CLOCK_INVALID (0U)
-
-/*----------------------------------------------------------------------*
- * Message Related Extensions *
- *----------------------------------------------------------------------*/
-#define CID_SENSORIF_SET_GPSTIME 0x0701 /* GPS time information setting CID */
-
-/*----------------------------------------------------------------------*
- * GPS version-related definitions *
- *----------------------------------------------------------------------*/
-#define GPS__CWORD82__VERSION_LEN (7U) /* _CWORD82_ version data length */
-
-/************************************************************************
-* struct declaration *
-************************************************************************/
-/************************************************************************
-* TAG : SENSOR_MSG_DELIVERY_ENTRY
-* ABSTRACT : vehicle sensor delivery message (to vehicle sensor)
-************************************************************************/
-typedef struct {
- PNO pno; /* destination process number */
- u_int8 pkg_num; /* number of package data (1 - 16) */
- u_int8 delivery_timing; /* delivery timing */
- u_int8 ctrl_flg; /* delivery control flag */
- u_int8 reserve[3];
- EventID event_id; /* event ID */
- DID did[SENSOR_PKG_DELIVERY_MAX]; /* data ID array */
-} SENSOR_MSG_DELIVERY_ENTRY_DAT;
-
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* message header */
- SENSOR_MSG_DELIVERY_ENTRY_DAT data; /* message body */
-} SENSOR_MSG_DELIVERY_ENTRY;
-
-/************************************************************************
-* TAG : SENSOR_MSG_GET_SENSOR_DATA
-* ABSTRACT : vehicle sensor getter message (to vehicle sensor)
-************************************************************************/
-typedef struct {
- PNO pno; /* destination process number */
- u_int8 pkg_num; /* number of package data (1 - 16) */
- u_int8 reserve;
- u_int16 offset; /* share memory offset */
- u_int16 size; /* share memory allocation size */
- EventID event_id; /* event ID */
- DID did[SENSOR_PKG_DELIVERY_MAX]; /* data ID about vehicle sensor */
-} SENSOR_MSG_GET_SENSOR_DATA_DAT;
-
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* message header */
- SENSOR_MSG_GET_SENSOR_DATA_DAT data; /* message body */
-} SENSOR_MSG_GET_SENSOR_DATA;
-
-/************************************************************************
-* TAG : SENSOR_INTERNAL_MSG_BUF
-* ABSTRACT : message buffer
-************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* message header */
- u_int8 data[SENSOR_MSGBUF_DSIZE]; /* message body */
-} SENSOR_INTERNAL_MSG_BUF;
-
-/********************************************************************************
- * TAG :TG_GPSTIME
- * ABSTRACT :GPS Absolute Time Structure
- * NOTE :
- ********************************************************************************/
-typedef struct {
- u_int16 year; /* Year information(4-digit year) */
- u_int8 month; /* Month information */
- u_int8 day; /* Day information */
- u_int8 hour; /* Hour information */
- u_int8 minute; /* Minute information */
- u_int8 second; /* Second information */
- u_int8 reserve; /* reserve */
-} TG_GPSTIME;
-
-/********************************************************************************
- * TAG :TG_GPS_RTCBKUP_DATA
- * ABSTRACT :RTC backup-related data structures
- * NOTE :RTC-backup-related data stored in the SRAM alternate DRAM
- ********************************************************************************/
-typedef struct {
- u_int8 time_status; /* Time Status */
- u_int8 reserve1[3]; /* Reserve 1 */
- TG_GPSTIME gps_time; /* GPS Absolute Time */
-} TG_GPS_RTCBKUP_DATA; /* */
-
-/************************************************************************
- * TAG : GPS_INTERRUPT
- * ABSTRACT : GPS interrupt status
- * NOTE :
-************************************************************************/
-typedef struct {
- u_int8 _CWORD102__interrupt; /* from GPS to _CWORD102_ interrupt status */
- u_int8 _CWORD56__interrupt; /* from GPS to _CWORD56_ interrupt status */
-} GPS_INTERRUPT;
-
-/********************************************************************************
- * TAG :LOCALTIME
- * ABSTRACT :LocalTime data structure
- * NOTE :
- ********************************************************************************/
-typedef struct {
- u_int8 status; /* status : valid or invalid */
- u_int8 reserve[3]; /* reserve */
- u_int16 year; /* year : 2000..2099 (FFFFh:invalid) */
- u_int8 month; /* month : 1..12 (FFh:invalid) */
- u_int8 day; /* date : 1..31 (FFh:invalid) */
- u_int8 hour; /* hour : 0..23 (FFh:invalid) */
- u_int8 min; /* minute : 0..59 (FFh:invalid) */
- u_int8 sec; /* second : 0..59 (FFh:invalid) */
- u_int8 reserve2; /* reserve */
-} LOCALTIME;
-
-#endif // POSITIONING_CLIENT_INCLUDE_POS_SENSOR_PRIVATE_H_
diff --git a/vehicleservice/positioning/client/include/SensorLocation_API.h b/vehicleservice/positioning/client/include/SensorLocation_API.h
deleted file mode 100755
index ae7f20a..0000000
--- a/vehicleservice/positioning/client/include/SensorLocation_API.h
+++ /dev/null
@@ -1,124 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/******************************************************************************
-@file SensorLocation_API.h
-@detail SensorLocation_API external header file<BR>
- SensorLocation_API External public header
-******************************************************************************/
-#ifndef POSITIONING_CLIENT_INCLUDE_SENSORLOCATION_API_H_
-#define POSITIONING_CLIENT_INCLUDE_SENSORLOCATION_API_H_
-
-/*****************************************************************************
- * Include *
- *****************************************************************************/
-
-/*****************************************************************************
- * Define *
- *****************************************************************************/
-/* Command ID */
-#define CID_VEHICLE_SENSORLOCATION_LONLAT (0x0201)
-/* Vehicle sensor information notification CID (Latitude and longitude information)*/
-#define CID_VEHICLE_SENSORLOCATION_ALTITUDE (0x0202)
-/* Vehicle sensor information notification CID (Altitude Information) */
-
-/* SENSORLOCATION_RET_API definition */
-#define SENSORLOCATION_RET_NORMAL (0) /* Successful completion */
-#define SENSORLOCATION_RET_ERROR_PARAM (-1) /* Parameter error */
-#define SENSORLOCATION_RET_ERROR_BUFFULL (-2) /* Number of registered FULL */
-#define SENSORLOCATION_RET_ERROR_INNER (-3) /* Internal error */
-
-/* Delivery opportunity definition */
-#define SENSORLOCATION_DELIVERY_TIMING_CHANGE (0) /* Change */
-#define SENSORLOCATION_DELIVERY_TIMING_UPDATE (1) /* UpDate */
-
-/* Presence information definitions DR */
-#define SENSORLOCATION_EXISTDR_NODR (0) /* Without DR */
-#define SENSORLOCATION_EXISTDR_DR (1) /* There DR */
-
-/* DR state definition */
-#define SENSORLOCATION_DRSTATUS_INVALID (0) /* Invalid */
-#define SENSORLOCATION_DRSTATUS_GPS_NODR (1) /* Information use GPS, not yet implemented DR */
-#define SENSORLOCATION_DRSTATUS_NOGPS_DR (2) /* No information available GPS, DR implementation */
-#define SENSORLOCATION_DRSTATUS_GPS_DR (3) /* Information use GPS, DR implementation */
-
-/* LONLAT initial value definition */
-#define SENSORLOCATION_LATITUDE_INIT_VALUE 0x7FFFFFFFL /* initial value */
-#define SENSORLOCATION_LONGITUDE_INIT_VALUE 0x7FFFFFFFL /* initial value */
-
-/*****************************************************************************
- * Typedef *
- *****************************************************************************/
-typedef int32 SENSORLOCATION_RET_API;
-
-/*****************************************************************************
- * Struct *
- *****************************************************************************/
-/*****************************************************************************
- * TAG : SENSORLOCATION_LONLATINFO_DAT
- * ABSTRACT : Latitude and longitude information data structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- u_int16 size; /* Size */
- u_int8 sensor_cnt; /* Sensor counter value */
- u_int8 is_exist_dr; /* Presence or absence information DR */
- u_int8 dr_status; /* DR state */
- u_int8 reserve[3]; /* Reserve */
- int32 longitude; /* Longitude */
- int32 latitude; /* Latitude */
-} SENSORLOCATION_MSG_LONLATINFO_DAT;
-
-/*****************************************************************************
- * TAG : SENSORLOCATION_ALTITUDEINFO_DAT
- * ABSTRACT : Altitude information data structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- u_int16 size; /* Size */
- u_int8 sensor_cnt; /* Sensor counter value */
- u_int8 is_exist_dr; /* Presence or absence information DR */
- u_int8 dr_status; /* DR state */
- u_int8 reserve[3]; /* Reserve */
- int32 altitude; /* Altitude(0.01m) */
-} SENSORLOCATION_MSG_ALTITUDEINFO_DAT;
-
-/*****************************************************************************
- * TAG : LONLAT
- * ABSTRACT : Latitude and Longitude data structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- int32 latitude; /* Latitude */
- int32 longitude; /* Longitude */
-} LONLAT;
-
-/*****************************************************************************
-* Function prototypes *
-*****************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-extern SENSORLOCATION_RET_API SensorLocationRegisterListenerLonLat(PNO pno, u_int8 delivery_timing);
-extern SENSORLOCATION_RET_API SensorLocationRegisterListenerAltitude(PNO pno, u_int8 delivery_timing);
-extern SENSORLOCATION_RET_API SensorLocationGetLonLat(SENSORLOCATION_MSG_LONLATINFO_DAT *dat);
-extern SENSORLOCATION_RET_API SensorLocationGetAltitude(SENSORLOCATION_MSG_ALTITUDEINFO_DAT *dat);
-extern SENSORLOCATION_RET_API SensorLocationGetLonLatOnShutdown(LONLAT *lonlat);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_SENSORLOCATION_API_H_
diff --git a/vehicleservice/positioning/client/include/SensorLocation_API_private.h b/vehicleservice/positioning/client/include/SensorLocation_API_private.h
deleted file mode 100755
index d37d9eb..0000000
--- a/vehicleservice/positioning/client/include/SensorLocation_API_private.h
+++ /dev/null
@@ -1,39 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_SENSORLOCATION_API_PRIVATE_H_
-#define POSITIONING_CLIENT_INCLUDE_SENSORLOCATION_API_PRIVATE_H_
-/******************************************************************************
- * File name :SensorLocation_API_private.h
- * System name :PastModel002
- * Subsystem name :Vehicle I/F library
- ******************************************************************************/
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-
-/*----------------------------------------------------------------------*
- * Shared Memory Related Extensions *
- *----------------------------------------------------------------------*/
-#define LONLAT_SEMAPHO_NAME ("LONLAT_SHARE_SEMAPHO") /* Semaphore name(MAX 32Byte) */
-
-/*----------------------------------------------------------------------*
- * Shared Memory Related Extensions *
- *----------------------------------------------------------------------*/
-#define LONLAT_SHARE_NAME ("LONLAT_SHARE_MEMORY") /* Shared memory name(MAX 32Byte) */
-
-#endif // POSITIONING_CLIENT_INCLUDE_SENSORLOCATION_API_PRIVATE_H_ */
diff --git a/vehicleservice/positioning/client/include/SensorMotion_API.h b/vehicleservice/positioning/client/include/SensorMotion_API.h
deleted file mode 100755
index 2db5511..0000000
--- a/vehicleservice/positioning/client/include/SensorMotion_API.h
+++ /dev/null
@@ -1,178 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/******************************************************************************
-@file SensorMotion_API.h
-@detail SensorMotion_API external header file<BR>
- SensorMotion_API External public header
-******************************************************************************/
-#ifndef POSITIONING_CLIENT_INCLUDE_SENSORMOTION_API_H_
-#define POSITIONING_CLIENT_INCLUDE_SENSORMOTION_API_H_
-
-/*****************************************************************************
- * Include *
- *****************************************************************************/
-
-/*****************************************************************************
- * Define *
- *****************************************************************************/
-/* Command ID */
-/* Vehicle sensor information notification CID (Rate information) */
-#define CID_VEHICLE_SENSORMOTION_SPEED (0x0203)
-/* Vehicle sensor information notification CID (Orientation information) */
-#define CID_VEHICLE_SENSORMOTION_HEADING (0x0204)
-
-/* Vehicle sensor information notification CID (GyroTrouble information) */
-#define CID_VEHICLE_SENSORMOTION_GYROTROUBLE (0x020A)
-/* Vehicle sensor information notification CID (GyroParameter information) */
-#define CID_VEHICLE_SENSORMOTION_GYROPARAMETER (0x020B)
-/* Vehicle sensor information notification CID (SpeedParameter information) */
-#define CID_VEHICLE_SENSORMOTION_SPEEDPULSEPARAMETER (0x020C)
-
-/* SENSORMOTION_RET_API definition */
-#define SENSORMOTION_RET_NORMAL (0) /* Successful completion */
-#define SENSORMOTION_RET_ERROR_PARAM (-1) /* Parameter error */
-#define SENSORMOTION_RET_ERROR_BUFFULL (-2) /* Number of registered FULL */
-#define SENSORMOTION_RET_ERROR_INNER (-3) /* Internal error */
-
-/* Delivery opportunity definition */
-#define SENSORMOTION_DELIVERY_TIMING_CHANGE (0) /* Change */
-#define SENSORMOTION_DELIVERY_TIMING_UPDATE (1) /* UpDate */
-
-/* Presence information definitions DR */
-#define SENSORMOTION_EXISTDR_NODR (0) /* Without DR */
-#define SENSORMOTION_EXISTDR_DR (1) /* There DR */
-
-/* DR state definition */
-#define SENSORMOTION_DRSTATUS_INVALID (0) /* Invalid */
-#define SENSORMOTION_DRSTATUS_GPS_NODR (1) /* Information use GPS, not yet implemented DR */
-#define SENSORMOTION_DRSTATUS_NOGPS_DR (2) /* No information available GPS, DR implementation */
-#define SENSORMOTION_DRSTATUS_GPS_DR (3) /* Information use GPS, DR implementation */
-
-/*----------------------------------------------------------------------*
- * General Purpose Definition
- *----------------------------------------------------------------------*/
-#define SENSORMOTION_NORMAL (0U)
-#define SENSORMOTION_ERROR (1U)
-#define SENSORMOTION_UNFIXED (2U)
-
-/*****************************************************************************
- * Typedef *
- *****************************************************************************/
-typedef int32 SENSORMOTION_RET_API;
-
-/*****************************************************************************
- * Struct *
- *****************************************************************************/
-/*****************************************************************************
- * TAG : SENSORMOTION_SPEEDINFO_DAT
- * ABSTRACT : Vehicle speed information data structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- u_int16 size; /* Size */
- u_int8 sensor_cnt; /* Sensor counter value */
- u_int8 is_exist_dr; /* Presence or absence information DR */
- u_int8 dr_status; /* DR state */
- u_int8 reserve; /* Reserve */
- u_int16 speed; /* Speed(0.01m/sec) */
-} SENSORMOTION_MSG_SPEEDINFO_DAT;
-
-/*****************************************************************************
- * TAG : SENSORMOTION_MSG_HEADINGINFO_DAT
- * ABSTRACT : Orientation information data structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- u_int16 size; /* Size */
- u_int8 sensor_cnt; /* Sensor counter value */
- u_int8 is_exist_dr; /* Presence or absence information DR */
- u_int8 dr_status; /* DR state */
- u_int8 reserve; /* Reserve */
- u_int16 heading; /* Heading */
-} SENSORMOTION_MSG_HEADINGINFO_DAT;
-
-/*****************************************************************************
- * TAG : SENSORMOTION_MSG_GYROTROUBLEINFO_DAT
- * ABSTRACT : GyroTrouble information data structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- u_int16 size; /* Size */
- u_int8 gyro_trouble; /* Gyro Trouble Status */
- u_int8 reserve; /* Reserve */
-} SENSORMOTION_MSG_GYROTROUBLEINFO_DAT;
-
-/*****************************************************************************
- * TAG : SENSORMOTION_MSG_GYROTROUBLEINFO
- * ABSTRACT : Delivery of the message GyroTrouble information
- * NOTE : Message structure(VehicleSens -> User)
- *****************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- SENSORMOTION_MSG_GYROTROUBLEINFO_DAT data; /* Delivery data (GyroTrouble) */
-} SENSORMOTION_MSG_GYROTROUBLEINFO;
-
-/*****************************************************************************
- * TAG : SENSORMOTION_MSG_GYROPARAMETERINFO_DAT
- * ABSTRACT : GyroParameter information data structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- u_int16 size; /* Size */
- u_int16 gyro_offset; /* Gyro Offset */
- u_int8 gyro_scale_factor; /* Gyro Scale Factor */
- u_int8 gyro_scale_factor_level; /* Gyro Scale Factor Level */
- u_int8 reserve[2]; /* Reserve */
-} SENSORMOTION_MSG_GYROPARAMETERINFO_DAT;
-
-/*****************************************************************************
- * TAG : SENSORMOTION_MSG_GYROPARAMETERINFO
- * ABSTRACT : Delivery of the message GyroParameter information
- * NOTE : Message structure(VehicleSens -> User)
- *****************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- SENSORMOTION_MSG_GYROPARAMETERINFO_DAT data; /* Delivery data (GyroParameter) */
-} SENSORMOTION_MSG_GYROPARAMETERINFO;
-
-/*****************************************************************************
- * TAG : SENSORMOTION_MSG_SPEEDPULSEPARAMETERINFO_DAT
- * ABSTRACT : SpeedPulseParameter information data structure
- * NOTE :
- *****************************************************************************/
-typedef struct {
- u_int16 size; /* Size */
- u_int16 speed_pulse_scale_factor; /* Speed Pulse Scale Factor */
- u_int8 speed_pulse_scale_factor_level; /* Speed Pulse Scale Factor Level */
- u_int8 reserve[3]; /* Reserve */
-} SENSORMOTION_MSG_SPEEDPULSEPARAMETERINFO_DAT;
-
-/*****************************************************************************
- * TAG : SENSORMOTION_MSG_SPEEDPULSEPARAMETERINFO
- * ABSTRACT : Delivery of the message SpeedPulseParameter information
- * NOTE : Message structure(VehicleSens -> User)
- *****************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- SENSORMOTION_MSG_SPEEDPULSEPARAMETERINFO_DAT data; /* Delivery data (SpeedPulseParameter) */
-} SENSORMOTION_MSG_SPEEDPULSEPARAMETERINFO;
-
-/*****************************************************************************
- * Function prototypes *
- *****************************************************************************/
-
-#endif // POSITIONING_CLIENT_INCLUDE_SENSORMOTION_API_H_
diff --git a/vehicleservice/positioning/client/include/Sensor_API.h b/vehicleservice/positioning/client/include/Sensor_API.h
deleted file mode 100755
index b49b4ac..0000000
--- a/vehicleservice/positioning/client/include/Sensor_API.h
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_SENSOR_API_H_
-#define POSITIONING_CLIENT_INCLUDE_SENSOR_API_H_
-/******************************************************************************
- * file name :Sensor_API.h
- * system name :GPF
- * sub system name :sensor interface library
- ******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "Sensor_Common_API.h"
-#include <vehicle_service/POS_sensor_API.h>
-#include "POS_sensor_private.h"
-
-/*!
- @brief GPS Rollover Based Week Number Structure
-*/
-typedef struct {
- uint16_t wkn; /**< GPS rollover base week number */
-} SENSOR_WKNROLLOVER;
-
-#endif // POSITIONING_CLIENT_INCLUDE_SENSOR_API_H_
diff --git a/vehicleservice/positioning/client/include/Sensor_API_private.h b/vehicleservice/positioning/client/include/Sensor_API_private.h
deleted file mode 100755
index c3b5f54..0000000
--- a/vehicleservice/positioning/client/include/Sensor_API_private.h
+++ /dev/null
@@ -1,174 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_SENSOR_API_PRIVATE_H_
-#define POSITIONING_CLIENT_INCLUDE_SENSOR_API_PRIVATE_H_
-/******************************************************************************
- * File name :Sensor_API_private.h
- * System name :GPF
- * Subsystem name Vehicle I/F library
- ******************************************************************************/
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-#define SENSOR_PUBLIC_DID_NUM 31
-
-/*----------------------------------------------------------------------*
- * Shared Memory Related Extensions *
- *----------------------------------------------------------------------*/
-#define SENSOR_SHARE_LOCK 0xFF /* Locking */
-#define SENSOR_SHARE_UNLOCK 0x00 /* Unlocking */
-
-#define SENSOR_SHARE_BLOCK_MNUM 1 /* Number of shared memory control blocks */
-#define SENSOR_SHARE_BLOCK_DNUM 10 /* Number of shared memory data blocks */
-/* Number of shared memory blocks */
-#define SENSOR_SHARE_BLOCK_NUM (SENSOR_SHARE_BLOCK_MNUM+SENSOR_SHARE_BLOCK_DNUM)
-
-#define SENSOR_SHARE_BLOCK_SIZE 512 /* Shared Memory Block Size(byte) */
-#define SENSOR_SHARE_HEAD_SIZE 40 /* Vehicle Sensor Information Header( (4)+1+3+16*2) */
-/* Shared Memory Data Size */
-#define SENSOR_SHARE_BLOCK_DSIZE (SENSOR_SHARE_BLOCK_SIZE - SENSOR_SHARE_HEAD_SIZE)
-/* Size of shared memory allocation area */
-#define SENSOR_SHARE_SIZE (SENSOR_SHARE_BLOCK_SIZE * SENSOR_SHARE_BLOCK_NUM)
-
-#define SENSOR_SEMAPHO_NAME ("SENSOR_SHARE_SEMAPHO") /* Semaphore name */
-#define GPS_INTERRUPT_SIGNAL_SEMAPHO_NAME ("GPS_INT_SIGNAL_SHARE_SEMAPHO") /* Semaphore name(MAX 32Byte) */
-#define GYRO_CONNECT_STATUS_SEMAPHO_NAME ("GYRO_CONNECT_STTS_SHARE_SEMAPHO") /* Semaphore name(MAX 32Byte) */
-#define EPHEMERIS_NUM_SEMAPHO_NAME ("EPHEMERIS_NUM_SHARE_SEMAPHO") /* Semaphore name(MAX 32Byte) */
-#define LOCALTIME_SEMAPHO_NAME ("LOCALTIME_SHARE_SEMAPHO") /* Semaphore name(MAX 32Byte) */
-
-/*----------------------------------------------------------------------*
- * Event Related Extensions *
- *----------------------------------------------------------------------*/
-#define SENSOR_EVENT_VAL_INIT (SENSOR_RET_ERROR_MIN - 1) /* Event initial value */
-
-/*----------------------------------------------------------------------*
- * Shared Memory Related Extensions *
- *----------------------------------------------------------------------*/
-#define SENSOR_SHARE_NAME ("SENSOR_SHARE_MEMORY") /* Shared memory name */
-#define GPS_INTERRUPT_SIGNAL_SHARE_NAME ("GPS_INT_SIGNAL_SHARE_MEMORY") /* Shared memory name(MAX 32Byte) */
-#define GYRO_CONNECT_STATUS_SHARE_NAME ("GYRO_CONNECT_STTS_SHARE_MEMORY") /* Shared memory name(MAX 32Byte) */
-#define EPHEMERIS_NUM_SHARE_NAME ("EPHEMERIS_NUM_SHARE_MEMORY") /* Shared memory name(MAX 32Byte) */
-#define LOCALTIME_SHARE_NAME ("LOCALTIME_SHARE_MEMORY") /* Shared memory name(MAX 32Byte) */
-
-/*-----------------------------------------------------------------------------
- * GPS local CID define
- *----------------------------------------------------------------------------*/
-#define CID_DEV_REQGPS MAKECID(CID_DEVHIGH, 0x00) /* GPS request */
-#define CID_DEV_REQRST MAKECID(CID_DEVHIGH, 0x01) /* GPS reset request */
-
-#define CID_GPS_SERIAL0 (CID)0x0100 /* GPS reset request function definition */
-/* GPS reset request CID */
-
-/*---------------------------------------------------------------------------
- * GPS error log output
- ---------------------------------------------------------------------------*/
-#define GPS_DBGMSG 0 /* Product Shipping Log Output(WPF_DEBUGMSG) */
-#define GPS_RTLMSG 1 /* Development test log output(WPF_RETAILMSG) */
-
-/*----------------------------------------------------------------------*
- * for message *
- *----------------------------------------------------------------------*/
-#define CID_SENSORIF_PKG_DELIVERY_ENTRY_EXT 0x0602 /* sensor extra package register command ID */
-
-/*----------------------------------------------------------------------*
- * for JudgeDid *
- *----------------------------------------------------------------------*/
-#define MODE_REGISTER_LISTENER_PKG_SENS_DATA 0 /* POS_RegisterListenerPkgSensData */
-#define MODE_REGISTER_LISTENER_SENSDATA 1 /* POS_RegisterListenerSensData */
-#define MODE_GET_SENSDATA 2 /* POS_GetSensData */
-
-/************************************************************************
-* Typedef definitions *
-************************************************************************/
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-
-/************************************************************************
-* TAG : SENSOR_SHARE_MNG
-* ABSTRACT : Shared memory management area
-************************************************************************/
-typedef struct {
- uint8_t lock_info[SENSOR_SHARE_BLOCK_NUM]; /* Usages */
- uint8_t reserve[501]; /* 512-11 */
-} SENSOR_SHARE_MNG;
-
-/************************************************************************
-* TAG : SENSOR_SHARE_BLOCK_DAT_DAT
-* ABSTRACT : Shared memory data area(Data section details)
-************************************************************************/
-typedef struct {
- uint8_t pkg_num; /* Number of packages */
- uint8_t reserve[3];
- uint16_t offset[SENSOR_PKG_DELIVERY_MAX]; /* Offset value */
- uint8_t data[SENSOR_SHARE_BLOCK_DSIZE]; /* Data portion */
-} SENSOR_SHARE_BLOCK_DAT_DAT;
-
-/************************************************************************
-* TAG : SENSOR_SHARE_BLOCK_DAT
-* ABSTRACT : Shared memory data area(One block)
-************************************************************************/
-typedef struct {
- uint16_t size; /* Size of the data */
- uint8_t reserve[2];
- SENSOR_SHARE_BLOCK_DAT_DAT data; /* Data portion */
-} SENSOR_SHARE_BLOCK_DAT;
-
-/************************************************************************
-* TAG : SENSOR_SHARE_BLOCK_MNG
-* ABSTRACT : Areas of memory that are shared
-************************************************************************/
-typedef struct {
- SENSOR_SHARE_MNG mng; /* Shared memory management information */
- SENSOR_SHARE_BLOCK_DAT data[SENSOR_SHARE_BLOCK_DNUM]; /* Shared memory data portion */
-} SENSOR_SHARE;
-
-/**
- * @brief Return code list structure
- */
-typedef struct {
-/*
- * Note.
- * This feature needs to be defined according to the unit type.
- */
- BOOL GRADE2_ret; /**< Return code in GRADE2 */
- BOOL GRADE1_ret; /**< Return code in GARDE1 */
- DID did; /**< DID */
-} SENSOR_RET_PKG;
-
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-RET_API PosDeleteEvent(EventID event_id);
-RET_API SensorLinkShareData(void **share_top, uint32_t *share_size, uint16_t *offset);
-RET_API SensorUnLinkShareData(SENSOR_SHARE *share_top, uint16_t offset);
-
-EventID PosCreateEvent(PNO pno);
-void SensorSetShareData(void *share_top, uint16_t offset, const void *data_src, uint16_t size_src);
-RET_API PosSndMsg(PNO pno_src, PNO pno_dest, CID cid, uint16_t msg_len, const void *msg_data);
-
-BOOL SensorJudgeDid(DID did, uint8_t mode);
-
-/* Function macro */
-#define SENSOR_DID_JUDGE_REGLIS_PKG(did) SensorJudgeDid(did, MODE_REGISTER_LISTENER_PKG_SENS_DATA)
-#define SENSOR_DID_JUDGE_REGLIS(did) SensorJudgeDid(did, MODE_REGISTER_LISTENER_SENSDATA)
-#define SENSOR_DID_JUDGE_GET(did) SensorJudgeDid(did, MODE_GET_SENSDATA)
-
-#endif // POSITIONING_CLIENT_INCLUDE_SENSOR_API_PRIVATE_H_ */
diff --git a/vehicleservice/positioning/client/include/Sensor_Common_API.h b/vehicleservice/positioning/client/include/Sensor_Common_API.h
deleted file mode 100755
index 5631e83..0000000
--- a/vehicleservice/positioning/client/include/Sensor_Common_API.h
+++ /dev/null
@@ -1,193 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_SENSOR_COMMON_API_H_
-#define POSITIONING_CLIENT_INCLUDE_SENSOR_COMMON_API_H_
-/******************************************************************************
- * File name :Sensor_Common_API.h
- * System name :PastModel002
- * Sub System name :Vehicle I/F Liblary,Sensor I/F Liblary
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include <vehicle_service/POS_sensor_API.h>
-#include "CommonDefine.h"
-
-/************************************************************************
- * Definition *
- ************************************************************************/
-/*----------------------------------------------------------------------*
- * ID data corresponding to the vehicle sensor information *
- *----------------------------------------------------------------------*/
-
-/*
- * Note.
- * This feature needs to be defined by the vendor.
- */
-
-/* VEHICLE__DID */
-
-/* ++ PastModel002 Support_UBX_Protocol_DID */
-#define VEHICLE_DID_GPS_UBLOX_NAV_POSLLH 0x80000060
-#define VEHICLE_DID_GPS_UBLOX_NAV_STATUS 0x80000061
-#define VEHICLE_DID_GPS_UBLOX_NAV_TIMEUTC 0x80000062
-#define VEHICLE_DID_GPS_UBLOX_NAV_VELNED 0x80000063
-#define VEHICLE_DID_GPS_UBLOX_NAV_DOP 0x80000064
-#define VEHICLE_DID_GPS_UBLOX_NAV_TIMEGPS 0x80000065
-#define VEHICLE_DID_GPS_UBLOX_NAV_SVINFO 0x80000066
-#define VEHICLE_DID_GPS_UBLOX_NAV_CLOCK 0x80000067
-#define VEHICLE_DID_GPS_UBLOX_MON_HW 0x80000068
-#define VEHICLE_DID_GPS_UBLOX_ACK_ACK 0x80000069
-#define VEHICLE_DID_GPS_UBLOX_ACK_NAK 0x8000006A
-#define VEHICLE_DID_GPS_UBLOX_CFG_RST 0x8000006B
-#define VEHICLE_DID_GPS_UBLOX_AID_INI 0x8000006C
-#define VEHICLE_DID_GPS_UBLOX_AID_EPH 0x8000006D
-#define VEHICLE_DID_GPS_UBLOX_CFG_MSG 0x8000006E
-#define VEHICLE_DID_GPS_UBLOX_CFG_NAVX5 0x8000006F
-/* -- PastModel002 Support_UBX_Protocol_DID */
-
-/* ++ used internally by the DR */
-#define VEHICLE_DID_GPS_COUNTER 0x8000001B
-#define VEHICLE_DID_GYRO_EXT 0x80000027
-
-#define VEHICLE_DID_DR_LONGITUDE 0x80000070
-#define VEHICLE_DID_DR_LATITUDE 0x80000071
-#define VEHICLE_DID_DR_ALTITUDE 0x80000072
-#define VEHICLE_DID_DR_SPEED 0x80000073
-#define VEHICLE_DID_DR_HEADING 0x80000074
-#define VEHICLE_DID_DR_SNS_COUNTER 0x80000075
-#define VEHICLE_DID_DR_GYRO_OFFSET 0x80000078
-#define VEHICLE_DID_DR_GYRO_SCALE_FACTOR 0x80000079
-#define VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL 0x8000007A
-#define VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR 0x8000007B
-#define VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL 0x8000007C
-
-/* -- used internally by the DR */
-
-/* ++ PastModel002 Support_DID */
-#define VEHICLE_DID_GYRO_TROUBLE 0x80000080
-#define VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL 0x80000081
-#define VEHICLE_DID_SYS_GPS_INTERRUPT_SIGNAL 0x80000082
-#define VEHICLE_DID_GYRO_CONNECT_STATUS 0x80000083
-#define VEHICLE_DID_VALID_EPH_NUM 0x80000084
-/* -- PastModel002 Support_DID */
-
-/* ++ Not supported by UBX_Protocol */
-#define VEHICLE_DID_LOCATION 0x80000020
-#define VEHICLE_DID_GPS__CWORD82__NMEA POS_DID_GPS__CWORD82__NMEA
-#define VEHICLE_DID_GPS__CWORD82__SETINITIAL POS_DID_GPS__CWORD82__SETINITIAL
-#define VEHICLE_DID_GPS__CWORD82__SETRMODE 0x80000034
-#define VEHICLE_DID_GPS__CWORD82__SETRMODEEX POS_DID_GPS__CWORD82__SETRMODEEX
-#define VEHICLE_DID_GPS__CWORD82__SELSENT POS_DID_GPS__CWORD82__SELSENT
-#define VEHICLE_DID_GPS__CWORD82__SETSBAS 0x80000037
-#define VEHICLE_DID_GPS__CWORD82__SETCONF1 0x80000038
-#define VEHICLE_DID_GPS__CWORD82__SETCONF2 0x80000039
-#define VEHICLE_DID_GPS__CWORD82__NMEA_GGA_INTERNAL 0xA050
-#define VEHICLE_DID_GPS__CWORD82__NMEA_DGGA_INTERNAL 0xA051
-#define VEHICLE_DID_GPS__CWORD82__NMEA_VTG_INTERNAL 0xA052
-#define VEHICLE_DID_GPS__CWORD82__NMEA_RMC_INTERNAL 0xA053
-#define VEHICLE_DID_GPS__CWORD82__NMEA_DRMC_INTERNAL 0xA054
-#define VEHICLE_DID_GPS__CWORD82__NMEA_GLL_INTERNAL 0xA055
-#define VEHICLE_DID_GPS__CWORD82__NMEA_DGLL_INTERNAL 0xA056
-#define VEHICLE_DID_GPS__CWORD82__NMEA_GSA_INTERNAL 0xA057
-#define VEHICLE_DID_GPS__CWORD82__NMEA_GSV1_INTERNAL 0xA058
-#define VEHICLE_DID_GPS__CWORD82__NMEA_GSV2_INTERNAL 0xA059
-#define VEHICLE_DID_GPS__CWORD82__NMEA_GSV3_INTERNAL 0xA060
-#define VEHICLE_DID_GPS__CWORD82__NMEA_PJRDC_GP_3_INTERNAL 0xA061
-#define VEHICLE_DID_LOCATION_LONLAT 0x80000095
-#define VEHICLE_DID_LOCATION_ALTITUDE 0x80000096
-#define VEHICLE_DID_MOTION_SPEED 0x80000062
-#define VEHICLE_DID_MOTION_HEADING 0x80000097
-#define VEHICLE_DID_GPS_TIME 0x80000098
-#define VEHICLE_DID_NAVIINFO_DIAG_GPS 0x80000099
-#define VEHICLE_DID_GPSWEEKCOR_CNT 0x8000009A
-
-#define VEHICLE_DID_GPS_CUSTOMDATA_NAVI 0x800000A0
-#define VEHICLE_DID_LOCATION_LONLAT_NAVI 0x800000A1
-#define VEHICLE_DID_LOCATION_ALTITUDE_NAVI 0x800000A2
-#define VEHICLE_DID_MOTION_SPEED_NAVI 0x800000A3
-#define VEHICLE_DID_MOTION_HEADING_NAVI 0x800000A4
-#define VEHICLE_DID_SETTINGTIME 0x800000A5
-
-#define VEHICLE_DID_LOCATIONINFO_NMEA_NAVI 0x800000A6
-
-#define VEHICLE_DID_MOTION_SPEED_INTERNAL 0x800000B0
-
-#define VEHICLE_DID_GPS_TIME_RAW 0x800000B1U /* QAC 1281 */
-#define VEHICLE_DID_GPS_WKNROLLOVER 0x800000B2U /* QAC 1281 */
-
-#define VEHICLE_DID_SPEED_PULSE_VEHICLE (0x80000044UL)
-
-/* -- Not supported by UBX_Protocol */
-
-/*----------------------------------------------------------------------*
- * Vehicle sensor data information *
- *----------------------------------------------------------------------*/
-#define VEHICLE_SNS_BATTERY_SHORT 0x02 /* BATTERY SHORT */
-#define VEHICLE_SNS_THERMAL_SHUT_DOWN 0x04 /* THERMAL SHUT DOWN */
-#define VEHICLE_SNS_UNKNOWN 0x05 /* UNKNOWN */
-
-/* Missing information data */
-#define VEHICLE_SNS_BREAK 0x01 /* Data without continuity */
-#define VEHICLE_SNS_NORMAL 0x00 /* Continuity of data */
-
-/*-------------------------------------------------------------------------------
- * Time Status Return Values
- -------------------------------------------------------------------------------*/
-#define GPS_TIMESTS_OK (0x00U) /* Exact values from the satellites */
-/* Ignore->MISRA-C++ Rule 16-2-2 */
-#define GPS_TIMESTS_NOTUTC (0x01U) /* Time from satellite but UTC uncorrected */
-/* Ignore->MISRA-C++ Rule 16-2-2 */
-#define GPS_TIMESTS_RTC (0x02U) /* RTC time */
-/* Ignore->MISRA-C++ Rule 16-2-2 */
-#define GPS_TIMESTS_NG (0x03U) /* Anomaly Time */
-/* Ignore->MISRA-C++ Rule 16-2-2 */
-
-/*-------------------------------------------------------------------------------
- * NMEA Receive Flag
- -------------------------------------------------------------------------------*/
-#define VEHICLE_SNS__CWORD82__DRMC POS_SNS__CWORD82__DRMC
-#define VEHICLE_SNS__CWORD82__GSA POS_SNS__CWORD82__GSA
-#define VEHICLE_SNS__CWORD82__GSV_1 POS_SNS__CWORD82__GSV_1
-#define VEHICLE_SNS__CWORD82__GSV_2 POS_SNS__CWORD82__GSV_2
-#define VEHICLE_SNS__CWORD82__GSV_3 POS_SNS__CWORD82__GSV_3
-#define VEHICLE_SNS__CWORD82__PJRDC_GP_3 POS_SNS__CWORD82__PJRDC_GP_3
-#define VEHICLE_SNS__CWORD82__PJRDC_GP_4 (0x40U) /* Ignore->MISRA-C++ Rule 16-2-2 */
-
-/************************************************************************
-* enum Definition *
-*************************************************************************/
-
-/*-------------------------------------------------------------------------------
- * _CWORD71_ UNIT type
- -------------------------------------------------------------------------------*/
-typedef enum {
- POS_TYPE_NONE = (0U), /* Undefined */
- POS_TYPE_GRADE1, /* GRADE1 (Integrated) */
- POS_TYPE_GRADE2 /* GRADE2 (Binary type) */
-} POS_TYPE;
-
-/************************************************************************
-* typedef Definition *
-*************************************************************************/
-
-typedef u_int32 DID; /* DataID */
-
-/************************************************************************
-* struct Definition *
-*************************************************************************/
-
-#endif // POSITIONING_CLIENT_INCLUDE_SENSOR_COMMON_API_H_
diff --git a/vehicleservice/positioning/client/include/VehicleDebug_API.h b/vehicleservice/positioning/client/include/VehicleDebug_API.h
deleted file mode 100755
index e0c9ef2..0000000
--- a/vehicleservice/positioning/client/include/VehicleDebug_API.h
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/******************************************************************************
- * File name : VehicleDebug_API.h
- * System name : PastModel002
- * Sub System name : VehicleDebug_API library
- ******************************************************************************/
-#ifndef POSITIONING_CLIENT_INCLUDE_VEHICLEDEBUG_API_H_
-#define POSITIONING_CLIENT_INCLUDE_VEHICLEDEBUG_API_H_
-
-/************************************************************************
- * Include *
- ***********************************************************************/
-
-/************************************************************************
-* Definition *
-************************************************************************/
-/*----------------------------------------------------------------------*
- * VEHICLEDEBUG_RET_API Definition *
- *----------------------------------------------------------------------*/
-/* Normal */
-#define VEHICLEDEBUG_RET_NORMAL 0 /* Successful completion */
-
-/* Abnormal */
-#define VEHICLEDEBUG_RET_ERROR (-1) /* An error has occurred */
-#define VEHICLEDEBUG_RET_ERROR_PARAM (-2) /* Parameter error */
-
-/*----------------------------------------------------------------------*
- * Message Definition *
- *----------------------------------------------------------------------*/
-/* Command ID */
-#define CID_VEHICLEDEBUG_LOG_SET 0x020D
-#define CID_VEHICLEDEBUG_LOG_GET 0x020E
-
-/* Message Length */
-#define VEHICLEDEBUG_MSGBUF_DSIZE 36U
-
-/*----------------------------------------------------------------------*
- * Log Kind Definition *
- *----------------------------------------------------------------------*/
-#define LOG_KIND_NUM 32U
-
-/*----------------------------------------------------------------------*
- * Log Mask Definition *
- *----------------------------------------------------------------------*/
-#define LOG_MASK_LOCATION_LOG 0x00000001UL
-
-/*----------------------------------------------------------------------*
- * Log Severity Definition *
- *----------------------------------------------------------------------*/
-/* Unused */
-
-/************************************************************************
-* type Definition *
-************************************************************************/
-typedef RET_API VEHICLEDEBUG_RET_API; /* API return value */
-
-/************************************************************************
-* struct Definition *
-************************************************************************/
-/************************************************************************
- * TAG : VEHICLEDEBUG_MSG_LOGINFO_DAT
- * ABSTRACT : Log data structure
- * NOTE :
- ************************************************************************/
-typedef struct {
- u_int32 log_sw; /* Kind of log */
- u_int8 severity[LOG_KIND_NUM]; /* Output level(unused) */
-} VEHICLEDEBUG_MSG_LOGINFO_DAT;
-
-/*****************************************************************************
- * TAG : VEHICLEDEBUG_MSG_BUF
- * ABSTRACT : VehicleDebug_API message buffer structure
- * NOTE : Message structure
- *****************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- u_int8 data[VEHICLEDEBUG_MSGBUF_DSIZE]; /* Message data */
-} VEHICLEDEBUG_MSG_BUF;
-
-/************************************************************************
- * Function prototypes *
- ************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*[VehicleDebug_API Public API]*/
-VEHICLEDEBUG_RET_API SensorGetLogSetting(PNO pno, u_int32 *log_sw, u_int8 *severity);
-VEHICLEDEBUG_RET_API SensorSetLogStatus(PNO pno, u_int32 log_sw, u_int8 *severity);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_VEHICLEDEBUG_API_H_
diff --git a/vehicleservice/positioning/client/include/Vehicle_API.h b/vehicleservice/positioning/client/include/Vehicle_API.h
deleted file mode 100755
index 78450c5..0000000
--- a/vehicleservice/positioning/client/include/Vehicle_API.h
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_VEHICLE_API_H_
-#define POSITIONING_CLIENT_INCLUDE_VEHICLE_API_H_
-/******************************************************************************
- * File name :Vehicle_API.h
- * System name :GPF
- * Sub System name :Vehicle I/F Liblary
- ******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include <vehicle_service/POS_define.h>
-#include "Sensor_Common_API.h"
-
-/****************************************************************************
-* Definition *
-*****************************************************************************/
-/*--------------------------------------------------------------------------*
- * VECHILE_RET_API Definition *
- *--------------------------------------------------------------------------*/
-/* Normal system */
-#define VEHICLE_RET_NORMAL 0 /* Successful completion */
-
-/* Abnormal system */
-#define VEHICLE_RET_ERROR_DID (-2) /* NoneDID */
-#define VEHICLE_RET_ERROR_PARAM (-4) /* Parameter error */
-#define VEHICLE_RET_ERROR_BUFFULL (-5) /* registration number FULL */
-#define VEHICLE_RET_ERROR_CREATE_EVENT (-6) /* Failure event generation */
-#define VEHICLE_RET_ERROR_MIN POS_RET_ERROR_MIN
-
-/*----------------------------------------------------------------------*
- * API-related registration information delivery vehicle sensor *
- *----------------------------------------------------------------------*/
-/* Delivery control */
-#define VEHICLE_DELIVERY_REGIST 0x01 /* Shipping register */
-
-/* Delivery opportunity */
-#define VEHICLE_DELIVERY_TIMING_UPDATE 0x01 /* Update */
-#define VEHICLE_DELIVERY_TIMING_CHANGE 0x02 /* Change */
-
-/*----------------------------------------------------------------------*
- * Message Definition *
- *----------------------------------------------------------------------*/
-/* Command ID */
-
-/* Registration information delivery vehicle sensor CID */
-#define CID_VEHICLEIF_DELIVERY_ENTRY 0x0101
-
-/* Vehicle sensor information notification CID */
-#define CID_VEHICLESENS_VEHICLE_INFO 0x0200
-
-/* GPS time notification CID */
-#define CID_VEHICLESENS_VEHICLE_INFO_GPS_TIME 0x0201
-
-/************************************************************************
-* typedef Definition *
-************************************************************************/
-typedef RET_API VEHICLE_RET_API; /* API return value */
-
-/************************************************************************
-* struct Definition *
-************************************************************************/
-
-/************************************************************************
-* TAG : VEHICLE_MSG_VSINFO_DAT
-* ABSTRACT : message delivery vehicle sensor information
-************************************************************************/
-typedef struct {
- DID did;
- u_int16 size;
- u_int8 rcv_flag;
- u_int8 sensor_cnt;
- u_int8 data[256];
-} VEHICLE_MSG_VSINFO_DAT;
-
-/* ++ GPS _CWORD82_ support */
-
-/************************************************************************
-* TAG : VEHICLE_MSG_SEND_DAT
-* ABSTRACT : Vehicle sensor information setting message(-> Vehicle sensor)
-************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- VEHICLE_MSG_SEND_DAT data; /* Message data */
-} VEHICLE_MSG_SEND;
-
-/* -- GPS _CWORD82_ support */
-
-/************************************************************************
-* Function prototypes *
-************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-/*[VEHICLE_API Public API]*/
-VEHICLE_RET_API VehicleInitialize(u_int32(*sighand)(void)); /* QAC 3001 */
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_VEHICLE_API_H_
diff --git a/vehicleservice/positioning/client/include/Vehicle_API_Dummy.h b/vehicleservice/positioning/client/include/Vehicle_API_Dummy.h
deleted file mode 100755
index b242ac6..0000000
--- a/vehicleservice/positioning/client/include/Vehicle_API_Dummy.h
+++ /dev/null
@@ -1,142 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_VEHICLE_API_DUMMY_H_
-#define POSITIONING_CLIENT_INCLUDE_VEHICLE_API_DUMMY_H_
-/******************************************************************************
- * File name : Vehicle_API_Dummy.h
- * System name : GPF
- * Sub System name : Vehicle I/F Liblary
- ******************************************************************************/
-
-#include "Sensor_Common_API.h"
-
-/****************************************************************************
-* Definition *
-*****************************************************************************/
-/*--------------------------------------------------------------------------*
- * VECHILE_RET_API Definition *
- *--------------------------------------------------------------------------*/
-/* Normal system */
-#define VEHICLE_RET_NORMAL 0 /* Successful completion */
-
-/* Abnormal system */
-#define VEHICLE_RET_ERROR_PID (-1) /* Abnormal thread ID */
-#define VEHICLE_RET_ERROR_DID (-2) /* NoneDID */
-#define VEHICLE_RET_ERROR_DID_DIS (-3) /* Non-ID data CANID */
-#define VEHICLE_RET_ERROR_PARAM (-4) /* Parameter error */
-#define VEHICLE_RET_ERROR_BUFFULL (-5) /* registration number FULL */
-#define VEHICLE_RET_ERROR_CREATE_EVENT (-6) /* Failure event generation */
-#define VEHICLE_RET_ERROR_TIMER (-7) /* Generation failure timer */
-#define VEHICLE_RET_ERROR_OUTOF_MEMORY (-8) /* Shared memory allocation failure */
-#define VEHICLE_RET_ERROR_SIZE (-9) /* Size error destination */
-#define VEHICLE_RET_ERROR_INVALID (-10) /* CANID undetermined */
-#define VEHICLE_RET_ERROR_MIN POS_RET_ERROR_MIN
-
-/*----------------------------------------------------------------------*
- * API-related registration information delivery vehicle sensor *
- *----------------------------------------------------------------------*/
-/* Delivery control */
-#define VEHICLE_DELIVERY_REGIST 0x01 /* Shipping register */
-
-/* Delivery opportunity */
-#define VEHICLE_DELIVERY_TIMING_UPDATE 0x01 /* Update */
-#define VEHICLE_DELIVERY_TIMING_CHANGE 0x02 /* Change */
-
-/*----------------------------------------------------------------------*
- * Message Definition *
- *----------------------------------------------------------------------*/
-/* Command ID */
-
-/* Registration information delivery vehicle sensor CID */
-#define CID_VEHICLEIF_DELIVERY_ENTRY 0x0101
-
-/* Vehicle sensor information notification CID */
-#define CID_VEHICLESENS_VEHICLE_INFO 0x0200
-
-#define CID_VEHICLEIF_GET_DR_DATA 0x0205
-
-/* The message body size data(byte) */
-#define VEHICLE_MSGBUF_DSIZE (SENSOR_MSG_VSINFO_DSIZE + 12)
-/* Header size of SENSOR_MSG_VSINFO_DSIZE + SENSOR_MSG_GPSDATA_DAT (12) */
-
-/************************************************************************
-* typedef Definition *
-************************************************************************/
-
-/************************************************************************
-* struct Definition *
-************************************************************************/
-
-/************************************************************************
-* TAG : VEHICLE_MSG_BUF
-* ABSTRACT : Message buffer
-************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- u_int8 data[VEHICLE_MSGBUF_DSIZE]; /* Message data */
-} VEHICLE_MSG_BUF;
-
-/************************************************************************
-* TAG : VEHICLE_MSG_GET_VEHICLE_DATA
-* ABSTRACT : Vehicle sensor information acquisition message(-> Vehicle sensor)
-************************************************************************/
-typedef struct {
- DID did; /* Data ID corresponding to vehicle sensor information */
- PNO pno; /* Destination PNO */
- u_int16 offset; /* Offset to shared memory storage area */
- u_int16 size; /* Size of shared memory storage area */
- u_int8 reserve[2];
- EventID event_id; /* Event ID */
-} VEHICLE_MSG_GET_VEHICLE_DATA_DAT;
-
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- VEHICLE_MSG_GET_VEHICLE_DATA_DAT data; /* Message data */
-} VEHICLE_MSG_GET_VEHICLE_DATA;
-
-/************************************************************************
-* TAG : VEHICLE_MSG_DELIVERY_ENTRY
-* ABSTRACT : Registration message delivery vehicle sensor information(->Vehicle sensor)
-************************************************************************/
-typedef struct {
- DID did; /* ID data corresponding to the vehicle sensor information */
- PNO pno; /* Shipping addressPNO */
- u_int8 delivery_timing; /* Delivery opportunity */
- u_int8 ctrl_flg; /* Delivery control */
- EventID event_id; /* Event ID */
-} VEHICLE_MSG_DELIVERY_ENTRY_DAT;
-
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- VEHICLE_MSG_DELIVERY_ENTRY_DAT data; /* Message data */
-} VEHICLE_MSG_DELIVERY_ENTRY;
-
-/************************************************************************
-* Function prototypes *
-************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-/*[VEHICLE_API Public API]*/
-
-int32 VehicleGetDrData(PNO pno, DID did, void *dest_data, u_int16 dest_size);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_CLIENT_INCLUDE_VEHICLE_API_DUMMY_H_
diff --git a/vehicleservice/positioning/client/include/Vehicle_API_private.h b/vehicleservice/positioning/client/include/Vehicle_API_private.h
deleted file mode 100755
index ad92ddb..0000000
--- a/vehicleservice/positioning/client/include/Vehicle_API_private.h
+++ /dev/null
@@ -1,129 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_CLIENT_INCLUDE_VEHICLE_API_PRIVATE_H_
-#define POSITIONING_CLIENT_INCLUDE_VEHICLE_API_PRIVATE_H_
-/******************************************************************************
- * File name :Vehicle_API_private.h
- * System name :GPF
- * Subsystem name :Vehicle I/F library
- ******************************************************************************/
-#include <vehicle_service/POS_sensor_API.h>
-#include "Vehicle_API.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-
-/*----------------------------------------------------------------------*
- * Shared Memory Related Extensions *
- *----------------------------------------------------------------------*/
-#define VEHICLE_SHARE_LOCK 0xFF /* Locking */
-#define VEHICLE_SHARE_UNLOCK 0x00 /* Unlocking */
-
-#define VEHICLE_SHARE_BLOCK_MNUM 1 /* Number of shared memory control blocks */
-#define VEHICLE_SHARE_BLOCK_DNUM 10 /* Number of shared memory data blocks */
-/* Number of shared memory blocks */
-#define VEHICLE_SHARE_BLOCK_NUM (VEHICLE_SHARE_BLOCK_MNUM+VEHICLE_SHARE_BLOCK_DNUM)
-
-#define VEHICLE_SHARE_BLOCK_SIZE 512 /* Shared Memory Block Size(byte) */
-#define VEHICLE_SHARE_BLOCK_DSIZE SENSOR_MSG_VSINFO_DSIZE /* Shared Memory Data Size */
-/* Size of shared memory allocation area */
-#define VEHICLE_SHARE_SIZE (VEHICLE_SHARE_BLOCK_SIZE * VEHICLE_SHARE_BLOCK_NUM)
-
-#define VEHICLE_SEMAPHO_NAME ("VEHICLE_SHARE_SEMAPHO") /* Semaphore name */
-
-#define VEHICLE_INVALID 0 /* Disabled */
-#define VEHICLE_EFFECTIVE 1 /* Enabled */
-#define VEHICLE_BIT31 0x80000000
-
-/* ++ PastModel002 compliant_error compliant */
-/* Message Data Size(byte) */
-#define VEHICLE_VSINFO_DSIZE 504 /* Vehicle sensor information */
-/* -- PastModel002 compliant_error compliant */
-
-/*----------------------------------------------------------------------*
- * Event Related Extensions *
- *----------------------------------------------------------------------*/
-#define VEHICLE_EVENT_VAL_INIT (VEHICLE_RET_ERROR_MIN-1) /* Event initial value */
-
-/*----------------------------------------------------------------------*
- * Shared Memory Related Extensions *
- *----------------------------------------------------------------------*/
-#define VEHICLE_SHARE_NAME ("POS_VEHICLE_SHARE_MEMORY") /* Shared memory name */
-
-/************************************************************************
-* Typedef definitions *
-************************************************************************/
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-
-/* ++ PastModel002 compliant_error compliant */
-
-/************************************************************************
-* TAG : VEHICLE_MSG_VSINFO_DAT
-* ABSTRACT : Vehicle sensor information notification message(-> User)
-************************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr; /* Message header */
- VEHICLE_MSG_VSINFO_DAT data; /* Message data */
-} VEHICLE_MSG_VSINFO;
-
-/* -- PastModel002 compliant_error compliant */
-
-/************************************************************************
-* TAG : VEHICLE_SHARE_MNG
-* ABSTRACT : Shared memory management area
-************************************************************************/
-typedef struct {
- u_int8 lock_info[VEHICLE_SHARE_BLOCK_NUM]; /* Usages */
- u_int8 reserve[501];
-} VEHICLE_SHARE_MNG;
-
-/************************************************************************
-* TAG : VEHICLE_SHARE_BLOCK_DAT
-* ABSTRACT : Shared memory data area(One block)
-************************************************************************/
-typedef struct {
- u_int16 size; /* Size of the data */
- u_int8 reserve[2];
- u_int8 data[VEHICLE_SHARE_BLOCK_DSIZE]; /* Data */
-} VEHICLE_SHARE_BLOCK_DAT;
-
-/************************************************************************
-* TAG : VEHICLE_SHARE_BLOCK_MNG
-* ABSTRACT : Areas of memory that are shared
-************************************************************************/
-typedef struct {
- VEHICLE_SHARE_MNG mng; /* Shared memory management information */
- VEHICLE_SHARE_BLOCK_DAT data[VEHICLE_SHARE_BLOCK_DNUM]; /* Shared memory data portion */
-} VEHICLE_SHARE;
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-RET_API VehicleDeleteEvent(EventID event_id);
-RET_API VehicleLinkShareData(void **share_top, uint32_t *share_size, uint16_t *offset);
-RET_API VehicleUnLinkShareData(VEHICLE_SHARE *share_top, u_int16 offset);
-EventID VehicleCreateEvent(PNO pno);
-void PosSetShareData(void *share_top, u_int16 offset, const void *data_src, u_int16 size_src);
-RET_API VehicleSndMsg(PNO pno_src, PNO pno_dest, CID cid, u_int16 msg_len, const void *msg_data);
-
-SENSOR_RET_API PosRegisterListenerProc(PCSTR notify_name, DID did, u_int8 ctrl_flg, u_int8 delivery_timing);
-
-#endif // POSITIONING_CLIENT_INCLUDE_VEHICLE_API_PRIVATE_H_ */
diff --git a/vehicleservice/positioning/client/include/vehicle_service/POS_common_API.h b/vehicleservice/positioning/client/include/vehicle_service/POS_common_API.h
deleted file mode 100755
index 5ee3005..0000000
--- a/vehicleservice/positioning/client/include/vehicle_service/POS_common_API.h
+++ /dev/null
@@ -1,1663 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#ifndef POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_COMMON_API_H_
-#define POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_COMMON_API_H_
-
-/**
- * @file POS_common_API.h
- * @brief API definition file for common function
- */
-
-/** @addtogroup BaseSystem
- * @{
- */
-/** @addtogroup vehicle_service
- * @ingroup BaseSystem
- * @{
- */
-/** @addtogroup positioning
- * @ingroup vehicle_service
- * @{
- */
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/POS_define.h>
-#include <gps_hal.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-/* State definitions can be used */
-#define SENSORLOCATION_STATUS_DISABLE (0) //!< \~english Not available
-#define SENSORLOCATION_STATUS_ENABLE (1) //!< \~english Available
-
-/* State definitions can be used */
-#define SENSORMOTION_STATUS_DISABLE (0) //!< \~english Not available
-#define SENSORMOTION_STATUS_ENABLE (1) //!< \~english Available
-/* Acquisition method */
-#define SENSOR_GET_METHOD_AUTO (0) //!< \~english Not specified
-#define SENSOR_GET_METHOD_GPS (1) //!< \~english GPS
-#define SENSOR_GET_METHOD_NAVI (2) //!< \~english Navigation
-#define SENSOR_GET_METHOD_DR (3) //!< \~english Dead Reckoning
-#define SENSOR_GET_METHOD_POS (4) //!< \~english positioning (Internal)
-
-
-#define LOCATIONINFO_NMEA_MAX (1020)
-//!< \~english Max length of 'Location Information'
-
-/* Command ID */
-/* Vehicle sensor information notification CID (Rate information) */
-
-/**
- * \~english @brief Delivery speed command ID
- * \~english @brief If you want to catch above envents, use NSFW like below.
- * \~english @code
- * l_eStatus = FrameworkUnifiedAttachCallbackToDispatcher(h_app, POS_NTFY_SEND_THREAD, CID_POSIF_REGISTER_LISTENER_SPEED, CBCallbackA);
- * @endcode
- */
-#define CID_POSIF_REGISTER_LISTENER_SPEED (0x0203)
-
-/**
- * \~english @brief Delivery longitude and latitude command ID
- * \~english @brief If you want to catch above envents, use NSFW like below.
- * \~english @code
- * l_eStatus = FrameworkUnifiedAttachCallbackToDispatcher(h_app, POS_NTFY_SEND_THREAD, CID_POSIF_REGISTER_LISTENER_LONLAT, CBCallbackA);
- * @endcode
- */
-#define CID_POSIF_REGISTER_LISTENER_LONLAT 0x0781
-
-/**
- * \~english @brief Delivery altitude command ID
- * \~english @brief If you want to catch above envents, use NSFW like below.
- * \~english @code
- * l_eStatus = FrameworkUnifiedAttachCallbackToDispatcher(h_app, POS_NTFY_SEND_THREAD, CID_POSIF_REGISTER_LISTENER_ALTITUDE, CBCallbackA);
- * @endcode
- */
-#define CID_POSIF_REGISTER_LISTENER_ALTITUDE 0x0782
-
-/**
- * \~english @brief Delivery heading command ID
- * \~english @brief If you want to catch above envents, use NSFW like below.
- * \~english @code
- * l_eStatus = FrameworkUnifiedAttachCallbackToDispatcher(h_app, POS_NTFY_SEND_THREAD, CID_POSIF_REGISTER_LISTENER_HEADING, CBCallbackA);
- * @endcode
- */
-#define CID_POSIF_REGISTER_LISTENER_HEADING 0x0783
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-/**
- * @struct POS_POSDATA
- * \~english position information
- */
-typedef struct {
- int8_t status; //!< \~english data status
- uint8_t posSts; //!< \~english position status
- uint16_t posAcc; //!< \~english position accuracy
- int32_t longitude; //!< \~english current longitude
- int32_t latitude; //!< \~english current latitude
- int32_t altitude; //!< \~english current altitude
- int16_t heading; //!< \~english current heading
- uint8_t reserved[2]; //!< \~english reserve
-} POS_POSDATA;
-
-/**
- * @struct SENSORLOCATION_MSG_LONLATINFO
- * \~english longitude and latitude information data delivery message
- */
-typedef struct {
- SENSORLOCATION_LONLATINFO_DAT data;
- //!< \~english longitude and latitude information data
-} SENSORLOCATION_MSG_LONLATINFO;
-
-/**
- * @struct SENSORLOCATION_MSG_ALTITUDEINFO
- * \~english altitude information data delivery message
- */
-typedef struct {
- SENSORLOCATION_ALTITUDEINFO_DAT data; //!< \~english altitude information data
-} SENSORLOCATION_MSG_ALTITUDEINFO;
-
-/**
- * @struct SENSORMOTION_MSG_HEADINGINFO
- * \~english heading information data delivery message
- */
-typedef struct {
- SENSORMOTION_HEADINGINFO_DAT data; //!< \~english heading information data
-} SENSORMOTION_MSG_HEADINGINFO;
-
-/**
- * @struct SENSORMOTION_MSG_SPEEDINFO
- * \~english speed information data delivery message
- */
-typedef struct {
- SENSORMOTION_SPEEDINFO_DAT data; //!< \~english speed information data
-} SENSORMOTION_MSG_SPEEDINFO;
-
-
-/**
- * @struct POS_LOCATIONINFO_NMEA
- * \~english Structure of Location Information (NMEA)
- */
-typedef struct {
- uint32_t length; //!< \~english length
- uint8_t data[LOCATIONINFO_NMEA_MAX]; //!< \~english data
-} POS_LOCATIONINFO_NMEA;
-
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-/* SENSOR_API public API */
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Register for longitude and lattitude delivery
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] notifyName
-/// - PCSTR - Destination thread name
-/// \~english @param [in] ucCtrlFlg
-/// - uint8_t - Delivery control flag(register)
-/// \~english @param [in] ucDeliveryTiming
-/// - uint8_t - Delivery timing(change/update)
-/// \~english @param [in] ucGetMethod
-/// - uint8_t - Get method(GPS/Navigation/Not specified)
-///
-/// \~english @par
-/// - Delivery control flag(ucCtrlFlg)
-/// - SENSOR_DELIVERY_REGIST - register
-/// - Register for specified logtitude and latitude delivery
-/// - Please note if call this function for multiple times, the data will be deliveried for multiple times.
-/// - The specified longitude and latitude will be deliveried during the registration(first delivery)
-/// - Delivery timing(ucDeliveryTiming)
-/// - SENSOR_DELIVERY_TIMING_CHANGE - change. Specified longitude and latitude will be deliveried \n
-/// only when it has been changed.
-/// - SENSOR_DELIVERY_TIMING_UPDATE - update. Specified longitude and latitude will be deliveried \n
-/// every time that has been updated by the vehicle sensors.
-/// - Get method(ucGetMethod)
-/// - SENSOR_GET_METHOD_GPS - GPS. The longitude and latitude from GPS will be deliveried.
-/// - SENSOR_GET_METHOD_NAVI - Navi. The longitude and latitude from Navigation will be deliveried.
-/// - SENSOR_GET_METHOD_AUTO - Not specified. The specified longitude and latitude will be deliveried \n
-/// according to the current environment.
-/// - Avaliable method is descriped as following:\n
-/// In the following environment, if the SENSOR_GET_METHOD_AUTO is set,treated as default \n
-/// In the following environment, if the unsupported method has been specified, \n
-/// POS_RET_ERROR_PARAM will be returned.\n
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_BUFFULL the register count is full
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of the dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of the internal status
-/// - There is no changes of the internal status by this API
-///
-/// \~english @par Failure condition
-/// - The parameter ucDeliveryTiming is neither update(SENSOR_DELIVERY_TIMING_UPDATE) nor change \n
-/// (SENSOR_DELIVERY_TIMING_CHANGE) [POS_RET_ERROR_PARAM]
-/// - The parameter ucCtrlFlg is not register(SENSOR_DELIVERY_REGIST) [POS_RET_ERROR_PARAM]
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter notifyName is NULL [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to the max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to the max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to the max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference to the event \n
-/// is reach to the max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference to the event \n
-/// is reach to the max [POS_RET_ERROR_INNER]
-/// - Memory allocate failed during the event table creation for the event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table during the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already been registered. \n
-/// [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, try to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message transfered between processes.\n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message transfer between processes. \n
-/// [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message transfer between processes.\n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between process. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered between processes. \n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer failed between process. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during waiting event. \n
-/// [POS_RET_ERROR_INNER]
-/// - The count of thread beyond max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during getting event. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event getting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [POS_RET_ERROR_INNER]
-/// - Getting event timeout. [POS_RET_ERROR_INNER]
-/// - Error happened during event getting. [POS_RET_ERROR_INNER]
-/// - The result of positioning service returned is SENSOR_RET_ERROR_PARAM. [POS_RET_ERROR_PARAM]
-/// - The result of positioning service returned is SENSOR_RET_ERROR_BUFFULL. [POS_RET_ERROR_BUFFULL]
-/// - The result of positioning service returned is SENSOR_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result of positioning service returned is not SENSOR_RET_ERROR_PARAM and SENSOR_RET_ERROR_BUFFULL \n
-/// and SENSOR_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to register longitude and latitude information delivery.\n
-/// This API return the result of registered.
-/// \n
-///
-/// \~english @par
-/// Please note the following points when use this API.
-/// - Duplication registering
-/// - The same destination thread name has already been registered
-/// - The registered delivery data updated and normal return.(first delivery)
-/// - To one delivery destination, the same data will not be duplication deliveried at same time.
-/// - After call this API, if the delivery destination thread name has been changed, please call this API again.
-///
-/// \~english @par
-/// Notification of message
-/// - After registered successfully, vehicle sensor information will been sent as system API \n
-/// message with following format.\n
-/// Command ID : @ref CID_POSIF_REGISTER_LISTENER_LONLAT \n
-/// message structure
-/// \~english @code
-/// typedef struct {
-/// SENSORLOCATION_LONLATINFO_DAT data; /* message data */
-/// } SENSORLOCATION_MSG_LONLATINFO;
-/// @endcode
-/// message data structure \n
-///
-/// \~english @code
-/// typedef struct {
-/// uint8_t getMethod; /* get method */
-/// uint8_t SyncCnt; /* Synchrony count */
-/// uint8_t isEnable; /* enable or not */
-/// uint8_t posSts; /* position status */
-/// uint16_t posAcc; /* Position accuracy */
-/// int32_t Longitude; /* Longitude */
-/// int32_t Latitude; /* Latitude */
-/// } SENSORLOCATION_LONLATINFO_DAT;
-/// @endcode
-/// - Get method(getMethod)
-/// - SENSOR_GET_METHOD_GPS - longitude and latitude from GPS
-/// - SENSOR_GET_METHOD_NAVI - longitude and latitude from Navigation
-/// - Synchrony count(SyncCnt)
-/// - Count for position data synchronous \n
-/// When delivery altitude and heading data, position data can be synchronized by SyncCnt.\n
-/// But the data of different method can not be synchronized by SyncCnt.\n
-/// Example 1: [LonLat from GPS] and [Heading from GPS] can be synchronized by SyncCnt.\n
-/// Example 2: [LonLat from GPS] and [LonLat from Navi] can not be synchronized by SyncCnt.\n
-/// Caution: The sensor count in sensor data delivery is another data.
-/// - Enable or not(isEnable) \n
-/// To describe this delivery message is whether can be used or not
-/// - 0 - not avaliable
-/// - not 0 - avaliable
-/// - when GPS data is specified,longitude and latitude is invalid at following condition:\n
-/// so [not avaliable] provieded
-/// - After system start, GPS unit has not received current location data and GPS unit \n
-/// status is not positioning fixed.
-/// - If it is not initialized status, certainly provide [avaliable] when Navigation data specified
-/// - If the status is [not avaliable], data following can not be guaranteed.
-/// - Position status(posSts)
-/// - Bit0 : GPS data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_GSP)
-/// - Bit1 : DGPS data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_DGPS)
-/// - Bit2 : DR data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_DR)
-/// - Bit3 : MapMatching data used result(1:used, 0:not used, definition of \n
-/// maskbit:POS_LOC_INFO_USE_MAPMATCHING)
-/// - Position accuracy(posAcc)
-/// - Detected accruray of current position:1LSB=1m \n
-/// - Longitude : (WGS-84)(10^-7degree as 1) \n
-/// East longitude is positive value and west longitude is negative value.
-/// - Latitude : (WGS-84)(10^-7degree as 1) \n
-/// North latitude positive value and south latitude is negative value.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Method
-///
-/// \~english @see
-/// - POS_GetLonLat
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_RegisterListenerLonLat(HANDLE hApp, PCSTR notifyName, uint8_t ucCtrlFlg, uint8_t ucDeliveryTiming,
- uint8_t ucGetMethod);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Register altitude delivery
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] notifyName
-/// - PCSTR - Destination thread name
-/// \~english @param [in] ucCtrlFlg
-/// - uint8_t - Delivery control flag(register)
-/// \~english @param [in] ucDeliveryTiming
-/// - uint8_t - Delivery timing(change/update)
-/// \~english @param [in] ucGetMethod
-/// - uint8_t - Get method(GPS/Not specified)
-///
-/// \~english @par
-/// - Delivery control flag(ucCtrlFlg)
-/// - SENSOR_DELIVERY_REGIST - register
-/// - Register specified altitude delivery
-/// - Please note that if the same data delivery has been registered for multiple times, the data will \n
-/// also be deliveried for registered multiple times.
-/// - The specified altitude will be deliveried at registered time (first delivery).
-/// - Delivery timing(ucDeliveryTiming)
-/// - SENSOR_DELIVERY_TIMING_CHANGE - change. Specified altitude will be deliveried only when it is changed.
-/// - SENSOR_DELIVERY_TIMING_UPDATE - update. Specified altitude will be deliveried when it is updated by \n
-/// vehicle sensor.
-/// - Get method(ucGetMethod)
-/// - SENSOR_GET_METHOD_GPS - GPS. The altitude from GPS will be deliveried.
-/// - SENSOR_GET_METHOD_AUTO - Not specified. The altitude will be deliveried according to \n
-/// the current environment
-/// - Avaliable method is descriped as following in each environment. \n
-/// In the following environment, if the SENSOR_GET_METHOD_AUTO is set,treated as default \n
-/// In the following environment, if the unsupported method has been specified, \n
-/// POS_RET_ERROR_PARAM will be returned.
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_BUFFULL the register count is full
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of the dispatcher \n
-/// for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter ucDeliveryTiming is neither update(SENSOR_DELIVERY_TIMING_UPDATE) nor change \n
-/// (SENSOR_DELIVERY_TIMING_CHANGE) [POS_RET_ERROR_PARAM]
-/// - The parameter ucCtrlFlg is not registered(SENSOR_DELIVERY_REGIST) [POS_RET_ERROR_PARAM]
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter notifyName is NULL [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reached to the max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reached to the max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reached to the max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference to the event \n
-/// is reach to max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference to the event \n
-/// is reach to the max [POS_RET_ERROR_INNER]
-/// - Memory allocate failed during the event table creation for that event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table during the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already been registered. \n
-/// [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full during event creation. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed during event table creation. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, try to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message transfered between processes.\n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message transfer between processes.\n
-/// [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message transfer between processes.\n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered between processes.\n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during event waiting. \n
-/// [POS_RET_ERROR_INNER]
-/// - The count of thread is reach to max in event management table during event waiting.[POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event getting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [POS_RET_ERROR_INNER]
-/// - Getting event timeout. [POS_RET_ERROR_INNER]
-/// - Error happened during event getting. [POS_RET_ERROR_INNER]
-/// - The result of positioning service is SENSOR_RET_ERROR_PARAM. [POS_RET_ERROR_PARAM]
-/// - The result of positioning service is SENSOR_RET_ERROR_BUFFULL. [POS_RET_ERROR_BUFFULL]
-/// - The result of positioning service is SENSOR_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result of positioning service is not SENSOR_RET_ERROR_PARAM and SENSOR_RET_ERROR_BUFFULL and \n
-/// SENSOR_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to register altitude delivery. \n
-/// This API will finish when get the return value.
-///
-/// \~english @par
-/// Please note the following points when use this API.
-/// - Duplication registering
-/// - The same destination thread name has already been registered
-/// - The registered delivery data updated and normal return.(first delivery)
-/// - To one delivery destination, the same data will not be duplication deliveried at same timing.
-/// - After call this API, if the delivery destination thread name is changed, please call this API again.
-///
-/// \~english @par
-/// Notification of message
-/// - After registered successfully, vehicle sensor will send system API message with following format. \n
-/// Command ID : @ref CID_POSIF_REGISTER_LISTENER_ALTITUDE \n
-/// message structure
-/// \~english @code
-/// typedef struct {
-/// SENSORLOCATION_ALTITUDEINFO_DAT data; /* message data */
-/// } SENSORLOCATION_MSG_ALTITUDEINFO;
-/// @endcode
-/// message data structure
-/// \~english @code
-/// typedef struct {
-/// uint8_t getMethod; /* get method */
-/// uint8_t SyncCnt; /* synchrony count */
-/// uint8_t isEnable; /* enable or not */
-/// uint8_t Reserve[3]; /* Reserve */
-/// int32_t Altitude; /* Altitude(unit:0.01m) */
-/// } SENSORLOCATION_ALTITUDEINFO_DAT;
-/// @endcode
-/// - Get method(getMethod)
-/// - SENSOR_GET_METHOD_GPS - altitude from GPS
-/// - Synchrony count(SyncCnt)
-/// - Count for position data synchronous \n
-/// When delivery altitude and heading data, position data can be synchronized by SyncCnt. \n
-/// But the data of different method can not be synchronized by SyncCnt.\n
-/// example: [longitude and latitude from GPS] and [heading from GPS] can be synchronized by SyncCnt.\n
-/// synchronized by SyncCnt. \n
-/// Caution: The sensor count in sensor data delivery is another data.
-/// - Enable or not(isEnable) \n
-/// To describe this delivery message is whether can be used or not.
-/// - 0 - not avaliable
-/// - not 0 - avaliable
-/// - when GPS data specified, Altitude is invalid at following condition(so [not avaliable] provieded):
-/// - Immediately after system start, GPS unit has not received current location data and GPS unit status \n
-/// is not positioning fix
-/// - If the status is [not avaliable], data following can not be guaranteed.
-/// - Altitude
-/// - altitude data(unit 0.01m)
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Method
-///
-/// \~english @see delivery
-/// - POS_GetAltitude
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_RegisterListenerAltitude(HANDLE hApp, PCSTR notifyName, uint8_t ucCtrlFlg, uint8_t ucDeliveryTiming,
- uint8_t ucGetMethod);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Register speed delivery
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] notifyName
-/// - PCSTR - Destination thread name
-/// \~english @param [in] ucCtrlFlg
-/// - uint8_t - Delivery control flag(register)
-/// \~english @param [in] ucDeliveryTiming
-/// - uint8_t - Delivery timing(change/update)
-/// \~english @param [in] ucGetMethod
-/// - uint8_t - Get method(POS/Navi/Not specified)
-///
-/// \~english @par
-/// - Delivery control flag(ucCtrlFlg)
-/// - SENSOR_DELIVERY_REGIST - register
-/// - Register specified speed delivery
-/// - Please note that if the same data delivery has been registered for multiple times, the data will \n
-/// also be deliveried for registered mutiple times.
-/// - The specified speed will be deliveried at registered time (first delivery).
-/// - Delivery timing(ucDeliveryTiming)
-/// - SENSOR_DELIVERY_TIMING_CHANGE - change. Specified speed will be deliveried only when it is changed.
-/// - SENSOR_DELIVERY_TIMING_UPDATE - update. Specified speed will be deliveried when it is updated by \n
-/// vehicle sensor.
-/// - Get method(ucGetMethod)
-/// - SENSOR_GET_METHOD_POS - The speed calculated in positioning based on speed pulse will be deliveried.
-/// - SENSOR_GET_METHOD_NAVI - Navi The speed from Navi will be deliveried.
-/// - SENSOR_GET_METHOD_AUTO - Not specified The speed will be deliveried according to the current environment
-/// deliveried.
-/// - Avaliable method is descriped as following in each environment. \n
-/// In the following environment, if the SENSOR_GET_METHOD_AUTO is set,treated as default \n
-/// In the following environment, if the unsupported method has been specified, \n
-/// POS_RET_ERROR_PARAM will be returned.
-///
-/// \~english @retval POS_RET_NORMAL normal end
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_BUFFULL the register count is full
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of the Dispatcher for App \n
-/// are completed.
-/// - Availability of service positioning is TRUE.
-///
-/// \~english @par change of internal status
-/// - There is no change of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter ucDeliveryTiming is neither update(SENSOR_DELIVERY_TIMING_UPDATE) \n
-/// nor change(SENSOR_DELIVERY_TIMING_CHANGE) [POS_RET_ERROR_PARAM]
-/// - The parameter ucCtrlFlg is not register(SENSOR_DELIVERY_REGIST) [POS_RET_ERROR_PARAM]
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter notifyName is NULL [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - Memory allocate failed during the event table creation for event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table during the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already been registered. \n
-/// [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full during event creation. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed during event table creation. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, try to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message transfered between processes. \n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message transfer between processes.\n
-/// [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message transfer between processes.\n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered between processes. \n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during event waiting. \n
-/// [POS_RET_ERROR_INNER]
-/// - The count of thread is reach to max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event getting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [POS_RET_ERROR_INNER]
-/// - Getting event timeout. [POS_RET_ERROR_INNER]
-/// - Error happened during event getting. [POS_RET_ERROR_INNER]
-/// - The result of positioning service is SENSOR_RET_ERROR_PARAM. [POS_RET_ERROR_PARAM]
-/// - The result of positioning service is SENSOR_RET_ERROR_BUFFULL. [POS_RET_ERROR_BUFFULL]
-/// - The result of positioning service is SENSOR_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result of positioning service is not SENSOR_RET_ERROR_PARAM and SENSOR_RET_ERROR_BUFFULL \n
-/// and SENSOR_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to register speed delivery. \n
-/// This API will finish when get the return value.
-///
-/// \~english @par
-/// Please note the following points when use this API.
-/// - Duplication registering
-/// - The same destination thread name has already been registered
-/// - The registered delivery data updated and normal return.(first delivery)
-/// - To one delivery destination, the same data will not be duplication deliveried at same timing.
-/// - After call this API, if the delivery destination thread name is changed, please call this API again.
-///
-/// \~english @par
-/// Notification of message
-/// - After registered successfully, vehicle sensor will send system API message with following format. \n
-/// Command ID : @ref CID_POSIF_REGISTER_LISTENER_SPEED \n
-/// message structure
-/// \~english @code
-/// typedef struct {
-/// SENSORMOTION_SPEEDINFO_DAT data; /* message data */
-/// } SENSORMOTION_MSG_SPEEDINFO;
-/// @endcode
-/// message data structure
-/// \~english @code
-/// typedef struct {
-/// uint8_t getMethod; /* get method */
-/// uint8_t SyncCnt; /* synchrony count */
-/// uint8_t isEnable; /* enable or not */
-/// uint8_t Reserve1[3]; /* Reserve */
-/// uint16_t Speed; /* speed(unit:0.01m/sec) */
-/// uint8_t Reserve2[2]; /* Reserve */
-/// } SENSORMOTION_SPEEDINFO_DAT;
-/// @endcode
-/// - Get method(getMethod)
-/// - SENSOR_GET_METHOD_POS - The speed calculated in positioning based on speed pulse will be deliveried.
-/// - SENSOR_GET_METHOD_NAVI - speed from Navi
-/// - Synchrony count(SyncCnt)
-/// - 0 (not change).
-/// - Enable or not(isEnable) \n
-/// To describe this data is whether enable or not.
-/// - 0 - not avaliable
-/// - not 0 - avaliable
-/// - Speed is invalid at following condition when speed pulse specified, so [not avaliable] provieded
-/// - Immediately after system start, the sensor data have not been received from SYS micon
-/// - If it is not initialization status, certainly provide [avaliable] when Navi data specified
-/// - If the status is [not avaliable], data following can not be guaranteed.
-/// - Speed
-/// - speed data(unit 0.01m/sec)
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Method
-///
-/// \~english @see
-/// - POS_GetSpeed
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_RegisterListenerSpeed(HANDLE hApp, PCSTR notifyName, uint8_t ucCtrlFlg, uint8_t ucDeliveryTiming,
- uint8_t ucGetMethod);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Register heading delivery
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] notifyName
-/// - PCSTR - Destination thread name
-/// \~english @param [in] ucCtrlFlg
-/// - uint8_t - Delivery control flag(register)
-/// \~english @param [in] ucDeliveryTiming
-/// - uint8_t - Delivery timing(change/update)
-/// \~english @param [in] ucGetMethod
-/// - uint8_t - Get method(GPS/Navi/Not specified)
-///
-/// \~english @par
-/// - Delivery control flag(ucCtrlFlg)
-/// - SENSOR_DELIVERY_REGIST - register
-/// - Register specified heading delivery
-/// - Please note that if the same data delivery has been registered for mutiple times, the data will \n
-/// also be deliveried for registered mutiple times.
-/// - The specified heading will be deliveried at registered time (first delivery).
-/// - Delivery timing(ucDeliveryTiming)
-/// - SENSOR_DELIVERY_TIMING_CHANGE - change. Specified heading will be deliveried only when it is changed.
-/// - SENSOR_DELIVERY_TIMING_UPDATE - update. Specified heading will be deliveried when it is updated by \n
-/// vehicle sensor.
-/// - Get method(ucGetMethod)
-/// - SENSOR_GET_METHOD_GPS - GPS. The heading from GPS will be deliveried.
-/// - SENSOR_GET_METHOD_AUTO - Not specified. The heading will be deliveried \n
-/// according to the current environment
-/// - Avaliable method is descriped as following in each environment. \n
-/// In the following environment, if the SENSOR_GET_METHOD_AUTO is set,treated as default \n
-/// In the following environment, if the unsupported method has been specified, \n
-/// POS_RET_ERROR_PARAM will be returned.
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_BUFFULL the register count is full
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of the Dispatcher \n
-/// for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter ucDeliveryTiming is neither update(SENSOR_DELIVERY_TIMING_UPDATE) nor change \n
-/// (SENSOR_DELIVERY_TIMING_CHANGE) [POS_RET_ERROR_PARAM]
-/// - The parameter ucCtrlFlg is not register(SENSOR_DELIVERY_REGIST) [POS_RET_ERROR_PARAM]
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter notifyName is NULL [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - Memory allocate failed during the event table creation for event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table during the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already \n
-/// been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full during event creation. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed during event table creation. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, try to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message transfered between processes. \n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message transfer \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message transfer between \n
-/// processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered between processes. \n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during event waiting. \n
-/// [POS_RET_ERROR_INNER]
-/// - The count of thread is reach to max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event getting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [POS_RET_ERROR_INNER]
-/// - Getting event timeout. [POS_RET_ERROR_INNER]
-/// - Error happened during event getting. [POS_RET_ERROR_INNER]
-/// - The result of positioning service is SENSOR_RET_ERROR_PARAM. [POS_RET_ERROR_PARAM]
-/// - The result of positioning service is SENSOR_RET_ERROR_BUFFULL. [POS_RET_ERROR_BUFFULL]
-/// - The result of positioning service is SENSOR_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result of positioning service is not SENSOR_RET_ERROR_PARAM and SENSOR_RET_ERROR_BUFFULL \n
-/// and SENSOR_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to register heading delivery.
-/// This API will finish when get the return value.
-///
-/// \~english @par
-/// Please note the following points when use this API.
-/// - Duplication registering
-/// - The same destination thread name has already been registered
-/// - The registered delivery data updated and normal return.(first delivery)
-/// - To one delivery destination, the same data will not be duplication deliveried at same timing.
-/// - After call this API, if the delivery destination thread name is changed, please call this API again.
-///
-/// \~english @par
-/// Notification of message
-/// - After registered successfully, vehicle sensor will send system API message with following format. \n
-/// Command ID : @ref CID_POSIF_REGISTER_LISTENER_HEADING \n
-/// message structure
-/// \~english @code
-/// typedef struct {
-/// SENSORMOTION_HEADINGINFO_DAT data; /* message data */
-/// } SENSORMOTION_MSG_HEADINGINFO;
-/// @endcode
-/// message data structure
-/// \~english @code
-/// typedef struct {
-/// uint8_t getMethod; /* get method */
-/// uint8_t SyncCnt; /* sync count */
-/// uint8_t isEnable; /* enable or not */
-/// uint8_t posSts; /* position status */
-/// uint8_t Reserve1[2]; /* Reserve */
-/// uint16_t Heading; /* heading(unit:0.01degree) */
-/// uint8_t Reserve2[2]; /* Reserve */
-/// } SENSORMOTION_HEADINGINFO_DAT;
-/// @endcode
-/// - Get method(getMethod)
-/// - SENSOR_GET_METHOD_GPS - Heading from GPS
-/// - SENSOR_GET_METHOD_NAVI - Heading from Navi
-/// - Synchrony count(SyncCnt)
-/// - Count for position data synchronous \n
-/// When delivery altitude and heading data, position data can be synchronized by this count. \n
-/// But the data of different method can not be synchronized by this count.\n
-/// example 1: [longitude and latitude from GPS] and [heading from GPS] can be synchronized by the count. \n
-/// example 2: [longitude and latitude from GPS] and [longitude and latitude from Navi] can not be \n
-/// synchronized by the count. \n
-/// Caution: The sensor count in sensor data delivery is another data.
-/// - Enable or not(isEnable) \n
-/// To describe this data is whether enable or not.
-/// - 0 - not avaliable
-/// - not 0 - avaliable
-/// - Heading is invalid at following condition when GPS data specified, so [not avaliable] provieded \n
-/// - Immediately after system start, GPS unit has not received current location data and GPS unit status \n
-/// is not positioning fix
-/// - If it is not initialization status, certainly provide [avaliable] when Navi data specified
-/// - If the status is [not avaliable], data following can not be guaranteed.
-/// - Position status(posSts)
-/// - Bit0 : GPS data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_GSP)
-/// - Bit1 : DGPS data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_DGPS)
-/// - Bit2 : DR data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_DR)
-/// - Bit3 : MapMatching data used result(1:used, 0:not used, definition of \n
-/// maskbit:POS_LOC_INFO_USE_MAPMATCHING)
-/// - Heading
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Method
-///
-/// \~english @see
-/// - POS_GetHeading
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_RegisterListenerHeading(HANDLE hApp, PCSTR notifyName, uint8_t ucCtrlFlg, uint8_t ucDeliveryTiming,
- uint8_t ucGetMethod);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Get longitude and latitude information
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [out] dat
-/// - SENSORLOCATION_LONLATINFO_DAT* - output pointer to longitude and latitude informaiton
-/// \~english @param [in] ucGetMethod
-/// - uint8_t - Get method(GPS/Navi/Not specified)
-///
-/// \~english @par
-/// - Get method(ucGetMethod)
-/// - SENSOR_GET_METHOD_GPS - GPS The longitude and latitude from GPS will be deliveried.
-/// - SENSOR_GET_METHOD_NAVI - Navi The longitude and latitude from Navi will be deliveried.
-/// - SENSOR_GET_METHOD_AUTO - Not specified The longitude and latitude will be deliveried \n
-/// according to the current environment.
-/// - Avaliable method is descriped as following in each environment. \n
-/// In the following environment, if the SENSOR_GET_METHOD_AUTO is set,treated as default \n
-/// In the following environment, if the unsupported method has been specified, \n
-/// POS_RET_ERROR_PARAM will be returned.
-/// \~english @par
-/// - SENSORLOCATION_LONLATINFO_DAT structure
-/// \~english @code
-/// typedef struct {
-/// uint8_t getMethod; /* get method */
-/// uint8_t SyncCnt; /* sync count */
-/// uint8_t isEnable; /* enable or not */
-/// uint8_t posSts; /* position status */
-/// uint16_t posAcc; /* Position accuracy */
-/// int32_t Longitude; /* Longitude */
-/// int32_t Latitude; /* Latitude */
-/// } SENSORLOCATION_LONLATINFO_DAT;
-/// @endcode
-/// - Get method(getMethod)
-/// - SENSOR_GET_METHOD_GPS - longitude and latitude from GPS
-/// - SENSOR_GET_METHOD_NAVI - longitude and latitude from Navi
-/// - Synchrony count(SyncCnt)
-/// - Count for position data synchronous\n
-/// When delivery altitude and heading data, position data can be synchronized by this count. \n
-/// But the data of different method can not be synchronized by this count. \n
-/// example 1: [longitude and latitude from GPS] and [heading from GPS] can be synchronized by this count. \n
-/// example 2: [longitude and latitude from GPS] and [longitude and latitude from Navi] can not be \n
-/// synchronized by this count. \n
-/// Caution: The sensor count in sensor data delivery is another data.
-/// - Enable or not(isEnable) \n
-/// To describe this data is whether enable or not.
-/// - 0 - not avaliable
-/// - not 0 - avaliable
-/// - longitude and latitude is invalid at following condition when GPS data specified, \n
-/// so [not avaliable] provieded
-/// - Immediately after system start, GPS unit has not received current location data and \n
-/// GPS unit status is not positioning fix
-/// - If it is not initialization status, certainly provide [avaliable] when Navi data specified\n
-/// - If the status is [not avaliable], data following can not be guaranteed.
-/// - Position status(posSts)
-/// - Bit0 : GPS data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_GSP)
-/// - Bit1 : DGPS data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_DGPS)
-/// - Bit2 : DR data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_DR)
-/// - Bit3 : MapMatching data used result(1:used, 0:not used, definition of \n
-/// maskbit:POS_LOC_INFO_USE_MAPMATCHING)
-/// - Position accuracy(posAcc)
-/// - Detected accruray of current position:1LSB=1m
-/// - Longitude : (WGS-84)(10^-7degree as 1) \n
-/// East longitude is positive value and west longitude is minus value.
-/// - Latitude : (WGS-84)(10^-7degree as 1)\n
-/// North latitudeis positive value and south latitude is minus value.
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of the Dispatcher \n
-/// for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par change of internal status
-/// - There is no change of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter dat is NULL [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - Memory allocate failed during the event table creation for event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table during the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already been registered. \n
-/// [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full during event creation. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed during event table creation. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, try to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - The memory for storing semaphore control data allocate failed. [POS_RET_ERROR_INNER]
-/// - Specified semaphore ID has not been registered when lock semaphore. [POS_RET_ERROR_INNER]
-/// - Internal mutex HANDLE is NULL when lock mutex. [POS_RET_ERROR_INNER]
-/// - Internal mutex HANDLE has not been registered in mutex table when lock mutex. [POS_RET_ERROR_INNER]
-/// - The owner of specified mutex is not itself when lock mutex. [POS_RET_ERROR_INNER]
-/// - Mutex has been multiple locked [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address. [POS_RET_ERROR_INNER]
-/// - Can not get usable share memory address. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory map. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory management. [POS_RET_ERROR_INNER]
-/// - Can not open share memory. [POS_RET_ERROR_INNER]
-/// - Failed to mapping share memory. [POS_RET_ERROR_INNER]
-/// - No empty field in share memory. [POS_RET_ERROR_INNER]
-/// - Failed to guarantee share memory. [POS_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message transfered between processes. \n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message transfer \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message transfer \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered between processes. \n
-/// [POS_RET_ERROR_INNER]
-/// - Message transfer failed between process. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during event waiting. \n
-/// [POS_RET_ERROR_INNER]
-/// - The count of thread is reach to max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event getting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address for accessing received data. \n
-/// [POS_RET_ERROR_INNER]
-/// - Can not get usable share memory address for accessing received data. [POS_RET_ERROR_INNER]
-/// - Memory for share memory map allocate failed for accessing received data. [POS_RET_ERROR_INNER]
-/// - Memory for share memory management allocate failed for accessing received data. [POS_RET_ERROR_INNER]
-/// - Can not open share memory for accessing received data. [POS_RET_ERROR_INNER]
-/// - Failed to mapping share memory for accessing received data. [POS_RET_ERROR_INNER]
-/// - The size of data stored in share memory is larger than the size of received data. [POS_RET_ERROR_INNER]
-/// - The result of getting sensor data get is POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result of getting sensor data get is not POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to get longitude and latitude from vehicle sensor
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Sync
-///
-/// \~english @see
-/// - POS_RegisterListenerLonLat
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_GetLonLat(HANDLE hApp, SENSORLOCATION_LONLATINFO_DAT *dat, uint8_t ucGetMethod);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Get altitude data
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [out] dat
-/// - SENSORLOCATION_ALTITUDEINFO_DAT* - output pointer to altitude data
-/// \~english @param [in] ucGetMethod
-/// - uint8_t - Get method(GPS/Not specified)
-///
-/// \~english @par
-/// - Get method(ucGetMethod)
-/// - SENSOR_GET_METHOD_GPS - GPS The altitude from GPS will be deliveried.
-/// - SENSOR_GET_METHOD_AUTO - Not specified The altitude will be deliveried \n
-/// according to the current environment
-/// - Avaliable method is descriped as following in each environment. \n
-/// In the following environment, if the SENSOR_GET_METHOD_AUTO is set,treated as default \n
-/// In the following environment, if the unsupported method has been specified, \n
-/// POS_RET_ERROR_PARAM will be returned.
-/// \~english @par
-/// - SENSORLOCATION_ALTITUDEINFO_DAT structure
-/// \~english @code
-/// typedef struct {
-/// uint8_t getMethod; /* get method */
-/// uint8_t SyncCnt; /* sync count */
-/// uint8_t isEnable; /* enable or not */
-/// uint8_t Reserve[3]; /* Reserve */
-/// int32_t Altitude; /* Altitude(unit:0.01m) */
-/// } SENSORLOCATION_ALTITUDEINFO_DAT;
-/// @endcode
-/// - Get method(getMethod)
-/// - SENSOR_GET_METHOD_GPS - altitude from GPS
-/// - Synchrony count(SyncCnt)
-/// - Count for position data synchronous \n
-/// When delivery altitude and heading data, position data can be synchronized by this count. \n
-/// But the data of different method can not be synchronized by this count. \n
-/// example: [longitude and latitude from GPS] and [heading from GPS] can be synchronized by the count. \n
-/// synchronized by the count. \n
-/// Caution: The sensor count in sensor data delivery is another data.
-/// - Enable or not(isEnable)\n
-/// To describe this data is whether enable or not.
-/// - 0 - not avaliable
-/// - not 0 - avaliable
-/// - Altitude is invalid at following condition when GPS data specified, so [not avaliable] provieded
-/// - Immediately after system start, GPS unit has not received current location data and GPS unit \n
-/// status is not positioning fix
-/// - If the status is [not avaliable], data following can not be guaranteed.
-/// - Altitude
-/// - altitude data(unit 0.01m)
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of \n
-/// the Dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter dat is NULL [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - Memory allocate falied during the event table creation for event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table during the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already been \n
-/// registered. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full during event creation. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed during event table creation. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, try to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - The memory for storing semaphore control data allocate failed. [POS_RET_ERROR_INNER]
-/// - Specified semaphore ID has not been registered when lock semaphore. [POS_RET_ERROR_INNER]
-/// - Internal mutex HANDLE is NULL when lock mutex. [POS_RET_ERROR_INNER]
-/// - Internal mutex HANDLE has not been registered in mutex table when lock mutex. [POS_RET_ERROR_INNER]
-/// - The owner of specified mutex is not itself when lock mutex. [POS_RET_ERROR_INNER]
-/// - Mutex has been multiple locked [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address. [POS_RET_ERROR_INNER]
-/// - Can not get usable share memory address. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory map. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory management. [POS_RET_ERROR_INNER]
-/// - Can not open share memory. [POS_RET_ERROR_INNER]
-/// - Failed to mapping share memory. [POS_RET_ERROR_INNER]
-/// - No empty field in share memory. [POS_RET_ERROR_INNER]
-/// - Failed to guarantee share memory. [POS_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message \n
-/// transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message transfer \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message \n
-/// transfer between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during \n
-/// event waiting. [POS_RET_ERROR_INNER]
-/// - The count of thread is reach to max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event getting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address for accessing
-/// received data. [POS_RET_ERROR_INNER]
-/// - Can not get usable share memory address for accessing received data. [POS_RET_ERROR_INNER]
-/// - Memory for share memory map allocate failed for accessing received data. [POS_RET_ERROR_INNER]
-/// - Memory for share memory management allocate failed for accessing received data. [POS_RET_ERROR_INNER]
-/// - Can not open share memory for accessing received data. [POS_RET_ERROR_INNER]
-/// - Failed to mapping share memory for accessing received data. [POS_RET_ERROR_INNER]
-/// - The size of data stored in share memory is larger than the size of received data. [POS_RET_ERROR_INNER]
-/// - The result of getting sensor data is POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result of getting sensor data is not POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to get altitude from vehicle sensor
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Sync
-///
-/// \~english @see
-/// - POS_RegisterListenerAltitude
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_GetAltitude(HANDLE hApp, SENSORLOCATION_ALTITUDEINFO_DAT *dat, uint8_t ucGetMethod);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Get speed data
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [out] dat
-/// - SENSORMOTION_SPEEDINFO_DAT* - output buffer pointer to store speed data
-/// \~english @param [in] ucGetMethod
-/// - uint8_t - Get method(POS/Navi/Not specified)
-///
-/// \~english @par
-/// - Get method(ucGetMethod)
-/// - SENSOR_GET_METHOD_POS - The speed calculated in positioning based on speed pulse will be deliveried.
-/// - SENSOR_GET_METHOD_NAVI - Navi The speed from Navi will be deliveried.
-/// - SENSOR_GET_METHOD_AUTO - Not specified The speed will be deliveried according to current \n
-/// environment.
-/// - Avaliable method is descriped as following in each environment. \n
-/// In the following environment, if the SENSOR_GET_METHOD_AUTO is set,treated as default \n
-/// In the following environment, if the unsupported method has been specified, \n
-/// POS_RET_ERROR_PARAM will be returned.
-///
-/// \~english @par
-/// - SENSORMOTION_SPEEDINFO_DAT structure
-/// \~english @code
-/// typedef struct {
-/// uint8_t getMethod; /* get method */
-/// uint8_t SyncCnt; /* sync count */
-/// uint8_t isEnable; /* enable or not */
-/// uint8_t Reserve1[3]; /* Reserve */
-/// uint16_t Speed; /* speed(unit:0.01m/sec) */
-/// uint8_t Reserve2[2]; /* Reserve */
-/// } SENSORMOTION_SPEEDINFO_DAT;
-/// @endcode
-/// - Get method(getMethod)
-/// - SENSOR_GET_METHOD_POS - The speed calculated in positioning based on speed pulse will be deliveried.
-/// - Sync count(SyncCnt)
-/// - 0.
-/// - Enable or not(isEnable) \n
-/// To describe this data is whether enable or not.
-/// - 0 - not avaliable
-/// - not 0 - avaliable
-/// - Speed is invalid at following condition when speed pulse specified, so [not avaliable] provieded
-/// - Immediately after system start, the sensor data have not been received from SYS micon
-/// - If it is not initialization status, certainly provide [avaliable] when Navi data specified
-/// - If the status is [not avaliable], data following can not be guaranteed.
-/// - Speed
-/// - speed data(unit 0.01m/sec)
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) \n
-/// of the dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter dat is NULL [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - Memory allocate falied when the event table creation that for event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table when the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already been \n
-/// registered. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full when event creation. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed when event table creation. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - The memory for storing semaphore control data allocate failed. [POS_RET_ERROR_INNER]
-/// - Specified semaphore ID has not been registered when semaphore lock. [POS_RET_ERROR_INNER]
-/// - Internal mutex HANDLE is NULL when mutex lock. [POS_RET_ERROR_INNER]
-/// - Internal mutex HANDLE has not been registered in mutex table when mutex lock. [POS_RET_ERROR_INNER]
-/// - The owner of specified mutex is not itself when mutex lock. [POS_RET_ERROR_INNER]
-/// - Mutex has been multiple locked [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address. [POS_RET_ERROR_INNER]
-/// - Can not get usable share memory address. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory map. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory management. [POS_RET_ERROR_INNER]
-/// - Can not open share memory. [POS_RET_ERROR_INNER]
-/// - Failed to mapping share memory. [POS_RET_ERROR_INNER]
-/// - No empty field in share memory. [POS_RET_ERROR_INNER]
-/// - Failed to guarantee share memory. [POS_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message transfered \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message transfer \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message transfer \n
-/// between processes [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered between \n
-/// processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during event \n
-/// waiting. [POS_RET_ERROR_INNER]
-/// - The count of thread is reach to max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event getting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address for accessing \n
-/// received data. [POS_RET_ERROR_INNER]
-/// - Can not get usable share memory address for accessing received data. [POS_RET_ERROR_INNER]
-/// - Memory for share memory map allocate failed for accessing received data. [POS_RET_ERROR_INNER]
-/// - Memory for share memory management allocate failed for accessing received data. [POS_RET_ERROR_INNER]
-/// - Can not open share memory for accessing received data. [POS_RET_ERROR_INNER]
-/// - Failed to mapping share memory for accessing received data. [POS_RET_ERROR_INNER]
-/// - The size of data stored in share memory is larger than the size of received data. [POS_RET_ERROR_INNER]
-/// - The result of getting sensor data is POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result of getting sensor data is not POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to get speed from vehicle sensor.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Sync
-///
-/// \~english @see
-/// - POS_RegisterListenerSpeed
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_GetSpeed(HANDLE hApp, SENSORMOTION_SPEEDINFO_DAT *dat, uint8_t ucGetMethod);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Get heading data
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [out] dat
-/// - SENSORMOTION_HEADINGINFO_DAT* - output buffer pointer to store heading data
-/// \~english @param [in] ucGetMethod
-/// - uint8_t - Get method(GPS/Navi/Not specified)
-///
-/// \~english @par
-/// - Get method(ucGetMethod)
-/// - SENSOR_GET_METHOD_GPS - GPS The heading from GPS will be deliveried.
-/// - SENSOR_GET_METHOD_NAVI - Navi The heading from Navi will be deliveried.
-/// - SENSOR_GET_METHOD_AUTO - Not specified The heading which most suitable in current environment \n
-/// - Avaliable method is descriped as following in each environment. \n
-/// In corresponding environment, the SENSOR_GET_METHOD_AUTO is set as default. \n
-/// In corresponding environment, if the unsupported method has been specified, \n
-/// POS_RET_ERROR_PARAM will be returned.
-/// \~english @par
-/// - SENSORMOTION_HEADINGINFO_DAT structure
-/// \~english @code
-/// typedef struct {
-/// uint8_t getMethod; /* get method */
-/// uint8_t SyncCnt; /* sync count */
-/// uint8_t isEnable; /* enable or not */
-/// uint8_t posSts; /* position status */
-/// uint8_t Reserve1[2]; /* Reserve */
-/// uint16_t Heading; /* heading(unit:0.01degree) */
-/// uint8_t Reserve2[2]; /* Reserve */
-/// } SENSORMOTION_HEADINGINFO_DAT;
-/// @endcode
-/// - Get method(getMethod)
-/// - SENSOR_GET_METHOD_GPS - Heading from GPS
-/// - SENSOR_GET_METHOD_NAVI - Heading from Navi
-/// - Synchrony count(SyncCnt)
-/// - Count for position data synchronous \n
-/// When delivery altitude and heading data, position data can be synchronized by this count. \n
-/// But the data of different method can not be synchronized by this count. \n
-/// example 1: [longitude and latitude from GPS] and [heading from GPS] can be synchronized by the count. \n
-/// example 2: [longitude and latitude from GPS] and [longitude and latitude from Navi] can not be \n
-/// synchronized by the count. \n
-/// Caution: The sensor count in sensor data delivery is another data.
-/// - Enable or not(isEnable) \n
-/// To describe this data is whether enable or not.
-/// - 0 - not avaliable
-/// - not 0 - avaliable
-/// - Heading is invalid at following condition when GPS data specified, so [not avaliable] provieded
-/// - Immediately after system start, GPS unit has not received current location data and GPS unit \n
-/// status is not positioning fix
-/// - If it is not initialization status, certainly provide [avaliable] when Navi data specified
-/// - If the status is [not avaliable], data following can not be guaranteed.
-/// - Position status(posSts)
-/// - Bit0 : GPS data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_GSP)
-/// - Bit1 : DGPS data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_DGPS)
-/// - Bit2 : DR data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_DR)
-/// - Bit3 : MapMatching data use result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_MAPMATCHING)
-/// - Heading
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of the Dispatcher
-/// - for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter dat is NULL [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - Memory allocate falied during the event table creation for event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table during the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already been \n
-/// registered. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full during event creation. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed during event table creation. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, try to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - The memory for storing semaphore control data allocate failed. [POS_RET_ERROR_INNER]
-/// - Specified semaphore ID has not been registered when semaphore lock. [POS_RET_ERROR_INNER]
-/// - Internal mutex HANDLE is NULL when mutex lock. [POS_RET_ERROR_INNER]
-/// - Internal mutex HANDLE has not been registered in mutex table when mutex lock. [POS_RET_ERROR_INNER]
-/// - The owner of specified mutex is not itself when mutex lock. [POS_RET_ERROR_INNER]
-/// - Mutex has been multiple locked [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address. [POS_RET_ERROR_INNER]
-/// - Can not get usable share memory address. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory map. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory management. [POS_RET_ERROR_INNER]
-/// - Can not open share memory. [POS_RET_ERROR_INNER]
-/// - Failed to mapping share memory. [POS_RET_ERROR_INNER]
-/// - No empty field in share memory. [POS_RET_ERROR_INNER]
-/// - Failed to guarantee share memory. [POS_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message transfered \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message transfer \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message transfer \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered between \n
-/// processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table \n
-/// during event waiting[POS_RET_ERROR_INNER]
-/// - The count of thread is reach to max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event getting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address for accessing received \n
-/// data. [POS_RET_ERROR_INNER]
-/// - Can not get usable share memory address for accessing received data. [POS_RET_ERROR_INNER]
-/// - Memory for share memory map allocate failed for accessing received data. [POS_RET_ERROR_INNER]
-/// - Memory for share memory management allocate failed for accessing received data. [POS_RET_ERROR_INNER]
-/// - Can not open share memory for accessing received data. [POS_RET_ERROR_INNER]
-/// - Failed to mapping share memory for accessing received data. [POS_RET_ERROR_INNER]
-/// - The size of data stored in share memory is larger than the size of received data. [POS_RET_ERROR_INNER]
-/// - The result of getting sensor data is POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result of getting sensor data is not POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to get heading from vehicle sensor.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Sync
-///
-/// \~english @see
-/// - POS_RegisterListenerHeading
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_GetHeading(HANDLE hApp, SENSORMOTION_HEADINGINFO_DAT *dat, uint8_t ucGetMethod);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Set speed information
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] navispeed
-/// - uint16_t - speed data[unit: 1.0km/h]
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of \n
-/// the Dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The data size is larger than specified value(POS_MSG_INFO_DSIZE) [POS_RET_ERROR_RESOURCE]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The message queue name has not been registered in control table. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table. [POS_RET_ERROR_INNER]
-/// - Speed data setting message transfer failed. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to set speed to vehicle sensor. \n
-/// This API will finish when get the return value. \n
-/// The speed set by this API is saved in positioning as the speed calculated by Navi.
-///
-/// \~english @par
-/// - Please note the following points when use this API.
-/// - This API is only called by Navi proxy.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Fire and Forget
-///
-/// \~english @see
-/// - None
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_SetSpeedInfo(HANDLE hApp, uint16_t navispeed);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Set location information
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] pstPosData
-/// - POS_POSDATA * - pointer to location information
-///
-/// \~english @par
-/// - POS_POSDATA structure
-/// \~english @code
-/// typedef struct
-/// {
-/// int8_t status; /* data status */
-/// uint8_t posSts; /* position status */
-/// uint16_t posAcc; /* Position accuracy 1LSB=1m */
-/// int32_t Longitude; /* Longitude(unit:1/128sec) */
-/// int32_t Latitude; /* Latitude(unit:1/128sec) */
-/// int32_t altitude; /* altitude (unit:0.01m) */
-/// int16_t heading; /* heading (unit:1degree) */
-/// uint8_t reserved[2]; /* reserve */
-/// } POS_POSDATA;
-/// @endcode
-///
-/// \~english @par
-/// - data status(status) \n
-/// Do not set the invalid data(do not update data).
-/// - data valid/invalid status
-/// - Bit0 : latitude(1:valid, 0:invalid, definition of maskbit:POS_LOC_INFO_LAT)
-/// - Bit1 : longitude(1:valid, 0:invalid, definition of maskbit:POS_LOC_INFO_LON)
-/// - Bit2 : altitude (1:valid, 0:invalid, definition of maskbit:POS_LOC_INFO_ALT)
-/// - Bit3 : heading (1:valid, 0:invalid, definition of maskbit:POS_LOC_INFO_HEAD)
-/// - Bit4~7 : reserve
-/// - Position status(posSts)
-/// - Bit0 : GPS data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_GSP)
-/// - Bit1 : DGPS data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_DGPS)
-/// - Bit2 : DR data used result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_DR)
-/// - Bit3 : MapMatching data use result(1:used, 0:not used, definition of maskbit:POS_LOC_INFO_USE_MAPMATCHING)
-/// - Bit4~7 : reserve
-/// - Position accuracy(posAcc)
-/// - Detected accruray of current position:1LSB=1m
-/// - longitude
-/// - data range: -180deg ~ +180deg
-/// - +: east longitude -: west longitude
-/// - latitude
-/// - data range:-90deg ~ +90deg
-/// - +: north latitude -: south latitude
-/// - heading
-/// - data range:-179deg ~ +180deg
-/// - Based on north, west(counter-clockwise) is +, east(clockwise) is -
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of the Dispatcher \n
-/// for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par change of internal status
-/// - There is no change of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter pstPosData is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The data status in parameter pstPosData is invalid value(0). [POS_RET_ERROR_PARAM]
-/// - The data status in parameter pstPosData is abnormal value(<15). [POS_RET_ERROR_PARAM]
-/// - The data size is larger than specified value(POS_MSG_INFO_DSIZE) [POS_RET_ERROR_RESOURCE]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The message queue name has not been registered in control table. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table. [POS_RET_ERROR_INNER]
-/// - Location data setting message transfer failed. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to set location to vehicle sensor. \n
-/// This API will finish when get the return value. \n
-/// The location set by this API is saved in positioning as the location calculated by Navi. \n
-/// If one of longitude and latitude is valid, the another data will be used as valid data no \n
-/// matter what status it is. \n
-/// If one of longitude and latitude is valid, the position accuracy data will be used as valid data.
-///
-/// \~english @par
-/// - Please note the following points when use this API.
-/// - This API is only called by Navi proxy.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Fire and Forget
-///
-/// \~english @see
-/// - None
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_SetLocationInfo(HANDLE hApp, POS_POSDATA* pstPosData);
-
-#ifdef __cplusplus
-}
-#endif
-/** @}*/ // end of positioning
-/** @}*/ // end of vehicle_service
-/** @}*/ // end of BaseSystem
-#endif // POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_COMMON_API_H_
diff --git a/vehicleservice/positioning/client/include/vehicle_service/POS_define.h b/vehicleservice/positioning/client/include/vehicle_service/POS_define.h
deleted file mode 100755
index 2ea918d..0000000
--- a/vehicleservice/positioning/client/include/vehicle_service/POS_define.h
+++ /dev/null
@@ -1,134 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#ifndef POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_DEFINE_H_
-#define POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_DEFINE_H_
-
-/**
- * @file POS_define.h
- * @brief Header file to define the constants and structure
- */
-
-/** @addtogroup BaseSystem
- * @{
- */
-/** @addtogroup vehicle_service
- * @ingroup BaseSystem
- * @{
- */
-/** @addtogroup positioning
- * @ingroup vehicle_service
- * @{
- */
-
-#include <native_service/frameworkunified_types.h>
-#include <gps_hal.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-#define POS_AVAILABILITY "Positioning/Availability" //!< \~english Availability
-
-/* message sender thread */
-#define POS_NTFY_SEND_THREAD "POS_Main" //!< \~english POS_Main thread
-#define POS_NTFY_SEND_THREAD_GPS "POS_Gps" //!< \~english POS_Gps thread
-
-/* SENSOR_RET_API */
-#define SENSOR_RET_NORMAL 0 //!< \~english normal finish
-#define SENSOR_RET_ERROR_PID (-1) //!< \~english thread ID error
-#define SENSOR_RET_ERROR_DID (-2) //!< \~english unregistered data ID error
-#define SENSOR_RET_ERROR_DID_DIS (-3) //!< \~english data ID not CAN ID
-#define SENSOR_RET_ERROR_PARAM (-4) //!< \~english parameter error
-#define SENSOR_RET_ERROR_BUFFULL (-5) //!< \~english buffer full error
-#define SENSOR_RET_ERROR_CREATE_EVENT (-6) //!< \~english create event error
-#define SENSOR_RET_ERROR_TIMER (-7) //!< \~english create timer error
-#define SENSOR_RET_ERROR_OUTOF_MEMORY (-8)
-//!< \~english share memory allocation size error
-
-#define SENSOR_RET_ERROR_SIZE (-9) //!< \~english memory size error
-#define SENSOR_RET_ERROR (-10) //!< \~english error occured
-#define SENSOR_RET_ERROR_NOSUPPORT (-11) //!< \~english no support
-#define SENSOR_RET_ERROR_INNER (-12) //!< \~english Internal error
-#define SENSOR_RET_ERROR_RESOURCE (-13) //!< \~english lack of resources
-#define SENSOR_RET_ERROR_MIN POS_RET_ERROR_MIN //!< \~english min value of error
-
-/* Data Status Definition */
-#define POS_LOC_INFO_LAT 0x01
-//!< \~english current position latitude(bit0) 1:valid 0:invalid
-
-#define POS_LOC_INFO_LON 0x02
-//!< \~english current position longitude(bit1) 1:valid 0:invalid
-
-#define POS_LOC_INFO_ALT 0x04
-//!< \~english current position altitude(bit2) 1:valid 0:invalid
-
-#define POS_LOC_INFO_HEAD 0x08
-//!< \~english current position heading(bit3) 1:valid 0:invalid
-
-/* Definition of positioning system */
-#define POS_LOC_INFO_USE_GSP 0x01
-//!< \~english GPS data used result(bit0) 1:valid 0:invalid
-
-#define POS_LOC_INFO_USE_DGPS 0x02
-//!< \~english DGPS data used result(bit1) 1:valid 0:invalid
-
-#define POS_LOC_INFO_USE_DR 0x04
-//!< \~english Dead Reckoning used result(bit2) 1:valid 0:invalid
-
-#define POS_LOC_INFO_USE_MAPMATCHING 0x08
-//!< \~english MapMatching result(bit3) 1:valid 0:invalid
-
-/*--- for message ---*/
-/* message body size (byte) */
-/* move to gps_hal.h */
-
-/*--- for register listener API ---*/
-/* control delivery */
-#define SENSOR_DELIVERY_REGIST 0x01 //!< \~english register delivery
-
-/* delivery timing control */
-#define SENSOR_DELIVERY_TIMING_UPDATE 0x01 //!< \~english delivery update timing
-#define SENSOR_DELIVERY_TIMING_CHANGE 0x02 //!< \~english delivery change timing
-
-/* POS_RET_API */
-#define POS_RET_NORMAL 0 //!< \~english normal finish
-#define POS_RET_ERROR (-1) //!< \~english error occured
-#define POS_RET_ERROR_DID (-2) //!< \~english data ID error
-#define POS_RET_ERROR_INNER (-3) //!< \~english internal error
-#define POS_RET_ERROR_PARAM (-4) //!< \~english parameter error
-#define POS_RET_ERROR_BUFFULL (-5) //!< \~english buffer full error
-#define POS_RET_ERROR_CREATE_EVENT (-6) //!< \~english create event error
-#define POS_RET_ERROR_OUTOF_MEMORY (-8)
-//!< \~english share memory allocation size error
-
-#define POS_RET_ERROR_SIZE (-9) //!< \~english memory size error
-#define POS_RET_ERROR_TIMEOUT (-10) //!< \~english timeout error
-#define POS_RET_ERROR_NOSUPPORT (-11) //!< \~english no support
-#define POS_RET_ERROR_BUSY (-12) //!< \~english busy
-#define POS_RET_ERROR_RESOURCE (-13) //!< \~english lack of resources
-#define POS_RET_ERROR_MIN (-13) //!< \~english min value of error
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-typedef int32_t SENSOR_RET_API; //!< \~english API return value
-typedef int32_t POS_RET_API; //!< \~english API return value
-typedef uint32_t DID; //!< \~english data ID
-typedef int32_t RET_API; //!< \~english _CWORD64_ API return value
-
-/** @}*/ // end of positioning
-/** @}*/ // end of vehicle_service
-/** @}*/ // end of BaseSystem
-#endif // POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_DEFINE_H_
diff --git a/vehicleservice/positioning/client/include/vehicle_service/POS_gps_API.h b/vehicleservice/positioning/client/include/vehicle_service/POS_gps_API.h
deleted file mode 100755
index 41e8e01..0000000
--- a/vehicleservice/positioning/client/include/vehicle_service/POS_gps_API.h
+++ /dev/null
@@ -1,1135 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#ifndef POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_GPS_API_H_
-#define POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_GPS_API_H_
-/**
- * @file POS_gps_API.h
- * @brief API definition file for GPS function
- */
-
-/** @addtogroup BaseSystem
- * @{
- */
-/** @addtogroup vehicle_service
- * @ingroup BaseSystem
- * @{
- */
-/** @addtogroup positioning
- * @ingroup vehicle_service
- * @{
- */
-
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/POS_define.h>
-#include <gps_hal.h>
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-typedef int32_t NAVIINFO_RET_API;
-//!< \~english define return value of Get/Set GPS information API
-
-/*---------------------------------------------------------------------------------*
- * Event declaration *
- *---------------------------------------------------------------------------------*/
-
-
-/**
- * \~english @brief GPS time setting result delivery command ID
- * \~english @brief If you want to catch above envents, use NSFW like below.
- * \~english @code
- * l_eStatus = FrameworkunifiedAttachCallbackToDispatcher(h_app,POS_NTFY_SEND_THREAD, CID_POSIF_REGISTER_LISTENER_GPS_TIME_SET_REQ, CBCallbackA);
- * @endcode
- */
-#define CID_POSIF_REGISTER_LISTENER_GPS_TIME_SET_REQ 0x0780
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-/**
- * @struct SENSOR_MSG_SEND_DAT
- * \~english message for setting vehicle sensor data(to vehicle sensor)
- */
-typedef struct {
- DID did; //!< \~english data ID
- uint16_t usSize; //!< \~english data size
- uint8_t data[502]; //!< \~english data body
-} SENSOR_MSG_SEND_DAT;
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-/* GPS_API public API */
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - GPS setting request
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] p_data
-/// - SENSOR_MSG_SEND_DAT * - pointer of GPS setting data
-///
-/// \~english @par
-/// - SENSOR_MSG_SEND_DAT structure
-/// \~english @code
-/// typedef struct
-/// {
-/// DID did; /* Data ID */
-/// uint16_t usSize; /* Data size */
-/// uint8_t data[502]; /* Data body */
-/// } SENSOR_MSG_SEND_DAT;
-/// @endcode
-///
-/// \~english @par
-/// - Data ID(did)
-/// - POS_DID_GPS__CWORD82__SETINITIAL - setting initial location and time data to GPS \n
-/// (reference to initial location, time setting(_CWORD82_))
-/// - POS_DID_GPS__CWORD82__SETRMODEEX - setting GPS receiver mode(pull extension sentence) \n
-/// (reference to GPS receiver mode setting(_CWORD82_))
-/// - POS_DID_GPS__CWORD82__SELSENT - setting command to GPS that output any sentence \n
-/// (reference to output any sentence setting(_CWORD82_))
-///
-///
-/// \~english @retval SENSOR_RET_NORMAL normal finish
-/// \~english @retval SENSOR_RET_ERROR_CREATE_EVENT event create error
-/// \~english @retval SENSOR_RET_ERROR_PARAM parameter error
-/// \~english @retval SENSOR_RET_ERROR_DID data ID not registered
-/// \~english @retval SENSOR_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval SENSOR_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) \n
-/// of the Dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status by this API
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [SENSOR_RET_ERROR_PARAM]
-/// - The parameter p_data is NULL [SENSOR_RET_ERROR_PARAM]
-/// - Data ID(p_data->did) is not supported [SENSOR_RET_ERROR_DID]
-/// - GPS setting data size(p_data->usSize) is not same with the data \n
-/// that related to data ID [SENSOR_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The message queue name has not been registered in control table when GPS \n
-/// setting message transfer between processes. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Message transfer HANDLE create failed. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Message transfer HANDLE get failed from internal table. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - GPS setting message transfer failed. [SENSOR_RET_ERROR_CREATE_EVENT]
-///
-/// \~english @par Detail
-/// - Call this API to set GPS data. \n
-/// The GPS data specified by the parameter p_data will be set in positioning.
-///
-/// \~english @par
-/// - Please note the following points when use this API.
-/// - This API is only called by Navigation proxy.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Fire and Forget
-///
-/// \~english @see
-/// - None
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-int32_t POS_ReqGPSSetting(HANDLE hApp, SENSOR_MSG_SEND_DAT *p_data);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Set GPS information
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] navilocinfo
-/// - NAVIINFO_ALL * - pointer of GPS information
-///
-/// \~english @par
-/// - NAVIINFO_ALL structure
-/// \~english @code
-/// typedef struct
-/// {
-/// uint8_t ucSensorCnt; /* sensor count */
-/// uint8_t reserve[3]; /* reserve */
-/// NAVIINFO_DIAG_GPS stDiagGps; /* position fix related information */
-/// NAVIINFO_NAVI_GPS stNaviGps; /* other GPS related information */
-/// } NAVIINFO_ALL;
-/// @endcode
-/// - sensor count \n
-/// sensor count value when GPS data received
-///
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS structure
-/// \~english @code
-/// typedef struct
-/// {
-/// NAVIINFO_DIAG_GPS_FIX stFix; /* position fix information */
-/// NAVIINFO_DIAG_GPS_SAT stSat; /* all satellite information */
-/// } NAVIINFO_DIAG_GPS;
-/// @endcode
-/// \n
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS_FIX structure
-/// \~english @code
-/// typedef struct
-/// {
-/// uint8_t ucFixSts; /* position fix status */
-/// uint8_t ucReserve[3]; /* reserve */
-/// NAVIINFO_DIAG_GPS_FIX_CNT stCnt; /* position fix count data */
-/// NAVIINFO_DIAG_GPS_FIX_XYZ stWgs84; /* lonlat data(WGS84 geodetic) */
-/// } NAVIINFO_DIAG_GPS_FIX;
-/// @endcode
-/// - position fix status(ucFixSts)
-/// - NAVIINFO_DIAG_GPS_FIX_STS_NON:not fixed
-/// - NAVIINFO_DIAG_GPS_FIX_STS_2D :2D fix
-/// - NAVIINFO_DIAG_GPS_FIX_STS_3D :3D fix
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS_FIX_CNT structure
-/// \~english @code
-/// typedef struct
-/// {
-/// uint32_t ulCnt3d; /* position fix ratio:3D(unit:sec) */
-/// uint32_t ulCnt2d; /* position fix ratio:2D(unit:sec) */
-/// uint32_t ulCntElse; /* position fix ratio:not fix(unit:sec) */
-/// } NAVIINFO_DIAG_GPS_FIX_CNT;
-/// @endcode
-///
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS_FIX_XYZ structure
-/// \~english @code
-/// typedef struct
-/// {
-/// int32_t lLat; /* GPS latitude(unit:1/256sec) (+: north latitude,-: south latitude) */
-/// int32_t lLon; /* GPS longitude(unit:1/256sec) (+: east longitude, -: west longitude) */
-/// } NAVIINFO_DIAG_GPS_FIX_XYZ;
-/// @endcode
-///
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS_SAT structure
-/// \~english @code
-/// typedef struct
-/// {
-/// NAVIINFO_DIAG_GPS_PRN stPrn[12]; /* all satellite information */
-/// } NAVIINFO_DIAG_GPS_SAT;
-/// @endcode
-///
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS_PRN structure
-/// \~english @code
-/// typedef struct
-/// {
-/// uint8_t ucRcvSts; /* reception status */
-/// uint8_t ucPrn; /* satellite No. */
-/// uint8_t ucelv; /* satellite angle(unit:1.0deg) */
-/// uint8_t ucLv; /* satellite level */
-/// uint16_t usAzm; /* satellite azimuth(unit:1.0deg) (clockwise from north) */
-/// uint8_t ucReserve[2]; /* reserve */
-/// } NAVIINFO_DIAG_GPS_PRN;
-/// @endcode
-/// - reception status(ucRcvSts)
-/// - NAVIINFO_DIAG_GPS_RCV_STS_NOTUSE :not used
-/// - NAVIINFO_DIAG_GPS_RCV_STS_SEARCHING :searching
-/// - NAVIINFO_DIAG_GPS_RCV_STS_TRACHING :tracking
-/// - NAVIINFO_DIAG_GPS_RCV_STS_NOTUSEFIX :not used for position fix
-/// - NAVIINFO_DIAG_GPS_RCV_STS_USEFIX :used for position fix
-/// \~english @par
-/// - NAVIINFO_NAVI_GPS structure
-/// \~english @code
-/// typedef struct
-/// {
-/// int32_t altitude; /* altitude(unit:1m) */
-/// uint16_t speed; /* speed(unit:1.00km/h) */
-/// uint16_t heading; /* heading(unit:0.1deg) (clockwise from north) */
-/// NAVIINFO_UTCTIME utc; /* UTC time */
-/// uint8_t tdsts; /* date and time status */
-/// uint8_t reserve[3]; /* reserve */
-/// } NAVIINFO_NAVI_GPS;
-/// @endcode
-/// - altitude(altitude) \n
-/// As the altitude is used as unit [0.01m] in internal, \n
-/// the altitude data range is (-21,474,839~21,474,839).
-/// - UTC(utc)
-/// - The time set after rollover.
-/// - date and time status(tdsts)
-/// - 0= time has not been adjusted after GPS receiver reset(time input or master reset or CSF start)
-/// - 1= time output from RTC Backup(have time adjustment result)
-/// - 2= time adjustment completed
-/// \~english @par
-/// - NAVIINFO_UTCTIME structure
-/// \~english @code
-/// typedef struct {
-/// uint16_t year; /* A.D. (1~) */
-/// uint8_t month; /* month(1~12) */
-/// uint8_t date; /* date(1~31) */
-/// uint8_t hour; /* hour(0~23) */
-/// uint8_t minute; /* minute(0~59) */
-/// uint8_t second; /* second(0~59) */
-/// uint8_t reserved; /* not used */
-/// } NAVIINFO_UTCTIME;
-/// @endcode
-///
-/// \~english @retval NAVIINFO_RET_NORMAL normal finish
-/// \~english @retval NAVIINFO_RET_ERROR_PARAM parameter error
-/// \~english @retval NAVIINFO_RET_ERROR_INNER internal error
-/// \~english @retval NAVIINFO_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval NAVIINFO_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) \n
-/// of the Dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter navilocinfo is NULL [NAVIINFO_RET_ERROR_PARAM]
-/// - The parameter hApp is NULL [NAVIINFO_RET_ERROR_PARAM]
-/// - GPS setting data size(p_data->usSize) is not same as the data that \n
-/// related to data ID [NAVIINFO_RET_ERROR_RESOURCE]
-/// - The count of message in message queue is reach to max [NAVIINFO_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [NAVIINFO_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [NAVIINFO_RET_ERROR_RESOURCE]
-/// - The message queue name has not been registered in control table. [NAVIINFO_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed. [NAVIINFO_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table. [NAVIINFO_RET_ERROR_INNER]
-/// - GPS setting message transfer failed between processes. [NAVIINFO_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to set GPS information to vehicle sensor.\n
-/// - This API will finish when get the return value.
-///
-/// \~english @par
-/// - Please note the following points when use this API.
-/// - This API is only called by Navigation proxy.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Fire and Forget and Method and Fire and Forget and Fire and Forget
-///
-/// \~english @see
-/// - POS_GetGPSInfo
-////////////////////////////////////////////////////////////////////////////////////////////
-NAVIINFO_RET_API POS_SetGPSInfo(HANDLE hApp, NAVIINFO_ALL *navilocinfo);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Get GPS data
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [out] navidiaginfo
-/// - NAVIINFO_DIAG_GPS* - pointer to get GPS data
-///
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS structure
-/// \~english @code
-/// typedef struct
-/// {
-/// NAVIINFO_DIAG_GPS_FIX stFix; /* position fix information */
-/// NAVIINFO_DIAG_GPS_SAT stSat; /* all satellite information */
-/// } NAVIINFO_DIAG_GPS;
-/// @endcode
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS_FIX structure
-/// \~english @code
-/// typedef struct
-/// {
-/// uint8_t ucFixSts; /* position fix status */
-/// uint8_t ucReserve[3]; /* reserve */
-/// NAVIINFO_DIAG_GPS_FIX_CNT stCnt; /* position fix count data */
-/// NAVIINFO_DIAG_GPS_FIX_XYZ stWgs84; /* lonlat data(WGS84 geodetic) */
-/// } NAVIINFO_DIAG_GPS_FIX;
-/// @endcode
-/// - position fix status(ucFixSts)
-/// - NAVIINFO_DIAG_GPS_FIX_STS_NON:not fixed
-/// - NAVIINFO_DIAG_GPS_FIX_STS_2D :2D fix
-/// - NAVIINFO_DIAG_GPS_FIX_STS_3D :3D fix
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS_FIX_CNT structure
-/// \~english @code
-/// typedef struct
-/// {
-/// uint32_t ulCnt3d; /* position fix count:3D(unit:sec) */
-/// uint32_t ulCnt2d; /* position fix count:2D(unit:sec) */
-/// uint32_t ulCntElse; /* position fix count:not fix(unit:sec) */
-/// } NAVIINFO_DIAG_GPS_FIX_CNT;
-/// @endcode
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS_FIX_XYZ structure
-/// \~english @code
-/// typedef struct
-/// {
-/// int32_t lLat; /* GPS latitude(unit:1/256sec) (+: north latitude, -: south latitude) */
-/// int32_t lLon; /* GPS longitude(unit:1/256sec) (+: east longitude, -: west longitude) */
-/// } NAVIINFO_DIAG_GPS_FIX_XYZ;
-/// @endcode
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS_SAT structure
-/// \~english @code
-/// typedef struct
-/// {
-/// NAVIINFO_DIAG_GPS_PRN stPrn[12]; /* all satellite information */
-/// } NAVIINFO_DIAG_GPS_SAT;
-/// @endcode
-/// \~english @par
-/// - NAVIINFO_DIAG_GPS_PRN structure
-/// \~english @code
-/// typedef struct
-/// {
-/// uint8_t ucRcvSts; /* reception status */
-/// uint8_t ucPrn; /* satellite No. */
-/// uint8_t ucelv; /* satellite angle(unit:1.0deg) */
-/// uint8_t ucLv; /* satellite level */
-/// uint16_t usAzm; /* satellite azimuth(unit:1.0deg) (clockwise from north) */
-/// uint8_t ucReserve[2]; /* reserve */
-/// } NAVIINFO_DIAG_GPS_PRN;
-/// @endcode
-/// - reception status(ucRcvSts)
-/// - NAVIINFO_DIAG_GPS_RCV_STS_NOTUSE : not used
-/// - NAVIINFO_DIAG_GPS_RCV_STS_SEARCHING : searching
-/// - NAVIINFO_DIAG_GPS_RCV_STS_TRACHING : tracking
-/// - NAVIINFO_DIAG_GPS_RCV_STS_NOTUSEFIX : not used for position fix
-/// - NAVIINFO_DIAG_GPS_RCV_STS_USEFIX : used for position fix
-///
-/// \~english @retval NAVIINFO_RET_NORMAL normal finish
-/// \~english @retval NAVIINFO_RET_ERROR_PARAM parameter error
-/// \~english @retval NAVIINFO_RET_ERROR_INNER internal error
-/// \~english @retval NAVIINFO_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval NAVIINFO_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) \n
-/// of the dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter navidiaginfo is NULL [NAVIINFO_RET_ERROR_PARAM]
-/// - The parameter hApp is NULL [NAVIINFO_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [NAVIINFO_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [NAVIINFO_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [NAVIINFO_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to max [NAVIINFO_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference is reach to max [NAVIINFO_RET_ERROR_INNER]
-/// - Memory allocate falied during the event table creation for event \n
-/// registering. [NAVIINFO_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [NAVIINFO_RET_ERROR_INNER]
-/// - Memory allocate failed in event table during the thread table creation. [NAVIINFO_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already \n
-/// been registered. [NAVIINFO_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [NAVIINFO_RET_ERROR_INNER]
-/// - The event table is full during event creation. [NAVIINFO_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed during event table creation. [NAVIINFO_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [NAVIINFO_RET_ERROR_INNER]
-/// - In event table, try to allocate the memory of the thread table creation, but \n
-/// failed. [NAVIINFO_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been \n
-/// registered. [NAVIINFO_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [NAVIINFO_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [NAVIINFO_RET_ERROR_INNER]
-/// - Initialize event object failed. [NAVIINFO_RET_ERROR_INNER]
-/// - The memory for storing semaphore control data allocate failed. [NAVIINFO_RET_ERROR_INNER]
-/// - Specified semaphore ID has not been registered when semaphore lock. [NAVIINFO_RET_ERROR_INNER]
-/// - Internal mutex HANDLE is NULL when mutex lock. [NAVIINFO_RET_ERROR_INNER]
-/// - Internal mutex HANDLE has not been registered in mutex table when mutex lock. [NAVIINFO_RET_ERROR_INNER]
-/// - The owner of specified mutex is not itself when mutex lock. [NAVIINFO_RET_ERROR_INNER]
-/// - Mutex has been multiple locked [NAVIINFO_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address. [NAVIINFO_RET_ERROR_INNER]
-/// - Can not get usable share memory address. [NAVIINFO_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory map. [NAVIINFO_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory management. [NAVIINFO_RET_ERROR_INNER]
-/// - Can not open share memory. [NAVIINFO_RET_ERROR_INNER]
-/// - Failed to mapping share memory. [NAVIINFO_RET_ERROR_INNER]
-/// - No empty field in share memory. [NAVIINFO_RET_ERROR_INNER]
-/// - Failed to guarantee share memory. [NAVIINFO_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message \n
-/// transfered between processes. [NAVIINFO_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [NAVIINFO_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [NAVIINFO_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message \n
-/// transfer between processes. [NAVIINFO_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message \n
-/// transfer between processes. [NAVIINFO_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [NAVIINFO_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered \n
-/// between processes. [NAVIINFO_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [NAVIINFO_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during \n
-/// event waiting. [NAVIINFO_RET_ERROR_INNER]
-/// - The count of thread arrived max in event management table during event waiting. [NAVIINFO_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [NAVIINFO_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [NAVIINFO_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [NAVIINFO_RET_ERROR_INNER]
-/// - The interruption happened during event getting [NAVIINFO_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [NAVIINFO_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address for accessing \n
-/// received data. [NAVIINFO_RET_ERROR_INNER]
-/// - Can not get usable share memory address for accessing received data. [NAVIINFO_RET_ERROR_INNER]
-/// - Memory for share memory map allocate failed for accessing received data. [NAVIINFO_RET_ERROR_INNER]
-/// - Memory for share memory management allocate failed for accessing received data. [NAVIINFO_RET_ERROR_INNER]
-/// - Can not open share memory for accessing received data. [NAVIINFO_RET_ERROR_INNER]
-/// - Failed to mapping share memory for accessing received data. [NAVIINFO_RET_ERROR_INNER]
-/// - The size of data stored in share memory is larger than the size of \n
-/// received data. [NAVIINFO_RET_ERROR_INNER]
-/// - The result of sensor data get processing is POS_RET_ERROR_RESOURCE. [NAVIINFO_RET_ERROR_RESOURCE]
-/// - The result of sensor data get processing is not POS_RET_ERROR_RESOURCE. [NAVIINFO_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to get GPS data for diag. \n
-/// This API will finish when get the return value.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Sync
-///
-/// \~english @see
-/// - POS_SetGPSInfo
-////////////////////////////////////////////////////////////////////////////////////////////
-NAVIINFO_RET_API POS_GetGPSInfo(HANDLE hApp, NAVIINFO_DIAG_GPS *navidiaginfo);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - GPS reset request
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] ResName
-/// - PCSTR - response thread name
-/// \~english @param [in] mode
-/// - uint8_t - reset mode
-///
-/// \~english @par
-/// - reset mode(mode) \n
-/// If the mode is not one of the following, return POS_RET_ERROR_PARAM
-/// - GPS_RST_COLDSTART - GPS reset request(cold start) \n
-/// Automatic search, track satellite and position fix after RAM initialized(all config \n
-/// items be initialized to default value).\n
-/// Initialize data objects:almanac/ ephemeris data, current position, GPS receiver mode and etc.\n
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_BUSY GPS device is still in setting
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) \n
-/// of the Dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter ResName is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter mode is not GPS_RST_COLDSTART [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - Memory allocate falied when the event table creation that for event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table when the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already been \n
-/// registered. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full when event creation. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed when event table creation. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when GPS reset \n
-/// message transfer between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when GPS reset message transfered \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when GPS reset message \n
-/// transfered between processes. [POS_RET_ERROR_INNER]
-/// - GPS reset message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during \n
-/// event waiting. [POS_RET_ERROR_INNER]
-/// - The count of thread is reach to max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event waiting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event waiting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event waiting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event waiting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event waiting. [POS_RET_ERROR_INNER]
-/// - The result of sensor data get processing is POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result of sensor data get processing is not POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to reset GPS device.
-///
-/// \~english @par
-/// - Please note the following points when use this API.
-/// - This API is only called by Navigation proxy.
-///
-/// \~english @par
-/// Notification of message
-/// - The result of communication with GPS device will be sent by system API message with following format. \n
-/// Command ID : CID_POSIF_REQ_GPS_RESET \n
-/// message structure
-/// \~english @code
-/// typedef struct
-/// {
-/// TG_GPS_RET_RESET data; /* GPS reset status data */
-/// } TG_GPS_RET_RESET_MSG;
-/// @endcode
-/// - message data body structure
-/// \~english @code
-/// typedef struct {
-/// unsigned long ret_rst_status; /* response GPS reset status */
-/// } TG_GPS_RET_RESET;
-/// @endcode
-/// - response GPS reset status(ret_rst_status)
-/// - GPS_SENDOK:acknowledge
-/// - GPS_SENDNG:connection error
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Fire and Forget
-///
-/// \~english @see
-/// - None
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_ReqGPSReset(HANDLE hApp, PCSTR ResName, uint8_t mode);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Register GPS time setting request delivery
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] notifyName
-/// - PCSTR - Destination thread name
-/// \~english @param [in] ucCtrlFlg
-/// - uint8_t - Delivery control flag(register)
-///
-/// \~english @par
-/// - Delivery control flag(ucCtrlFlg)
-/// - SENSOR_DELIVERY_REGIST - register
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_BUFFULL the register count is full
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of \n
-/// the Dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter notifyName is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter ucCtrlFlg is not register(SENSOR_DELIVERY_REGIST) [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - Memory allocate falied during the event table creation for event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table during the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already been \n
-/// registered. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full during event creation. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed during event table creation. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, try to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message \n
-/// transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed in process. [POS_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message transfer \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message \n
-/// transfer between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during \n
-/// event waiting. [POS_RET_ERROR_INNER]
-/// - The count of thread arrived max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event getting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [POS_RET_ERROR_INNER]
-/// - The result from positioning service is SENSOR_RET_ERROR_PARAM. [POS_RET_ERROR_PARAM]
-/// - The result from positioning service is SENSOR_RET_ERROR_BUFFULL. [POS_RET_ERROR_BUFFULL]
-/// - The result from positioning service is SENSOR_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result from positioning service is not SENSOR_RET_ERROR_PARAM or \n
-/// SENSOR_RET_ERROR_BUFFULL or SENSOR_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to register GPS time setting request delivery. \n
-/// This API will finish when get the return value.
-///
-///
-/// \~english @par
-/// Please note the following points when use this API.
-/// - Duplication registering
-/// - The same destination thread name has already been registered
-/// - The registered delivery data updated and normal return.(first delivery)
-/// - To one delivery destination, the same data will not be duplication deliveried at same timing.
-/// - After call this API, if the delivery destination thread name has been changed, please call this API again.
-///
-/// \~english @par
-/// Notification of message
-/// - After registered successfully, vehicle sensor information will be sent by system \n
-/// API message with following format. \n
-/// Command ID : @ref CID_POSIF_REGISTER_LISTENER_GPS_TIME_SET_REQ \n
-/// time info structure \n
-/// The year, month, date, hour, minute and second should be the format set to GPS
-/// \~english @code
-/// typedef struct {
-/// uint16_t year; /* A.D.(1~) */
-/// uint8_t month; /* month(1~12) */
-/// uint8_t date; /* date(1~31) */
-/// uint8_t hour; /* hour(0~23) */
-/// uint8_t minute; /* minute(0~59) */
-/// uint8_t second; /* second(0~59) */
-/// uint8_t reserved; /* not used */
-/// } POS_DATETIME;
-/// @endcode
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Method
-///
-/// \~english @see
-/// - None
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_RegisterListenerGPSTimeSetReq(HANDLE hApp, PCSTR notifyName, uint8_t ucCtrlFlg);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Temporarily set GPS time from Diag function
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] pstDateTime
-/// - POS_DATETIME * - pointer of GPS time
-///
-/// \~english @par
-/// - POS_DATETIME structure
-/// \~english @code
-/// typedef struct {
-/// uint16_t year; /* A.D.(1~) */
-/// uint8_t month; /* month(1~12) */
-/// uint8_t date; /* date(1~31) */
-/// uint8_t hour; /* hour(0~23) */
-/// uint8_t minute; /* minute(0~59) */
-/// uint8_t second; /* second(0~59) */
-/// uint8_t reserved; /* not used */
-/// } POS_DATETIME;
-/// @endcode
-///
-/// \~english @retval NAVIINFO_RET_NORMAL normal finish
-/// \~english @retval NAVIINFO_RET_ERROR_PARAM parameter error
-/// \~english @retval NAVIINFO_RET_ERROR_INNER internal error
-/// \~english @retval NAVIINFO_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval NAVIINFO_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) \n
-/// of the dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par change of internal status
-/// - There is no change of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter pstDateTime is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - GPS time Data size is larger than 144 [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The message queue name has not been registered in control table. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table. [POS_RET_ERROR_INNER]
-/// - GPS time setting message transfer failed. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to set GPS time data to vehicle sensor. \n
-/// This API will finish when get the return value.
-///
-///
-/// \~english @par
-/// Please note the following points when use this API.
-/// - This API will not notify the result of setting time to GPS device. \n
-/// Return normal only there is no error such as parameter error.
-/// - If want to get the result of setting time to GPS device, use \n
-/// POS_RegisterListnerGpsTime to get GPS time and judge it.
-/// - This API is only called by Diag service.
-/// - While GPS data is receiving from GPS device, the GPS time set by this API is ignored \n
-/// and it is set actual GPS time notified by positioning_hal.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Fire and Forget
-///
-/// \~english @see
-/// - POS_GetGPStime
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_SetGPStime(HANDLE hApp, POS_DATETIME* pstDateTime);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Register GPS time delivery
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] notifyName
-/// - PCSTR - Destination thread name
-/// \~english @param [in] ucCtrlFlg
-/// - uint8_t - Delivery control flag(register)
-/// \~english @param [in] ucDeliveryTiming
-/// - uint8_t - Delivery timing(change/update)
-///
-/// \~english @par
-/// - Delivery control flag(ucCtrlFlg)
-/// - SENSOR_DELIVERY_REGIST - register
-/// - Register specified data delivery
-/// - Please note that if the same data delivery has been registered for multiple \n
-/// times, the data will also be deliveried for registered multiple times.
-/// - The specified GPS time information will be deliveried at registered time (first delivery).
-/// - Delivery timing(ucDeliveryTiming)
-/// - SENSOR_DELIVERY_TIMING_CHANGE - change Specified data will be deliveried only when it changed.
-/// - SENSOR_DELIVERY_TIMING_UPDATE - update Specified data will be deliveried as \n
-/// long as it updated by vehicle sensor.
-///
-/// \~english @retval SENSOR_RET_NORMAL normal finish
-/// \~english @retval SENSOR_RET_ERROR_CREATE_EVENT event creation error
-/// \~english @retval SENSOR_RET_ERROR_PARAM parameter error
-/// \~english @retval SENSOR_RET_ERROR_INNER internal error
-/// \~english @retval SENSOR_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval SENSOR_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of \n
-/// the Dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [SENSOR_RET_ERROR_PARAM]
-/// - The parameter notifyName is NULL [SENSOR_RET_ERROR_PARAM]
-/// - The parameter ucCtrlFlg is not register(SENSOR_DELIVERY_REGIST) [SENSOR_RET_ERROR_PARAM]
-/// - The parameter ucDeliveryTiming is neither update(SENSOR_DELIVERY_TIMING_UPDATE) \n
-/// nor change(SENSOR_DELIVERY_TIMING_CHANGE) [SENSOR_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to \n
-/// max [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event is created in system, but the count of reference is reach to max [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Memory allocate falied during the event table creation for event \n
-/// registering. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The thread can not register in the event table. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Memory allocate failed in event table during the thread table creation. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - After register the thread table in event table, the event flag has already been \n
-/// registered. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - After register the thread table in event table, the event flag register \n
-/// failed. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event table is full during event creation. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The memory for event HANDLE allocate failed during event table creation. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The thread can not be registered in event table. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - In event table, try to allocate the memory of the thread table creation, but \n
-/// failed. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - After register the thread in event table, the event flag has already been \n
-/// registered. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - After register the thread in event table, the event flag register failed. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Specified event ID has not been registered in table. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Initialize event object failed. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - ProcessNo has not been registered in message control table when message \n
-/// transfered between processes. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [SENSOR_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message \n
-/// transfer between processes. [SENSOR_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message \n
-/// transfer between processes. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered \n
-/// between processes. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [SENSOR_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during \n
-/// event waiting. [SENSOR_RET_ERROR_INNER]
-/// - The count of thread arrived max in event management table during event waiting. [SENSOR_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event get. [SENSOR_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event get. [SENSOR_RET_ERROR_INNER]
-/// - The flagID has not been registered during event get. [SENSOR_RET_ERROR_INNER]
-/// - The interruption happened during event get [SENSOR_RET_ERROR_INNER]
-/// - Whatever error happened during event get. [SENSOR_RET_ERROR_INNER]
-/// - Get event timeout. [SENSOR_RET_ERROR_INNER]
-/// - Error happened during event get. [SENSOR_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to register GPS time delivery. \n
-/// This API will finish when get the return value.
-///
-///
-/// \~english @par
-/// Please note the following points when use this API.
-/// - Duplication registering
-/// - The same destination thread name has already been registered
-/// - The registered delivery data updated and normal return.(first delivery)
-/// - To one delivery destination, the same data will not be duplication deliveried at same timing.
-/// - After call this API, if the delivery destination thread name has changed, please call this API again.
-///
-/// \~english @par
-/// Notification of message
-/// - After registered successfully, vehicle sensor will send GPS time data \n
-/// as system API message with following format.
-/// - If the register successed, certainly delivery first data. And then \n
-/// delivery data according to the delivery timing.
-/// - Command ID : CID_VEHICLESENS_VEHICLE_INFO_GPS_TIME\n
-/// - SENSOR_MSG_GPSTIME structure
-/// \~english @code
-/// typedef struct {
-/// NAVIINFO_UTCTIME utc; /* UTC time */
-/// uint8_t tdsts; /* time status */
-/// uint8_t reserve[3]; /* reserve */
-/// } SENSOR_MSG_GPSTIME;
-/// @endcode
-/// - time status(tdsts)
-/// - 0= time has not been adjusted after GPS receiver reset(time input or master reset or CSF start)
-/// - 1= time output from RTC Backup(have time adjustment result)
-/// - 2= time adjustment completed
-///
-/// \~english @par
-/// - NAVIINFO_UTCTIME structure
-/// \~english @code
-/// typedef struct {
-/// uint16_t year; /* A.D.(1~) */
-/// uint8_t month; /* month(1~12) */
-/// uint8_t date; /* date(1~31) */
-/// uint8_t hour; /* hour(0~23) */
-/// uint8_t minute; /* minute(0~59) */
-/// uint8_t second; /* second(0~59) */
-/// uint8_t reserved; /* not used */
-/// } POS_DATETIME;
-/// @endcode
-///
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Method
-///
-/// \~english @see
-/// - None
-////////////////////////////////////////////////////////////////////////////////////////////
-SENSOR_RET_API POS_RegisterListenerGPStime(HANDLE hApp, PCSTR notifyName, uint8_t ucCtrlFlg, uint8_t ucDeliveryTiming);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Get GPS time
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [out] dat
-/// - SENSOR_GPSTIME* - output buffer pointer to store GPS time
-///
-/// \~english @par
-/// - SENSOR_GPSTIME structure
-/// \~english @code
-/// typedef struct {
-/// NAVIINFO_UTCTIME utc; /* UTC time */
-/// uint8_t tdsts; /* date amd time status */
-/// uint8_t reserve[3]; /* reserve */
-/// } SENSOR_GPSTIME;
-/// @endcode
-/// - date amd time status(tdsts)
-/// - 0= time has not been adjusted after GPS receiver reset(time input or master reset or CSF start)
-/// - 1= time output from RTC Backup(have time adjustment result)
-/// - 2= time adjustment completed
-///
-/// \~english @par
-/// - NAVIINFO_UTCTIME structure
-/// \~english @code
-/// typedef struct {
-/// uint16_t year; /* A.D.(1~) */
-/// uint8_t month; /* month(1~12) */
-/// uint8_t date; /* date(1~31) */
-/// uint8_t hour; /* hour(0~23) */
-/// uint8_t minute; /* minute(0~59) */
-/// uint8_t second; /* second(0~59) */
-/// uint8_t reserved; /* not used */
-/// } NAVIINFO_UTCTIME;
-/// @endcode
-///
-/// \~english @retval POS_RET_NORMAL normal finish
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) \n
-/// of the Dispatcher for App are completed.
-/// - Availability of positioning service is TRUE.
-///
-/// \~english @par changes of internal status
-/// - There is no changes of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter dat is NULL [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - The event is created in system, but the count of reference is reach to max [POS_RET_ERROR_INNER]
-/// - Memory allocate falied during the event table creation for event registering. [POS_RET_ERROR_INNER]
-/// - The thread can not register in the event table. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed in event table during the thread table creation. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag has already \n
-/// been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread table in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - The event table is full during event creation. [POS_RET_ERROR_INNER]
-/// - The memory for event HANDLE allocate failed during event table creation. [POS_RET_ERROR_INNER]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_INNER]
-/// - In event table, try to allocate the memory of the thread table creation, but failed. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag has already been registered. [POS_RET_ERROR_INNER]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_INNER]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_INNER]
-/// - Initialize event object failed. [POS_RET_ERROR_INNER]
-/// - The memory for storing semaphore control data allocate failed. [POS_RET_ERROR_INNER]
-/// - Specified semaphore ID has not been registered when semaphore lock. [POS_RET_ERROR_INNER]
-/// - Internal mutex HANDLE is NULL when mutex lock. [POS_RET_ERROR_INNER]
-/// - Internal mutex HANDLE has not been registered in mutex table when mutex lock. [POS_RET_ERROR_INNER]
-/// - The owner of specified mutex is not itself when mutex lock. [POS_RET_ERROR_INNER]
-/// - Mutex has been multiple locked [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address. [POS_RET_ERROR_INNER]
-/// - Can not get usable share memory address. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory map. [POS_RET_ERROR_INNER]
-/// - Memory allocate failed for share memory management. [POS_RET_ERROR_INNER]
-/// - Can not open share memory. [POS_RET_ERROR_INNER]
-/// - Failed to mapping share memory. [POS_RET_ERROR_INNER]
-/// - No empty field in share memory. [POS_RET_ERROR_INNER]
-/// - Failed to guarantee share memory. [POS_RET_ERROR_INNER]
-/// - ProcessNo has not been registered in message control table when message \n
-/// transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message \n
-/// transfer between processes. [POS_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message \n
-/// transfer between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered \n
-/// between processes. [POS_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [POS_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during \n
-/// event waiting. [POS_RET_ERROR_INNER]
-/// - The count of thread arrived max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event getting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event getting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event getting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event getting. [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address for accessing \n
-/// received data. [POS_RET_ERROR_INNER]
-/// - Can not get usable share memory address for accessing received data. [POS_RET_ERROR_INNER]
-/// - Memory for share memory map allocate failed for accessing received data. [POS_RET_ERROR_INNER]
-/// - Memory for share memory management allocate failed for accessing received data. [POS_RET_ERROR_INNER]
-/// - Can not open share memory for accessing received data. [POS_RET_ERROR_INNER]
-/// - Failed to mapping share memory for accessing received data. [POS_RET_ERROR_INNER]
-/// - The size of data stored in share memory is larger than the size of received data. [POS_RET_ERROR_INNER]
-/// - The result of sensor data getting process is POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_RESOURCE]
-/// - The result of sensor data getting process is not POS_RET_ERROR_RESOURCE. [POS_RET_ERROR_INNER]
-///
-/// \~english @par Detail
-/// - Call this API to get GPS time from vehicle sensor.
-///
-/// \~english @par
-/// - Please note the following points when use this API.
-///
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Sync
-///
-/// \~english @see
-/// - POS_SetGPStime
-////////////////////////////////////////////////////////////////////////////////////////////
-POS_RET_API POS_GetGPStime(HANDLE hApp, SENSOR_GPSTIME* dat);
-
-#ifdef __cplusplus
-}
-#endif
-/** @}*/ // end of positioning
-/** @}*/ // end of vehicle_service
-/** @}*/ // end of BaseSystem
-#endif // POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_GPS_API_H_
diff --git a/vehicleservice/positioning/client/include/vehicle_service/POS_sensor_API.h b/vehicleservice/positioning/client/include/vehicle_service/POS_sensor_API.h
deleted file mode 100755
index a7a35c4..0000000
--- a/vehicleservice/positioning/client/include/vehicle_service/POS_sensor_API.h
+++ /dev/null
@@ -1,716 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#ifndef POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_SENSOR_API_H_
-#define POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_SENSOR_API_H_
-/**
- * @file POS_sensor_API.h
- * @brief API definition file for Sensor function
- */
-
-/** @addtogroup BaseSystem
- * @{
- */
-/** @addtogroup vehicle_service
- * @ingroup BaseSystem
- * @{
- */
-/** @addtogroup positioning
- * @ingroup vehicle_service
- * @{
- */
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/POS_define.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-/* POSITIONING_DID */
-#define POS_DID_SPEED_PULSE 0x80000012 //!< \~english Data ID of speed pulse
-#define POS_DID_SPEED_KMPH 0x80000013 //!< \~english Data ID of KMPH speed
-#define POS_DID_SNS_COUNTER 0x8000001A
-//!< \~english Data ID of sensor counter
-#define POS_DID_GYRO_X 0x80000014 //!< \~english Data ID of X axis gyro
-#define POS_DID_GYRO_Y 0x80000085 //!< \~english Data ID of Y axis gyro
-#define POS_DID_GYRO_Z 0x80000086 //!< \~english Data ID of Z axis gyro
-#define POS_DID_GYRO POS_DID_GYRO_X
-//!< \~english Data ID of POS_DID_GYRO is same as POS_DID_GYRO_X
-#define POS_DID_GSNS_X 0x80000015 //!< \~english Data ID of x axis gsensor
-#define POS_DID_GSNS_Y 0x80000016 //!< \~english Data ID of Y axis gsensor
-#define POS_DID_GSNS_Z 0x80000026 //!< \~english Data ID of Z axis gsensor
-#define POS_DID_REV 0x80000017 //!< \~english Data ID of reverse signal
-#define POS_DID_GPS_ANTENNA 0x80000019
-//!< \~english Data ID of GPS antenna status
-#define POS_DID_SPEED_PULSE_FST 0x80000028
-//!< \~english Data ID of first time speed pulse
-#define POS_DID_GYRO_X_FST 0x80000029 //!< \~english Data ID of first time X axis gyro
-#define POS_DID_GYRO_Y_FST 0x80000043 //!< \~english Data ID of first time Y axis gyro
-#define POS_DID_GYRO_Z_FST 0x80000023 //!< \~english Data ID of first time Z axis gyro
-#define POS_DID_GYRO_FST POS_DID_GYRO_X_FST
-//!< \~~english Data ID of POS_DID_GYRO_FST is same as POS_DID_GYRO_X_FST
-#define POS_DID_REV_FST 0x8000007E
-//!< \~english Data ID of first time reverse signal
-#define POS_DID_GYRO_TEMP 0x80000090 //!< \~english Data ID of gyro temperature
-#define POS_DID_GYRO_TEMP_FST 0x80000091
-//!< \~english Data ID of first time gyro temperature
-#define POS_DID_GSNS_X_FST 0x80000087
-//!< \~english Data ID of first time x axis gsensor
-#define POS_DID_GSNS_Y_FST 0x80000088
-//!< \~english Data ID of first time Y axis gsensor
-#define POS_DID_GSNS_Z_FST 0x80000089
-//!< \~english Data ID of first time Z axis gsensor
-#define POS_DID_PULSE_TIME 0x8000003A //!< \~english Data ID of pulse time
-
-#define POS_DID_GPS__CWORD82__NMEA 0x80000030U
-//!< \~english Data ID of _CWORD82_ GPS NMEA sentence
-#define POS_DID_GPS__CWORD82___CWORD44_GP4 0x80000031U
-//!< \~english Data ID of _CWORD82_ GPS _CWORD44_GP4 data
-#define POS_DID_GPS__CWORD82__FULLBINARY 0x80000032U
-//!< \~english Data ID of _CWORD82_ GPS full binary data
-#define POS_DID_GPS_NMEA 0x8000009AU
-//!< \~english Data ID of GPS NMEA sentence
-#define POS_DID_GPS_CLOCK_DRIFT 0x800000B3U
-//!< \~english Data ID of GPS time drift data
-#define POS_DID_GPS_CLOCK_FREQ 0x800000B4U
-//!< \~english Data ID of GPS time frequency data
-
-/**
- * \~english @brief Delivery sensor extra package command ID
- * \~english @brief If you want to catch above envents, use NSFW like below.
- * \~english @code
- * l_eStatus = FrameworkUnifiedAttachCallbackToDispatcher(h_app, POS_NTFY_SEND_THREAD, CID_POSIF_REGISTER_LISTENER_PKG_SENSOR_DATA, CBCallbackA);
- * @endcode
- */
-#define CID_POSIF_REGISTER_LISTENER_PKG_SENSOR_DATA 0x0700
-
-/**
- * \~english @brief Delivery sensor information command ID
- * \~english @brief If you want to catch above envents, use NSFW like below.
- * \~english @code
- * l_eStatus = FrameworkUnifiedAttachCallbackToDispatcher(h_app, POS_NTFY_SEND_THREAD, CID_POSIF_REGISTER_LISTENER_SENSOR_DATA, CBCallbackA);
- * @endcode
- */
-#define CID_POSIF_REGISTER_LISTENER_SENSOR_DATA 0x0200
-
-#define SENSOR_MSGBUF_DSIZE 4096
-//!< \~english message body maximum size
-
-#define SENSOR_VSHEAD_DSIZE 36
-//!< \~english vehicle sensor header size(1+3+16*2)
-
-#define SENSOR_VSINFO_DSIZE (SENSOR_MSGBUF_DSIZE - SENSOR_VSHEAD_DSIZE)
-//!< \~english vehicle sensor data size
-
-// Same name/value is defined, but client doesn't include HAL header.
-// It defines SENSOR_MSG_VSINFO_DSIZE if not included HAL.
-#ifndef HAL_API_POSITIONING_HAL_H_
-#define SENSOR_MSG_VSINFO_DSIZE 1904u
-//!< \~english vehicle sensor message body maximum size
-#endif
-
-#define SENSOR_PKG_DELIVERY_MAX 16
-//!< \~english number of data ID per a package
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-/**
- * @struct SENSOR_PKG_MSG_VSINFO
- * \~english positioning sensor notification message (to User)
- */
-typedef struct {
- uint8_t ucDNum; //!< \~english number of data
- uint8_t ucDataBreak; //!< \~english data lack infomation
- uint8_t ucDivideCnt; //!< \~english total partition
- uint8_t ucDivideSendCnt; //!< \~english partition transmit count
- uint16_t usOffset[SENSOR_PKG_DELIVERY_MAX]; //!< \~english offset
- uint8_t ucData[SENSOR_VSINFO_DSIZE]; //!< \~english data body
-} SENSOR_PKG_MSG_VSINFO;
-
-/**
- * @struct SENSOR_MSG_VSINFO
- * \~english message delivery positioning sensor information
- */
-typedef struct {
- DID did; //!< \~english data ID
- uint16_t size; //!< \~english data size
- uint8_t rcvFlag; //!< \~english reception flag
- uint8_t reserve; //!< \~english reserve
- uint8_t data[SENSOR_MSG_VSINFO_DSIZE]; //!< \~english data body
-} SENSOR_MSG_VSINFO;
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-/* SENSOR_API public API */
-#ifdef __cplusplus
-extern "C" {
-#endif
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Send the extra package when first delivery.
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] notifyName
-/// - PCSTR - Destination thread name
-/// \~english @param [in] ucPkgNum
-/// - uint8_t - data number in package(1 to 16)
-/// \~english @param [in] pulDid
-/// - DID * - buffer pointer of the data ID array in package
-/// \~english @param [in] ucCtrlFlg
-/// - uint8_t - Delivery control flag(register)
-/// \~english @param [in] ucDeliveryTiming
-/// - uint8_t - Delivery timing(change/update)
-///
-/// \~english @par
-/// - data number in package(ucPkgNum) \n
-/// The following 8 data ID can be registered. And the register data number range is 1~16.
-/// - buffer pointer of the data ID array in package(pulDid) \n
-/// The data ID set to the first in pulDid is the delivery key. \n
-/// If the data ID not one of the following be set, return SENSOR_RET_ERROR_PARAM.
-/// - POS_DID_SNS_COUNTER - sensor counter
-/// - POS_DID_GYRO_X - gyro output (X axis)
-/// - POS_DID_GYRO_Y - gyro output (Y axis)
-/// - POS_DID_GYRO_Z - gyro output (Z axis)
-/// - POS_DID_SPEED_PULSE - speed pulse
-/// - POS_DID_REV - REV signal(0:forward 1:backward)
-/// - POS_DID_GSNS_X - Gsensor output X axis
-/// - POS_DID_GSNS_Y - Gsensor output Y axis
-/// - POS_DID_GSNS_Z - Gsensor output Z axis
-/// - POS_DID_GYRO_TEMP - gyro temperature
-/// - POS_DID_PULSE_TIME - pulse time\n
-/// \~english @par
-/// - Because positioning is G/W between Navi and HAL, value depends on the design of HAL.
-/// \~english @par
-/// - Note:The Gsensor output is 0 in the environment without Gsensor hardware.\n
-/// \~english @par
-/// - Delivery control flag(ucCtrlFlg)
-/// - SENSOR_DELIVERY_REGIST - register
-/// - Register specified LonLat delivery
-/// - Please note that if the same data delivery has been registered for multiple times, \n
-/// the data will also be deliveried for registered multiple times.
-/// - The specified LonLat will be deliveried at register time no matter what delivery \n
-/// timing has been registered (first delivery).
-/// - Delivery timing(ucDeliveryTiming)
-/// - SENSOR_DELIVERY_TIMING_CHANGE - change Specified LonLat be deliveried only when it is changed.
-/// - SENSOR_DELIVERY_TIMING_UPDATE - update Specified Lonlat be deliveried as long as \n
-/// it is updated by vehicle sensor.
-///
-///
-/// \~english @retval SENSOR_RET_NORMAL normal end
-/// \~english @retval SENSOR_RET_ERROR_CREATE_EVENT event create failed
-/// \~english @retval SENSOR_RET_ERROR_PARAM parameter error
-/// \~english @retval SENSOR_RET_ERROR_INNER internal error
-/// \~english @retval SENSOR_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval SENSOR_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization \n
-/// (FrameworkunifiedCreateDispatcherWithoutLoop and etc.) of the Dispatcher for App are completed.
-/// - Availability of service positioning is TRUE.
-///
-/// \~english @par change of internal status
-/// - There is no change of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [SENSOR_RET_ERROR_PARAM]
-/// - The parameter ucCtrlFlg is not register(SENSOR_DELIVERY_REGIST) [SENSOR_RET_ERROR_PARAM]
-/// - The parameter ucDeliveryTiming is neither update(SENSOR_DELIVERY_TIMING_UPDATE) \n
-/// nor change(SENSOR_DELIVERY_TIMING_CHANGE) [SENSOR_RET_ERROR_PARAM]
-/// - The parameter notifyName is NULL [SENSOR_RET_ERROR_PARAM]
-/// - The parameter ucPkgNum is 0 or it is larger than 16 [SENSOR_RET_ERROR_PARAM]
-/// - The parameter pulDid is NULL [SENSOR_RET_ERROR_PARAM]
-/// - The data ID in paramter buffer pulDid is not avaliable value [SENSOR_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The event has been registered in event table and created in same process, \n
-/// but the count of reference is reach to max [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table and created in system, but the \n
-/// count of reference is reach to max [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table, but memory for the thread event table \n
-/// creation allocate falied. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table, but the thread can not be registered in \n
-/// event table. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table, but memory for thread table creation \n
-/// allocate falied. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table, and the event flag has already been \n
-/// registered. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table, and the event flag register failed. \n
-/// [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - No empty field for registering the event HANDLE into event table. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Memory for event HANDLE get failed. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has not been registered in event table and not finished registering \n
-/// [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has not been registered in event table, and memory for thread table \n
-/// creation allocate falied. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has not been registered in event table, and the event flag has already been \n
-/// registered. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has not been registered in event table, and the event flag register failed. \n
-/// [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - ProcessNo has not been registered in message control table when message transfered \n
-/// between processes. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered in process. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer failed in process. [SENSOR_RET_ERROR_INNER]
-/// - The destination process name is NULL. [SENSOR_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message transfer \n
-/// between processes. [SENSOR_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message \n
-/// transfer between processes. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between processes. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered \n
-/// between processes. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer failed between processes. [SENSOR_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during event \n
-/// waiting. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The count of thread is reach to max in event management table during event \n
-/// waiting. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The EV_FLAG_BIT is not set in flagID during event getting. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The ID of message event queue has not been created during event getting. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The flagID has not been registered during event getting. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The interruption happened during event getting [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Whatever error happened during event getting. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Got event is SENSOR_RET_ERROR_INNER. [SENSOR_RET_ERROR_INNER]
-///
-/// \~english @par Detial
-/// - Call this API to register vehicle sensor data delivery. \n
-/// This API return the result of registering. \n
-/// The data from sensor data received to registering will be deliveried. \n
-/// The first delivery data is the sensor data(max 64 number of sensor counter, \n
-/// reverse signal,gyro temperature, max 640 number of gyro output(X axis), gyro output(X axis), gyro output(Z axis), \n
-/// speed pulse,Gsensor output(X axis), Gsensor output(Y axis), Gsensor output(Z axis), max 2048 number of pulse time) in 6.4 second. \n
-/// If the data number is more than max number, delivery the data in newest 6.4 second. \n
-/// If the sensor data accumulated more than max number, set VEHICLE_SNS_BREAK to data missing information. \n
-/// If sensor data number is more than the data number send in one time(10 number of \n
-/// sensor counter,reverse signal,gyro temperature, 100 number of gyro output(X axis), gyro output(X axis), gyro output(Z axis), \n
-/// speed pulse, Gsensor output(X axis),Gsensor output(Y axis), Gsensor output(Z axis), 320 number of pulse time), \n
-/// the old data is divided into partitions(every partition with 10 number of sensor counter, \n
-/// reverse signal,gyro temperature, 100 number of gyro output(X axis), gyro output(X axis), gyro output(Z axis), \n
-/// speed pulse,Gsensor output(X axis), Gsensor output(Y axis), Gsensor output(Z axis), 320 number of pulse time) to delivery. \n
-/// The last message for first delivery is the message that the partition count equal to partition No. \n
-/// After first delivery, the message data(1 number of sensor counter,reverse signal, \n
-/// gyro temperature, 10 number of gyro output(X axis), gyro output(X axis), gyro output(Z axis),speed pulse, \n
-/// Gsensor output(X axis), Gsensor output(Y axis), Gsensor output(Z axis), 32 number of pulse time) deliveried. \n
-/// And because the data missing information, divided partition count, \n
-/// diveided partition No is not used, they will be set to 0 in message.\n
-/// (sample)The sensor data in 6.4 second divided to delivery
-/// - 1st message(sensor counter, reverse signal, gyro temperature=10 number, gyro output(X axis), gyro output(Y axis), gyro output(Z axis), speed pulse, \n
-/// Gsensor output(X axis), Gsensor output(Y axis), Gsensor output(Z axis)=100 number, pulse time=320 number), divided \n
-/// partition count=7, divided partition No=1)
-/// - 2nd message(sensor counter, reverse signal, gyro temperature=10 number, gyro output(X axis), gyro output(Y axis), gyro output(Z axis), speed pulse, \n
-/// Gsensor output(X axis), Gsensor output(Y axis), Gsensor output(Z axis)=100 number, pulse time=320 number), divided \n
-/// partition count=7, divided partition No=2)
-/// - 3rd message(sensor counter, reverse signal, gyro temperature=10 number, gyro output(X axis), gyro output(Y axis), gyro output(Z axis), speed pulse, \n
-/// Gsensor output(X axis), Gsensor output(Y axis), Gsensor output(Z axis)=100 number, pulse time=320 number), divided \n
-/// partition count=7,divided partition No=3)
-/// - 4th message(sensor counter, reverse signal, gyro temperature=10 number, gyro output(X axis), gyro output(Y axis), gyro output(Z axis), speed pulse, \n
-/// Gsensor output(X axis), Gsensor output(Y axis), Gsensor output(Z axis)=100 number, pulse time=320 number), divided \n
-/// partition count=7,divided partition No=4)
-/// - 5th message(sensor counter, reverse signal, gyro temperature=10 number, gyro output(X axis), gyro output(Y axis), gyro output(Z axis), speed pulse, \n
-/// Gsensor output(X axis), Gsensor output(Y axis), Gsensor output(Z axis)=100 number, pulse time=320 number), divided \n
-/// partition count=7,divided partition No=5)
-/// - 6th message(sensor counter, reverse signal, gyro temperature=10 number, gyro output(X axis), gyro output(Y axis), gyro output(Z axis), speed pulse, \n
-/// Gsensor output(X axis), Gsensor output(Y axis), Gsensor output(Z axis)=100 number, pulse time=320 number), divided \n
-/// partition count=7,divided partition No=6)
-/// - 7th message(sensor counter, reverse signal, gyro temperature=4 number, gyro output(X axis), gyro output(Y axis), gyro output(Z axis), speed pulse, \n
-/// Gsensor output(X axis), Gsensor output(Y axis), Gsensor output(Z axis)=40 number, pulse time=128 number), divided \n
-/// partition count=7,divided partition No=7)
-///
-/// \~english @par
-/// - Please note the following points when use this API.
-/// - Duplication registering
-/// - The same destination thread name has already been registered
-/// - The registered delivery data updated and normal return.(first delivery)
-/// - To one delivery destination, the same data will not be duplication deliveried at same timing.
-/// - After delivery the sensor data accumulated in 6.4 second(first delivery), the sensor data \n
-/// will not be accumulated any more. So the same data will be deliveried as first \n
-/// delivery when registered again.
-/// - This API is only called by Navi proxy.
-/// - After call this API, if the delivery destination thread name is changed, please call this API again.
-///
-/// \~english @par
-/// message structure
-/// - After success to register, vehicle sensor will send message as system API message with following format.
-/// Command ID : @ref CID_POSIF_REGISTER_LISTENER_PKG_SENSOR_DATA \n
-/// Definition of structure
-/// \~english @code
-/// #define SENSOR_MSGBUF_DSIZE 4096 /* max size of message body */
-/// #define SENSOR_VSHEAD_DSIZE 36 /* vehicle sensor header size(1+3+16*2) */
-/// #define SENSOR_PKG_DELIVERY_MAX 16 /* max number of Data ID in package */
-/// #define SENSOR_VSINFO_DSIZE (SENSOR_MSGBUF_DSIZE - SENSOR_VSHEAD_DSIZE)
-/// typedef struct {
-/// uint8_t ucDNum; /* number of data */
-/// uint8_t ucDataBreak; /* data missing information */
-/// uint8_t ucDivideCnt; /* divided partition count */
-/// uint8_t ucDivideSendCnt; /* divided partition No. */
-/// uint16_t usOffset[SENSOR_PKG_DELIVERY_MAX]; /* offset */
-/// uint8_t ucData[SENSOR_VSINFO_DSIZE]; /* vehicle sensor data */
-/// } SENSOR_PKG_MSG_VSINFO;
-/// @endcode
-/// - number of data \n
-/// Data number in package
-/// - data missing information \n
-/// VEHICLE_SNS_BREAK:not continuous data \n
-/// VEHICLE_SNS_NORMAL:continuous data
-/// - divided partition count \n
-/// All divided partition count \n
-/// If it is more than 1, data divided to delivery
-/// - divided partition No. \n
-/// The No. of the divided partition. If it equal to the divided partition count, \n
-/// that meanings this message is the last divided partition of the package.
-/// - offset \n
-/// The array of the offset from the head of vehicle sensor data
-/// - vehicle sensor data
-/// - Data ID(4Byte)
-/// - Data size(2Byte)
-/// - reception flag(1Byte)
-/// - If the data get from CAN, direct line, GPS, set to 0x01
-/// - If data has not been received, set to 0x00
-/// - reserve(1Byte)\n
-/// - Data body is cycle fit with the packaged data.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Method
-///
-/// \~english @see
-/// - POS_RegisterListenerSensData, POS_GetSensData
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-SENSOR_RET_API POS_RegisterListenerPkgSensData(HANDLE hApp, PCSTR notifyName, uint8_t ucPkgNum, DID *pulDid,
- uint8_t ucCtrlFlg, uint8_t ucDeliveryTiming);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Register sensor data delivery.
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] notifyName
-/// - PCSTR - Destination thread name
-/// \~english @param [in] ulDid
-/// - DID - Data ID of vehicle info
-/// \~english @param [in] ucCtrlFlg
-/// - uint8_t - Delivery control flag(register)
-/// \~english @param [in] ucDeliveryTiming
-/// - uint8_t - Delivery timing(change/update)
-///
-/// \~english @par
-/// - Data ID of vehicle info(ulDid) \n
-///
-/// \~english @par
-/// - Note:The Gsensor output is 0 in the environment without Gsensor hardware.
-/// \~english @par
-/// - Delivery control flag(ucCtrlFlg)
-/// - SENSOR_DELIVERY_REGIST - register
-/// - Register specified LonLat delivery
-/// - Please note that if the same data delivery has been registered for multiple times, \n
-/// the data will also be deliveried for registered multiple times.
-/// - The specified LonLat will be deliveried at register time no matter what delivery \n
-/// timing has been registered (first delivery).
-/// - Delivery timing(ucDeliveryTiming)
-/// - SENSOR_DELIVERY_TIMING_CHANGE - change Specified LonLat be deliveried only when it is changed.
-/// - SENSOR_DELIVERY_TIMING_UPDATE - update Specified Lonlat be deliveried \n
-/// as long as it is updated by vehicle sensor.
-///
-/// \~english @retval SENSOR_RET_NORMAL normal end
-/// \~english @retval SENSOR_RET_ERROR_CREATE_EVENT event create failed
-/// \~english @retval SENSOR_RET_ERROR_PARAM parameter error
-/// \~english @retval SENSOR_RET_ERROR_INNER internal error
-/// \~english @retval SENSOR_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval SENSOR_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) \n
-/// of the Dispatcher for App are completed.
-/// - Availability of service positioning is TRUE.
-///
-/// \~english @par change of internal status
-/// - There is no change of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter ucDeliveryTiming is neither update \n
-/// (SENSOR_DELIVERY_TIMING_UPDATE) nor change(SENSOR_DELIVERY_TIMING_CHANGE) [SENSOR_RET_ERROR_PARAM]
-/// - The parameter ucCtrlFlg is not register(SENSOR_DELIVERY_REGIST) [SENSOR_RET_ERROR_PARAM]
-/// - The parameter hApp is NULL [SENSOR_RET_ERROR_PARAM]
-/// - The parameter notifyName is NULL [SENSOR_RET_ERROR_PARAM]
-/// - The parameter ulDID is not avaliable value [SENSOR_RET_ERROR_PARAM]
-/// - The parameter ulDID is a value can not specified [SENSOR_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [SENSOR_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to \n
-/// max [SENSOR_RET_ERROR_RESOURCE]
-/// - The event has been registered in event table and created in same process, \n
-/// but the count of reference is reach to max [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table and created in system, but the count \n
-/// of reference is reach to max [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table, but memory for the thread event table \n
-/// creation allocate falied. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table, but the thread can not be registered \n
-/// in event table. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table, but memory for thread table creation \n
-/// allocate falied. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table, and the event flag has already been \n
-/// registered. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has been registered in event table, and the event flag register failed. \n
-/// [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - No empty field for registering the event HANDLE into event table. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Memory for event HANDLE get failed. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has not been registered in event table and not finished registering \n
-/// [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has not been registered in event table, and memory for thread table \n
-/// creation allocate falied. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has not been registered in event table, and the event flag has already \n
-/// been registered. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The event has not been registered in event table, and the event flag register \n
-/// failed. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - ProcessNo has not been registered in message control table when message transfered \n
-/// in process. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed when message transfered in process. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer failed in process. [SENSOR_RET_ERROR_INNER]
-/// - The destination process name is NULL. [SENSOR_RET_ERROR_INNER]
-/// - The destination process name size is larger than 20 characters when message \n
-/// transfer between process. [SENSOR_RET_ERROR_INNER]
-/// - The message queue name has not been registered in control table when message \n
-/// transfer between process. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer HANDLE create failed when message transfered between process. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer HANDLE get failed from internal table when message transfered \n
-/// between process. [SENSOR_RET_ERROR_INNER]
-/// - Message transfer failed between process. [SENSOR_RET_ERROR_INNER]
-/// - Specified event HANDLE has not been registered in event HANDLE table during waiting \n
-/// event. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The count of thread is reach to max in event management table during waiting \n
-/// event. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The EV_FLAG_BIT is not set in flagID during getting event. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The ID of message event queue has not been created during getting event. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The flagID has not been registered during getting event. [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - The interruption happened during getting event [SENSOR_RET_ERROR_CREATE_EVENT]
-/// - Whatever error happened during getting event. [SENSOR_RET_ERROR_CREATE_EVENT]
-///
-/// \~english @par Detial
-/// - Call this API to register vehicle sensor data delivery. \n
-/// This API return the result of registering.
-///
-/// \~english @par
-/// Please note the following points when use this API.
-/// - Duplication registering
-/// - The same destination thread name has already been registered
-/// - The registered delivery data updated and normal return.(first delivery)
-/// - To one delivery destination, the same data will not be duplication deliveried at same timing.
-/// - After call this API, if the delivery destination thread name is changed, please call this API again.
-///
-/// \~english @par
-/// message structure
-/// - After success to register, vehicle sensor will send message as system API message with following format.
-/// - If the register successed, certainly delivery first data. And then delivery data according to
-/// the delivery timing. \n
-/// Command ID : @ref CID_POSIF_REGISTER_LISTENER_SENSOR_DATA \n
-///
-/// \~english @code
-/// #define SENSOR_MSG_VSINFO_DSIZE 1904 /* max size of message body */
-/// typedef struct
-/// {
-/// DID did; /* data ID */
-/// uint16_t size; /* data size of vehicle sensor data */
-/// uint8_t rcvFlag; /* reception flag */
-/// uint8_t reserve; /* reserve */
-/// uint8_t data[SENSOR_MSG_VSINFO_DSIZE]; /* vehicle sensor data */
-/// } SENSOR_MSG_VSINFO;
-/// @endcode
-/// - reception flag(1Byte)
-/// - If the data get from CAN or direct line, set to 0x01
-/// - If data has not been received, set to 0x00
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Method
-///
-/// \~english @see
-/// - POS_RegisterListenerPkgSensData, POS_GetSensData
-///
-////////////////////////////////////////////////////////////////////////////////////////////
-SENSOR_RET_API POS_RegisterListenerSensData(HANDLE hApp, PCSTR notifyName, DID ulDid, uint8_t ucCtrlFlg,
- uint8_t ucDeliveryTiming);
-
-////////////////////////////////////////////////////////////////////////////////////////////
-/// \ingroup tag_Positioning
-/// \~english @par Brief
-/// - Get vehicle sensor data.
-///
-/// \~english @param [in] hApp
-/// - HANDLE - App Handle
-/// \~english @param [in] ulDid
-/// - DID - Data ID of vehicle info
-/// \~english @param [out] pDestData
-/// - void* - pointer of buffer for storing vehicle sensor data
-/// \~english @param [in] usDestSize
-/// - uint16_t - vehicle sensor data buffer size
-///
-/// \~english @par
-/// - Data ID of vehicle info(ulDid)
-/// - POS_DID_SPEED_PULSE - speed pulse(count of pulse)
-/// - POS_DID_GYRO_X - gyro output (X axis)
-/// - POS_DID_GYRO_Y - gyro output (Y axis)
-/// - POS_DID_GYRO_Z - gyro output (Z axis)
-/// - POS_DID_GSNS_X - Gsensor output (X axis)
-/// - POS_DID_GSNS_Y - Gsensor output (Y axis)
-/// - POS_DID_GSNS_Z - Gsensor output (Z axis)
-/// - POS_DID_GPS_ANTENNA - GPS antenna connection status
-/// - POS_DID_GPS__CWORD82__NMEA - GPS NMEA(_CWORD82_)
-/// - POS_DID_GPS__CWORD82__FULLBINARY - GPS _CWORD82_ full binary(_CWORD82_)
-/// - POS_DID_GPS_NMEA - GPS NMEA
-/// - POS_DID_GYRO_TEMP - gyro temperature
-/// - POS_DID_GPS_CLOCK_DRIFT - GPS clock drift
-/// - POS_DID_GPS_CLOCK_FREQ - GPS clock frequency
-/// - The avaliable data ID of each hardware type is as following.
-/// \~english @par
-/// - Because positioning is G/W between Navi and HAL, value depends on the design of HAL.
-/// \~english @par
-/// - Note:The Gsensor output is 0 in the environment without Gsensor hardware.
-/// - vehicle sensor data buffer size(usDestSize) \n
-/// Please note it is the size of output buffer, not the size of data.
-///
-/// \~english @retval more than 0 data size
-/// \~english @retval POS_RET_ERROR_CREATE_EVENT event create failed
-/// \~english @retval POS_RET_ERROR_OUTOF_MEMORY share memory guarantee failed
-/// \~english @retval POS_RET_ERROR_PARAM parameter error
-/// \~english @retval POS_RET_ERROR_SIZE buffer size error
-/// \~english @retval POS_RET_ERROR_INNER internal error
-/// \~english @retval POS_RET_ERROR_NOSUPPORT unsupported
-/// \~english @retval POS_RET_ERROR_RESOURCE lack of resource
-///
-/// \~english @par Precondition
-/// - The creation/initialization(FrameworkunifiedCreateDispatcherWithoutLoop and etc.) \n
-/// of the Dispatcher for App are completed.
-/// - Availability of service positioning is TRUE.
-///
-/// \~english @par change of internal status
-/// - There is no change of internal status
-///
-/// \~english @par Failure condition
-/// - The parameter hApp is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter pDestData is NULL [POS_RET_ERROR_PARAM]
-/// - The parameter ulDid is not avaliable value in current hardware environment [POS_RET_ERROR_PARAM]
-/// - The count of message in message queue is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of mutex is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The count of item in ProcessName-ProcessNo convert table is reach to max [POS_RET_ERROR_RESOURCE]
-/// - The event is created in same process, but the count of reference is reach to max \n
-/// [POS_RET_ERROR_CREATE_EVENT]
-/// - The event is created in system, but the count of reference is reach to max [POS_RET_ERROR_CREATE_EVENT]
-/// - Memory allocate falied during the event table creation for \n
-/// event registering. [POS_RET_ERROR_CREATE_EVENT]
-/// - The thread can not register in the event table. [POS_RET_ERROR_CREATE_EVENT]
-/// - Memory allocate failed in event table during the thread table creation. [POS_RET_ERROR_CREATE_EVENT]
-/// - After register the thread table in event table, the event flag has already \n
-/// been registered. [POS_RET_ERROR_CREATE_EVENT]
-/// - After register the thread table in event table, the event flag register \n
-/// failed. [POS_RET_ERROR_CREATE_EVENT]
-/// - The event table is full during event creation. [POS_RET_ERROR_CREATE_EVENT]
-/// - The memory for event HANDLE allocate failed during event table creation. [POS_RET_ERROR_CREATE_EVENT]
-/// - The thread can not be registered in event table. [POS_RET_ERROR_CREATE_EVENT]
-/// - In event table, to allocate the memory of the thread table creation, \n
-/// but failed. [POS_RET_ERROR_CREATE_EVENT]
-/// - After register the thread in event table, the event flag has already been \n
-/// registered. [POS_RET_ERROR_CREATE_EVENT]
-/// - After register the thread in event table, the event flag register failed. [POS_RET_ERROR_CREATE_EVENT]
-/// - Specified event ID has not been registered in table. [POS_RET_ERROR_CREATE_EVENT]
-/// - Initialize event object failed. [POS_RET_ERROR_CREATE_EVENT]
-/// - There is no empty field in semaphore table for semaphore creation [POS_RET_ERROR_OUTOF_MEMORY]
-/// - The memory for storing semaphore control data allocate failed. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Specified semaphore ID has not been registered when semaphore lock. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Internal mutex HANDLE is NULL when mutex lock. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Internal mutex HANDLE has not been registered in mutex table when mutex lock. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - The owner of specified mutex is not itself when mutex lock. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Mutex has been multiple locked [POS_RET_ERROR_OUTOF_MEMORY]
-/// - The HANDLE is NULL when getting usable share memory address. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Can not get usable share memory address. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Memory allocate failed for share memory map. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Memory allocate failed for share memory management. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Can not open share memory. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Failed to mapping share memory. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - No empty field in share memory. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - ProcessNo has not been registered in message control table when message \n
-/// transfered between processes. [POS_RET_ERROR_CREATE_EVENT]
-/// - Message transfer HANDLE get failed when message transfered between processes. [POS_RET_ERROR_CREATE_EVENT]
-/// - Message transfer failed between processes. [POS_RET_ERROR_CREATE_EVENT]
-/// - The destination process name size is larger than 20 characters when message \n
-/// transfer between processes. [POS_RET_ERROR_CREATE_EVENT]
-/// - The message queue name has not been registered in control table when message \n
-/// transfer between processes. [POS_RET_ERROR_CREATE_EVENT]
-/// - Message transfer HANDLE create failed when message transfered between processes. \n
-/// [POS_RET_ERROR_CREATE_EVENT]
-/// - Message transfer HANDLE get failed from internal table when message transfered \n
-/// between processes. [POS_RET_ERROR_CREATE_EVENT]
-/// - Message transfer failed between processes. [POS_RET_ERROR_CREATE_EVENT]
-/// - Specified event HANDLE has not been registered in event HANDLE table during \n
-/// event waiting. [POS_RET_ERROR_INNER]
-/// - The count of thread is reach to max in event management table during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during event waiting. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during event waiting. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during event waiting. [POS_RET_ERROR_INNER]
-/// - The interruption happened during event waiting [POS_RET_ERROR_INNER]
-/// - Whatever error happened during event waiting. [POS_RET_ERROR_INNER]
-/// - The EV_FLAG_BIT is not set in flagID during getting event. [POS_RET_ERROR_INNER]
-/// - The ID of message event queue has not been created during getting event. [POS_RET_ERROR_INNER]
-/// - The flagID has not been registered during getting event. [POS_RET_ERROR_INNER]
-/// - The interruption happened during getting event [POS_RET_ERROR_INNER]
-/// - Whatever error happened during getting event. [POS_RET_ERROR_INNER]
-/// - The HANDLE is NULL when getting usable share memory address for accessing \n
-/// received data. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Can not get usable share memory address for accessing received data. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Memory for share memory map allocate failed for accessing received data. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Memory for share memory management allocate failed for accessing received \n
-/// data. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Can not open share memory for accessing received data. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Failed to mapping share memory for accessing received data. [POS_RET_ERROR_OUTOF_MEMORY]
-/// - Can not get share memory normally [POS_RET_ERROR_OUTOF_MEMORY]
-/// - The size of data stored in share memory is larger than the size of received data. [POS_RET_ERROR_SIZE]
-///
-/// \~english @par Detial
-/// - Call this API to get vehicle sensor data. \n
-/// This vehicle sensor data stored in the output buffer of the parameter, this API return.
-///
-/// \~english @par Classification
-/// - Public
-///
-/// \~english @par Type
-/// - Sync
-///
-/// \~english @see
-/// - POS_RegisterListenerPkgSensData, POS_RegisterListenerSensData
-///
-
-POS_RET_API POS_GetSensData(HANDLE hApp, DID ulDid, void *pDestData, uint16_t usDestSize);
-
-#ifdef __cplusplus
-}
-#endif
-/** @}*/ // end of positioning
-/** @}*/ // end of vehicle_service
-/** @}*/ // end of BaseSystem
-#endif // POSITIONING_CLIENT_INCLUDE_VEHICLE_SERVICE_POS_SENSOR_API_H_
diff --git a/vehicleservice/positioning/client/include/vehicle_service/positioning.h b/vehicleservice/positioning/client/include/vehicle_service/positioning.h
deleted file mode 100755
index a5a1e56..0000000
--- a/vehicleservice/positioning/client/include/vehicle_service/positioning.h
+++ /dev/null
@@ -1,46 +0,0 @@
-//
-// @copyright Copyright (c) 2017-2020 TOYOTA MOTOR CORPORATION.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-//
-
-
-#ifndef VEHICLESERVICE_POSITIONING_H_ // NOLINT(build/header_guard)
-#define VEHICLESERVICE_POSITIONING_H_ // NOLINT(build/header_guard)
-
-/**
- * @file positioning.h
- * @brief Common header of positioning
- */
-
-/** @addtogroup BaseSystem
- * @{
- */
-/** @addtogroup vehicle_service
- * @ingroup BaseSystem
- * @{
- */
-/** @addtogroup positioning
- * @ingroup vehicle_service
- * @{
- */
-
-#include <vehicle_service/POS_define.h>
-#include <vehicle_service/POS_sensor_API.h>
-#include <vehicle_service/POS_gps_API.h>
-#include <vehicle_service/POS_common_API.h>
-
-/** @}*/ // end of positioning
-/** @}*/ // end of vehicle_service
-/** @}*/ // end of BaseSystem
-#endif // VEHICLESERVICE_POSITIONING_H_
diff --git a/vehicleservice/positioning/client/src/POS_common_API/Common_API.cpp b/vehicleservice/positioning/client/src/POS_common_API/Common_API.cpp
deleted file mode 100755
index f266dec..0000000
--- a/vehicleservice/positioning/client/src/POS_common_API/Common_API.cpp
+++ /dev/null
@@ -1,889 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Common_API.cpp
- * @brief
- * Module : POSITIONING
- * Common I/F service functionality
- */
-#include <vehicle_service/positioning_base_library.h>
-#include <vehicle_service/POS_define.h>
-#include <vehicle_service/POS_common_API.h>
-#include "POS_common_private.h"
-#include "Vehicle_API_private.h"
-#include "POS_private.h"
-
-/**
- * @brief
- * Latitude and longitude informationDelivery registration
- *
- * Registering Latitude and Longitude Information Delivery
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] notifyName PCSTR - Destination thread name
- * @param[in] ucCtrlFlg uint8_t - Delivery control(Delivery registration/Delivery stop/Resume delivery)
- * @param[in] ucDeliveryTiming uint8_t - Delivery timing(Changing/Updating)
- * @param[in] ucGetMethod uint8_t - Acquisition method(GPS/Navigation/Not specified)
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_BUFFULL Buffer-full<br>
- * POS_RET_ERROR_INNER Internal error<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_RegisterListenerLonLat(HANDLE hApp, // NOLINT(readability/nolint)
- PCSTR notifyName, // NOLINT(readability/nolint)
- uint8_t ucCtrlFlg, // NOLINT(readability/nolint)
- uint8_t ucDeliveryTiming, // NOLINT(readability/nolint)
- uint8_t ucGetMethod) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value of this function */
- SENSOR_RET_API ret_sens = SENSOR_RET_NORMAL; /* API return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- DID did = VEHICLE_DID_LOCATION_LONLAT; /* Data ID */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if ((ucDeliveryTiming != SENSOR_DELIVERY_TIMING_CHANGE) &&
- (ucDeliveryTiming != SENSOR_DELIVERY_TIMING_UPDATE)) {
- /* Change delivery timing,Terminate as a parameter error except update */
- ret = POS_RET_ERROR_PARAM;
- } else if (ucCtrlFlg != SENSOR_DELIVERY_REGIST) {
- /* Parameters other than delivery registration are terminated abnormally when delivery control is terminated. */
- ret = POS_RET_ERROR_PARAM;
- } else if (hApp == NULL) {
- /* If the handler is NULL, the process terminates with an error. */
- ret = POS_RET_ERROR_PARAM;
- } else if (notifyName == NULL) {
- /* If the thread name is NULL, it terminates with an abnormal parameter. */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
-
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- if (ucGetMethod == SENSOR_GET_METHOD_GPS) {
- did = VEHICLE_DID_LOCATION_LONLAT;
- } else if ((ucGetMethod == SENSOR_GET_METHOD_NAVI) ||
- (ucGetMethod == SENSOR_GET_METHOD_AUTO)) {
- did = VEHICLE_DID_LOCATION_LONLAT_NAVI;
- } else {
- /* End as a parameter error abnormality except for GPS/unspecified acquisition method */
- ret = POS_RET_ERROR_PARAM;
- }
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = POS_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = POS_RET_ERROR_NOSUPPORT;
- }
- }
-
- /* Delivery registration */
- if (ret == POS_RET_NORMAL) {
- /* Delivery registry SensorAPI calls */
- ret_sens = PosRegisterListenerProc(notifyName, /* Destination thread name */
- did, /* Data ID */
- ucCtrlFlg, /* Delivery control */
- ucDeliveryTiming); /* Delivery timing */
-
- /* Decision of delivery registration result */
- if (ret_sens == SENSOR_RET_NORMAL) {
- ret = POS_RET_NORMAL;
- } else if (ret_sens == SENSOR_RET_ERROR_PARAM) {
- ret = POS_RET_ERROR_PARAM;
- } else if (ret_sens == SENSOR_RET_ERROR_BUFFULL) {
- ret = POS_RET_ERROR_BUFFULL;
- } else if (ret_sens == SENSOR_RET_ERROR_RESOURCE) {
- ret = POS_RET_ERROR_RESOURCE;
- } else {
- ret = POS_RET_ERROR_INNER;
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * Altitude information delivery registration
- *
- * Register for the delivery of altitude information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] notifyName PCSTR - Destination thread name
- * @param[in] ucCtrlFlg uint8_t - Delivery control(Delivery registration/Delivery stop/Resume delivery)
- * @param[in] ucDeliveryTiming uint8_t - Delivery timing(Changing/Updating)
- * @param[in] ucGetMethod uint8_t - Acquisition method(GPS/Navigation/Not specified)
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_RegisterListenerAltitude(HANDLE hApp, // NOLINT(readability/nolint)
- PCSTR notifyName, // NOLINT(readability/nolint)
- uint8_t ucCtrlFlg, // NOLINT(readability/nolint)
- uint8_t ucDeliveryTiming, // NOLINT(readability/nolint)
- uint8_t ucGetMethod) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value */
- SENSOR_RET_API ret_sens = SENSOR_RET_NORMAL; /* API return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- DID did = VEHICLE_DID_LOCATION_ALTITUDE; /* Data ID */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if ((ucDeliveryTiming != SENSOR_DELIVERY_TIMING_CHANGE) &&
- (ucDeliveryTiming != SENSOR_DELIVERY_TIMING_UPDATE)) {
- /* Change delivery timing,Terminate as a parameter error except update */
- ret = POS_RET_ERROR_PARAM;
- } else if (ucCtrlFlg != SENSOR_DELIVERY_REGIST) {
- /* Parameters other than delivery registration are terminated abnormally when delivery control is terminated. */
- ret = POS_RET_ERROR_PARAM;
- } else if (hApp == NULL) {
- /* If the handler is NULL, the process terminates with an error. */
- ret = POS_RET_ERROR_PARAM;
- } else if (notifyName == NULL) {
- /* If the thread name is NULL, it terminates with an abnormal parameter. */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- if ((ucGetMethod == SENSOR_GET_METHOD_GPS) ||
- (ucGetMethod == SENSOR_GET_METHOD_AUTO)) {
- did = VEHICLE_DID_LOCATION_ALTITUDE;
- } else {
- /* End as a parameter error abnormality except for GPS/unspecified acquisition method */
- ret = POS_RET_ERROR_PARAM;
- }
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- }
- }
-
- /* Delivery registration */
- if (ret == POS_RET_NORMAL) {
- /* Delivery registry SensorAPI calls */
- ret_sens = PosRegisterListenerProc(notifyName, /* Destination thread name */
- did, /* Data ID */
- ucCtrlFlg, /* Delivery control */
- ucDeliveryTiming); /* Delivery timing */
-
- /* Decision of delivery registration result */
- if (ret_sens == SENSOR_RET_NORMAL) {
- ret = POS_RET_NORMAL;
- } else if (ret_sens == SENSOR_RET_ERROR_PARAM) {
- ret = POS_RET_ERROR_PARAM;
- } else if (ret_sens == SENSOR_RET_ERROR_BUFFULL) {
- ret = POS_RET_ERROR_BUFFULL;
- } else if (ret_sens == SENSOR_RET_ERROR_RESOURCE) {
- ret = POS_RET_ERROR_RESOURCE;
- } else {
- ret = POS_RET_ERROR_INNER;
- }
- }
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * Vehicle Speed Information Transmission Registration
- *
- * Register delivery of vehicle speed information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] notifyName PCSTR - Destination thread name
- * @param[in] ucCtrlFlg uint8_t - Delivery control(Delivery registration/Delivery stop/Resume delivery)
- * @param[in] ucDeliveryTiming uint8_t - Delivery timing(Changing/Updating)
- * @param[in] ucGetMethod uint8_t - Acquisition method(POS/Navigation/Not specified)
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_BUFFULL Buffer-full<br>
- * POS_RET_ERROR_INNER Internal error<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_RegisterListenerSpeed(HANDLE hApp, // NOLINT(readability/nolint)
- PCSTR notifyName, // NOLINT(readability/nolint)
- uint8_t ucCtrlFlg, // NOLINT(readability/nolint)
- uint8_t ucDeliveryTiming, // NOLINT(readability/nolint)
- uint8_t ucGetMethod) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value of this function */
- SENSOR_RET_API ret_sens = SENSOR_RET_NORMAL; /* API return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- DID did; /* Data ID */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if ((ucDeliveryTiming != SENSOR_DELIVERY_TIMING_CHANGE) &&
- (ucDeliveryTiming != SENSOR_DELIVERY_TIMING_UPDATE)) {
- /* Change delivery timing,Terminate as a parameter error except update */
- ret = POS_RET_ERROR_PARAM;
- } else if (ucCtrlFlg != SENSOR_DELIVERY_REGIST) {
- /* Parameters other than delivery registration are terminated abnormally when delivery control is terminated. */
- ret = POS_RET_ERROR_PARAM;
- } else if (hApp == NULL) {
- /* If the handler is NULL, the process terminates with an error. */
- ret = POS_RET_ERROR_PARAM;
- } else if (notifyName == NULL) {
- /* If the thread name is NULL, it terminates with an abnormal parameter. */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- if (ucGetMethod == SENSOR_GET_METHOD_POS) {
- did = VEHICLE_DID_MOTION_SPEED_INTERNAL;
- } else if ((ucGetMethod == SENSOR_GET_METHOD_NAVI) ||
- (ucGetMethod == SENSOR_GET_METHOD_AUTO)) {
- did = VEHICLE_DID_MOTION_SPEED_NAVI;
- } else {
- ret = POS_RET_ERROR_PARAM;
- }
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = POS_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = POS_RET_ERROR_NOSUPPORT;
- }
- }
-
- /* Delivery registration */
- if (ret == POS_RET_NORMAL) {
- /* Delivery registry SensorAPI calls */
- ret_sens = PosRegisterListenerProc(notifyName, /* Destination thread name */
- did, /* Data ID */
- ucCtrlFlg, /* Delivery control */
- ucDeliveryTiming); /* Delivery timing */
-
- /* Decision of delivery registration result */
- if (ret_sens == SENSOR_RET_NORMAL) {
- ret = POS_RET_NORMAL;
- } else if (ret_sens == SENSOR_RET_ERROR_PARAM) {
- ret = POS_RET_ERROR_PARAM;
- } else if (ret_sens == SENSOR_RET_ERROR_BUFFULL) {
- ret = POS_RET_ERROR_BUFFULL;
- } else if (ret_sens == SENSOR_RET_ERROR_RESOURCE) {
- ret = POS_RET_ERROR_RESOURCE;
- } else {
- ret = POS_RET_ERROR_INNER;
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * Compass Information Transmission Register
- *
- * Register the delivery of the vehicle orientation information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] notifyName PCSTR - Destination thread name
- * @param[in] ucCtrlFlg uint8_t - Delivery control(Delivery registration/Delivery stop/Resume delivery)
- * @param[in] ucDeliveryTiming uint8_t - Delivery timing(Changing/Updating)
- * @param[in] ucGetMethod uint8_t - Acquisition method(GPS/Navigation/Not specified)
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_RegisterListenerHeading(HANDLE hApp, // NOLINT(readability/nolint)
- PCSTR notifyName, // NOLINT(readability/nolint)
- uint8_t ucCtrlFlg, // NOLINT(readability/nolint)
- uint8_t ucDeliveryTiming, // NOLINT(readability/nolint)
- uint8_t ucGetMethod) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value */
- SENSOR_RET_API ret_sens = SENSOR_RET_NORMAL; /* API return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- DID did = VEHICLE_DID_MOTION_HEADING; /* TODO VEHICLE_DID_LOCATION_HEADING Missing */
- /* Data ID */
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if ((ucDeliveryTiming != SENSOR_DELIVERY_TIMING_CHANGE) &&
- (ucDeliveryTiming != SENSOR_DELIVERY_TIMING_UPDATE)) {
- /* Change delivery timing,Terminate as a parameter error except update */
- ret = POS_RET_ERROR_PARAM;
- } else if (ucCtrlFlg != SENSOR_DELIVERY_REGIST) {
- /* Parameters other than delivery registration are terminated abnormally when delivery control is terminated. */
- ret = POS_RET_ERROR_PARAM;
- } else if (hApp == NULL) {
- /* If the handler is NULL, the process terminates with an error. */
- ret = POS_RET_ERROR_PARAM;
- } else if (notifyName == NULL) {
- /* If the thread name is NULL, it terminates with an abnormal parameter. */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- if (ucGetMethod == SENSOR_GET_METHOD_GPS) {
- did = VEHICLE_DID_MOTION_HEADING;
- } else if ((ucGetMethod == SENSOR_GET_METHOD_NAVI) ||
- (ucGetMethod == SENSOR_GET_METHOD_AUTO)) {
- did = VEHICLE_DID_MOTION_HEADING_NAVI;
- } else {
- /* End as a parameter error abnormality except for GPS/unspecified acquisition method */
- ret = POS_RET_ERROR_PARAM;
- }
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- }
- }
-
- /* Delivery registration */
- if (ret == POS_RET_NORMAL) {
- /* Delivery registry SensorAPI calls */
- ret_sens = PosRegisterListenerProc(notifyName, /* Destination thread name */
- did, /* Data ID */
- ucCtrlFlg, /* Delivery control */
- ucDeliveryTiming); /* Delivery timing */
-
- /* Decision of delivery registration result */
- if (ret_sens == SENSOR_RET_NORMAL) {
- ret = POS_RET_NORMAL;
- } else if (ret_sens == SENSOR_RET_ERROR_PARAM) {
- ret = POS_RET_ERROR_PARAM;
- } else if (ret_sens == SENSOR_RET_ERROR_BUFFULL) {
- ret = POS_RET_ERROR_BUFFULL;
- } else if (ret_sens == SENSOR_RET_ERROR_RESOURCE) {
- ret = POS_RET_ERROR_RESOURCE;
- } else {
- ret = POS_RET_ERROR_INNER;
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * Get Lltitude and longitude information
- *
- * Get Lltitude and longitude information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] dat SENSORLOCATION_LONLATINFO_DAT* - Pointer to the acquired latitude/longitude information storage destination
- * @param[in] ucGetMethod uint8_t - Acquisition method(GPS/Navigation/Not specified)
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment<br>
- * POS_RET_ERROR_INNER Internal error
- *
- */
-POS_RET_API POS_GetLonLat(HANDLE hApp, // NOLINT(readability/nolint)
- SENSORLOCATION_LONLATINFO_DAT *dat, // NOLINT(readability/nolint)
- uint8_t ucGetMethod) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- DID did = VEHICLE_DID_LOCATION_LONLAT; /* DID */
- int32_t ret_get_proc; /* POS_GetProc Return Values */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if (hApp == NULL) {
- /* If the handler is NULL, the process terminates with an error. */
- ret = POS_RET_ERROR_PARAM;
- } else if (dat == NULL) {
- /* If the longitude/latitude data is NULL, it ends with an abnormal parameter. */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- if (ucGetMethod == SENSOR_GET_METHOD_GPS) {
- did = VEHICLE_DID_LOCATION_LONLAT;
- } else if ((ucGetMethod == SENSOR_GET_METHOD_NAVI) ||
- (ucGetMethod == SENSOR_GET_METHOD_AUTO)) {
- did = VEHICLE_DID_LOCATION_LONLAT_NAVI;
- } else {
- /* End as a parameter error abnormality except for GPS/unspecified acquisition method */
- ret = POS_RET_ERROR_PARAM;
- }
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = POS_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = POS_RET_ERROR_NOSUPPORT;
- }
- }
-
- /* Sensor information acquisition */
- if (ret == POS_RET_NORMAL) {
- /* Data acquisition process */
- ret_get_proc = PosGetProc(did, reinterpret_cast<void *>(dat), sizeof(SENSORLOCATION_LONLATINFO_DAT));
- if (static_cast<int32_t>(sizeof(SENSORLOCATION_LONLATINFO_DAT)) > ret_get_proc) {
- /* Failed to acquire */
- if (ret_get_proc == POS_RET_ERROR_RESOURCE) {
- /* Insufficient resource */
- ret = POS_RET_ERROR_RESOURCE;
- } else {
- ret = POS_RET_ERROR_INNER;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosGetProc ERROR [ret = %d]", ret);
- }
- }
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * Altitude information acquisition
- *
- * Obtain altitude information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] dat SENSORLOCATION_ALTITUDEINFO_DAT* - Pointer to the acquired altitude information storage destination
- * @param[in] ucGetMethod uint8_t - Acquisition method(GPS/Not specified)
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment<br>
- * POS_RET_ERROR_INNER Internal error
- *
- */
-POS_RET_API POS_GetAltitude(HANDLE hApp, // NOLINT(readability/nolint)
- SENSORLOCATION_ALTITUDEINFO_DAT *dat, // NOLINT(readability/nolint)
- uint8_t ucGetMethod) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- DID did = VEHICLE_DID_LOCATION_ALTITUDE; /* DID */
- int32_t ret_get_proc; /* POS_GetProc Return Values */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if (hApp == NULL) {
- /* If the handler is NULL, the process terminates with an error. */
- ret = POS_RET_ERROR_PARAM;
- } else if (dat == NULL) {
- /* If the altitude data is NULL, it terminates with an abnormal parameter. */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- if ((ucGetMethod == SENSOR_GET_METHOD_GPS) ||
- (ucGetMethod == SENSOR_GET_METHOD_AUTO)) {
- did = VEHICLE_DID_LOCATION_ALTITUDE;
- } else {
- /* End as a parameter error abnormality except for GPS/unspecified acquisition method */
- ret = POS_RET_ERROR_PARAM;
- }
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = POS_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = POS_RET_ERROR_NOSUPPORT;
- }
- }
- /* Sensor information acquisition */
- if (ret == POS_RET_NORMAL) {
- /* Data acquisition process */
- ret_get_proc = PosGetProc(did, reinterpret_cast<void *>(dat), sizeof(SENSORLOCATION_ALTITUDEINFO_DAT));
- if (static_cast<int32_t>(sizeof(SENSORLOCATION_ALTITUDEINFO_DAT)) > ret_get_proc) {
- /* Failed to acquire */
- if (ret_get_proc == POS_RET_ERROR_RESOURCE) {
- /* Insufficient resource */
- ret = POS_RET_ERROR_RESOURCE;
- } else {
- ret = POS_RET_ERROR_INNER;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosGetProc ERROR [ret = %d]", ret);
- }
- }
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * Vehicle Speed Information Acquisition
- *
- * Obtain vehicle speed information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] dat SENSORMOTION_SPEEDINFO_DAT* - Pointer to the acquired car speed information storage destination
- * @param[in] ucGetMethod uint8_t - Acquisition method(GPS/Navigation/Not specified)
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment<br>
- * POS_RET_ERROR_INNER Internal error
- *
- */
-POS_RET_API POS_GetSpeed(HANDLE hApp, // NOLINT(readability/nolint)
- SENSORMOTION_SPEEDINFO_DAT *dat, // NOLINT(readability/nolint)
- uint8_t ucGetMethod) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- DID did; /* Data ID */
- int32_t ret_get_proc; /* POS_GetProc Return Values */
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
- if (hApp == NULL) {
- /* If the handler is NULL, the process terminates with an error. */
- ret = POS_RET_ERROR_PARAM;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Argument ERROR [hApp = %p]", hApp);
- } else if (dat == NULL) {
- /* When the pointer to the vehicle speed data storage destination is NULL, the pointer terminates with an error in the parameter. */
- ret = POS_RET_ERROR_PARAM;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Argument ERROR [dat = %p]", dat);
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- if (ucGetMethod == SENSOR_GET_METHOD_POS) {
- did = VEHICLE_DID_MOTION_SPEED_INTERNAL;
- } else if ((ucGetMethod == SENSOR_GET_METHOD_NAVI) ||
- (ucGetMethod == SENSOR_GET_METHOD_AUTO)) {
- did = VEHICLE_DID_MOTION_SPEED_NAVI;
- } else {
- /* End as a parameter error abnormality except for POS/unspecified acquisition method */
- ret = POS_RET_ERROR_PARAM;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "Argument ERROR [type = %d, ucGetMethod = %d]",
- type, ucGetMethod);
- }
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = POS_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = POS_RET_ERROR_NOSUPPORT;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "GetEnvSupportInfo ERROR [type = %d]", type);
- }
- }
-
- if (ret == POS_RET_NORMAL) {
- /* Data acquisition process */
- ret_get_proc = PosGetProc(did, dat, sizeof(SENSORMOTION_SPEEDINFO_DAT));
- if (static_cast<int32_t>(sizeof(SENSORMOTION_SPEEDINFO_DAT)) > ret_get_proc) {
- /* Failed to acquire */
- if (ret_get_proc == POS_RET_ERROR_RESOURCE) {
- /* Insufficient resource */
- ret = POS_RET_ERROR_RESOURCE;
- } else {
- ret = POS_RET_ERROR_INNER;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosGetProc ERROR [ret = %d]", ret);
- }
- }
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "- [ret = %d]", ret);
-
- return ret;
-}
-
-/**
- * @brief
- * Compass information acquisition
- *
- * Get Bill Direction Information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] dat SENSORMOTION_HEADINGINFO_DAT* - Pointer to the acquired altitude information storage destination
- * @param[in] ucGetMethod uint8_t - Acquisition method(GPS/Navigation/Not specified)
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment<br>
- * POS_RET_ERROR_INNER Internal error
- *
- */
-POS_RET_API POS_GetHeading(HANDLE hApp, // NOLINT(readability/nolint)
- SENSORMOTION_HEADINGINFO_DAT *dat, // NOLINT(readability/nolint)
- uint8_t ucGetMethod) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- DID did = VEHICLE_DID_MOTION_HEADING; /* Data ID */
- int32_t ret_get_proc; /* POS_GetProc Return Values */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if (hApp == NULL) {
- /* If the handler is NULL, the process terminates with an error. */
- ret = POS_RET_ERROR_PARAM;
- } else if (dat == NULL) {
- /* If the longitude/latitude data is NULL, it ends with an abnormal parameter. */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- if (ucGetMethod == SENSOR_GET_METHOD_GPS) {
- did = VEHICLE_DID_MOTION_HEADING;
- } else if ((ucGetMethod == SENSOR_GET_METHOD_NAVI) ||
- (ucGetMethod == SENSOR_GET_METHOD_AUTO)) {
- did = VEHICLE_DID_MOTION_HEADING_NAVI;
- } else {
- /* End as a parameter error abnormality except for GPS/unspecified acquisition method */
- ret = POS_RET_ERROR_PARAM;
- }
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- }
- }
- /* Sensor information acquisition */
- if (ret == POS_RET_NORMAL) {
- /* Data acquisition process */
- ret_get_proc = PosGetProc(did, reinterpret_cast<void *>(dat), sizeof(SENSORMOTION_HEADINGINFO_DAT));
- if (static_cast<int32_t>(sizeof(SENSORMOTION_HEADINGINFO_DAT)) > ret_get_proc) {
- /** Failed to acquire */
- if (ret_get_proc == POS_RET_ERROR_RESOURCE) {
- /** Insufficient resource */
- ret = POS_RET_ERROR_RESOURCE;
- } else {
- ret = POS_RET_ERROR_INNER;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosGetProc ERROR [ret = %d]", ret);
- }
- }
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * Vehicle speed information setting
- *
- * Setting Vehicle Speed Information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] navispped uint16_t - Vehicle speed information[Unit:1.0km/h]
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_SetSpeedInfo(HANDLE hApp, uint16_t navispeed) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- uint16_t speed; /* Vehicle speed */
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if (hApp == NULL) {
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- }
- }
-
- if (ret == POS_RET_NORMAL) {
- /* Adjustment by unit [1.0km/h]->[0.01m/sec] */
- speed = static_cast<uint16_t>(navispeed * 10000 / 360);
- /* Data setting(After setting,Immediate termination) */
- ret = PosSetProc(VEHICLE_DID_MOTION_SPEED_NAVI,
- reinterpret_cast<void *>(&speed), sizeof(uint16_t), FALSE);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * Location information setting
- *
- * Set location information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] posData POS_POSDATA - Pointer to location information
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_INNER Internal error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_SetLocationInfo(HANDLE hApp, POS_POSDATA* pstPosData) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value of this function */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if ((pstPosData == NULL) || (hApp == NULL)) {
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- }
- }
-
- if (ret == POS_RET_NORMAL) {
- /* Data status check */
- if ((0x01 > pstPosData->status) || (0x0F < pstPosData->status)) {
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Parameter range check */
- /* Latitude */
- if ((pstPosData->status & POS_LOC_INFO_LAT) == POS_LOC_INFO_LAT) {
- (void)POS_CHKPARAM32(pstPosData->latitude, -41472000, 41472000);
- }
- /* Longitude */
- if ((pstPosData->status & POS_LOC_INFO_LON) == POS_LOC_INFO_LON) {
- (void)POS_CHKPARAM32(pstPosData->longitude, -82944000, 82944000);
- }
- /* Orientation */
- if ((pstPosData->status & POS_LOC_INFO_HEAD) == POS_LOC_INFO_HEAD) {
- (void)POS_CHKPARAM16(pstPosData->heading, -179, 180);
- }
-
- /* Data setting(After setting,Immediate termination) */
- ret = PosSetProc(VEHICLE_DID_GPS_CUSTOMDATA_NAVI, // == POSHAL_DID_GPS_CUSTOMDATA_NAVI
- reinterpret_cast<void *>(pstPosData), sizeof(POS_POSDATA), FALSE);
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
diff --git a/vehicleservice/positioning/client/src/POS_common_API/Makefile b/vehicleservice/positioning/client/src/POS_common_API/Makefile
deleted file mode 100755
index 4d7a90f..0000000
--- a/vehicleservice/positioning/client/src/POS_common_API/Makefile
+++ /dev/null
@@ -1,47 +0,0 @@
-#
-# @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-######### installed shared library(*.so) #############
-INST_SHLIBS = libPOS_common_API
-
-######### compiled sources #############
-libPOS_common_API_SRCS += Common_API.cpp
-
-######### add include path #############
-CPPFLAGS += -I../../../server/include/common
-CPPFLAGS += -I../../include
-CPPFLAGS += -I../../../server/include/nsfw
-
-######### add compile option #############
-CPPFLAGS += -DLINUX -fPIC
-
-LDFLAGS += -Wl,--no-undefined
-LDFLAGS += -Wl,--no-as-needed
-CPPFLAGS += -Werror=implicit-function-declaration
-CPPFLAGS += -Werror=format-security
-CPPFLAGS += -Wconversion
-CPPFLAGS += -Wint-to-pointer-cast
-CPPFLAGS += -Wpointer-arith
-CPPFLAGS += -Wformat
-
-######### linked library (dynamic) #############
-LDLIBS += -Wl,-Bdynamic -lNS_FrameworkUnified
-LDLIBS += -Wl,-Bdynamic -lPOS_base_API
-LDLIBS += -Wl,-Bdynamic -lvp
-
-######### add library path #############
-LDFLAGS += -shared
-
-include ../../../../vehicle_service.mk
diff --git a/vehicleservice/positioning/client/src/POS_common_API/libPOS_common_API.ver b/vehicleservice/positioning/client/src/POS_common_API/libPOS_common_API.ver
deleted file mode 100755
index afc7f3a..0000000
--- a/vehicleservice/positioning/client/src/POS_common_API/libPOS_common_API.ver
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#
-# libPOS_common_API version script
-#
-{
- global:
- POS_GetAltitude;
- POS_GetHeading;
- POS_GetLonLat;
- POS_GetSpeed;
- POS_RegisterListenerAltitude;
- POS_RegisterListenerHeading;
- POS_RegisterListenerLonLat;
- POS_RegisterListenerSpeed;
- POS_SetLocationInfo;
- POS_SetSpeedInfo;
-
- POS_SetLocationInfoNmea;
- local:
- *;
-};
-
diff --git a/vehicleservice/positioning/client/src/POS_gps_API/Gps_API.cpp b/vehicleservice/positioning/client/src/POS_gps_API/Gps_API.cpp
deleted file mode 100755
index 7395f9d..0000000
--- a/vehicleservice/positioning/client/src/POS_gps_API/Gps_API.cpp
+++ /dev/null
@@ -1,456 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * Gps_API.cpp
- * @brief
- * Module : POSITIONING
- * GPS I/F service functionality
- */
-#include <vehicle_service/positioning_base_library.h>
-#include <vehicle_service/POS_define.h>
-#include <vehicle_service/POS_gps_API.h>
-#include <vehicle_service/POS_common_API.h>
-#include <vehicle_service/POS_sensor_API.h>
-#include "POS_common_private.h"
-#include "POS_private.h"
-#include "Vehicle_API_private.h"
-#include "Gps_API_private.h"
-
-
-/**
- * @brief
- * GPS reset request
- *
- * Request a GPS reset
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] ResName PCSTR - Destination thread name
- * @param[in] mode uint8_t - Reset mode
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_INNER Internal processing error<br>
- * POS_RET_ERROR_BUSY Busy occurrence<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_ReqGPSReset(HANDLE hApp, PCSTR ResName, uint8_t mode) { // NOLINT(readability/nolint)
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- POS_RET_API ret = POS_RET_NORMAL; /* Return value of this function */
- RET_API ret_api = RET_NORMAL; /* API return value */
- POS_RESETINFO snd_msg; /* Reset information */
- EventID event_id; /* Event ID */
- int32_t event_val; /* Event value */
- PNO my_pno; /* Caller PNO */
- PNO rs_pno; /* Destination PNO */
- uint32_t pid; /* Process ID */
- uint32_t tid; /* Thread ID */
- char name[128]; /* Name buffer */
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if ((hApp == NULL) || (ResName == NULL)) {
- ret = POS_RET_ERROR_PARAM;
- } else if (GPS_RST_COLDSTART != mode) {
- /* Parameter error except */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = POS_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = POS_RET_ERROR_NOSUPPORT;
- }
-
- if (ret == POS_RET_NORMAL) {
- /* Resource acquisition */
- if (VehicleGetResource() == TRUE) {
- /* Event Generation */
- rs_pno = _pb_CnvName2Pno(ResName);
- pid = (uint32_t)getpid();
- tid = GetTid();
-
- snprintf(name, sizeof(name), "PR_p%u_t%u", pid, tid);
- my_pno = _pb_CnvName2Pno(name);
- event_id = VehicleCreateEvent(my_pno);
- if (0 != event_id) {
- /* Successful event generation */
- memset(&snd_msg, 0x00, sizeof(POS_RESETINFO));
-
- /* Message creation */
- snd_msg.mode = mode; /* Reset mode */
- snd_msg.snd_pno = my_pno; /* Caller PNo. */
- snd_msg.res_pno = rs_pno; /* Destination PNo. */
-
- /* Message transmission request */
- ret_api = _pb_SndMsg_Ext(POS_THREAD_NAME,
- CID_GPS_REQRESET,
- sizeof(POS_RESETINFO),
- reinterpret_cast<void*>(&snd_msg), 0);
-
- if (RET_NORMAL == ret_api) {
- /* If the data setup process is successful,Wait for a completion event */
- ret_api = _pb_WaitEvent(event_id,
- SAPI_EVWAIT_VAL,
- VEHICLE_RET_ERROR_MIN, VEHICLE_RET_NORMAL, &event_val, INFINITE);
- if (RET_NORMAL != ret_api) {
- /* When not put in event wait state */
- /* Event generation failure */
- ret = POS_RET_ERROR_INNER;
- } else {
- /* Return from Event Wait */
- /* Set event value (processing result) as return value */
- ret = (POS_RET_API)event_val;
- }
- } else {
- /* Message transmission processing failed */
- ret = POS_RET_ERROR_INNER;
- }
- /* Event deletion */
- ret_api = VehicleDeleteEvent(event_id);
- } else {
- /* Event generation failure */
- ret = POS_RET_ERROR_INNER;
- }
- } else {
- /* Insufficient resource */
- ret = POS_RET_ERROR_RESOURCE;
- }
- /* Resource release */
- VehicleReleaseResource();
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * GPS time setting request delivery registration
- *
- * Register delivery of GPS time setting request
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] notifyName PCSTR - Destination thread name
- * @param[in] ucCtrlFlg uint8_t - Delivery control(Delivery registration/Delivery stop/Resume delivery)
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_BUFFULL Buffer-full<br>
- * POS_RET_ERROR_INNER Internal error<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_RegisterListenerGPSTimeSetReq(HANDLE hApp, // NOLINT(readability/nolint)
- PCSTR notifyName, // NOLINT(readability/nolint)
- uint8_t ucCtrlFlg) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value of this function */
- SENSOR_RET_API ret_sens = SENSOR_RET_NORMAL; /* API return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if ((hApp == NULL) || (notifyName == NULL)) {
- ret = POS_RET_ERROR_PARAM;
- } else if (SENSOR_DELIVERY_REGIST != ucCtrlFlg) {
- /* Parameter error other than delivery registration */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = POS_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = POS_RET_ERROR_NOSUPPORT;
- }
- }
-
- /* Delivery registration */
- if (POS_RET_NORMAL == ret) {
- /* Delivery registry SensorAPI calls */
- ret_sens = PosRegisterListenerProc(notifyName, /* Destination thread name */
- VEHICLE_DID_SETTINGTIME, /* Data ID */
- ucCtrlFlg, /* Delivery control */
- VEHICLE_DELIVERY_TIMING_UPDATE); /* Delivery timing */
-
- /* Decision of delivery registration result */
- if (ret_sens == SENSOR_RET_NORMAL) {
- ret = POS_RET_NORMAL;
- } else if (ret_sens == SENSOR_RET_ERROR_PARAM) {
- ret = POS_RET_ERROR_PARAM;
- } else if (ret_sens == SENSOR_RET_ERROR_BUFFULL) {
- ret = POS_RET_ERROR_BUFFULL;
- } else if (ret_sens == SENSOR_RET_ERROR_RESOURCE) {
- ret = POS_RET_ERROR_RESOURCE;
- } else {
- ret = POS_RET_ERROR_INNER;
- }
- }
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * GPS time setting
- *
- * Set the GPS time
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] pstDateTime POS_DATETIME - Pointer to GPS time information
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_INNER Internal error<br>
- * POS_RET_ERROR_TIMEOUT Timeout error<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_SetGPStime(HANDLE hApp, POS_DATETIME* pstDateTime) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value of this function */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if ((pstDateTime == NULL) || (hApp == NULL)) {
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = POS_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = POS_RET_ERROR_NOSUPPORT;
- }
- }
-
- if (ret == POS_RET_NORMAL) {
- /* Parameter range check */
- /* Month */
- if (POS_RET_ERROR == POS_CHKPARAMU8(pstDateTime->month, 1, 12)) {
- return POS_RET_ERROR_PARAM;
- }
- /* Day */
- if (POS_RET_ERROR == POS_CHKPARAMU8(pstDateTime->date, 1, 31)) {
- return POS_RET_ERROR_PARAM;
- }
- /* Hour */
- if (POS_RET_ERROR == POS_CHKPARAMU8(pstDateTime->hour, 0, 23)) {
- return POS_RET_ERROR_PARAM;
- }
- /* Minutes */
- if (POS_RET_ERROR == POS_CHKPARAMU8(pstDateTime->minute, 0, 59)) {
- return POS_RET_ERROR_PARAM;
- }
- /* Second */
- if (POS_RET_ERROR == POS_CHKPARAMU8(pstDateTime->second, 0, 59)) {
- return POS_RET_ERROR_PARAM;
- }
-
- /* Data setting(Immediate recovery)*/
- ret = PosSetProc(VEHICLE_DID_SETTINGTIME,
- reinterpret_cast<void*>(pstDateTime), sizeof(POS_DATETIME), FALSE);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * GPS Time Delivery Registration
- *
- * Registering GPS time delivery
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] nofifyName PCSTR - Destination thread name
- * @param[in] ucCtrlFlg uint8_t - Delivery control(Delivery registration/Delivery stop/Resume delivery)
- * @param[in] ucDeliveryTiming uint8_t - Delivery timing(Changing/Updating)
- *
- * @return SENSOR_RET_NORMAL Successful registration<br>
- * SENSOR_RET_ERROR_CREATE_EVENT Event generation failure<br>
- * SENSOR_RET_ERROR_PARAM Parameter error<br>
- * SENSOR_RET_ERROR_BUFFULL FULL of delivery registers<br>
- * SENSOR_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-SENSOR_RET_API POS_RegisterListenerGPStime(HANDLE hApp, // NOLINT(readability/nolint)
- PCSTR notifyName, // NOLINT(readability/nolint)
- uint8_t ucCtrlFlg, // NOLINT(readability/nolint)
- uint8_t ucDeliveryTiming) { // NOLINT(readability/nolint)
- SENSOR_RET_API ret = SENSOR_RET_NORMAL;
- UNIT_TYPE type = UNIT_TYPE_NONE;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- if (hApp == NULL) {
- /* Parameter error */
- ret = SENSOR_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = SENSOR_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- } else {
- /* fail */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- }
- }
-
- if (SENSOR_RET_NORMAL == ret) {
- if (notifyName == NULL) {
- /* Parameter error */
- ret = SENSOR_RET_ERROR_PARAM;
- }
- if (ucCtrlFlg != SENSOR_DELIVERY_REGIST) {
- /* Parameter error */
- ret = SENSOR_RET_ERROR_PARAM;
- }
- if ((ucDeliveryTiming != SENSOR_DELIVERY_TIMING_CHANGE) &&
- (ucDeliveryTiming != SENSOR_DELIVERY_TIMING_UPDATE)) {
- /* Parameter error */
- ret = SENSOR_RET_ERROR_PARAM;
- }
- }
-
- if (SENSOR_RET_NORMAL == ret) {
- /* Delivery registration process */
- ret = PosRegisterListenerProc(notifyName, VEHICLE_DID_GPS_TIME, ucCtrlFlg, ucDeliveryTiming);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "- [ret = %d]", ret);
- return ret;
-}
-
-/**
- * @brief
- * Get GPS time
- *
- * Get the GPS time
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] *dat SENSOR_GPSTIME - Pointer to GPS time information
- *
- * @return POS_RET_NORMAL Normal completion(Include illegal)<br>
- * POS_RET_ERROR_INNER Internal error<br>
- * POS_RET_ERROR_PARAM Parameter error<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_GetGPStime(HANDLE hApp, SENSOR_GPSTIME* dat) { // NOLINT(readability/nolint)
- POS_RET_API ret = POS_RET_NORMAL; /* Return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- DID did = VEHICLE_DID_GPS_TIME; /* DID */
- int32_t ret_get_proc; /* POS_GetProc Return Values */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* Arguments & Support Configuration Check */
- if (hApp == NULL) {
- /* If the handler is NULL, the process terminates with an error. */
- ret = POS_RET_ERROR_PARAM;
- } else if (dat == NULL) {
- /* If the longitude/latitude data is NULL, it ends with an abnormal parameter. */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- ret = POS_RET_NORMAL;
- } else {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = POS_RET_ERROR_NOSUPPORT;
- }
- }
-
- /* Sensor information acquisition */
- if (ret == POS_RET_NORMAL) {
- /* Data acquisition process */
- ret_get_proc = PosGetProc(did, reinterpret_cast<void*>(dat), sizeof(SENSOR_GPSTIME));
- if (static_cast<int32_t>(sizeof(SENSOR_GPSTIME)) > ret_get_proc) {
- /* Failed to acquire */
- if (ret_get_proc == POS_RET_ERROR_RESOURCE) {
- /* Insufficient resource */
- ret = POS_RET_ERROR_RESOURCE;
- } else {
- ret = POS_RET_ERROR_INNER;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosGetProc ERROR [ret = %d]", ret);
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "- [ret = %d]", ret);
-
- return ret;
-}
diff --git a/vehicleservice/positioning/client/src/POS_gps_API/Makefile b/vehicleservice/positioning/client/src/POS_gps_API/Makefile
deleted file mode 100755
index c6391a9..0000000
--- a/vehicleservice/positioning/client/src/POS_gps_API/Makefile
+++ /dev/null
@@ -1,51 +0,0 @@
-#
-# @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-######### installed shared library(*.so) #############
-INST_SHLIBS = libPOS_gps_API
-
-######### compiled sources #############
-libPOS_gps_API_SRCS += Gps_API.cpp
-libPOS_gps_API_SRCS += Naviinfo_API.cpp
-
-######### add include path #############
-CPPFLAGS += -I../../../server/include/common
-CPPFLAGS += -I../../include
-CPPFLAGS += -I../../../server/include/nsfw
-
-CPPFLAGS += -I../Vehicle_API
-CPPFLAGS += -I../Vehicle_API/common
-
-######### add compile option #############
-CPPFLAGS += -DLINUX -fPIC
-
-LDFLAGS += -Wl,--no-undefined
-LDFLAGS += -Wl,--no-as-needed
-CPPFLAGS += -Werror=implicit-function-declaration
-CPPFLAGS += -Werror=format-security
-CPPFLAGS += -Wconversion
-CPPFLAGS += -Wint-to-pointer-cast
-CPPFLAGS += -Wpointer-arith
-CPPFLAGS += -Wformat
-
-######### linked library (dynamic) #############
-LDLIBS += -Wl,-Bdynamic -lNS_FrameworkUnified
-LDLIBS += -Wl,-Bdynamic -lPOS_base_API
-LDLIBS += -Wl,-Bdynamic -lvp
-
-######### add library path #############
-LDFLAGS += -shared
-
-include ../../../../vehicle_service.mk
diff --git a/vehicleservice/positioning/client/src/POS_gps_API/Naviinfo_API.cpp b/vehicleservice/positioning/client/src/POS_gps_API/Naviinfo_API.cpp
deleted file mode 100755
index cfe04ff..0000000
--- a/vehicleservice/positioning/client/src/POS_gps_API/Naviinfo_API.cpp
+++ /dev/null
@@ -1,404 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/******************************************************************************
-@file Naviinfo_API.cpp
-@detail Naviinfo_API Functions
-@lib libNaviinfo_API.so
-******************************************************************************/
-
-/*****************************************************************************
- * Include *
- *****************************************************************************/
-#include "Naviinfo_API.h"
-#include <vehicle_service/POS_define.h>
-#include <vehicle_service/POS_sensor_API.h>
-#include <vehicle_service/POS_gps_API.h>
-#include "Vehicle_API_Dummy.h"
-#include "POS_private.h"
-#include <native_service/frameworkunified_types.h> // NOLINT(build/include_order)
-
-void PosCnvGpsInfo(NAVIINFO_ALL *navi_loc_info);
-
-
-/**
- * @brief
- * GPS information setting
- *
- * Set GPS information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] navilocinfo NAVIINFO_ALL* - Pointer to GPS information storage area
- *
- * @return NAVIINFO_RET_NORMAL Normal completion<br>
- * NAVIINFO_RET_ERROR_PARAM Parameter error<br>
- * NAVIINFO_RET_ERROR_INNER Internal error<br>
- * NAVIINFO_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-NAVIINFO_RET_API POS_SetGPSInfo(HANDLE hApp, NAVIINFO_ALL *navilocinfo)
-{
- NAVIINFO_RET_API ret = NAVIINFO_RET_NORMAL; /* Return value of this function */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- NAVIINFO_ALL navi_loc_info_tmp; /* Conversion quantity area */
- RET_API ret_api;
-
- /** NULL checking */
- if (navilocinfo == NULL) {
- /** Parameter error */
- ret = NAVIINFO_RET_ERROR_PARAM;
- } else if (hApp == NULL) {
- /** Parameter error */
- ret = NAVIINFO_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = NAVIINFO_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = NAVIINFO_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = NAVIINFO_RET_ERROR_NOSUPPORT;
- }
- }
-
- if (ret == NAVIINFO_RET_NORMAL) {
- /* Parameter range check */
- if (navilocinfo->stNaviGps.tdsts != 0) { /* Other than ""Time not calibrated after receiver reset"" */
- /* Positioning status information */
- if (POS_RET_ERROR == POS_CHKPARAMU8(navilocinfo->stDiagGps.stFix.ucFixSts, 0, 2)) {
- return NAVIINFO_RET_ERROR_PARAM;
- }
- /* Latitude */
- if (POS_RET_ERROR == POS_CHKPARAM32(navilocinfo->stDiagGps.stFix.stWgs84.lLat, -82944000, 82944000)) {
- return NAVIINFO_RET_ERROR_PARAM;
- }
- /* Longitude */
- if (POS_RET_ERROR == POS_CHKPARAM32(navilocinfo->stDiagGps.stFix.stWgs84.lLon, -165888000, 165888000)) {
- return NAVIINFO_RET_ERROR_PARAM;
- }
- /* Measurement Azimuth */
- if (POS_RET_ERROR == POS_CHKPARAMU16(navilocinfo->stNaviGps.heading, 0, 3599)) {
- return NAVIINFO_RET_ERROR_PARAM;
- }
- /* UTC(Month) */
- if (POS_RET_ERROR == POS_CHKPARAMU8(navilocinfo->stNaviGps.utc.month, 1, 12)) {
- return NAVIINFO_RET_ERROR_PARAM;
- }
- /* UTC(Day) */
- if (POS_RET_ERROR == POS_CHKPARAMU8(navilocinfo->stNaviGps.utc.date, 1, 31)) {
- return NAVIINFO_RET_ERROR_PARAM;
- }
- /* UTC(Hour) */
- if (POS_RET_ERROR == POS_CHKPARAMU8(navilocinfo->stNaviGps.utc.hour, 0, 23)) {
- return NAVIINFO_RET_ERROR_PARAM;
- }
- /* UTC(Minutes) */
- if (POS_RET_ERROR == POS_CHKPARAMU8(navilocinfo->stNaviGps.utc.minute, 0, 59)) {
- return NAVIINFO_RET_ERROR_PARAM;
- }
- /* UTC(Second) */
- if (POS_RET_ERROR == POS_CHKPARAMU8(navilocinfo->stNaviGps.utc.second, 0, 59)) {
- return NAVIINFO_RET_ERROR_PARAM;
- }
- }
- /* Date and Time Status */
- if (POS_RET_ERROR == POS_CHKPARAMU8(navilocinfo->stNaviGps.tdsts, 0, 2)) {
- return NAVIINFO_RET_ERROR_PARAM;
- }
-
- /* Copy to conversion area */
- memcpy(&navi_loc_info_tmp, navilocinfo, sizeof(NAVIINFO_ALL));
- /** Data unit conversion */
- PosCnvGpsInfo(&navi_loc_info_tmp);
-
- /* Resource acquisition */
- if (VehicleGetResource() == TRUE) {
-
- /** Send navigation information to vehicle sensor */
- ret_api = _pb_SndMsg_Ext(POS_THREAD_NAME,
- CID_NAVIINFO_DELIVER,
- sizeof(NAVIINFO_ALL),
- reinterpret_cast<void*>(&navi_loc_info_tmp), 0);
- if (ret_api != RET_NORMAL) {
- /** Message transmission failure */
- ret = NAVIINFO_RET_ERROR_INNER;
- }
- } else {
- /* When resource shortage occurs, the system terminates with an insufficient resource error. */
- ret = NAVIINFO_RET_ERROR_RESOURCE;
- }
- /* Resource release */
- VehicleReleaseResource();
- }
-
- return ret;
-}
-
-/**
- * @brief
- * GPS information acquisition
- *
- * Access GPS information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] navidiaginfo NAVIINFO_DIAG_GPS* - Pointer to GPS information storage area
- *
- * @return NAVIINFO_RET_NORMAL Normal completion<br>
- * NAVIINFO_RET_ERROR_PARAM Parameter error<br>
- * NAVIINFO_RET_ERROR_INNER Internal error<br>
- * NAVIINFO_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-NAVIINFO_RET_API POS_GetGPSInfo(HANDLE hApp, NAVIINFO_DIAG_GPS *navidiaginfo)
-{
- NAVIINFO_RET_API ret = NAVIINFO_RET_NORMAL; /* Return value of this function */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- int32_t ret_veh; /* VehicleAPI Return Values */
- NAVIINFO_DIAG_GPS dest_data; /* Data acquisition area */
-
- /** NULL checking */
- if (navidiaginfo == NULL) {
- /** Parameter error */
- ret = NAVIINFO_RET_ERROR_PARAM;
- } else if (hApp == NULL) {
- /** Parameter error */
- ret = NAVIINFO_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = NAVIINFO_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = NAVIINFO_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = NAVIINFO_RET_ERROR_NOSUPPORT;
- }
- }
-
- if (ret == NAVIINFO_RET_NORMAL) {
- /** Acquisition of navigation data for Diag provide */
- ret_veh = PosGetProc(
- (DID)VEHICLE_DID_NAVIINFO_DIAG_GPS,
- reinterpret_cast<void*>(&dest_data),
- (u_int16)sizeof(dest_data));
-
- if (static_cast<int32_t>(sizeof(NAVIINFO_DIAG_GPS)) > ret_veh) {
- /** Failed to acquire */
- if (ret_veh == POS_RET_ERROR_RESOURCE) {
- ret = NAVIINFO_RET_ERROR_RESOURCE;
- } else {
- ret = NAVIINFO_RET_ERROR_INNER;
- }
- } else {
- /** Successful acquisition */
- memcpy( navidiaginfo, &dest_data, sizeof(NAVIINFO_DIAG_GPS));
- }
- }
-
- return ret;
-}
-
-/* ++ GPS _CWORD82_ support */
-/**
- * @brief
- * GPS setting transmission request
- *
- * Requesting GPS Settings with Complete Return
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] p_data SENSOR_MSG_SEND_DAT* - GPS setting information to be sent
- *
- * @return SENSOR_RET_NORMAL Normal completion<br>
- * SENSOR_RET_ERROR_CREATE_EVENT Event generation failure<br>
- * SENSOR_RET_ERROR_PARAM Parameter error<br>
- * SENSOR_RET_ERROR_DID Unregistered DID<br>
- * SENSOR_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-int32 POS_ReqGPSSetting(HANDLE hApp, SENSOR_MSG_SEND_DAT *p_data) { /* Ignore->MISRA-C++:2008 Rule 7-1-2 */
- SENSOR_RET_API ret = SENSOR_RET_NORMAL; /* Return value */
- RET_API ret_api; /* System API return value */
- uint16_t expected_size; /* Message size for the specified DID */
-
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
-
- if (hApp == NULL) {
- /* Parameter error */
- ret = SENSOR_RET_ERROR_PARAM;
- }
-
- if (ret == SENSOR_RET_NORMAL) {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Argument check (DID) + Size calculation */
- if (p_data != reinterpret_cast<SENSOR_MSG_SEND_DAT*>(NULL)) {
- switch (p_data->did) {
- case VEHICLE_DID_GPS__CWORD82__SETINITIAL:
- {
- expected_size = 71;
- break;
- }
- case VEHICLE_DID_GPS__CWORD82__SETRMODE:
- {
- expected_size = 50;
- break;
- }
- case VEHICLE_DID_GPS__CWORD82__SETRMODEEX:
- {
- expected_size = 63;
- break;
- }
- case VEHICLE_DID_GPS__CWORD82__SELSENT:
- {
- expected_size = 21;
- break;
- }
- case VEHICLE_DID_GPS__CWORD82__SETSBAS:
- {
- expected_size = 34;
- break;
- }
- case VEHICLE_DID_GPS__CWORD82__SETCONF1:
- {
- expected_size = 37;
- break;
- }
- case VEHICLE_DID_GPS__CWORD82__SETCONF2:
- {
- expected_size = 45;
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- ret = SENSOR_RET_ERROR_DID;
- break;
- }
- } else {
- ret = SENSOR_RET_ERROR_PARAM;
- }
- }
-
- /* Supported HW Configuration Check */
- if (ret == SENSOR_RET_NORMAL) {
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = SENSOR_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- }
- }
-
- if (ret == SENSOR_RET_NORMAL) {
- /* Argument check (Size)*/
- if (expected_size != p_data->usSize) {
- ret = SENSOR_RET_ERROR_PARAM;
- } else {
- /* Message buffer initialization */
-
- /* Create message data */
-
- /* Resource acquisition */
- if (VehicleGetResource() == TRUE) {
- /* External Process Transmission and Reception Messages */
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__,
- "POSITIONING: POS_ReqGPSSetting() --> cid = %d",
- CID_SENSORIF__CWORD82__REQUEST);
- ret_api = _pb_SndMsg_Ext(POS_THREAD_NAME,
- CID_SENSORIF__CWORD82__REQUEST,
- sizeof(SENSOR_MSG_SEND_DAT),
- reinterpret_cast<void *>(p_data), 0);
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__, "POSITIONING: POS_ReqGPSSetting() <--");
-
- if (ret_api != RET_NORMAL) {
- ret = SENSOR_RET_ERROR_CREATE_EVENT;
- }
- } else {
- /* When resource shortage occurs, the system terminates with an insufficient resource error. */
- ret = SENSOR_RET_ERROR_RESOURCE;
- }
- /* Resource release */
- VehicleReleaseResource();
- }
- }
-
- return ret;
-}
-/* -- GPS _CWORD82_ support */
-
-/**
- * @brief
- * GPS information conversion process
- *
- * Convert GPS information to a format to be provided to the vehicle sensor
- *
- * @param[in] none
- * @param[in] navi_loc_info NAVIINFO_ALL* - GPS information pointer
- *
- * @return none
- */
-void PosCnvGpsInfo(NAVIINFO_ALL *navi_loc_info) {
- int32_t altitude;
- int64_t tmp;
- uint16_t heading;
-
- /* Unit conversion of fix altitude[1m]->[0.01m] */
- tmp = (int64_t)((int64_t)(navi_loc_info->stNaviGps.altitude) * 100);
- if (tmp > static_cast<int32_t>(0x7FFFFFFF)) {
- /* +Overflow of digits */
- altitude = static_cast<int32_t>(0x7FFFFFFF);
- } else if (tmp < static_cast<int32_t>(0x80000000)) { /* Ignore->MISRA-C:2004 Rule 3.1 */
- /* -Overflow of digits */
- altitude = static_cast<int32_t>(0x80000000); /* Ignore->MISRA-C:2004 Rule 3.1 */
- } else {
- altitude = static_cast<int32_t>(tmp);
- }
- navi_loc_info->stNaviGps.altitude = altitude;
-
- /* Measurement Azimuth Conversion[0.Once]->[0.01 degree] */
- heading = navi_loc_info->stNaviGps.heading;
- heading = static_cast<uint16_t>(heading - ((heading / 3600) * 3600));
- heading = static_cast<uint16_t>(heading * 10);
- navi_loc_info->stNaviGps.heading = heading;
-
- return;
-}
diff --git a/vehicleservice/positioning/client/src/POS_gps_API/libPOS_gps_API.ver b/vehicleservice/positioning/client/src/POS_gps_API/libPOS_gps_API.ver
deleted file mode 100755
index 038c99e..0000000
--- a/vehicleservice/positioning/client/src/POS_gps_API/libPOS_gps_API.ver
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#
-# libPOS_gps_API version script
-#
-{
- global:
- POS_GetGPSInfo;
- POS_GetGPSVersion;
- POS_RegisterListenerGPSTimeSetReq;
- POS_RegisterListenerGPStime;
- POS_ReqGPSReset;
- POS_ReqGPSSetting;
- POS_SetGPSInfo;
- POS_SetGPStime;
- POS_GetGPStime;
- local:
- *;
-};
-
diff --git a/vehicleservice/positioning/client/src/POS_sensor_API/Makefile b/vehicleservice/positioning/client/src/POS_sensor_API/Makefile
deleted file mode 100755
index a4f627f..0000000
--- a/vehicleservice/positioning/client/src/POS_sensor_API/Makefile
+++ /dev/null
@@ -1,48 +0,0 @@
-#
-# @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-######### installed shared library(*.so) #############
-INST_SHLIBS = libPOS_sensor_API
-
-######### compiled sources #############
-libPOS_sensor_API_SRCS += Sensor_API.cpp
-libPOS_sensor_API_SRCS += Vehicle_API.cpp
-
-######### add include path #############
-CPPFLAGS += -I../../../server/include/common
-CPPFLAGS += -I../../include
-CPPFLAGS += -I../../../server/include/nsfw
-
-######### add compile option #############
-CPPFLAGS += -DLINUX -fPIC
-
-LDFLAGS += -Wl,--no-undefined
-LDFLAGS += -Wl,--no-as-needed
-CPPFLAGS += -Werror=implicit-function-declaration
-CPPFLAGS += -Werror=format-security
-CPPFLAGS += -Wconversion
-CPPFLAGS += -Wint-to-pointer-cast
-CPPFLAGS += -Wpointer-arith
-CPPFLAGS += -Wformat
-
-######### linked library (dynamic) #############
-LDLIBS += -Wl,-Bdynamic -lNS_FrameworkUnified
-LDLIBS += -Wl,-Bdynamic -lPOS_base_API
-LDLIBS += -Wl,-Bdynamic -lvp
-######### add library path #############
-LDFLAGS += -shared
-
-
-include ../../../../vehicle_service.mk
diff --git a/vehicleservice/positioning/client/src/POS_sensor_API/Sensor_API.cpp b/vehicleservice/positioning/client/src/POS_sensor_API/Sensor_API.cpp
deleted file mode 100755
index 179eb92..0000000
--- a/vehicleservice/positioning/client/src/POS_sensor_API/Sensor_API.cpp
+++ /dev/null
@@ -1,784 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :Sensor_API.cpp
- * System name :GPF
- * Subsystem name :Sensor I/F library
- * Program name :SensorI/F API
- ******************************************************************************/
-
-#include <stdio.h>
-#include <vehicle_service/POS_sensor_API.h>
-#include <vehicle_service/POS_define.h>
-#include <vehicle_service/POS_sensor_API.h>
-#include <vehicle_service/positioning_base_library.h>
-#include "POS_sensor_private.h"
-#include "Sensor_Common_API.h"
-#include "Sensor_API_private.h"
-#include "Sensor_Common_API.h"
-#include "Vehicle_API_Dummy.h"
-#include "Vehicle_API_private.h"
-#include "Naviinfo_API.h"
-#include "POS_private.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-/********************************************************************************
- * TAG :TG_GPS_REQ_RESET
- * ABSTRACT :GPS reset request
- * NOTE :I/F information between host applications(Reset mode)
- ********************************************************************************/
-/**
- * @brief POS_RegisterListenerPkgSensData Return code list
- */
-static const SENSOR_RET_PKG g_ret_list_reg_lis_pkg_sens_data[SENSOR_PUBLIC_DID_NUM] = {
- /* GRADE2 GRADE1 DID (Key) */
- {TRUE, TRUE, POS_DID_SPEED_PULSE },
- {FALSE, TRUE, POS_DID_SPEED_KMPH },
- {TRUE, TRUE, POS_DID_GYRO_X },
- {TRUE, TRUE, POS_DID_GYRO_Y },
- {TRUE, TRUE, POS_DID_GYRO_Z },
- {TRUE, TRUE, POS_DID_GSNS_X },
- {TRUE, TRUE, POS_DID_GSNS_Y },
- {TRUE, TRUE, POS_DID_GSNS_Z },
- {FALSE, TRUE, POS_DID_GPS_ANTENNA },
- {TRUE, TRUE, POS_DID_SNS_COUNTER },
- {FALSE, TRUE, POS_DID_SPEED_PULSE_FST },
- {FALSE, TRUE, POS_DID_GYRO_X_FST },
- {FALSE, TRUE, POS_DID_GYRO_Y_FST },
- {FALSE, TRUE, POS_DID_GYRO_Z_FST },
- {FALSE, TRUE, POS_DID_GPS__CWORD82__NMEA },
- {FALSE, TRUE, POS_DID_GPS__CWORD82___CWORD44_GP4 },
- {FALSE, TRUE, POS_DID_GPS__CWORD82__FULLBINARY },
- {FALSE, TRUE, POS_DID_GPS_NMEA },
- {TRUE, TRUE, POS_DID_REV },
- {FALSE, TRUE, POS_DID_REV_FST },
- {TRUE, TRUE, POS_DID_GYRO_TEMP },
- {FALSE, TRUE, POS_DID_GYRO_TEMP_FST },
- {FALSE, TRUE, POS_DID_GSNS_X_FST },
- {FALSE, TRUE, POS_DID_GSNS_Y_FST },
- {FALSE, TRUE, POS_DID_GSNS_Z_FST },
- {TRUE, TRUE, POS_DID_PULSE_TIME },
- {FALSE, TRUE, POS_DID_GPS_CLOCK_DRIFT },
- {FALSE, TRUE, POS_DID_GPS_CLOCK_FREQ },
- {FALSE, TRUE, VEHICLE_DID_GPS_TIME }, /* For local use */
- {FALSE, TRUE, VEHICLE_DID_GPS_TIME_RAW }, /* For local use */
- {FALSE, TRUE, VEHICLE_DID_GPS_WKNROLLOVER} /* For local use */
-};
-
-/**
- * @brief POS_RegisterListenerSensData Return code list
- */
-static const SENSOR_RET_PKG g_ret_list_reg_lis_sens_data[SENSOR_PUBLIC_DID_NUM] = {
- /* GRADE2 GRADE1 DID (Key) */
- {TRUE, TRUE, POS_DID_SPEED_PULSE },
- {FALSE, TRUE, POS_DID_SPEED_KMPH },
- {TRUE, TRUE, POS_DID_GYRO_X },
- {TRUE, TRUE, POS_DID_GYRO_Y },
- {TRUE, TRUE, POS_DID_GYRO_Z },
- {TRUE, TRUE, POS_DID_GSNS_X },
- {TRUE, TRUE, POS_DID_GSNS_Y },
- {TRUE, TRUE, POS_DID_GSNS_Z },
- {TRUE, TRUE, POS_DID_GPS_ANTENNA },
- {FALSE, TRUE, POS_DID_SNS_COUNTER },
- {TRUE, TRUE, POS_DID_SPEED_PULSE_FST },
- {TRUE, TRUE, POS_DID_GYRO_X_FST },
- {TRUE, TRUE, POS_DID_GYRO_Y_FST },
- {TRUE, TRUE, POS_DID_GYRO_Z_FST },
- {TRUE, TRUE, POS_DID_GPS__CWORD82__NMEA },
- {FALSE, TRUE, POS_DID_GPS__CWORD82___CWORD44_GP4 },
- {TRUE, TRUE, POS_DID_GPS__CWORD82__FULLBINARY },
- {FALSE, TRUE, POS_DID_GPS_NMEA },
- {FALSE, TRUE, POS_DID_REV },
- {TRUE, TRUE, POS_DID_REV_FST },
- {TRUE, TRUE, POS_DID_GYRO_TEMP },
- {TRUE, TRUE, POS_DID_GYRO_TEMP_FST },
- {TRUE, TRUE, POS_DID_GSNS_X_FST },
- {TRUE, TRUE, POS_DID_GSNS_Y_FST },
- {TRUE, TRUE, POS_DID_GSNS_Z_FST },
- {FALSE, TRUE, POS_DID_PULSE_TIME },
- {FALSE, TRUE, POS_DID_GPS_CLOCK_DRIFT },
- {FALSE, TRUE, POS_DID_GPS_CLOCK_FREQ },
- {FALSE, TRUE, VEHICLE_DID_GPS_TIME }, /* For local use */
- {FALSE, TRUE, VEHICLE_DID_GPS_TIME_RAW }, /* For local use */
- {FALSE, TRUE, VEHICLE_DID_GPS_WKNROLLOVER } /* For local use */
-};
-
-/**
- * @brief POS_GetSensData Return code list
- */
-static const SENSOR_RET_PKG g_ret_list_get_sens_data[SENSOR_PUBLIC_DID_NUM] = {
- /* GRADE2 GRADE1 DID (Key) */
- {TRUE, TRUE, POS_DID_SPEED_PULSE },
- {FALSE, TRUE, POS_DID_SPEED_KMPH },
- {TRUE, TRUE, POS_DID_GYRO_X },
- {TRUE, TRUE, POS_DID_GYRO_Y },
- {TRUE, TRUE, POS_DID_GYRO_Z },
- {TRUE, TRUE, POS_DID_GSNS_X },
- {TRUE, TRUE, POS_DID_GSNS_Y },
- {TRUE, TRUE, POS_DID_GSNS_Z },
- {TRUE, TRUE, POS_DID_GPS_ANTENNA },
- {FALSE, TRUE, POS_DID_SNS_COUNTER },
- {FALSE, TRUE, POS_DID_SPEED_PULSE_FST },
- {FALSE, TRUE, POS_DID_GYRO_X_FST },
- {FALSE, TRUE, POS_DID_GYRO_Y_FST },
- {FALSE, TRUE, POS_DID_GYRO_Z_FST },
- {TRUE, TRUE, POS_DID_GPS__CWORD82__NMEA },
- {FALSE, TRUE, POS_DID_GPS__CWORD82___CWORD44_GP4 },
- {TRUE, TRUE, POS_DID_GPS__CWORD82__FULLBINARY },
- {FALSE, TRUE, POS_DID_GPS_NMEA },
- {FALSE, TRUE, POS_DID_REV },
- {FALSE, TRUE, POS_DID_REV_FST },
- {TRUE, TRUE, POS_DID_GYRO_TEMP },
- {FALSE, TRUE, POS_DID_GYRO_TEMP_FST },
- {FALSE, TRUE, POS_DID_GSNS_X_FST },
- {FALSE, TRUE, POS_DID_GSNS_Y_FST },
- {FALSE, TRUE, POS_DID_GSNS_Z_FST },
- {FALSE, TRUE, POS_DID_PULSE_TIME },
- {FALSE, TRUE, POS_DID_GPS_CLOCK_DRIFT },
- {FALSE, TRUE, POS_DID_GPS_CLOCK_FREQ },
- {FALSE, TRUE, VEHICLE_DID_GPS_TIME }, /* For local use */
- {FALSE, TRUE, VEHICLE_DID_GPS_TIME_RAW }, /* For local use */
- {FALSE, TRUE, VEHICLE_DID_GPS_WKNROLLOVER } /* For local use */
-};
-
-/**
- * @brief
- * DID-decision functions for Sensor API
- *
- * Determines whether or not the DID specified by the public API corresponds to the DID.
- *
- * @param[in] did Data ID
- * @param[in] mode Operation mode 1:For Package Delivery Registration API<br>
- * 2:For Sensor Data Delivery Registration API<br>
- * 3:For Sensor Data Acquisition API
- *
- * @return TRUE Be supported
- * FALSE Not supported
- */
-BOOL SensorJudgeDid(DID did, uint8_t mode) {
- BOOL ret = FALSE;
- UNIT_TYPE type;
- const SENSOR_RET_PKG *pkg_list = NULL;
- int32_t i;
-
- /* Set Return pakage list */
- switch (mode) {
- case MODE_REGISTER_LISTENER_PKG_SENS_DATA: /* POS_RegisterListenerPkgSensData */
- {
- pkg_list = g_ret_list_reg_lis_pkg_sens_data;
- break;
- }
- case MODE_REGISTER_LISTENER_SENSDATA: /* POS_RegisterListenerSensData */
- {
- pkg_list = g_ret_list_reg_lis_sens_data;
- break;
- }
- case MODE_GET_SENSDATA: /* POS_GetSensData */
- {
- pkg_list = g_ret_list_get_sens_data;
- break;
- }
- default:
- /* Error log */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Argument ERROR [mode = %d]", mode);
- break;
- }
-
- if (pkg_list != NULL) {
- /* Search Return code list for DID */
- for (i = 0; i < SENSOR_PUBLIC_DID_NUM; i++) {
- if (did == pkg_list[i].did) {
- break;
- }
- }
-
- if (i != SENSOR_PUBLIC_DID_NUM) {
- /* Get Unit type */
- type = GetEnvSupportInfo();
- switch (type) {
- case UNIT_TYPE_GRADE1:
- {
- ret = pkg_list[i].GRADE1_ret;
- break;
- }
- case UNIT_TYPE_GRADE2:
- {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = pkg_list[i].GRADE2_ret;
- break;
- }
- default:
- /* Error log */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "GetEnvSupportInfo ERROR [type = %d]", type);
- break;
- }
- } else {
- /* Error log */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Argument ERROR [did = %d]", did);
- }
- }
-
- return ret;
-}
-
-/**
- * @brief
- * Vehicle Sensor Information Extended Package Delivery Registration
- * Sensor information is delivered for the first time.,Extension Packaging and Registering for Delivery.
- *
- * @param[in] hApp Application handle
- * @param[in] notifyName Destination thread name
- * @param[in] ucPkgNum Number of package data(1 to 16)
- * @param[in] *pulDid Pointer to an array of data IDs for vehicle information
- * @param[in] ucCtrlFlg Delivery control<br>
- * Delivery registration: SENSOR_DELIVERY_REGIST<br>
- * Delivery stop: SENSOR_DELIVERY_STOP (Note: Not mounted)<br>
- * Resume delivery: SENSOR_DELIVERY_RESTART (Note: Not mounted)
- * @param[in] ucDeliveryTiming Delivery timing<br>
- * Updating : SENSOR_DELIVERY_TIMING_UPDATE<br>
- * Changing : SENSOR_DELIVERY_TIMING_CHANGE
- *
- * @return SENSOR_RET_NORMAL Successful registration<br>
- * SENSOR_RET_ERROR_CREATE_EVENT Event generation failure<br>
- * SENSOR_RET_ERROR_PARAM Parameter error<br>
- * SENSOR_RET_ERROR_DID Unregistered ID<br>
- * SENSOR_RET_ERROR_BUFFULL FULL of delivery registers<br>
- * SENSOR_RET_ERROR_NOSUPPORT Unsupported environment<br>
- * SENSOR_RET_ERROR_INNER Internal abnormality
- *
- */
-SENSOR_RET_API POS_RegisterListenerPkgSensData(HANDLE hApp,
- PCSTR notifyName,
- uint8_t ucPkgNum,
- DID *pulDid, uint8_t ucCtrlFlg, uint8_t ucDeliveryTiming) {
- SENSOR_RET_API ret; /* Return value */
- BOOL ret_b;
- RET_API ret_api; /* System API return value */
- EventID event_id; /* Event ID */
- int32_t event_val; /* Event value */
- SENSOR_MSG_DELIVERY_ENTRY_DAT data; /* Message data */
- int32_t i; /* Generic counters */
- PNO ch_pno; /* Converted internal PNO */
- UNIT_TYPE type; /* Supported HW Configuration Type */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- ret = SENSOR_RET_NORMAL;
- /* Check Handle */
- if (hApp == NULL) {
- /* NULL terminates with an abnormal parameter */
- ret = SENSOR_RET_ERROR_PARAM;
- }
-
- if (ret == SENSOR_RET_NORMAL) {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = SENSOR_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- }
- }
-
- if (ret == SENSOR_RET_NORMAL) {
- /* Check Delivery Control Designation */
- if (SENSOR_DELIVERY_REGIST != ucCtrlFlg) {
- /* Parameters other than delivery registration terminated abnormally. */
- ret = SENSOR_RET_ERROR_PARAM;
- } else if ((ucDeliveryTiming != SENSOR_DELIVERY_TIMING_CHANGE) &&
- (ucDeliveryTiming != SENSOR_DELIVERY_TIMING_UPDATE)) {
- /* Check delivery timing */
- /* Change delivery timing,Terminate as a parameter error except update */
- ret = SENSOR_RET_ERROR_PARAM;
- } else if (notifyName == NULL) {
- /* Check Thread Name */
- /* NULL terminates with an abnormal parameter */
- ret = SENSOR_RET_ERROR_PARAM;
- } else if ((0 == ucPkgNum) || (SENSOR_PKG_DELIVERY_MAX < ucPkgNum)) {
- /* Check Package Data Count */
- /* Out-of-range is terminated as a parameter error. */
- ret = SENSOR_RET_ERROR_PARAM;
- } else if (pulDid == NULL) {
- /* Check Data ID */
- /* NULL terminates with an abnormal parameter */
- ret = SENSOR_RET_ERROR_PARAM;
- } else {
- /* Check if data ID is acceptable */
- for (i = 0; i < ucPkgNum; i++) {
- /* Judge DID */
- ret_b = SENSOR_DID_JUDGE_REGLIS_PKG(pulDid[i]);
- if (ret_b == FALSE) {
- /* An unacceptable ID terminates with an abnormal parameter. */
- ret = SENSOR_RET_ERROR_PARAM;
- break;
- } else {
- ret = SENSOR_RET_NORMAL;
- }
- }
- }
- }
-
- if (ret == SENSOR_RET_NORMAL) {
- /* Resource acquisition */
- if (VehicleGetResource() == TRUE) {
-
- /* Initialization */
- event_id = 0;
- event_val = 0;
- memset(reinterpret_cast<void *>(&data), 0, sizeof(SENSOR_MSG_DELIVERY_ENTRY_DAT));
-
- /* Get PNO from Thread Name */
- ch_pno = _pb_CnvName2Pno(notifyName);
-
- /* Event Generation */
- event_id = PosCreateEvent(ch_pno);
-
- if (0 != event_id) {
- /* Successful event generation */
-
- /*--------------------------------------------------------------*
- * Send Vehicle Sensor Information Delivery Registration Message *
- *--------------------------------------------------------------*/
- /* Create Message Data */
- data.pno = ch_pno;
- data.pkg_num = ucPkgNum;
- data.delivery_timing = ucDeliveryTiming;
- data.ctrl_flg = ucCtrlFlg;
- data.event_id = event_id;
- for (i = 0; i < ucPkgNum; i++) {
- data.did[i] = pulDid[i];
- }
-
- /* Messaging */
- ret_api = PosSndMsg(ch_pno,
- PNO_VEHICLE_SENSOR,
- CID_SENSORIF_PKG_DELIVERY_ENTRY_EXT,
- (uint16_t)sizeof(SENSOR_MSG_DELIVERY_ENTRY_DAT),
- (const void *)&data);
-
- if (RET_NORMAL == ret_api) {
- /* Message transmission processing is successful */
- /* Wait for completion event from vehicle sensor thread */
- ret_api = _pb_WaitEvent(event_id,
- SAPI_EVWAIT_VAL,
- SENSOR_RET_ERROR_MIN,
- SENSOR_RET_NORMAL,
- &event_val,
- POS_API_TIME_OUT_MS);
- if (RET_NORMAL != ret_api) {
- /* Return an internal error */
- ret = SENSOR_RET_ERROR_INNER;
- } else {
- /* Return from Event Wait */
- /* Set event value (processing result) as return value */
- ret = (SENSOR_RET_API)event_val;
- }
- } else {
- /* Message transmission processing failed */
- /* Return an internal error */
- ret = SENSOR_RET_ERROR_INNER;
- }
-
- /* Event deletion */
- ret_api = PosDeleteEvent(event_id);
- } else {
- /* Event generation failure */
- ret = SENSOR_RET_ERROR_CREATE_EVENT;
- }
- } else {
- /* When resource shortage occurs, the system terminates with an insufficient resource error. */
- ret = SENSOR_RET_ERROR_RESOURCE;
- }
- /* Resource release */
- VehicleReleaseResource();
- }
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "- [ret = %d]", ret);
-
- return ret;
-}
-
-/*******************************************************************************
- * MODULE : PosCreateEvent
- * ABSTRACT : Event creation process
- * FUNCTION : Generate an event
- * ARGUMENT : pno : Thread ID
- * NOTE :
- * RETURN : Non-zero : Event ID
- * : Zero : Event generation failure
- ******************************************************************************/
-EventID PosCreateEvent(PNO pno) {
- EventID event_id; /* Event ID */
- char event_name[32]; /* Event name character string buffer */
- RET_API ret_api; /* System API return value */
-
- /* Initialization of event name character string buffer */
- (void)memset(reinterpret_cast<void *>(event_name), 0, sizeof(event_name));
-
- /* Event name creation */
- snprintf(event_name, sizeof(event_name), "SENSOR_%X", pno); /* Ignore->MISRA-C++:2008 Rule 5-2-12 */
-
- /* Event Generation */
- event_id = _pb_CreateEvent(FALSE , 0, event_name); /* Ignore->MISRA-C++:2008 Rule 5-2-12 */
-
- if (0 != event_id) {
- /* For successful event generation */
-
- /* Initialize the event */
- ret_api = _pb_SetEvent(event_id, SAPI_EVSET_ABSOLUTE, SENSOR_EVENT_VAL_INIT);
- if (RET_NORMAL != ret_api) {
- /* Event initialization failed */
-
- /* Delete Event and Return Event Generation Failed */
- ret_api = PosDeleteEvent(event_id);
- event_id = 0;
- }
- }
-
- return event_id;
-}
-
-/*******************************************************************************
- * MODULE : PosDeleteEvent
- * ABSTRACT : Event deletion processing
- * FUNCTION : Delete events
- * ARGUMENT : event_id : Event ID of the event to delete
- * NOTE :
- * RETURN : RET_NORMAL : Normal completion
- * : RET_EV_NONE : Specified event does not exist
- ******************************************************************************/
-RET_API PosDeleteEvent(EventID event_id) {
- return(_pb_DeleteEvent(event_id));
-}
-
-/*******************************************************************************
- * MODULE : SensorLinkShareData
- * ABSTRACT : Link to shared memory
- * FUNCTION : Link to shared memory
- * ARGUMENT : **share_top : Storage destination of shared memory top address
- * : *share_size : Storage destination of shared memory area size
- * : *offset : Offset storage destination to free shared memory area
- * NOTE :
- * RETURN : RET_NORMAL : Normal completion
- * : RET_ERROR : There is no shared memory area.
- ******************************************************************************/
-RET_API SensorLinkShareData(void **share_top, uint32_t *share_size, uint16_t *offset) { // LCOV_EXCL_START 8:dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API ret_api; /* System API return value */
- SemID sem_id; /* Semaphore ID */
- SENSOR_SHARE *share_top_tmp;
- int32_t i;
-
- /* Initialization */
- ret_api = RET_ERROR;
-
- /* Create Semaphore */
- sem_id = _pb_CreateSemaphore(const_cast<char *>(SENSOR_SEMAPHO_NAME));
- if (0 != sem_id) {
- /* Semaphore Lock */
- ret_api = _pb_SemLock(sem_id);
- if (RET_NORMAL == ret_api) {
- /* Link to shared memory */
- ret_api = _pb_LinkShareData(const_cast<char *>(SENSOR_SHARE_NAME), share_top, share_size);
- if (RET_NORMAL == ret_api) {
- /* By searching the free shared memory area,Offset is calculated if there is free space. */
- share_top_tmp = reinterpret_cast<SENSOR_SHARE *>(*share_top);
-
- /* Because the first block of the shared memory area is the control area,Loop from i = 1 */
- for (i = 1; i < SENSOR_SHARE_BLOCK_NUM; i++) {
- if (SENSOR_SHARE_UNLOCK == share_top_tmp->mng.lock_info[i]) {
- break;
- }
- }
- if (i < SENSOR_SHARE_BLOCK_NUM) {
- /* Empty space */
- /* Lock the block */
- share_top_tmp->mng.lock_info[i] = SENSOR_SHARE_LOCK;
-
- /* Calculate the offset to the block */
- *offset = static_cast<uint16_t>(i * SENSOR_SHARE_BLOCK_SIZE);
-
- /* Normal completion */
- ret_api = RET_NORMAL;
- } else {
- /* No free space */
- ret_api = RET_ERROR;
- }
- } else {
- /* Failed link to shared memory */
- ret_api = RET_ERROR;
- }
- /* Semaphore unlock */
- _pb_SemUnlock(sem_id);
- } else {
- /* Semaphore lock failed */
- ret_api = RET_ERROR;
- }
- } else {
- /* Semaphore creation failed */
- ret_api = RET_ERROR;
- }
-
- return ret_api;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
- * MODULE : SensorUnLinkShareData
- * ABSTRACT : Unlinking shared memory
- * FUNCTION : Unlink shared memory
- * ARGUMENT : *share_top : Start address of shared memory
- * : offset : Offset to shared memory free area
- * NOTE :
- * RETURN : RET_NORMAL : Normal completion
- * : RET_ERROR : There is no shared memory area./semaphore error
- ******************************************************************************/
-RET_API SensorUnLinkShareData(SENSOR_SHARE *share_top, uint16_t offset) { // LCOV_EXCL_START 8:dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API ret_api; /* System API return value */
- SemID sem_id; /* Semaphore ID */
- int32_t i;
-
- /* Initialization */
- ret_api = RET_ERROR;
-
- /* Create Semaphore */
- sem_id = _pb_CreateSemaphore(const_cast<char *>(SENSOR_SEMAPHO_NAME));
- if (0 != sem_id) {
- /* Semaphore Lock */
- ret_api = _pb_SemLock(sem_id);
- if (RET_NORMAL == ret_api) {
- /* Unlock the block */
- i = static_cast<int32>(offset) / SENSOR_SHARE_BLOCK_SIZE;
- share_top->mng.lock_info[i] = SENSOR_SHARE_UNLOCK;
-
- /* Semaphore unlock */
- _pb_SemUnlock(sem_id);
-
- /* Normal completion */
- ret_api = RET_NORMAL;
- } else {
- /* Semaphore lock failed */
- ret_api = RET_ERROR;
- }
- } else {
- /* Semaphore creation failed */
- ret_api = RET_ERROR;
- }
-
- return ret_api;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
- * MODULE : SensorSetShareData
- * ABSTRACT : Write processing to shared memory
- * FUNCTION : Write shared memory
- * ARGUMENT : *share_top : Start address of shared memory
- * : offset : Offsets to shared memory write destination
- * : *data_src :
- : size_src :
- * NOTE :
- * RETURN : void
- ******************************************************************************/
-void SensorSetShareData(void *share_top, uint16_t offset, const void *data_src, uint16_t size_src) { // LCOV_EXCL_START 8:dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- SENSOR_SHARE_BLOCK_DAT *share_dat;
-
- /* Calculate Shared Memory Write Address */
- share_dat = reinterpret_cast<SENSOR_SHARE_BLOCK_DAT *>(reinterpret_cast<uint8_t *>(share_top) + offset);
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
-
- /* Clear Shared Memory */
- memset(reinterpret_cast<void *>(share_dat), 0, sizeof(SENSOR_SHARE_BLOCK_DAT));
-
- /* Set write size to shared memory */
- share_dat->size = size_src;
-
- /* Set specified data in shared memory */
- memcpy(reinterpret_cast<void *>(&share_dat->data), data_src, (size_t)size_src);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
- * MODULE : PosSndMsg
- * ABSTRACT : Message transmission processing
- * FUNCTION : Send a message to the specified PNO
- * ARGUMENT : pno_src : Source PNO
- * : pno_dest : Destination PNO
- * : cid : Command ID
- * : msg_len : Message data body length
- * : *msg_len : Pointer to message data
- * NOTE :
- * RETURN : RET_NORMAL : Normal completion
- * : RET_ERRNOTRDY : Destination process is not wakeup
- * : RET_ERRMSGFULL : Message queue overflows
- * : RET_ERRPARAM : Buffer size error
- ******************************************************************************/
-RET_API PosSndMsg(PNO pno_src, PNO pno_dest, CID cid, uint16_t msg_len, const void *msg_data) {
- SENSOR_INTERNAL_MSG_BUF msg_buf; /* message buffer */
- T_APIMSG_MSGBUF_HEADER *msg_hdr; /* Pointer to the message header */
- RET_API ret_api; /* Return value */
- PCSTR thread_name; /* Destination thread name */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* _CWORD71_ processing speed(Memset modification) */
- /* Initializing the header of the message buffer */
- memset(reinterpret_cast<void *>(&msg_buf.hdr), 0, sizeof(T_APIMSG_MSGBUF_HEADER));
-
- /* Get pointer to send buffer */
- msg_hdr = reinterpret_cast<T_APIMSG_MSGBUF_HEADER *>(reinterpret_cast<void *>(&msg_buf));
-
- /*--------------------------------------------------------------*
- * Create message headers *
- *--------------------------------------------------------------*/
- msg_hdr->hdr.sndpno = pno_src; /* Source PNO */
- msg_hdr->hdr.cid = cid; /* Command ID */
- msg_hdr->hdr.msgbodysize = msg_len; /* Message data body length */
-
- /*--------------------------------------------------------------*
- * Create message data *
- *--------------------------------------------------------------*/
- if ((0 != msg_data) && (0 != msg_len)) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Set the message data */
- memcpy(reinterpret_cast<void *>(msg_buf.data), msg_data, (size_t)msg_len);
- }
- /*--------------------------------------------------------------*
- * Send messages *
- *--------------------------------------------------------------*/
- /* Get Thread Name from PNO */
- if (pno_dest <= SYS_PNO_MAX) {
- thread_name = POS_THREAD_NAME;
- } else {
- thread_name = _pb_CnvPno2Name(pno_dest);
- }
-
- if ((pno_dest <= SYS_PNO_MAX) && (pno_src <= SYS_PNO_MAX)) {
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "[LOG pno_dest = 0x%x]", pno_dest);
-
- /* Internal Process Transmission and Reception Messages */
- ret_api = _pb_SndMsg(pno_dest,
- (uint16_t)(sizeof(T_APIMSG_MSGBUF_HEADER) + msg_len),/* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- reinterpret_cast<void *>(&msg_buf), 0);
- } else {
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__,
- "[LOG thread_name = %s, cid = 0x%x]", thread_name, cid);
-
- /* External Process Transmission and Reception Messages */
- ret_api = _pb_SndMsg_Ext(thread_name,
- cid,
- (uint16_t)(msg_len), /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- reinterpret_cast<void *>(&(msg_buf.data)), 0);
- }
- /* If RET_ERROR,Register a dialog if called from a Vehicle related thread */ /* Task_30332 */
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "[ERROR]");
- }
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "- [ret = %d]", ret_api);
-
- return ret_api;
-}
-
-/**
- * @brief
- * Sensor information acquisition
- *
- * Obtain sensor information
- *
- * @param[in] hApp HANDLE - Application handle
- * @param[in] did DID - Data ID for vehicle information
- * @param[in] dest_data void* - Pointer representing the storage destination of vehicle sensor information
- * @param[in] dest_size uint16_t - Storage destination size of vehicle sensor information(byte)
- *
- * @return 0 or more Stored data size(Include illegal)<br>
- * POS_RET_ERROR_CREATE_EVENT Event generation failure<br>
- * POS_RET_ERROR_OUTOF_MEMORY Shared memory allocation failed<br>
- * POS_RET_ERROR_SIZE Storage destination size error<br>
- * POS_RET_ERROR_DID Unregistered ID<br>
- * POS_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-POS_RET_API POS_GetSensData(HANDLE hApp, DID did, void *dest_data, uint16_t dest_size)
-{
- POS_RET_API ret; /* Return value */
- UNIT_TYPE type = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- BOOL ret_b;
-
- /** NULL checking */
- if ((hApp == NULL) || (dest_data == NULL)) {
- /** Parameter error */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = POS_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = POS_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = POS_RET_ERROR_NOSUPPORT;
- }
- }
-
- if (ret == NAVIINFO_RET_NORMAL) {
- /* Judge DID*/
- ret_b = SENSOR_DID_JUDGE_GET(did);
- if (ret_b == FALSE) {
- /* An unacceptable ID is regarded as a parameter error. */
- ret = POS_RET_ERROR_PARAM;
- } else {
- /* Data acquisition process */
- ret = PosGetProc(did, dest_data, dest_size);
- }
- }
-
- return ret;
-}
diff --git a/vehicleservice/positioning/client/src/POS_sensor_API/Vehicle_API.cpp b/vehicleservice/positioning/client/src/POS_sensor_API/Vehicle_API.cpp
deleted file mode 100755
index 3cd97f8..0000000
--- a/vehicleservice/positioning/client/src/POS_sensor_API/Vehicle_API.cpp
+++ /dev/null
@@ -1,292 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :Vehicle_API.cpp
- * System name :GPF
- * Subsystem name :Vehicle I/F library
- * Program name :Vehicle I/F API
- * Module configuration :POS_RegisterListenerSensData() Vehicle sensor information delivery registration
- ******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include <stdio.h>
-#include <vehicle_service/POS_sensor_API.h>
-#include "Sensor_API_private.h"
-#include "Vehicle_API_Dummy.h"
-#include "Vehicle_API_private.h"
-#include "POS_private.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
- * initialize
-******************************************************************************/
-VEHICLE_RET_API VehicleInitialize(u_int32 (*sighand)()) { // LCOV_EXCL_START 8:dead code // NOLINT(readability/nolint)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API _CWORD64_api_ret;
- VEHICLE_RET_API ret;
-
- _CWORD64_api_ret = _pb_Setup_CWORD64_API(NULL);
-
- if (_CWORD64_api_ret == RET_NORMAL) {
- ret = RET_NORMAL;
- } else {
- ret = RET_ERROR;
- }
- return ret;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Vehicle sensor information delivery registration
- * Register delivery of vehicle sensor information
- *
- * @param[in] hApp Application handle
- * @param[in] notifyName Destination thread name
- * @param[in] ulDid Pointer to an array of data IDs for vehicle information
- * @param[in] ucCtrlFlg Delivery control<br>
- * Delivery registration: SENSOR_DELIVERY_REGIST<br>
- * Delivery stop: SENSOR_DELIVERY_STOP (Note: Not mounted)<br>
- * Resume delivery: SENSOR_DELIVERY_RESTART (Note: Not mounted)
- * @param[in] ucDeliveryTiming Delivery timing<br>
- * Updating : SENSOR_DELIVERY_TIMING_UPDATE<br>
- * Changing : SENSOR_DELIVERY_TIMING_CHANGE
- *
- * @return SENSOR_RET_NORMAL Successful registration<br>
- * SENSOR_RET_ERROR_CREATE_EVENT Event generation failure<br>
- * SENSOR_RET_ERROR_PARAM Parameter error<br>
- * SENSOR_RET_ERROR_DID Unregistered ID<br>
- * SENSOR_RET_ERROR_BUFFULL FULL of delivery registers<br>
- * SENSOR_RET_ERROR_NOSUPPORT Unsupported environment
- *
- */
-SENSOR_RET_API POS_RegisterListenerSensData(HANDLE hApp,
- PCSTR notifyName, DID ulDid, u_int8 ucCtrlFlg, u_int8 ucDeliveryTiming) {
- SENSOR_RET_API ret; /* Return value */
- UNIT_TYPE type; /* Supported HW Configuration Type */
- BOOL ret_b;
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- /* Check Delivery Control Designation */
- ret = SENSOR_RET_NORMAL;
- /* Arguments & Support Configuration Check */
- if ((ucDeliveryTiming != SENSOR_DELIVERY_TIMING_CHANGE) &&
- (ucDeliveryTiming != SENSOR_DELIVERY_TIMING_UPDATE)) {
- /* Change delivery timing,Terminate as a parameter error except update */
- ret = SENSOR_RET_ERROR_PARAM;
- } else if (SENSOR_DELIVERY_REGIST != ucCtrlFlg) {
- /* Parameters other than delivery registration terminated abnormally. */
- ret = SENSOR_RET_ERROR_PARAM;
- } else if (hApp == NULL) {
- /* Check Handle */
- /* NULL terminates with an abnormal parameter */
- ret = SENSOR_RET_ERROR_PARAM;
- } else if (notifyName == NULL) {
- /* Check Thread Name */
- /* NULL terminates with an abnormal parameter */
- ret = SENSOR_RET_ERROR_PARAM;
- } else {
- /* Positioning Base API initialization */
- _pb_Setup_CWORD64_API(hApp);
-
- /* Supported HW Configuration Check */
- type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == type) {
- /* GRADE1 */
- ret = SENSOR_RET_NORMAL;
- } else if (UNIT_TYPE_GRADE2 == type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- } else {
- /* Environment error */
- ret = SENSOR_RET_ERROR_NOSUPPORT;
- }
- }
-
- if (SENSOR_RET_NORMAL == ret) {
- /* Judge DID */
- ret_b = SENSOR_DID_JUDGE_REGLIS(ulDid);
- if (ret_b == FALSE) {
- /* An unacceptable ID is regarded as a parameter error. */
- ret = SENSOR_RET_ERROR_PARAM;
- } else {
- /* Delivery registration process */
- ret = PosRegisterListenerProc(notifyName, ulDid, ucCtrlFlg, ucDeliveryTiming);
- }
- }
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "- [ret = %d]", ret);
-
- return ret;
-}
-
-/*******************************************************************************
- * MODULE : PosSetShareData
- * ABSTRACT : Write processing to shared memory
- * FUNCTION : Write shared memory
- * ARGUMENT : *share_top : Start address of shared memory
- * : offset : Offsets to shared memory write destination
- * : *data_src : Data
- * : size_src : Size
- * NOTE :
- * RETURN : void
- ******************************************************************************/
-void PosSetShareData(void *share_top, u_int16 offset, const void *data_src, u_int16 size_src) {
- VEHICLE_SHARE_BLOCK_DAT *share_dat;
- /* Calculate Shared Memory Write Address */
- share_dat = reinterpret_cast<VEHICLE_SHARE_BLOCK_DAT *>(reinterpret_cast<u_int8 *>(share_top) + offset);
-
- /* _CWORD71_ processing speed(Memset modification) */
- /* Clear Shared Memory(Unused area) */
- share_dat->reserve[0] = 0;
- share_dat->reserve[1] = 0;
-
- /* Set write size to shared memory */
- share_dat->size = size_src;
-
- /* Set specified data in shared memory */
- memcpy(reinterpret_cast<void *>(share_dat->data), data_src, (size_t)size_src);
-}
-
-/*******************************************************************************
-* MODULE : VehicleGetDrData
-* ABSTRACT : DR information acquisition
-* FUNCTION : Retrieves DR information (optional data) by returning to completion.
-* ARGUMENT : pno : Thread ID
-* : did : Data ID for DR information
-* : *dest_data : Pointer to the storage destination of DR information
-* : dest_size : Storage destination size of DR information(byte)
-* NOTE :
-* RETURN : Zero or more : Stored data size
-* : VEHICLE_RET_ERROR_CREATE_EVENT : Event generation failure
-* : VEHICLE_RET_ERROR_OUTOF_MEMORY : Shared memory allocation failed
-* : VEHICLE_RET_ERROR_SIZE : Storage destination size error
-* : VEHICLE_RET_ERROR_DID : Unregistered ID
-******************************************************************************/
-int32 VehicleGetDrData(PNO pno, DID did, void *dest_data, u_int16 dest_size) { // LCOV_EXCL_START 8:dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VEHICLE_RET_API ret; /* Return value */
- RET_API ret_api; /* System API return value */
- EventID event_id; /* Event ID */
- int32 event_val; /* Event value */
- void *share_top; /* Start address of shared memory */
- u_int32 share_size; /* Size of shared memory area */
- u_int16 offset; /* Offset to free shared memory area */
- VEHICLE_SHARE_BLOCK_DAT *share_dat; /* Address of free shared memory area */
- VEHICLE_MSG_GET_VEHICLE_DATA_DAT data; /* Message data */
-
- /* Initialization */
- event_id = 0;
- event_val = 0;
- memset(reinterpret_cast<void *>(&data), 0, sizeof(VEHICLE_MSG_GET_VEHICLE_DATA_DAT));
-
- /* Event Generation */
- event_id = VehicleCreateEvent(pno);
-
- if (0 != event_id) {
- /* Successful event generation */
- /* Allocate shared memory */
- ret_api = VehicleLinkShareData(reinterpret_cast<void **>(&share_top), &share_size, &offset);
- if (RET_NORMAL != ret_api) {
- /* Failed to allocate shared memory */
- ret = VEHICLE_RET_ERROR_OUTOF_MEMORY;
- } else {
- /* When the shared memory is allocated successfully */
-
- /* Calculate start address of free shared memory area */
- share_dat = reinterpret_cast<VEHICLE_SHARE_BLOCK_DAT *>(reinterpret_cast<u_int8 *>(share_top) + offset);
-
- /* Send vehicle sensor information acquisition message */
- data.did = did;
- data.pno = pno;
- data.offset = offset;
- data.size = VEHICLE_SHARE_BLOCK_DSIZE;
- data.event_id = event_id;
- /* Messaging */
-
- ret_api = VehicleSndMsg(pno,
- PNO_VEHICLE_SENSOR,
- CID_VEHICLEIF_GET_DR_DATA,
- sizeof(VEHICLE_MSG_GET_VEHICLE_DATA_DAT),
- (const void *)&data);
-
- if (RET_NORMAL == ret_api) {
- /* Message transmission processing is successful */
- /* Wait for completion event from vehicle sensor thread */
- ret_api = _pb_WaitEvent(event_id,
- SAPI_EVWAIT_VAL,
- VEHICLE_RET_ERROR_MIN, VEHICLE_RET_NORMAL, &event_val, INFINITE);
- if (RET_NORMAL != ret_api) {
- /* When not put in event wait state */
- /* Return an event generation failure */
- ret = VEHICLE_RET_ERROR_CREATE_EVENT;
- } else {
- /* Return from Event Wait */
-
- /* Link to shared memory */
- ret_api = _pb_LinkShareData(const_cast<char *>(VEHICLE_SHARE_NAME), &share_top, &share_size);
-
- /* Calculate the address of the shared memory storage area. */
- share_dat = reinterpret_cast<VEHICLE_SHARE_BLOCK_DAT *>(reinterpret_cast<u_int8 *>(share_top)
- + offset);
-
- if (event_val < 0) {
- /* Vehicle sensor information acquisition failure */
- ret = (VEHICLE_RET_API)event_val;
- } else if (RET_NORMAL != ret_api) {
- /* Shared memory error */
- ret = VEHICLE_RET_ERROR_OUTOF_MEMORY;
- } else if (dest_size < share_dat->size) {
- /* Storage destination size error */
- ret = VEHICLE_RET_ERROR_SIZE;
- } else {
- /* Vehicle sensor information acquisition success */
-
- /* Copy from shared memory to user memory */
- memcpy(dest_data, share_dat->data, (size_t)share_dat->size);
-
- /* Set Write Size to Return Value */
- ret = static_cast<int32>(share_dat->size);
- }
- }
- } else {
- /* Message transmission processing failed */
- /* Return an event generation failure */
- ret = VEHICLE_RET_ERROR_CREATE_EVENT;
- }
- /* Free shared memory */
- (void)VehicleUnLinkShareData(reinterpret_cast<VEHICLE_SHARE*>(share_top), offset);
- }
-
- /* Event deletion */
- ret_api = VehicleDeleteEvent(event_id);
-
- } else {
- /* Event generation failure */
- ret = VEHICLE_RET_ERROR_CREATE_EVENT;
- }
- return ret;
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/client/src/POS_sensor_API/libPOS_sensor_API.ver b/vehicleservice/positioning/client/src/POS_sensor_API/libPOS_sensor_API.ver
deleted file mode 100755
index 10fd95b..0000000
--- a/vehicleservice/positioning/client/src/POS_sensor_API/libPOS_sensor_API.ver
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#
-# libPOS_sensor_API version script
-#
-{
- global:
- POS_GetSensData;
- POS_RegisterListenerPkgSensData;
- POS_RegisterListenerSensData;
- *PosSndMsg*;
- *PosCreateEvent*;
- *PosDeleteEvent*;
- *PosSetShareData*;
- local:
- *;
-};
-
diff --git a/vehicleservice/positioning/server/Makefile b/vehicleservice/positioning/server/Makefile
deleted file mode 100755
index 6ef1082..0000000
--- a/vehicleservice/positioning/server/Makefile
+++ /dev/null
@@ -1,22 +0,0 @@
-#
-# @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-######### subdirectories #########
-SUBDIRS += src/Sensor
-SUBDIRS += src/ServiceInterface
-SUBDIRS += src/nsfw
-
-include ../../vehicle_service.mk
diff --git a/vehicleservice/positioning/server/include/Sensor/ClockDataMng.h b/vehicleservice/positioning/server/include/Sensor/ClockDataMng.h
deleted file mode 100755
index 69a96c2..0000000
--- a/vehicleservice/positioning/server/include/Sensor/ClockDataMng.h
+++ /dev/null
@@ -1,100 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/******************************************************************************
- * File name : ClockDataMng.h
- * System name : PastModel002
- * Subsystem name : Time-related processing
- ******************************************************************************/
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKDATAMNG_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKDATAMNG_H_
-
-#include <vehicle_service/positioning_base_library.h>
-
-
-#include "positioning_hal.h"
-#include "CanInput_API.h"
-#include "Sensor_API.h"
-
-/********************************************************************************
-* Macro definitions *
-*********************************************************************************/
-#define CLOCKDATAMNG_SECONDS_PAR_WEEK (7 * 24 * 60 * 60)
-#define CLOCKDATAMNG_CNV_WEEK2SEC(WEEK) ((WEEK)* CLOCKDATAMNG_SECONDS_PAR_WEEK)
-
-/* [PastModel002 Specifications]Time difference tolerance(plus or minus 512 week or less,GPS TIME range from 0 to 1023 week) */
-#define CLOCKDATAMNG_TIME_DIFF_LIMIT_UPPER (512 * CLOCKDATAMNG_SECONDS_PAR_WEEK)
-#define CLOCKDATAMNG_TIME_DIFF_LIMIT_LOWER (-512 * CLOCKDATAMNG_SECONDS_PAR_WEEK)
-
-/* [PastModel002 Specifications]Time difference addition value(+1024week,GPS TIME range from 0 to 1023 week) */
-#define CLOCKDATAMNG_TIME_DIFF_ADD_VALUE (CLOCKDATAMNG_TIME_DIFF_LIMIT_UPPER * 2)
-
-/* [PastModel002 Specifications]GPS TIME weekNo scope */
-#define CLOCKDATAMNG_GPS_TIME_WEEKNO_LIMIT 1024
-
-/* [PastModel002 Specifications]Initial value of time difference information at the previous shutdown */
-#define CLOCKDATAMNG_TIME_DIFF_INIT_VALUE 0x7FFFFFFFL
-
-/* [PastModel002 Specifications]AID-INI lifetime(+4Time) */
-#define CLOCKDATAMNG_AID_INI_EFFECTIVE_TIME (4 * 60 * 60)
-
-/* [PastModel002 Specifications]AID-EPH lifetime(plus or minus 2 hours) */
-#define CLOCKDATAMNG_AID_EPH_EFFECTIVE_TIME (2 * 60 * 60)
-
-#define MUTEX_CLOCKDATAMNG __TEXT("MUTEX_VEHICLE_CLOCKDATAMNG")
-
-/********************************************************************************
-* Struct definitions *
-*********************************************************************************/
-/********************************************************************************
- * TAG :CLOCKDATAMNG_GPS_TIME
- * ABSTRACT :GPS time structure
- * NOTE :
- ********************************************************************************/
-typedef struct {
- u_int32 tow; /* Time of week (msec) */
- int16 week_no; /* GPS Week No. */
- u_int8 reserve[2]; /* reserve */
- BOOL validity_flag; /* Enabled/DisabledFlagging */
-} CLOCKDATAMNG_GPS_TIME;
-
-/********************************************************************************
-* Function prototype *
-*********************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
- BOOL ClockDataMngInitialize(void);
- void ClockDataMngSetLastTimeDiff(int32 time_diff);
-
- void ClockDataMngSetGpsTime(const SENSOR_MSG_GPSDATA_DAT *gps_time_data);
- void ClockDataMngGetGpsTime(CLOCKDATAMNG_GPS_TIME *gps_time_data);
-
- BOOL ClockDataMngGetLocalTime(const CANINPUT_MSG_LOCALTIMEINFO_DAT *can_local_time, LOCALTIME *vehicle_local_time);
- BOOL ClockDataMngGetTimeDiff(LOCALTIME *local_time, int32 *time_diff);
-
- void ClockDataMngGetStartupTime(CLOCKDATAMNG_GPS_TIME *start_up_time);
- int32 ClockDataMngCalculateTimeDiff(int32 munuend, int32 subtrahend);
-
- BOOL ClockDataMngCheckLocalTime(LOCALTIME *local_time);
- int32 ClockDataMngConversionLocalTime2GpsTime(LOCALTIME *local_time, BOOL calc_second_available);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKDATAMNG_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/ClockGPS_Process_Proto.h b/vehicleservice/positioning/server/include/Sensor/ClockGPS_Process_Proto.h
deleted file mode 100755
index 5f20c33..0000000
--- a/vehicleservice/positioning/server/include/Sensor/ClockGPS_Process_Proto.h
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * FILE : ClockGPS_Process_Proto.h
- * SYSTEM : _CWORD107_
- * SUBSYSTEM: ClockGPS thread
- * TITLE : Header for publication in a process (EXL)
- ******************************************************************************/
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKGPS_PROCESS_PROTO_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKGPS_PROCESS_PROTO_H_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-EFrameworkunifiedStatus ClockGPSThread(HANDLE h_app);
-int TimerSramInit(int); /* Baackup data check/initialization function */ /* Ignore->MISRA-C++:2008 Rule 3-9-2 */
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKGPS_PROCESS_PROTO_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/ClockUtility.h b/vehicleservice/positioning/server/include/Sensor/ClockUtility.h
deleted file mode 100755
index 8924975..0000000
--- a/vehicleservice/positioning/server/include/Sensor/ClockUtility.h
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*************************************************************************
-@file ClockUtility.h
-@detail Common processing function header file concerning clock
-*****************************************************************************/
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKUTILITY_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKUTILITY_H_
-
-#include <vehicle_service/positioning_base_library.h>
-#include "Clock_API.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
- /*
- Function prototype declaration
- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-
- RET_API ClockUtilityConvertDateToSecond(const LPSYSTEMTIME lp_st, u_int32* uli_sec);
- RET_API ClockUtilityConvertSecondToDate(const u_int32* uli_sec, LPSYSTEMTIME lp_st);
-
- /* Converting TimeData Types to SYSTEMTIME Types Functions */
- CLOCK_RETURN ClockApiConvertTimeDataToSYSTEMTIME(const TimeData* base_time,
- SYSTEMTIME* result_time);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKUTILITY_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/ClockUtility_private.h b/vehicleservice/positioning/server/include/Sensor/ClockUtility_private.h
deleted file mode 100755
index 8c322ae..0000000
--- a/vehicleservice/positioning/server/include/Sensor/ClockUtility_private.h
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*************************************************************************
-@file ClockUtility_private.h
-@detail Common processing function private header file concerning clock
-*****************************************************************************/
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKUTILITY_PRIVATE_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKUTILITY_PRIVATE_H_
-
-#include "CommonDefine.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
- /*
- Macro definitions
- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-#define MONTH_MAX (12U) /* Maximum value of month */
-
- /*
- Data typing
- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
- /* Time parameter */
- typedef struct ClockDayCnvTblTag {
- YearCntTbl st_tbl[CNV_YEAR_MAX + 1 ]; /* Have +1 data for end determination */
- } ClockDayCntTbl;
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_CLOCKUTILITY_PRIVATE_H_
-
diff --git a/vehicleservice/positioning/server/include/Sensor/DeadReckoning_Common.h b/vehicleservice/positioning/server/include/Sensor/DeadReckoning_Common.h
deleted file mode 100755
index 1c6e060..0000000
--- a/vehicleservice/positioning/server/include/Sensor/DeadReckoning_Common.h
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_COMMON_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_COMMON_H_
-/****************************************************************************
- * File name :DeadReckoning_Common.h
- * System name :PastModel002
- * Subsystem name :
- ****************************************************************************/
-
-#include "Dead_Reckoning_Local_Api.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-#define DEADRECKONING_ZERO 0
-#define DEADRECKONING_BIT0 0x00000001
-#define DEADRECKONING_BIT1 0x00000002
-#define DEADRECKONING_BIT2 0x00000004
-#define DEADRECKONING_BIT3 0x00000008
-#define DEADRECKONING_BIT4 0x00000010
-#define DEADRECKONING_BIT5 0x00000020
-#define DEADRECKONING_BIT6 0x00000040
-#define DEADRECKONING_BIT7 0x00000080
-#define DEADRECKONING_BIT29 0x20000000
-#define DEADRECKONING_BIT30 0x40000000
-#define DEADRECKONING_BIT31 0x80000000
-#define DEADRECKONING_NEQ 1
-#define DEADRECKONING_EQ 0
-#define DEADRECKONING_INVALID 0
-#define DEADRECKONING_EFFECTIVE 1
-#define DEADRECKONING_CHGTYPE_NCHG DEADRECKONING_EQ
-#define DEADRECKONING_CHGTYPE_CHG DEADRECKONING_NEQ
-#define DEADRECKONING_GETMETHOD_DR 4 /* Data collection way: DR */
-
-/* Offset value of normal data of vehicle sensor */
-#define DEADRECKONING_OFFSET_NORMAL 4
-
-/************************************************************************
-* Typedef definitions *
-************************************************************************/
-
-/* Data Master Set Notification Function */
-typedef void (*PFUNC_DR_DMASTER_SET_N) (DID, u_int8, u_int8);
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-/*********************************************************************
-* TAG : DEADRECKONING_DID_OFFSET_TBL
-* ABSTRACT : Vehicle sensor data ID,Structure of each data in the offset table
-***********************************************************************/
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_offset; /* Offset value */
- u_int8 uc_reserve[2]; /* Reserved */
-} DEADRECKONING_DID_OFFSET_TBL;
-
-/*********************************************************************
-* TAG :
-* ABSTRACT :
-***********************************************************************/
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-u_int8 DeadReckoningMemcmp(const void *, const void *, size_t);
-int32 DeadReckoningCheckDid(DID);
-u_int16 DeadReckoningGetDataMasterOffset(DID);
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_COMMON_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/DeadReckoning_DataMaster.h b/vehicleservice/positioning/server/include/Sensor/DeadReckoning_DataMaster.h
deleted file mode 100755
index 00c056a..0000000
--- a/vehicleservice/positioning/server/include/Sensor/DeadReckoning_DataMaster.h
+++ /dev/null
@@ -1,127 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_DATAMASTER_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_DATAMASTER_H_
-/****************************************************************************
- * File name :DeadReckoning_DataMaster.h
- * System name :PastModel002
- * Subsystem name :DeadReckoning processes
- ****************************************************************************/
-
-#include "DeadReckoning_Common.h"
-#include "Dead_Reckoning_Local_Api.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-/* Initial value */
-#define VEHICLE_DINIT_LONGITUDE 0x00
-#define VEHICLE_DINIT_LATITUDE 0x00
-#define VEHICLE_DINIT_ALTITUDE 0x00
-#define VEHICLE_DINIT_SPEED 0x00
-#define VEHICLE_DINIT_HEADING 0x00
-#define VEHICLE_DINIT_DR_SNS_COUNTER 0x00
-#define VEHICLE_DINIT_GYRO_OFFSET 0x0000
-#define VEHICLE_DINIT_GYRO_SCALE_FACTOR 0x00
-#define VEHICLE_DINIT_GYRO_SCALE_FACTOR_LEVEL 0x00
-#define VEHICLE_DINIT_SPEED_PULSE_SCALE_FACTOR 0x0000
-#define VEHICLE_DINIT_SPEED_PULSE_SCALE_FACTOR_LEVEL 0x00
-
-#define VEHICLE_DSIZE_LONGITUDE 0x04
-#define VEHICLE_DSIZE_LATITUDE 0x04
-#define VEHICLE_DSIZE_ALTITUDE 0x04
-#define VEHICLE_DSIZE_SPEED 0x02
-#define VEHICLE_DSIZE_HEADING 0x02
-#define VEHICLE_DSIZE_DR_SNS_COUNTER 0x01
-#define VEHICLE_DSIZE_GYRO_OFFSET 0x02
-#define VEHICLE_DSIZE_GYRO_SCALE_FACTOR 0x01
-#define VEHICLE_DSIZE_GYRO_SCALE_FACTOR_LEVEL 0x01
-#define VEHICLE_DSIZE_SPEED_PULSE_SCALE_FACTOR 0x02
-#define VEHICLE_DSIZE_SPEED_PULSE_SCALE_FACTOR_LEVEL 0x01
-
-/* Data received*/
-#define DEADRECKONING_RCVFLAG_ON 0x01
-#define DEADRECKONING_RCVFLAG_OFF 0x00
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-
-/*********************************************************************
-* TAG : DEADRECKONING_DATA_MASTER
-* ABSTRACT : Vehicle SW Data Master Structure
-***********************************************************************/
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcv_flag; /* Receive flag */
- u_int8 dr_status; /* DR status */
- u_int8 uc_data[4]; /* Vehicle DR data */
-} DEADRECKONING_DATA_MASTER;
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-void DeadReckoningInitDataMaster(void);
-void DeadReckoningSetDataMaster(const DEADRECKONING_DATA_MASTER *, PFUNC_DR_DMASTER_SET_N);
-void DeadReckoningGetDataMaster(DID ul_did, DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitLongitudeDr(void);
-u_int8 DeadReckoningSetLongitudeDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetLongitudeDr(DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitLatitudeDr(void);
-u_int8 DeadReckoningSetLatitudeDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetLatitudeDr(DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitAltitudeDr(void);
-u_int8 DeadReckoningSetAltitudeDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetAltitudeDr(DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitSpeedDr(void);
-u_int8 DeadReckoningSetSpeedDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetSpeedDr(DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitHeadingDr(void);
-u_int8 DeadReckoningSetHeadingDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetHeadingDr(DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitSnsCounterDr(void);
-u_int8 DeadReckoningSetSnsCounterDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetSnsCounterDr(DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitGyroOffsetDr(void);
-u_int8 DeadReckoningSetGyroOffsetDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetGyroOffsetDr(DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitGyroScaleFactorDr(void);
-u_int8 DeadReckoningSetGyroScaleFactorDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetGyroScaleFactorDr(DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitGyroScaleFactorLevelDr(void);
-u_int8 DeadReckoningSetGyroScaleFactorLevelDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetGyroScaleFactorLevelDr(DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitSpeedPulseScaleFactorDr(void);
-u_int8 DeadReckoningSetSpeedPulseScaleFactorDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetSpeedPulseScaleFactorDr(DEADRECKONING_DATA_MASTER *);
-
-void DeadReckoningInitSpeedPulseScaleFactorLevelDr(void);
-u_int8 DeadReckoningSetSpeedPulseScaleFactorLevelDr(const DEADRECKONING_DATA_MASTER *);
-void DeadReckoningGetSpeedPulseScaleFactorLevelDr(DEADRECKONING_DATA_MASTER *);
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_DATAMASTER_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/DeadReckoning_DeliveryCtrl.h b/vehicleservice/positioning/server/include/Sensor/DeadReckoning_DeliveryCtrl.h
deleted file mode 100755
index a555a47..0000000
--- a/vehicleservice/positioning/server/include/Sensor/DeadReckoning_DeliveryCtrl.h
+++ /dev/null
@@ -1,137 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_DELIVERYCTRL_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_DELIVERYCTRL_H_
-/******************************************************************************
- * File name :DeadReckoning_DeliveryCtrl.h
- * System name :PastModel002
- * Subsystem name :
- ******************************************************************************/
-
-#include "DeadReckoning_DataMaster.h"
-#include "Dead_Reckoning_Local_Api.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-#define DEADRECKONING_SIGNAL 6 /* Number of vehicle signals */
-#define DEADRECKONING_DELIVERY 10 /* Number of delivery destinations */
-/* Vehicle sensor information */
-#define DEADRECKONING_DELIVERY_INFO (DEADRECKONING_SIGNAL)
-/* Maximum number of vehicle sensor information */
-#define DEADRECKONING_DELIVERY_INFO_MAX (DEADRECKONING_DELIVERY_INFO * DEADRECKONING_DELIVERY)
-/* Vehicle Sensor Information Valid Number */
-#define DEADRECKONING_DID_EFFECTIVE (DEADRECKONING_SIGNAL)
-#define DEADRECKONING_ACTION_TYPE_ADD 0 /* Vehicle sensor addition processing */
-#define DEADRECKONING_ACTION_TYPE_UPDATE 1 /* Vehicle sensor update processing */
-
-#define DEADRECKONING_LINK_INDEX_END 0xFFFF /* End of the link index */
-
-#define DEADRECKONING_DELIVERY_METHOD_NORMAL 0 /* Delivery system normal delivery */
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-
-/*********************************************************************
-* TAG :DEADRECKONING_DELIVERY_CTRL_TBL_DATA
-* ABSTRACT : Structure of each data of the vehicle sensor delivery destination management table
-***********************************************************************/
-typedef struct {
- DID ul_did; /* Data ID */
- PNO us_pno; /* Shipping PID */
- u_int8 uc_chg_type; /* Delivery timing */
- u_int8 uc_ctrl_flg; /* Delivery operation */
- u_int16 us_link_idx; /* Link index */
- u_int8 uc_method; /* Delivery system */
- u_int8 uc_reserve; /* reserve */
-} DEADRECKONING_DELIVERY_CTRL_TBL_DATA;
-
-/*********************************************************************
-* TAG : DEADRECKONING_DELIVERY_CTRL_TBL
-* ABSTRACT : Vehicle Sensor Delivery Destination Management Table Structure
-***********************************************************************/
-typedef struct {
- u_int16 us_num; /* Number of delivery destination management data items */
- u_int8 uc_reserve[2]; /* Reserved */
- /* Array of each data */
- DEADRECKONING_DELIVERY_CTRL_TBL_DATA st_ctrl_data[DEADRECKONING_DELIVERY_INFO_MAX];
-} DEADRECKONING_DELIVERY_CTRL_TBL;
-
-/*********************************************************************
-* TAG : DEADRECKONING_DELIVERY_CTRL_TBL_MNG_DATA
-* ABSTRACT : Structure of each data of Vehicle Sensor Destination Management Table Management
-***********************************************************************/
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_start_idx; /* Start index */
- u_int16 us_end_idx; /* End index */
- u_int16 us_dlvry_entry_num; /* Number of registered shipping addresses */
- u_int8 uc_reserve[2]; /* Reserved */
-} DEADRECKONING_DELIVERY_CTRL_TBL_MNG_DATA;
-
-/*********************************************************************
-* TAG : DEADRECKONING_DELIVERY_CTRL_TBL_MNG
-* ABSTRACT : Structure of Vehicle Sensor Delivery Destination Management Table Management
-***********************************************************************/
-typedef struct {
- u_int16 us_num; /* Number of data items */
- u_int8 uc_reserve[2]; /* Reserved */
- /* Array of each data */
- DEADRECKONING_DELIVERY_CTRL_TBL_MNG_DATA st_ctrl_tbl_mng_data[DEADRECKONING_DELIVERY_INFO];
-} DEADRECKONING_DELIVERY_CTRL_TBL_MNG;
-
-/*********************************************************************
-* TAG : DEADRECKONING_DELIVERY_PNO_TBL
-* ABSTRACT : Vehicle Sensor Destination PNO Table
-***********************************************************************/
-typedef struct {
- PNO us_pno; /* Thread ID */
- u_int16 us_index; /* Appropriate INDEX in the delivery control table */
- u_int8 uc_method; /* Delivery system */
- u_int8 uc_reserve[3]; /* reserve */
-} DEADRECKONING_DELIVERY_PNO_TBL_DAT;
-
-typedef struct {
- u_int16 us_num; /* Number of data items */
- u_int8 uc_reserve[2]; /* reserve */
- DEADRECKONING_DELIVERY_PNO_TBL_DAT st_pno_data[DEADRECKONING_DELIVERY_INFO_MAX];
-} DEADRECKONING_DELIVERY_PNO_TBL;
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-
-DEADRECKONING_DELIVERY_PNO_TBL* DeadReckoningMakeDeliveryPnoTbl(DID ul_did, u_int8 change_type);
-
-DEAD_RECKONING_RET_API DeadReckoningEntryDeliveryCtrl(const DEADRECKONING_MSG_DELIVERY_ENTRY *);
-
-void DeadReckoningInitDeliveryCtrlTbl(void);
-void DeadReckoningInitDeliveryCtrlTblMng(void);
-
-void DeadReckoningAddDeliveryCtrlTbl(const DEADRECKONING_MSG_DELIVERY_ENTRY *);
-void DeadReckoningUpdateDeliveryCtrlTbl(DEADRECKONING_DELIVERY_CTRL_TBL_MNG_DATA *);
-void DeadReckoningAddDeliveryCtrlTblMng(const DEADRECKONING_MSG_DELIVERY_ENTRY *);
-void DeadReckoningUpdateDeliveryCtrlTblMng(DEADRECKONING_DELIVERY_CTRL_TBL_MNG_DATA *);
-
-void DeadReckoningAddPnoTbl(u_int16);
-void DeadReckoningDeliveryProc(DID ul_did, u_int8 uc_chg_type, u_int8 uc_get_method);
-void DeadReckoningFirstDelivery(PNO us_pno, DID ul_did);
-
-RET_API DRManagerSndMsg(PNO us_pno_src, PNO us_pno_dest, CID us_cid, u_int16 us_msg_len, const void *p_msg_data);
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_DELIVERYCTRL_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/DeadReckoning_main.h b/vehicleservice/positioning/server/include/Sensor/DeadReckoning_main.h
deleted file mode 100755
index 3e2e9d4..0000000
--- a/vehicleservice/positioning/server/include/Sensor/DeadReckoning_main.h
+++ /dev/null
@@ -1,146 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_MAIN_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_MAIN_H_
-/****************************************************************************
- * File name :DeadReckoning_main.h
- * System name :PastModel002
- * Subsystem name :
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-
-#include "Sensor_Common_API.h"
-
-#include "Dead_Reckoning_API.h"
-#include "Dead_Reckoning_Local_Api.h"
-#include "DeadReckoning_Common.h"
-#include "DeadReckoning_DataMaster.h"
-#include "DeadReckoning_DeliveryCtrl.h"
-
-#include "Sensor_API.h"
-#include "VehicleSens_DeliveryCtrl.h"
-#include "VehicleDebug_API.h"
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-/* Return value */
-#define RET_SWMNG_SUCCESS RET_NORMAL /* Success of API processing */
-#define RET_SWMNG_ERROR RET_ERROR /* API processing failed */
-
-/*** Rcv Message Relationships ***************************************************/
-/* Size of data section */
-#define DEAD_RECKONING_RCVMSG_MSGBUF 512 /* RcvMSG Byte count in data section */
-#define DEAD_RECKONING_RCVDATA_SENSOR_MSGBUF 40 /* RcvMSG Byte count of Sensor data section */
-#define DEAD_RECKONING_RCVDATA_SENSOR_FIRST_MSGBUF 1000 /* RcvMSG Initial Byte count of sensor data section */
-#define DEAD_RECKONING_SENSOR_FIRST_NUM 175 /* Initial number of saved sensor data */
-
-/* Event initial value */
-/* DR_API_private. Synchronize with DR_EVENT_VAL_INIT in h */
-#define DR_EVENT_VAL_INIT (-101)
-
-/* Event initial value */
-/* DeadReckoning_main. Synchronize with h's VEHICELEDEBUG_EVENT_VAL_INIT */
-#define VEHICLEDEBUG_EVENT_VAL_INIT (-101)
-
-/* PastModel002 sleep time[ms] for CPU load balancing in the first sensor data processing */
-#define DR_FST_SENS_CALC_SLEEP_TIME 15
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-
-/*********************************************************************
-* TAG : DEAD_RECKONING_RCVDATA
-* ABSTRACT : Message receive buffer structure
-***********************************************************************/
-typedef struct {
- T_APIMSG_MSGBUF_HEADER hdr;
- u_int8 data[DEAD_RECKONING_RCVMSG_MSGBUF]; /* Data portion */
-} DEAD_RECKONING_RCVDATA;
-
-/*********************************************************************
-* TAG : DEAD_RECKONING_RCVDATA_SENSOR
-* ABSTRACT : LineSensor Vehicle Signal Notification Message Structure
-***********************************************************************/
-typedef struct {
- u_int32 did; /* Data ID */
- u_int8 size; /* Size of the data */
- u_int8 reserve[3]; /* Reserved */
- u_int8 data[DEAD_RECKONING_RCVDATA_SENSOR_MSGBUF]; /* Data content */
-} DEAD_RECKONING_RCVDATA_SENSOR;
-
-/*********************************************************************
-* TAG : DEAD_RECKONING_RCVDATA_SENSOR_FIRST
-* ABSTRACT : LineSensor Vehicle Signal Notification Message Structure
-***********************************************************************/
-typedef struct {
- u_int32 did; /* Data ID */
- u_int16 size; /* Size of the data */
- u_int8 reserve[1]; /* Reserved */
- u_int8 num; /* Number of data */
- u_int8 data[DEAD_RECKONING_RCVDATA_SENSOR_FIRST_MSGBUF]; /* Data content */
-} DEAD_RECKONING_RCVDATA_SENSOR_FIRST;
-
-/*********************************************************************
-* TAG : DEAD_RECKONING_SAVEDATA_SENSOR_FIRST
-* ABSTRACT : LineSensor Vehicle Signal-Storage Message Structures
-***********************************************************************/
-typedef struct {
- u_int16 gyro_x_data[DEAD_RECKONING_SENSOR_FIRST_NUM * NUM_OF_100msData]; /* Data content */
- u_int16 gyro_y_data[DEAD_RECKONING_SENSOR_FIRST_NUM * NUM_OF_100msData]; /* Data content */
- u_int16 gyro_z_data[DEAD_RECKONING_SENSOR_FIRST_NUM * NUM_OF_100msData]; /* Data content */
- u_int16 spd_pulse_data[DEAD_RECKONING_SENSOR_FIRST_NUM]; /* Data content */
- u_int8 spd_pulse_check_data[DEAD_RECKONING_SENSOR_FIRST_NUM]; /* Data content */
- u_int8 rev_data[DEAD_RECKONING_SENSOR_FIRST_NUM]; /* Data content */
- u_int8 data_num; /* Number of data */
- u_int8 reserve[3]; /* reserve */
- u_int16 gyro_x_rcv_size; /* Receiving Size */
- u_int16 gyro_y_rcv_size; /* Receiving Size */
- u_int16 gyro_z_rcv_size; /* Receiving Size */
- u_int16 spd_pulse_rcv_size; /* Receiving Size */
- u_int16 spd_pulse_check_rcv_size; /* Receiving Size */
- u_int16 rev_rcv_size; /* Receiving Size */
-} DEAD_RECKONING_SAVEDATA_SENSOR_FIRST;
-
-/*********************************************************************
-* TAG : DEAD_RECKONING_LONLAT_INFO
-* ABSTRACT : Get Position Information Structure
-***********************************************************************/
-typedef struct {
- u_int8 calc_called; /* Whether Calculate_DeadReckoningData was called */
- u_int8 available;
- u_int8 reserve[2];
- LONLAT lonlat;
-} DEAD_RECKONING_LONLAT_INFO;
-
-/************************************************************************
-* DeadReckoning_main function prototype *
-************************************************************************/
-
-void DeadReckoningRcvMsg(const DEAD_RECKONING_RCVDATA *msg, DEAD_RECKONING_LONLAT_INFO *location_info);
-void DeadReckoningRcvMsgFstSens(const DEAD_RECKONING_RCVDATA *msg, DEAD_RECKONING_LONLAT_INFO *location_info,
- const SENSOR_MSG_GPSDATA_DAT *rcv_gps_msg, Struct_GpsData* send_gps_msg,
- Struct_SensData* send_sensor_msg);
-int32 DeadReckoningInit(void);
-void DeadReckoningGetDRData(const DEADRECKONING_MSG_GET_DR_DATA *msg);
-void DeadReckoningSetMapMatchingData(const DR_MSG_MAP_MATCHING_DATA *msg);
-void DeadReckoningClearBackupData(const DR_MSG_CLEAR_BACKUP_DATA *msg);
-void DeadReckoningGetLocationLogStatus(PNO pno);
-void DeadReckoningSetLocationLogStatus(BOOL log_sw, u_int8 severity);
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_DEADRECKONING_MAIN_H_ */
diff --git a/vehicleservice/positioning/server/include/Sensor/GpsInt.h b/vehicleservice/positioning/server/include/Sensor/GpsInt.h
deleted file mode 100755
index fbb69de..0000000
--- a/vehicleservice/positioning/server/include/Sensor/GpsInt.h
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*****************************************************************************************
-* File name :GpsInt.h
-* System name :PastModel002
-* Process name :Vehicle
-* Overview :GPS interrupt thread header
-******************************************************************************************/
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_GPSINT_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_GPSINT_H_
-
-/*******************************************************************************
-* Include File
-*******************************************************************************/
-
-/*******************************************************************************
-* Define
-*******************************************************************************/
-#define GPS_IRQ_ADR 0x00000306UL /* GPS IRQ addresses */
-#define GPS_MASK_6BIT 0x00000040UL /* GPS IRQ bit-mask position */
-
-#define GPS_GPIO0_IRQSTATUS_0_OFFSET 0x0000002CUL /* IRQSTATUS_0 offset */
-#define GPS_GPIO0_IRQSTATUS_SET_0_OFFSET 0x00000034UL /* IRQSTATUS_SET_0 offset */
-#define GPS_GPIO0_RISINGDETECT_OFFSET 0x00000148UL /* RISINGDETECT offsets */
-
-/* IRQSTATUS_0 address */
-#define GPS_GPIO0_IRQSTATUS_0_ADDR (DM816X_GPIO0_BASE + GPS_GPIO0_IRQSTATUS_0_OFFSET)
-
-/* IRQSTATUS_SET_0 address */
-#define GPS_GPIO0_IRQSTATUS_SET_0_ADDR (DM816X_GPIO0_BASE + GPS_GPIO0_IRQSTATUS_SET_0_OFFSET)
-
-/* RISINGDETECT addresses */
-#define GPS_GPIO0_RISINGDETECT_ADDR (DM816X_GPIO0_BASE + GPS_GPIO0_RISINGDETECT_OFFSET)
-
-/*******************************************************************************
-* Struct
-*******************************************************************************/
-typedef struct {
- DWORD irq_status_reg; /* Interrupt Source Clear Register */
- DWORD irq_status_set_reg; /* Interrupt enable register */
- DWORD rising_detect_reg; /* Rising edge detection setting register */
-} GPS_INT_DATA;
-
-/***************************
-* Function prototype declaration
-***************************/
-RET_API DEVGpsIntInitial(void);
-BOOL DEVGpsIntMapDevice(void);
-void DEVGpsIntUnMapDevice(void);
-void DEVGpsIntSetInterupt(void);
-void DEVGpsIntIntRegClear(void);
-RET_API DEVGpsIntSndMsg(void);
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_GPSINT_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/SensorLog.h b/vehicleservice/positioning/server/include/Sensor/SensorLog.h
deleted file mode 100755
index 9b6a49a..0000000
--- a/vehicleservice/positioning/server/include/Sensor/SensorLog.h
+++ /dev/null
@@ -1,114 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * SensorLog.h
- * @brief
- * Definition for Sensor Logging I/F Liblary
- */
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_SENSORLOG_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_SENSORLOG_H_
-
-#include <stdint.h>
-#include <vehicle_service/positioning_base_library.h>
-#include <vehicle_service/POS_define.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-/* NAV-SVINFO sizes(chnum=20) */
-#define SENSLOG_GPS_SIZE_NAVSVINFO 248
-
-/* Sensor log data type */
-typedef enum {
- SENSLOG_DATA_I_UNSPECIFIED = 0, /* Input:Not specified */
-
- SENSLOG_DATA_I_SYS, /* Input:Sensor */
- SENSLOG_DATA_I_SYS_STS, /* Input:External terminal status */
- SENSLOG_DATA_I_GPS, /* Input:GPS(_CWORD82_/u-blox) */
- SENSLOG_DATA_I_LOC, /* Input:Location information */
- SENSLOG_DATA_I_SPEED, /* Input:Vehicle speed */
- SENSLOG_DATA_I_TIME, /* Input:Request to set GPS time */
- SENSLOG_DATA_I_GPSINF, /* Input:GPS information setting request */
- SENSLOG_DATA_I_GPSRST, /* Input:GPS reset request */
- SENSLOG_DATA_I_GPSSET, /* Input:GPS setting request */
- SENSLOG_DATA_I_NAVSVINFO, /* Input:NAV-SVINFO(u-blox)*/
- SENSLOG_DATA_I_SYS_ABNORMAL, /* Input:Sensor(When an error occurs) */
- SENSLOG_DATA_I_COUNT /* Classified number */
-} SENSLOG_DATA_I;
-
-typedef enum {
- SENSLOG_DATA_O_UNSPECIFIED = 0, /* Output:Not specified */
-
- SENSLOG_DATA_O_SYS, /* Output:Sensor */
- SENSLOG_DATA_O_SYS_PKG, /* Output:Sensor(PKG) */
- SENSLOG_DATA_O_GPS, /* Output:GPS(_CWORD82_/u-blox) */
- SENSLOG_DATA_O_LONLAT_N, /* Output:Latitude and longitude(NAVI) */
- SENSLOG_DATA_O_LONLAT_G, /* Output:Latitude and longitude(GPS) */
- SENSLOG_DATA_O_ALT, /* Output:Altitude */
- SENSLOG_DATA_O_SPEED_N, /* Output:Vehicle speed(NAVI) */
- SENSLOG_DATA_O_SPEED_P, /* Output:Vehicle speed(POS) */
- SENSLOG_DATA_O_HEAD_N, /* Output:Orientation(NAVI) */
- SENSLOG_DATA_O_HEAD_G, /* Output:Orientation(GPS) */
- SENSLOG_DATA_O_TIME_SETREQ, /* Output:GPS time delivery request */
- SENSLOG_DATA_O_TIME, /* Output:GPS time */
- SENSLOG_DATA_O_GPSINF, /* Output:GPS information */
- SENSLOG_DATA_O_TIME_CS, /* Output:GPS time(For the ClockService) */
- SENSLOG_DATA_O_GPSRST, /* Output:GPS reset response */
-
- SENSLOG_DATA_O_COUNT /* Classified number */
-} SENSLOG_DATA_O;
-
-/* Send/Receive result */
-#define SENSLOG_RES_SUCCESS 0 /* Send/Receive Success */
-#define SENSLOG_RES_FAIL 1 /* Send/Receive Abnormality */
-
-/* Destination name(Internal use) */
-#define SENSLOG_PNAME_CLOCK "*Clock" /* Clock Service */
-#define SENSLOG_PNAME_COMMUSB "*CommUSB" /* CommUSB */
-
-#define SENSLOG_ON 1
-#define SENSLOG_OFF 0
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-/* SensorLog public API */
-#ifdef __cplusplus
-extern "C" {
-#endif
- void SensLogInitialize(uint8_t *p_mount_path);
- uint8_t SensLogGetNavSvinfoFlag(void);
- void SensLogWriteInputData(uint16_t us_data_type, DID ul_did, PNO us_pno, uint8_t *p_data, \
- uint16_t us_size, uint8_t uc_result, uint8_t u_write_flag, uint8_t u_write_abnormal_flag);
- void SensLogWriteOutputData(uint16_t us_data_type, DID ul_did, PNO us_pno, uint8_t *p_data, \
- uint16_t us_size, uint8_t uc_result);
- void SensLogTerminate(void);
- void SensLogStore(void);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_SENSORLOG_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/VehicleSens_Common.h b/vehicleservice/positioning/server/include/Sensor/VehicleSens_Common.h
deleted file mode 100755
index 7b47268..0000000
--- a/vehicleservice/positioning/server/include/Sensor/VehicleSens_Common.h
+++ /dev/null
@@ -1,131 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_COMMON_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_COMMON_H_
-/****************************************************************************
- * File name :VehicleSens_Common.h
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- ****************************************************************************/
-
-#include "Vehicle_API_Dummy.h"
-#include "Vehicle_API_private.h"
-
-#include "positioning_hal.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-#define VEHICLESENS_ZERO 0
-#define VEHICLESENS_BIT0 0x00000001
-#define VEHICLESENS_BIT1 0x00000002
-#define VEHICLESENS_BIT2 0x00000004
-#define VEHICLESENS_BIT3 0x00000008
-#define VEHICLESENS_BIT4 0x00000010
-#define VEHICLESENS_BIT5 0x00000020
-#define VEHICLESENS_BIT6 0x00000040
-#define VEHICLESENS_BIT7 0x00000080
-#define VEHICLESENS_BIT29 0x20000000
-#define VEHICLESENS_BIT30 0x40000000
-#define VEHICLESENS_BIT31 0x80000000
-#define VEHICLESENS_NEQ 1
-#define VEHICLESENS_EQ 0
-#define VEHICLESENS_INVALID 0
-#define VEHICLESENS_EFFECTIVE 1
-#define VEHICLESENS_CHGTYPE_NCHG VEHICLESENS_EQ
-#define VEHICLESENS_CHGTYPE_CHG VEHICLESENS_NEQ
-#define VEHICLESENS_GETMETHOD_CAN 0 /* Data collection way: CAN communication */
-#define VEHICLESENS_GETMETHOD_LINE 1 /* Data collection way: LineSensor drivers */
-#define VEHICLESENS_GETMETHOD_NO_DETECTION 2 /* Data collection way: Not downloaded */
-#define VEHICLESENS_GETMETHOD_GPS 3 /* Data collection way: GPS */
-#define VEHICLESENS_GETMETHOD_NAVI 4 /* Data collection way: NAVI */
-#define VEHICLESENS_GETMETHOD_CLOCK 5 /* Data collection way: Clock Information */
-#define VEHICLESENS_GETMETHOD_INTERNAL 6 /* Data collection way: Internal calculation */
-#define VEHICLESENS_GETMETHOD_OTHER 7 /* Data collection way: Others */
-
-/* Offset value of normal data of vehicle sensor */
-#define VEHICLESENS_OFFSET_NORMAL 32
-/* Offset value of normal data of vehicle sensor */
-#define VEHICLESENS_OFFSET_GPS_FORMAT 268 /* 8 + 260 */
-/* Offset value of normal data of vehicle sensor */
-#define VEHICLESENS_OFFSET_GPS_BINARY 368 /* 8 + 360 */
-/* ++ GPS _CWORD82_ support */
-#define VEHICLESENS_OFFSET_GPS_NMEA 460 /* 8 + 452 Packaged delivery offset */
-/* -- GPS _CWORD82_ support */
-
-/* ++ PastModel002 support */
-/* U-Blox GPS offsets */
-#define VEHICLESENS_OFFSET_GPS_UBLOX 220 /* 220 */
-/* -- PastModel002 support */
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-#define VEHICLESENS_OFFSET_10WORD_PKG_EXT 208 /* Offset value of 10 initial deliveries(WORD) 8 + (20 * 10) */
-#define VEHICLESENS_OFFSET_WORD_PKG_EXT 28 /* Offset value of 10 initial deliveries(WORD) 8 + 20 */
-#define VEHICLESENS_OFFSET_BYTE_PKG_EXT 18 /* Offset value of 10 initial deliveries(BYTE) 8 + 10 */
-#define VEHICLESENS_OFFSET_32LONG_PKG_EXT 1328 /* Offset value of 10 initial deliveries(LONG) 8 + (132 * 10) */
-#define VEHICLESENS_OFFSET_20WORD 48 /* Offset value of 20 sensor data(WORD) 8 + 40 */
-#define VEHICLESENS_OFFSET_20WORD_FST 408 /* Offset value of 20 initial sensor data(WORD) 8 + 400 */
-#define VEHICLESENS_DNUM_4 4 /* Number of sensor data */
-#define VEHICLESENS_DNUM_5 5 /* Number of sensor data */
-#define VEHICLESENS_DNUM_7 7 /* Number of sensor data */
-#endif
-#define VEHICLESENS_EXT_OFF 0 /* Normal delivery */
-#define VEHICLESENS_EXT_ON 1 /* Extended delivery */
-
-#if CONFIG_HW_PORTSET_TYPE_C
-#define VEHICLESENS_OFFSET_GPS_NMEA 248 /* 8 + 240 */
-#endif
-
-/************************************************************************
-* Typedef definitions *
-************************************************************************/
-/* typedef u_int32 DID; */ /* Data ID */
-
-/* Data Master Set Notification Function */
-typedef void (*PFUNC_DMASTER_SET_N) (DID, u_int8, u_int8);
-typedef void (*PFUNC_DMASTER_SET_SHARED_MEMORY) (DID, u_int8);
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-/*********************************************************************
-* TAG : VEHICLESENS_DID_OFFSET_TBL
-* ABSTRACT : Vehicle sensor data ID,Structure of each data in the offset table
-***********************************************************************/
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_offset; /* Offset value */
- u_int8 uc_reserve[2]; /* Reserved */
-} VEHICLESENS_DID_OFFSET_TBL;
-
-/*********************************************************************
-* TAG :
-* ABSTRACT :
-***********************************************************************/
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-u_int8 VehicleSensmemcmp(const void *, const void *, size_t);
-int32 VehicleSensCheckDid(DID);
-u_int16 VehicleSensGetDataMasterOffset(DID);
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-u_int16 VehicleSensGetDataMasterExtOffset(DID);
-#endif
-void VehicleSensSetGpsVersion(const SENSOR_MSG_GPSDATA_DAT *pstData);
-void VehicleSensGetDebugPosDate(void* pBuf, u_int8 uc_get_method);
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_COMMON_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/VehicleSens_DataMaster.h b/vehicleservice/positioning/server/include/Sensor/VehicleSens_DataMaster.h
deleted file mode 100755
index a180764..0000000
--- a/vehicleservice/positioning/server/include/Sensor/VehicleSens_DataMaster.h
+++ /dev/null
@@ -1,1091 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_DATAMASTER_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_DATAMASTER_H_
-/****************************************************************************
- * File name :VehicleSens_DataMaster.h
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- ****************************************************************************/
-
-#include "Vehicle_API_Dummy.h"
-#include "Vehicle_API_private.h"
-
-#include "positioning_hal.h"
-#include "VehicleSens_Common.h"
-#include "VehicleSens_SelectionItemList.h"
-#include "CommonDefine.h"
-#include <vehicle_service/POS_common_API.h>
-#include <vehicle_service/POS_gps_API.h>
-#include "Naviinfo_API.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-/* Initial value */
-#define VEHICLE_DINIT_SP1P 0x0000
-#define VEHICLE_DINIT_SP1S 0x00
-#define VEHICLE_DINIT_SP1 0x0000
-#define VEHICLE_DINIT_ECOMODE 0x00
-#define VEHICLE_DINIT_NE1 0x0000
-#define VEHICLE_DINIT_R_ACCALL 0x00
-#define VEHICLE_DINIT_R_AC_WNG 0x00
-#define VEHICLE_DINIT_R_SW_CON 0x00
-#define VEHICLE_DINIT_R_BEEP 0x00
-#define VEHICLE_DINIT_I_RA_AUT 0x00
-#define VEHICLE_DINIT_I_RA_AC 0x00
-#define VEHICLE_DINIT_I_RA_LO 0x00
-#define VEHICLE_DINIT_I_RA_HI 0x00
-#define VEHICLE_DINIT_I_AUTO_D 0x00
-#define VEHICLE_DINIT_I_AUTO_P 0x00
-#define VEHICLE_DINIT_I_DEF 0x00
-#define VEHICLE_DINIT_I_RRDEF 0x00
-#define VEHICLE_DINIT_I_RFAUT 0x00
-#define VEHICLE_DINIT_I_REC 0x00
-#define VEHICLE_DINIT_I_FRS 0x00
-#define VEHICLE_DINIT_I_AC 0x00
-#define VEHICLE_DINIT_I_MHTR 0x00
-#define VEHICLE_DINIT_I_WIPD 0x00
-#define VEHICLE_DINIT_I_DUSY 0x00
-#define VEHICLE_DINIT_I_SWNG 0x00
-#define VEHICLE_DINIT_I_BLW_F 0x00
-#define VEHICLE_DINIT_I_OAUT_D 0x00
-#define VEHICLE_DINIT_I_OLET_D 0x00
-#define VEHICLE_DINIT_I_OAUT_P 0x00
-#define VEHICLE_DINIT_I_OLET_P 0x00
-#define VEHICLE_DINIT_ST_BMN_F 0x00
-#define VEHICLE_DINIT_I_AIRPR 0x00
-#define VEHICLE_DINIT_I_O2 0x00
-#define VEHICLE_DINIT_I_PLSM 0x00
-#define VEHICLE_DINIT_I_KAFUN 0x00
-#define VEHICLE_DINIT_I_SAFS 0x00
-#define VEHICLE_DINIT_R_ONSCRN 0x00
-#define VEHICLE_DINIT_I_HUM 0x00
-#define VEHICLE_DINIT_I_TMP_D 0x00
-#define VEHICLE_DINIT_I_TMP_P 0x00
-#define VEHICLE_DINIT_SL_ACDSP 0x00
-#define VEHICLE_DINIT_SL_DUSY 0x00
-#define VEHICLE_DINIT_SL_CIF 0x00
-#define VEHICLE_DINIT_SL_BLW_F 0x00
-#define VEHICLE_DINIT_SL_SRLVL 0x00
-#define VEHICLE_DINIT_SL_RR_IH 0x00
-#define VEHICLE_DINIT_SL_RAUTO 0x00
-#define VEHICLE_DINIT_SL_BLW_R 0x00
-#define VEHICLE_DINIT_SL_DST 0x00
-#define VEHICLE_DINIT_SL_WIPD 0x00
-#define VEHICLE_DINIT_SL_MRHT 0x00
-#define VEHICLE_DINIT_SL_AIRP 0x00
-#define VEHICLE_DINIT_SL_O2 0x00
-#define VEHICLE_DINIT_SL_PLSM 0x00
-#define VEHICLE_DINIT_SL_KAFUN 0x00
-#define VEHICLE_DINIT_SL_SWNG 0x00
-#define VEHICLE_DINIT_ST_CN_OK 0x00
-#define VEHICLE_DINIT_SL_RBLW 0x00
-#define VEHICLE_DINIT_SL_HUM 0x00
-#define VEHICLE_DINIT_R_INLVL 0x00
-#define VEHICLE_DINIT_I_INLVL 0x00
-#define VEHICLE_DINIT_I_AUT_RR 0x00
-#define VEHICLE_DINIT_I_AUT_RL 0x00
-#define VEHICLE_DINIT_I_CNT_IH 0x00
-#define VEHICLE_DINIT_I_RAUTO 0x00
-#define VEHICLE_DINIT_ST_BMN_R 0x00
-#define VEHICLE_DINIT_I_BLW_R 0x00
-#define VEHICLE_DINIT_R_RONSCR 0x00
-#define VEHICLE_DINIT_I_OLT_RR 0x00
-#define VEHICLE_DINIT_I_OLT_RL 0x00
-#define VEHICLE_DINIT_I_TMP_RR 0x00
-#define VEHICLE_DINIT_I_TMP_RL 0x00
-#define VEHICLE_DINIT_ACN_AMB 0x00
-#define VEHICLE_DINIT_AC_AMB05 0x00
-#define VEHICLE_DINIT_SOC_MON 0x00
-#define VEHICLE_DINIT_RDYIND 0x00
-#define VEHICLE_DINIT_HV_M2B 0x00
-#define VEHICLE_DINIT_HV_EP 0x00
-#define VEHICLE_DINIT_HV_EM 0x00
-#define VEHICLE_DINIT_RNRG 0x00
-#define VEHICLE_DINIT_HV_MP 0x00
-#define VEHICLE_DINIT_HV_MB 0x00
-#define VEHICLE_DINIT_HV_RG 0x00
-#define VEHICLE_DINIT_B_P 0x00
-#define VEHICLE_DINIT_B_R 0x00
-#define VEHICLE_DINIT_B_N 0x00
-#define VEHICLE_DINIT_B_D 0x00
-#define VEHICLE_DINIT_B_FC 0x0000
-#define VEHICLE_DINIT_R_DISP 0x00
-#define VEHICLE_DINIT_HVFLAG 0x00
-#define VEHICLE_DINIT_DVINF 0x00
-#define VEHICLE_DINIT_IN_FC 0x0000
-#define VEHICLE_DINIT_UNIT_0 0x00
-#define VEHICLE_DINIT_AS_SP 0x0000
-#define VEHICLE_DINIT_UNIT_1 0x00
-#define VEHICLE_DINIT_FC_SCL 0x00
-#define VEHICLE_DINIT_RANGE 0x0000
-#define VEHICLE_DINIT_UNIT_4 0x00
-#define VEHICLE_DINIT_TO_FC 0x0000
-#define VEHICLE_DINIT_UNIT_6 0x00
-#define VEHICLE_DINIT_AS_TM 0x0000
-#define VEHICLE_DINIT_ADIM_C 0x00
-#define VEHICLE_DINIT_LGCY 0x00
-#define VEHICLE_DINIT_BCTY 0x00
-#define VEHICLE_DINIT_RTRRQ 0x00
-#define VEHICLE_DINIT_DEST_BDB 0x00
-#define VEHICLE_DINIT_DS_PACK1 0x00
-#define VEHICLE_DINIT_DS_PACK2 0x00
-#define VEHICLE_DINIT_STRG_WHL 0x00
-#define VEHICLE_DINIT_TRIP_CNT 0x0000
-#define VEHICLE_DINIT_TIME_CNT 0x00000000
-#define VEHICLE_DINIT_TPM_VAR 0x00
-#define VEHICLE_DINIT_TPM_WA1 0x00
-#define VEHICLE_DINIT_TPM_TNUM 0x00
-#define VEHICLE_DINIT_TPM_REQ0 0x00
-#define VEHICLE_DINIT_TPM_TAN0 0x00
-#define VEHICLE_DINIT_TPM_FLPR 0x00
-#define VEHICLE_DINIT_TPM_FL0 0x00
-#define VEHICLE_DINIT_TPM_FRPR 0x00
-#define VEHICLE_DINIT_TPM_FR0 0x00
-#define VEHICLE_DINIT_TPM_RLPR 0x00
-#define VEHICLE_DINIT_TPM_RL0 0x00
-#define VEHICLE_DINIT_TPM_RRPR 0x00
-#define VEHICLE_DINIT_TPM_RR0 0x00
-#define VEHICLE_DINIT_TPM_SPPR 0x00
-#define VEHICLE_DINIT_TPM_SP0 0x00
-#define VEHICLE_DINIT_B_R2 0x00
-#define VEHICLE_DINIT_VSP0B 0x00
-#define VEHICLE_DINIT_EPBLOCK 0x00
-
-#define VEHICLE_DINIT_DESTINATION_DEST_BDB 0x00
-#define VEHICLE_DINIT_DESTINATION_DS_PACK1 0x00
-#define VEHICLE_DINIT_DESTINATION_DS_PACK2 0x00
-#define VEHICLE_DINIT_HV 0x00
-#define VEHICLE_DINIT_2WD4WD 0x00
-#define VEHICLE_DINIT_STEERING_WHEEL 0x00
-#define VEHICLE_DINIT_VB 0x00
-#define VEHICLE_DINIT_IG 0x00
-#define VEHICLE_DINIT_MIC 0x00
-#define VEHICLE_DINIT_TEST 0x00
-#define VEHICLE_DINIT_VTRADAPTER 0x00
-#define VEHICLE_DINIT_AUXADAPTER 0x00
-#define VEHICLE_DINIT_BACKDOOR 0x00
-#define VEHICLE_DINIT_PKB 0x00
-#define VEHICLE_DINIT_PKB_CAN 0x00
-#define VEHICLE_DINIT_ADIM 0x00
-#define VEHICLE_DINIT_ILL 0x00
-#define VEHICLE_DINIT_RHEOSTAT 0x00
-#define VEHICLE_DINIT_PANELTEMP 0x00
-#define VEHICLE_DINIT_SYSTEMP 0x0000
-#define VEHICLE_DINIT_SPEED_PULSE 0x0000
-#define VEHICLE_DINIT_SPEED_KMPH 0x0000
-#define VEHICLE_DINIT_GYRO_X 0x0000
-#define VEHICLE_DINIT_GYRO_Y 0x0000
-#define VEHICLE_DINIT_GYRO_Z 0x0000
-#define VEHICLE_DINIT_GYRO VEHICLE_DINIT_GYRO_X
-#define VEHICLE_DINIT_GSNS_X 0x0000
-#define VEHICLE_DINIT_GSNS_Y 0x0000
-#define VEHICLE_DINIT_GSNS_Z 0x0000
-#define VEHICLE_DINIT_REV 0x00
-#define VEHICLE_DINIT_VSC1S03_4 0x00
-#define VEHICLE_DINIT_VSC1S03_5 0x00
-#define VEHICLE_DINIT_VSC1S03_6 0x00
-#define VEHICLE_DINIT_VSC1S03_7 0x00
-#define VEHICLE_DINIT_ECO1S01_2 0x00
-#define VEHICLE_DINIT_ENG1F07_0 0x00
-#define VEHICLE_DINIT_ENG1F07_1 0x00
-#define VEHICLE_DINIT_ENG1S03_0 0x00
-#define VEHICLE_DINIT_ENG1S03_1 0x00
-#define VEHICLE_DINIT_ACN1S04_0 0x00
-#define VEHICLE_DINIT_ACN1S04_1 0x00
-#define VEHICLE_DINIT_ACN1S04_2 0x00
-#define VEHICLE_DINIT_ACN1S04_3 0x00
-#define VEHICLE_DINIT_ACN1S04_4 0x00
-#define VEHICLE_DINIT_ACN1S04_5 0x00
-#define VEHICLE_DINIT_ACN1S04_7 0x00
-#define VEHICLE_DINIT_ACN1S05_0 0x00
-#define VEHICLE_DINIT_ACN1S05_1 0x00
-#define VEHICLE_DINIT_ACN1S06_0 0x00
-#define VEHICLE_DINIT_ACN1S06_1 0x00
-#define VEHICLE_DINIT_ACN1S06_2 0x00
-#define VEHICLE_DINIT_ACN1S06_4 0x00
-#define VEHICLE_DINIT_ACN1S06_7 0x00
-#define VEHICLE_DINIT_ACN1S08_0 0x00
-#define VEHICLE_DINIT_ACN1S08_1 0x00
-#define VEHICLE_DINIT_ACN1S08_2 0x00
-#define VEHICLE_DINIT_ACN1S08_6 0x00
-#define VEHICLE_DINIT_ACN1S08_7 0x00
-#define VEHICLE_DINIT_ACN1S07_3 0x00
-#define VEHICLE_DINIT_ACN1S07_5 0x00
-#define VEHICLE_DINIT_EHV1S90_2 0x00
-#define VEHICLE_DINIT_EHV1S90_3 0x00
-#define VEHICLE_DINIT_EHV1S90_4 0x00
-#define VEHICLE_DINIT_EHV1S90_5 0x00
-#define VEHICLE_DINIT_EHV1S90_6 0x00
-#define VEHICLE_DINIT_EHV1S90_7 0x00
-#define VEHICLE_DINIT_ECT1S92_1 0x00
-#define VEHICLE_DINIT_ECT1S92_5 0x00
-#define VEHICLE_DINIT_ENG1S28_0 0x00
-#define VEHICLE_DINIT_ENG1S28_1 0x00
-#define VEHICLE_DINIT_BGM1S01_0 0x00
-#define VEHICLE_DINIT_ENG1F03_1 0x00
-#define VEHICLE_DINIT_ENG1F03_3 0x00
-#define VEHICLE_DINIT_MET1S01_5 0x00
-#define VEHICLE_DINIT_MET1S01_6 0x00
-#define VEHICLE_DINIT_MET1S01_7 0x00
-#define VEHICLE_DINIT_MET1S03_2 0x00
-#define VEHICLE_DINIT_MET1S03_3 0x00
-#define VEHICLE_DINIT_MET1S03_4 0x00
-#define VEHICLE_DINIT_MET1S04_4 0x00
-#define VEHICLE_DINIT_MET1S04_5 0x00
-#define VEHICLE_DINIT_MET1S04_6 0x00
-#define VEHICLE_DINIT_MET1S04_7 0x00
-#define VEHICLE_DINIT_MET1S05_5 0x00
-#define VEHICLE_DINIT_MET1S05_6 0x00
-#define VEHICLE_DINIT_MET1S05_7 0x00
-#define VEHICLE_DINIT_MET1S07_6 0x00
-#define VEHICLE_DINIT_MET1S07_7 0x00
-#define VEHICLE_DINIT_BDB1S01_4 0x00
-#define VEHICLE_DINIT_BDB1S01_5 0x00
-#define VEHICLE_DINIT_BDB1S03_4 0x00
-#define VEHICLE_DINIT_BDB1S08_2 0x00
-#define VEHICLE_DINIT_BDB1S08_3 0x00
-#define VEHICLE_DINIT_BDB1S08_4 0x00
-#define VEHICLE_DINIT_BDB1S08_5 0x00
-#define VEHICLE_DINIT_BDB1F03_2 0x00
-#define VEHICLE_DINIT_BDB1F03_3 0x00
-#define VEHICLE_DINIT_BDB1F03_4 0x00
-#define VEHICLE_DINIT_BDB1F03_5 0x00
-#define VEHICLE_DINIT_BDB1F03_6 0x00
-#define VEHICLE_DINIT_BDB1F03_7 0x00
-#define VEHICLE_DINIT_TPM1S02_2 0x00
-#define VEHICLE_DINIT_TPM1S02_5 0x00
-#define VEHICLE_DINIT_TPM1S03_2 0x00
-#define VEHICLE_DINIT_TPM1S03_3 0x00
-#define VEHICLE_DINIT_TPM1S03_4 0x00
-#define VEHICLE_DINIT_TPM1S03_5 0x00
-#define VEHICLE_DINIT_TPM1S03_6 0x00
-#define VEHICLE_DINIT_TPM1S03_7 0x00
-#define VEHICLE_DINIT_ENG1S92_3 0x00
-#define VEHICLE_DINIT_MMT1S52_0 0x00
-#define VEHICLE_DINIT_EPB1S01_0 0x00
-#define VEHICLE_DINIT_MINIJACK 0x00
-#define VEHICLE_DINIT_GPS_ANTENNA 0x00
-#define VEHICLE_DINIT_SNS_COUNTER 0x00
-#define VEHICLE_DINIT_GPS_COUNTER 0x00
-
-/* ++ PastModel002 support */
-#define VEHICLE_DINIT_GPS_UBLOX_NAV_POSLLH 0x00
-#define VEHICLE_DINIT_GPS_UBLOX_NAV_STATUS 0x00
-#define VEHICLE_DINIT_GPS_UBLOX_NAV_TIMEUTC 0x00
-#define VEHICLE_DINIT_GPS_UBLOX_NAV_VELNED 0x00
-#define VEHICLE_DINIT_GPS_UBLOX_NAV_DOP 0x00
-#define VEHICLE_DINIT_GPS_UBLOX_NAV_TIMEGPS 0x00
-#define VEHICLE_DINIT_GPS_UBLOX_NAV_SVINFO 0x00
-#define VEHICLE_DINIT_GPS_UBLOX_NAV_CLOCK 0x00
-#define VEHICLE_DINIT_GPS_UBLOX_MON_HW 0x00
-
-#define VEHICLE_DINIT_SPEED_PULSE_FLAG 0x00
-#define VEHICLE_DINIT_GPS_INTERRUPT_FLAG 0x00
-
-#define VEHICLE_DINIT_GYRO_TROUBLE 0x00 /* Gyro failure status undefined(GYRO_UNFIXED) */
-#define VEHICLE_DINIT_MAIN_GPS_INTERRUPT_SIGNAL 0x00
-#define VEHICLE_DINIT_SYS_GPS_INTERRUPT_SIGNAL 0x00
-#define VEHICLE_DINIT_GYRO_CONNECT_STATUS 0x00
-/* -- PastModel002 support */
-
-/* Size of the data(byte) */
-#define VEHICLE_DSIZE_DESTINATION 0x03
-#define VEHICLE_DSIZE_HV 0x01
-#define VEHICLE_DSIZE_2WD4WD 0x01
-#define VEHICLE_DSIZE_STEERING_WHEEL 0x01
-#define VEHICLE_DSIZE_VB 0x01
-#define VEHICLE_DSIZE_IG 0x01
-#define VEHICLE_DSIZE_MIC 0x01
-#define VEHICLE_DSIZE_TEST 0x01
-#define VEHICLE_DSIZE_VTRADAPTER 0x01
-#define VEHICLE_DSIZE_AUXADAPTER 0x01
-#define VEHICLE_DSIZE_BACKDOOR 0x01
-#define VEHICLE_DSIZE_PKB 0x01
-#define VEHICLE_DSIZE_ADIM 0x01
-#define VEHICLE_DSIZE_ILL 0x01
-#define VEHICLE_DSIZE_RHEOSTAT 0x01
-#define VEHICLE_DSIZE_PANELTEMP 0x01
-#define VEHICLE_DSIZE_SYSTEMP 0x02
-#define VEHICLE_DSIZE_SPEED_PULSE 0x14
-#define VEHICLE_DSIZE_SPEED_KMPH 0x02
-#define VEHICLE_DSIZE_GYRO_X 0x14
-#define VEHICLE_DSIZE_GYRO_Y 0x14
-#define VEHICLE_DSIZE_GYRO_Z 0x14
-#define VEHICLE_DSIZE_GYRO VEHICLE_DSIZE_GYRO_X
-#define VEHICLE_DSIZE_GYRO_TEMP 0x02
-#define VEHICLE_DSIZE_PULSE_TIME 0x84
-#define VEHICLE_DSIZE_GSNS_X 0x06
-#define VEHICLE_DSIZE_GSNS_Y 0x06
-#define VEHICLE_DSIZE_GSNS_Z 0x06
-#define VEHICLE_DSIZE_REV 0x01
-#define VEHICLE_DSIZE_VSC1S03 0x09 /* Internal extensions */
-#define VEHICLE_DSIZE_ECO1S01 0x05
-#define VEHICLE_DSIZE_ENG1F07 0x08
-#define VEHICLE_DSIZE_ENG1S03 0x08
-#define VEHICLE_DSIZE_ACN1S04 0x08
-#define VEHICLE_DSIZE_ACN1S05 0x02
-#define VEHICLE_DSIZE_ACN1S06 0x08
-#define VEHICLE_DSIZE_ACN1S08 0x08
-#define VEHICLE_DSIZE_ACN1S07 0x06
-#define VEHICLE_DSIZE_EHV1S90 0x08
-#define VEHICLE_DSIZE_ECT1S92 0x08
-#define VEHICLE_DSIZE_ENG1S28 0x02
-#define VEHICLE_DSIZE_BGM1S01 0x01
-#define VEHICLE_DSIZE_ENG1F03 0x08
-#define VEHICLE_DSIZE_CAA1N01 0x08
-#define VEHICLE_DSIZE_MET1S01 0x08
-#define VEHICLE_DSIZE_MET1S03 0x08
-#define VEHICLE_DSIZE_MET1S04 0x08
-#define VEHICLE_DSIZE_MET1S05 0x08
-#define VEHICLE_DSIZE_MET1S07 0x08
-#define VEHICLE_DSIZE_BDB1S01 0x08
-#define VEHICLE_DSIZE_BDB1S03 0x08
-#define VEHICLE_DSIZE_BDB1S08 0x08
-#define VEHICLE_DSIZE_BDB1F03 0x08
-#define VEHICLE_DSIZE_TPM1S02 0x08
-#define VEHICLE_DSIZE_TPM1S03 0x08
-#define VEHICLE_DSIZE_ENG1S92 0x08
-#define VEHICLE_DSIZE_MMT1S52 0x08
-#define VEHICLE_DSIZE_EPB1S01 0x03
-#define VEHICLE_DSIZE_MINIJACK 0x01
-#define VEHICLE_DSIZE_GPS_ANTENNA 0x01
-#define VEHICLE_DSIZE_SNS_COUNTER 0x01
-#define VEHICLE_DSIZE_GPS_COUNTER 0x01
-#define VEHICLE_DSIZE_SIRF_BINARY 360
-#define VEHICLE_DSIZE_RTC VEHICLE_DSIZE_GPS_FORMAT
-#define VEHICLE_DSIZE_GPS_VERSION VEHICLE_DSIZE_GPS_FORMAT
-#define VEHICLE_DSIZE_SATELLITE_STATUS VEHICLE_DSIZE_GPS_FORMAT
-#define VEHICLE_DSIZE_LOCATION VEHICLE_DSIZE_GPS_FORMAT
-/* ++ GPS _CWORD82_ support */
-#define VEHICLE_DSIZE_GPS__CWORD82___CWORD44_GP4 VEHICLE_DSIZE_GPS_FORMAT
-#define VEHICLE_DSIZE_GPS__CWORD82__NMEA 424
-#define VEHICLE_DSIZE_GPS__CWORD82__FULLBINARY VEHICLE_DSIZE_GPS_FORMAT
-/* -- GPS _CWORD82_ support */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-#define VEHICLE_DSIZE_DATA_MASTER_FST 0x1200
-
-#define VEHICLE_DSIZE_GYRO_X_FST LSDRV_FSTSNS_DSIZE_GYRO_X
-#define VEHICLE_DSIZE_GYRO_Y_FST LSDRV_FSTSNS_DSIZE_GYRO_Y
-#define VEHICLE_DSIZE_GYRO_Z_FST LSDRV_FSTSNS_DSIZE_GYRO_Z
-#define VEHICLE_DSIZE_SPEED_PULSE_FST LSDRV_FSTSNS_DSIZE_SPEED
-#define VEHICLE_DSIZE_GSNSX_FST LSDRV_FSTSNS_DSIZE_GSENSOR_X
-#define VEHICLE_DSIZE_GSNSY_FST LSDRV_FSTSNS_DSIZE_GSENSOR_Y
-#define VEHICLE_DSIZE_GSNSZ_FST LSDRV_FSTSNS_DSIZE_GSENSOR_Z
-#define VEHICLE_DSIZE_GYROTEMP_FST LSDRV_FSTSNS_DSIZE_GYRO_TEMP
-#define VEHICLE_DSIZE_SPEED_PULSE_FLAG_FST LSDRV_FSTSNS_DSIZE_SPEED_FLG
-#define VEHICLE_DSIZE_REV_FST LSDRV_FSTSNS_DSIZE_REV
-
-#define VEHICLE_DSIZE_GYRO_EXT 0x500
-#define VEHICLE_DSIZE_SPEED_PULSE_EXT 0x500
-#define VEHICLE_DSIZE_GSNS_X_EXT 0x500
-#define VEHICLE_DSIZE_GSNS_Y_EXT 0x500
-#define VEHICLE_DSIZE_GSNS_Z_EXT 0x500
-#define VEHICLE_DSIZE_SNS_COUNTER_EXT 0x40
-#define VEHICLE_DSIZE_GYRO_TEMP_EXT 0x80
-#define VEHICLE_DSIZE_REV_EXT 0x40
-#define VEHICLE_DSIZE_PULSE_TIME_EXT 0x2100
-
-#define VEHICLE_DSIZE_GYRO_EXT_INIT 0x00 /* Gyro output extended data master registration number initial value */
-#define VEHICLE_DSIZE_SPEED_PULSE_EXT_INIT 0x00 /* Vehicle speed expansion data master registration number initial value */
-#define VEHICLE_DSIZE_GSNS_X_EXT_INIT 0x00 /* Initial value of G sensor (X-axis) extended data master registration number */
-#define VEHICLE_DSIZE_GSNS_Y_EXT_INIT 0x00 /* Initial value of G sensor (Y-axis) expansion data master registration number */
-#define VEHICLE_DSIZE_GSNS_Z_EXT_INIT 0x00 /* Initial value of G sensor (Z-axis) expansion data master registration number */
-#define VEHICLE_DSIZE_SNS_COUNTER_EXT_INIT 0x00 /* Initial value of register number of sensor counter extended data master */
-#define VEHICLE_DSIZE_REV_EXT_INIT 0x00 /* REV extended data master registration number initial value */
-#define VEHICLE_DSIZE_GYRO_TEMP_EXT_INIT 0x00 /* Gyro Temperature Extended Data Master Registration Number Initial Value */
-#define VEHICLE_DSIZE_PULSE_TIME_EXT_INIT 0x00 /* Extended data master registration number initial value between pulse time */
-
-#define VEHICLE_DSIZE_GYRO_TROUBLE 0x01
-#define VEHICLE_DSIZE_MAIN_GPS_INTERRUPT_SIGNAL 0x01
-#define VEHICLE_DSIZE_SYS_GPS_INTERRUPT_SIGNAL 0x01
-#define VEHICLE_DSIZE_GYRO_CONNECT_STATUS 0x01
-
-#define VEHICLE_DKEEP_MAX 64 /* Internal data retention count */
-
-/* Data storage location */
-#define VEHICLE_DATA_POS_00 0x00 /* Data storage position 0 */
-#define VEHICLE_DATA_POS_01 0x01 /* Data storage position 1 */
-#endif
-
-#define VEHICLE_DSIZE_GPS_FORMAT 1904
-
-/* ++ PastModel002 support */
-/* GPS_u-blox data size(Up to 208 bytes + 1 byte of sensor counter) */
-#define VEHICLE_DSIZE_GPS_UBLOX_FORMAT 212
-/* ++ PastModel002 support */
-
-/* NMEA data size */
-#define VEHICLE_DSIZE_GPS_NMEA_GGA 71 /* Positioning information(Fixed-length sentence 71 Byte) */
-#define VEHICLE_DSIZE_GPS_NMEA_DGGA 75 /* Double precision GGA - Positioning information(Fixed-length sentence 75 Byte) */
-#define VEHICLE_DSIZE_GPS_NMEA_VTG 37 /* Progress Direction,Velocity information(Fixed-length sentence 37 Byte) */
-#define VEHICLE_DSIZE_GPS_NMEA_RMC 61 /* RMC - Minimal information(Fixed-length sentence 61 Byte) */
-#define VEHICLE_DSIZE_GPS_NMEA_DRMC 67 /* Double RMC - Minimal information(Fixed-length sentence 67 Byte) */
-#define VEHICLE_DSIZE_GPS_NMEA_GLL 44 /* GLL - Geographical locality information(Fixed-length sentence 44 Byte) */
-#define VEHICLE_DSIZE_GPS_NMEA_DGLL 50 /* Double-precision GLL - Geographical locality information(Fixed-length sentence 50 Byte) */
-/* GSA - DOP information and positioning satellite information(Fixed-length sentence 66 Byte) */
-#define VEHICLE_DSIZE_GPS_NMEA_GSA 66
-#define VEHICLE_DSIZE_GPS_NMEA_GSV_1 70 /* GSV - Visual satellite information(Fixed-length sentence 70 Byte) */
-#define VEHICLE_DSIZE_GPS_NMEA_GSV_2 70 /* GSV - Visual satellite information(Fixed-length sentence 70 Byte) */
-#define VEHICLE_DSIZE_GPS_NMEA_GSV_3 70 /* GSV - Visual satellite information(Fixed-length sentence 70 Byte) */
-/* _CWORD44_,GP,3 - Visual satellite reception information */
-#define VEHICLE_DSIZE_GPS_NMEA_PJRDC_GP_3 78
-/* _CWORD44_,GP,4 - Receiver-specific information */
-#define VEHICLE_DSIZE_GPS_NMEA_PJRDC_GP_4 25
-
-/* FULLBINARY data size */
-/* Fully customized output */
-#define VEHICLE_DSIZE_GPS_FULLBINARY GPS_CMD_FULLBIN_SZ
-
-#if CONFIG_HW_PORTSET_TYPE_C
-#define VEHICLE_DSIZE_NMEA 0
-#define VEHICLE_DSIZE_GGA 0x00
-#define VEHICLE_DSIZE_GLL 0x00
-#define VEHICLE_DSIZE_GSA 0x00
-#define VEHICLE_DSIZE_GSV 0x00
-#define VEHICLE_DSIZE_RMC 0x00
-#define VEHICLE_DSIZE_VTG 0x00
-#endif
-
-/* ++ PastModel002 support */
-#define VEHICLE_DSIZE_GPS_UBLOX_HEADER_SIZE 0 /* UBX common header size */
-
-#define VEHICLE_DSIZE_GPS_UBLOX_NAV_CLOCK 0
-#define VEHICLE_DSIZE_GPS_UBLOX_NAV_DOP 0
-#define VEHICLE_DSIZE_GPS_UBLOX_NAV_POSLLH 0
-#define VEHICLE_DSIZE_GPS_UBLOX_NAV_STATUS 0
-#define VEHICLE_DSIZE_GPS_UBLOX_NAV_SVINFO 0 /* 8 + 12*numCh(For variable,Define only the fixed part) */
-#define VEHICLE_DSIZE_GPS_UBLOX_NAV_TIMEGPS 0
-#define VEHICLE_DSIZE_GPS_UBLOX_NAV_TIMEUTC 0
-#define VEHICLE_DSIZE_GPS_UBLOX_NAV_VELNED 0
-#define VEHICLE_DSIZE_GPS_UBLOX_MON_HW 0
-
-#define VEHICLE_DSIZE_SPEED_PULSE_FLAG 0x00
-#define VEHICLE_DSIZE_GPS_INTERRUPT_FLAG 0x00
-
-#define VEHICLE_DSIZE_GPS_UBLOX_NAV_SVINFO_CH_MAX 0 /* Maximum number of NAV_SVINFO channels */
-#define VEHICLE_DSIZE_GPS_UBLOX_NAV_SVINFO_ALONE_MAX 0 /* NAV_SVINFO channel:Maximum Single Data Size */
-/* -- PastModel002 support */
-
-/* Data received*/
-#define VEHICLE_RCVFLAG_ON 0x00
-#define VEHICLE_RCVFLAG_OFF 0x00
-
-/* Upper limit of number of data items stored between pulses */
-#define VEHICLE_SNS_INFO_PULSE_NUM 0
-
-/*------------------------------------------------------------------------------*
- * NMEA reception flag *
- -------------------------------------------------------------------------------*/
-/* Not supported by UBX_Protocol */
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-
-/*********************************************************************
-* TAG : VEHICLESENS_DATA_MASTER
-* ABSTRACT : Vehicle sensor data master structure
-***********************************************************************/
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_snscnt; /* Sensor Counter */
- u_int8 uc_data[132]; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER;
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_reserve; /* Reserved */
- u_int8 uc_data[8448]; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER_EXT;
-
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 partition_flg; /* Fragmented Transmission Flag */
- u_int8 uc_data[VEHICLE_DSIZE_DATA_MASTER_FST]; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER_FST;
-
-#endif
-
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_reserve; /* Reserved */
- u_int8 uc_data[VEHICLE_DSIZE_GPS_FORMAT]; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER_GPS_FORMAT;
-
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_reserve; /* Reserved */
- u_int8 uc_data[VEHICLE_DSIZE_SIRF_BINARY]; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER_GPS_BINARY;
-
-/* ++ GPS _CWORD82_ support */
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_reserve; /* Reserved */
- u_int8 uc_data[VEHICLE_DSIZE_GPS__CWORD82__NMEA]; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER_GPS_NMEA_FORMAT;
-
-/* -- GPS _CWORD82_ support */
-#if CONFIG_HW_PORTSET_TYPE_C
-
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_reserve; /* Reserved */
- u_int8 uc_data[VEHICLE_DSIZE_NMEA]; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER_GPS_NMEA;
-#endif
-
-/* ++ PastModel002 support */
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_sensor_cnt; /* Sensor Counter */
- u_int8 uc_gpscnt_flag; /* GPS counter flag */
- u_int8 reserve[3]; /* reserve */
- u_int8 uc_data[VEHICLE_DSIZE_GPS_UBLOX_FORMAT]; /* UBLOX_GPS data */
-} VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT;
-
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_reserve; /* Reserved */
- u_int8 uc_data; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER_GYRO_TROUBLE;
-
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_reserve; /* Reserved */
- u_int8 uc_data; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL;
-
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_reserve; /* Reserved */
- u_int8 uc_data; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER_GYRO_CONNECT_STATUS;
-
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_size; /* Size of the data */
- u_int8 uc_rcvflag; /* Receive flag */
- u_int8 uc_sensor_cnt; /* Sensor Counter */
- u_int8 uc_data; /* Vehicle sensor data */
-} VEHICLESENS_DATA_MASTER_GPS_ANTENNA_STATUS;
-
-/* ++ PastModel002 support */
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*********************************************************************
-* TAG : VEHICLESENS_PKG_DELIVERY_TEMP_EXT
-* ABSTRACT : Structure of Vehicle Sensor Initial Delivery Management Table
-***********************************************************************/
-typedef struct {
- u_int16 us_gyro[10]; /* Gyro output */
- u_int16 us_sp_pls[10]; /* Vehicle speed pulse */
- u_int8 uc_sens_cnt; /* Sensor Counter */
- u_int8 uc_reserve[3]; /* reserve */
-} VEHICLESENS_PKG_DELIVERY_TEMP_TBL;
-
-// for VEHICLESENS_PKG_DELIVERY_TEMP_EXT.start_point index
-enum VEHICLESENS_PKG_INDEX {
- SNSCounter = 0,
- SpeedPulse,
- GyroExt,
- GsnsX,
- GsnsY,
- Rev,
- GyroTemp,
- PulseTime,
- GyroY,
- GyroZ,
- GsnsZ,
- MAX
-};
-
-typedef struct {
- uint16_t start_point[8]; /* Sequence reference start position */
- uint16_t end_point; /* Array registration completion position */
- uint16_t data_break; /* All data undelivered flag */
-} VEHICLESENS_PKG_DELIVERY_TEMP_EXT;
-
-/************************************************************************
-* External variable *
-************************************************************************/
-extern VEHICLESENS_PKG_DELIVERY_TEMP_EXT gstPkgTempExt; // NOLINT(readability/nolint)
-#endif
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-void VehicleSensInitDataMaster(void);
-void VehicleSensSetDataMasterLineSens(const LSDRV_LSDATA *, PFUNC_DMASTER_SET_N func, BOOL);
-void VehicleSensSetDataMasterLineSensG(const LSDRV_LSDATA_G *, PFUNC_DMASTER_SET_N func, BOOL);
-void VehicleSensSetDataMasterGps(SENSOR_MSG_GPSDATA_DAT *, PFUNC_DMASTER_SET_N func);
-void VehicleSensGetDataMaster(DID ul_did, u_int8, VEHICLESENS_DATA_MASTER *);
-void VehicleSensGetGpsDataMaster(DID ul_did, u_int8, SENSOR_MSG_GPSDATA_DAT *);
-void VehicleSensSetDataMasterData(const POS_MSGINFO *, PFUNC_DMASTER_SET_N func);
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-void VehicleSensSetDataMasterLineSensFst(const LSDRV_LSDATA_FST *pst_data, PFUNC_DMASTER_SET_N p_data_master_set_n);
-void VehicleSensSetDataMasterLineSensFstG(const LSDRV_MSG_LSDATA_DAT_FST *pst_data,
- PFUNC_DMASTER_SET_N p_data_master_set_n);
-void VehicleSensGetDataMasterFst(DID ul_did, u_int8, VEHICLESENS_DATA_MASTER_FST *);
-void VehicleSensGetDataMasterExt(DID ul_did, u_int8, VEHICLESENS_DATA_MASTER_EXT *);
-#endif
-
-void VehicleSensSetDataMasterGyroTrouble(const LSDRV_MSG_LSDATA_DAT_GYRO_TROUBLE *pst_data,
- PFUNC_DMASTER_SET_N p_data_master_set_n);
-void VehicleSensSetDataMasterSysGpsInterruptSignal(const LSDRV_MSG_LSDATA_DAT_GPS_INTERRUPT_SIGNAL *pst_data,
- PFUNC_DMASTER_SET_SHARED_MEMORY p_data_master_set_shared_memory);
-void VehicleSensSetDataMasterMainGpsInterruptSignal(const SENSOR_MSG_GPSDATA_DAT *pst_data,
- PFUNC_DMASTER_SET_SHARED_MEMORY p_data_master_set_shared_memory);
-void VehicleSensSetDataMasterGyroConnectStatus(const LSDRV_MSG_LSDATA_DAT_GYRO_CONNECT_STATUS *pst_data,
- PFUNC_DMASTER_SET_SHARED_MEMORY p_data_master_set_shared_memory);
-void VehicleSensSetDataMasterGpsAntennaStatus(const LSDRV_MSG_LSDATA_DAT_GPS_ANTENNA_STATUS *pst_data,
- PFUNC_DMASTER_SET_N p_data_master_set_n);
-
-void VehicleSensGetDataMasterGyroTrouble(DID ul_did, u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_GYRO_TROUBLE *pst_data);
-void VehicleSensGetDataMasterSysGpsInterruptSignal(DID ul_did, u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_data);
-void VehicleSensGetDataMasterMainGpsInterruptSignal(DID ul_did, u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_data);
-void VehicleSensGetDataMasterGyroConnectStatus(DID ul_did, u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_GYRO_CONNECT_STATUS *pst_data);
-void VehicleSensGetDataMasterGpsAntennaStatus(DID ul_did, u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_GPS_ANTENNA_STATUS *pst_data);
-
-void VehicleSensGetGsnsX(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitGsnsXl(void);
-u_int8 VehicleSensSetGsnsXl(const LSDRV_LSDATA *);
-void VehicleSensGetGsnsXl(VEHICLESENS_DATA_MASTER *);
-u_int8 VehicleSensSetGsnsXlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGsnsXFst(VEHICLESENS_DATA_MASTER_FST *, u_int8);
-void VehicleSensInitGsnsXFstl(void);
-u_int8 VehicleSensSetGsnsXFstG(const LSDRV_LSDATA_FST_GSENSOR_X *pst_data);
-void VehicleSensGetGsnsXFstl(VEHICLESENS_DATA_MASTER_FST *pst_data);
-
-void VehicleSensGetGsnsY(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitGsnsYl(void);
-u_int8 VehicleSensSetGsnsYl(const LSDRV_LSDATA *);
-void VehicleSensGetGsnsYl(VEHICLESENS_DATA_MASTER *);
-u_int8 VehicleSensSetGsnsYlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGsnsYFst(VEHICLESENS_DATA_MASTER_FST *, u_int8);
-void VehicleSensInitGsnsYFstl(void);
-u_int8 VehicleSensSetGsnsYFstG(const LSDRV_LSDATA_FST_GSENSOR_Y *pst_data);
-void VehicleSensGetGsnsYFstl(VEHICLESENS_DATA_MASTER_FST *pst_data);
-
-void VehicleSensGetGsnsZ(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitGsnsZl(void);
-u_int8 VehicleSensSetGsnsZl(const LSDRV_LSDATA *);
-void VehicleSensGetGsnsZl(VEHICLESENS_DATA_MASTER *);
-u_int8 VehicleSensSetGsnsZlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGsnsZFst(VEHICLESENS_DATA_MASTER_FST *, u_int8);
-void VehicleSensInitGsnsZFstl(void);
-u_int8 VehicleSensSetGsnsZFstG(const LSDRV_LSDATA_FST_GSENSOR_Z *pst_data);
-void VehicleSensGetGsnsZFstl(VEHICLESENS_DATA_MASTER_FST *pst_data);
-
-void VehicleSensGetGyroX(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitGyroXl(void);
-u_int8 VehicleSensSetGyroXl(const LSDRV_LSDATA *);
-u_int8 VehicleSensSetGyroXlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGyroXl(VEHICLESENS_DATA_MASTER *);
-
-void VehicleSensGetGyroY(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitGyroYl(void);
-u_int8 VehicleSensSetGyroYl(const LSDRV_LSDATA *);
-u_int8 VehicleSensSetGyroYlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGyroYl(VEHICLESENS_DATA_MASTER *);
-
-void VehicleSensGetGyroZ(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitGyroZl(void);
-u_int8 VehicleSensSetGyroZl(const LSDRV_LSDATA *);
-u_int8 VehicleSensSetGyroZlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGyroZl(VEHICLESENS_DATA_MASTER *);
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-void VehicleSensGetSpeedPulseFst(VEHICLESENS_DATA_MASTER_FST *, u_int8);
-void VehicleSensInitSpeedPulseFstl(void);
-u_int8 VehicleSensSetSpeedPulseFstl(const LSDRV_LSDATA_FST *);
-u_int8 VehicleSensSetSpeedPulseFstG(const LSDRV_LSDATA_FST_SPEED *);
-void VehicleSensGetSpeedPulseFstl(VEHICLESENS_DATA_MASTER_FST *);
-
-void VehicleSensGetGyroXFst(VEHICLESENS_DATA_MASTER_FST *, u_int8);
-void VehicleSensInitGyroXFstl(void);
-u_int8 VehicleSensSetGyroXFstl(const LSDRV_LSDATA_FST *);
-u_int8 VehicleSensSetGyroXFstG(const LSDRV_LSDATA_FST_GYRO_X *);
-void VehicleSensGetGyroXFstl(VEHICLESENS_DATA_MASTER_FST *);
-
-void VehicleSensGetGyroYFst(VEHICLESENS_DATA_MASTER_FST *, u_int8);
-void VehicleSensInitGyroYFstl(void);
-u_int8 VehicleSensSetGyroYFstl(const LSDRV_LSDATA_FST *);
-u_int8 VehicleSensSetGyroYFstG(const LSDRV_LSDATA_FST_GYRO_Y *);
-void VehicleSensGetGyroYFstl(VEHICLESENS_DATA_MASTER_FST *);
-
-void VehicleSensGetGyroYExt(VEHICLESENS_DATA_MASTER_EXT *, u_int8);
-void VehicleSensInitGyroYExtl(void);
-void VehicleSensSetGyroYExtlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGyroYExtl(VEHICLESENS_DATA_MASTER_EXT *);
-
-void VehicleSensGetGyroZFst(VEHICLESENS_DATA_MASTER_FST *, u_int8);
-void VehicleSensInitGyroZFstl(void);
-u_int8 VehicleSensSetGyroZFstl(const LSDRV_LSDATA_FST *);
-u_int8 VehicleSensSetGyroZFstG(const LSDRV_LSDATA_FST_GYRO_Z *);
-void VehicleSensGetGyroZFstl(VEHICLESENS_DATA_MASTER_FST *);
-
-void VehicleSensGetGyroZExt(VEHICLESENS_DATA_MASTER_EXT *, u_int8);
-void VehicleSensInitGyroZExtl(void);
-void VehicleSensSetGyroZExtlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGyroZExtl(VEHICLESENS_DATA_MASTER_EXT *);
-
-void VehicleSensGetSpeedPulseFlagFst(VEHICLESENS_DATA_MASTER_FST *, u_int8);
-void VehicleSensInitSpeedPulseFlagFstl(void);
-u_int8 VehicleSensSetSpeedPulseFlagFstl(const LSDRV_LSDATA_FST *);
-u_int8 VehicleSensSetSpeedPulseFlagFstG(const LSDRV_LSDATA_FST_SPEED_PULSE_FLAG *);
-void VehicleSensGetSpeedPulseFlagFstl(VEHICLESENS_DATA_MASTER_FST *);
-
-void VehicleSensGetRevFst(VEHICLESENS_DATA_MASTER_FST *, u_int8);
-void VehicleSensInitRevFstl(void);
-u_int8 VehicleSensSetRevFstl(const LSDRV_LSDATA_FST *);
-u_int8 VehicleSensSetRevFstG(const LSDRV_LSDATA_FST_REV *);
-void VehicleSensGetRevFstl(VEHICLESENS_DATA_MASTER_FST *);
-
-void VehicleSensGetGsnsXExt(VEHICLESENS_DATA_MASTER_EXT *, u_int8);
-void VehicleSensInitGsnsXExtl(void);
-void VehicleSensSetGsnsXExtl(const LSDRV_LSDATA *);
-void VehicleSensSetGsnsXExtlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGsnsXExtl(VEHICLESENS_DATA_MASTER_EXT *);
-
-void VehicleSensGetGsnsYExt(VEHICLESENS_DATA_MASTER_EXT *, u_int8);
-void VehicleSensInitGsnsYExtl(void);
-void VehicleSensSetGsnsYExtl(const LSDRV_LSDATA *);
-void VehicleSensSetGsnsYExtlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGsnsYExtl(VEHICLESENS_DATA_MASTER_EXT *);
-
-void VehicleSensGetGsnsZExt(VEHICLESENS_DATA_MASTER_EXT *, u_int8);
-void VehicleSensInitGsnsZExtl(void);
-void VehicleSensSetGsnsZExtl(const LSDRV_LSDATA *);
-void VehicleSensSetGsnsZExtlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGsnsZExtl(VEHICLESENS_DATA_MASTER_EXT *);
-
-void VehicleSensGetGyroExt(VEHICLESENS_DATA_MASTER_EXT *, u_int8);
-void VehicleSensInitGyroExtl(void);
-void VehicleSensSetGyroExtl(const LSDRV_LSDATA *);
-void VehicleSensSetGyroExtlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGyroExtl(VEHICLESENS_DATA_MASTER_EXT *);
-
-void VehicleSensGetGyroRev(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitGyroRevl(void);
-u_int8 VehicleSensSetGyroRevl(const LSDRV_LSDATA *);
-u_int8 VehicleSensSetGyroRevlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetGyroRevl(VEHICLESENS_DATA_MASTER *);
-
-void VehicleSensGetSpeedPulseExt(VEHICLESENS_DATA_MASTER_EXT *, u_int8);
-void VehicleSensInitSpeedPulseExtl(void);
-void VehicleSensSetSpeedPulseExtl(const LSDRV_LSDATA *);
-void VehicleSensSetSpeedPulseExtlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetSpeedPulseExtl(VEHICLESENS_DATA_MASTER_EXT *);
-
-void VehicleSensGetSnsCounterExt(VEHICLESENS_DATA_MASTER_EXT *, u_int8);
-void VehicleSensInitSnsCounterExtl(void);
-void VehicleSensSetSnsCounterExtl(const LSDRV_LSDATA *);
-void VehicleSensSetSnsCounterExtlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetSnsCounterExtl(VEHICLESENS_DATA_MASTER_EXT *);
-
-void VehicleSensGetRevExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method);
-void VehicleSensGetRevExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data);
-void VehicleSensInitRevExtl(void);
-void VehicleSensSetRevExtlG(const LSDRV_LSDATA_G *pst_data);
-
-#endif
-
-void VehicleSensGetSpeedKmph(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitSpeedKmphl(void);
-u_int8 VehicleSensSetSpeedKmphl(const LSDRV_LSDATA *);
-u_int8 VehicleSensSetSpeedKmphlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetSpeedKmphl(VEHICLESENS_DATA_MASTER *);
-
-void VehicleSensGetGyroTemp(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method);
-void VehicleSensInitGyroTempl(void);
-u_int8 VehicleSensSetGyroTemplG(const LSDRV_LSDATA_G *pst_data);
-void VehicleSensGetGyroTempl(VEHICLESENS_DATA_MASTER *pst_data);
-
-void VehicleSensGetGyroTempFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method);
-void VehicleSensInitGyroTempFstl(void);
-u_int8 VehicleSensSetGyroTempFstG(const LSDRV_LSDATA_FST_GYRO_TEMP *pst_data);
-void VehicleSensGetGyroTempFstl(VEHICLESENS_DATA_MASTER_FST *pst_data);
-
-void VehicleSensGetGyroTempExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method);
-void VehicleSensInitGyroTempExtl(void);
-void VehicleSensSetGyroTempExtlG(const LSDRV_LSDATA_G *pst_data);
-void VehicleSensGetGyroTempExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data);
-
-void VehicleSensGetPulseTime(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method);
-void VehicleSensInitPulseTimel(void);
-u_int8 VehicleSensSetPulseTimelG(const LSDRV_LSDATA_G *pst_data);
-void VehicleSensGetPulseTimel(VEHICLESENS_DATA_MASTER *pst_data);
-
-void VehicleSensGetPulseTimeExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method);
-void VehicleSensInitPulseTimeExtl(void);
-void VehicleSensSetPulseTimeExtlG(const LSDRV_LSDATA_G *pst_data);
-void VehicleSensGetPulseTimeExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data);
-
-void VehicleSensGetRev(VEHICLESENS_DATA_MASTER *, u_int8);
-
-void VehicleSensInitRevl(void);
-u_int8 VehicleSensSetRevl(const LSDRV_LSDATA *);
-void VehicleSensGetRevl(VEHICLESENS_DATA_MASTER *);
-u_int8 VehicleSensSetRevlG(const LSDRV_LSDATA_G *pst_data);
-void VehicleSensGetRevline(VEHICLESENS_DATA_MASTER *);
-
-void VehicleSensGetSpeedPulse(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitSpeedPulsel(void);
-u_int8 VehicleSensSetSpeedPulsel(const LSDRV_LSDATA *);
-u_int8 VehicleSensSetSpeedPulselG(const LSDRV_LSDATA_G *);
-void VehicleSensGetSpeedPulsel(VEHICLESENS_DATA_MASTER *);
-
-void VehicleSensGetGpsAntenna(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitGpsAntennal(void);
-u_int8 VehicleSensSetGpsAntennal(const LSDRV_LSDATA *);
-void VehicleSensGetGpsAntennal(VEHICLESENS_DATA_MASTER *);
-
-void VehicleSensGetSnsCounter(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitSnsCounterl(void);
-u_int8 VehicleSensSetSnsCounterl(const LSDRV_LSDATA *);
-u_int8 VehicleSensSetSnsCounterlG(const LSDRV_LSDATA_G *);
-void VehicleSensGetSnsCounterl(VEHICLESENS_DATA_MASTER *);
-
-void VehicleSensInitGpsCounterg(void);
-u_int8 VehicleSensSetGpsCounterg(const SENSOR_MSG_GPSDATA_DAT *);
-void VehicleSensGetGpsCounterg(SENSOR_MSG_GPSDATA_DAT *);
-
-/* ++ PastModel002 support */
-/* U-BLOX_GPS MON-HW */
-void VehicleSensInitMonHwG(void);
-u_int8 VehicleSensSetMonHwG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetMonHwG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* U-BLOX_GPS NAV-CLOCK */
-void VehicleSensInitNavClockG(void);
-u_int8 VehicleSensSetNavClockG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetNavClockG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* U-BLOX_GPS NAV-DOP */
-void VehicleSensInitNavDopG(void);
-u_int8 VehicleSensSetNavDopG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetNavDopG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* U-BLOX_GPS NAV-POSLLH */
-void VehicleSensInitNavPosllhG(void);
-u_int8 VehicleSensSetNavPosllhG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetNavPosllhG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* U-BLOX_GPS NAV-STATUS */
-void VehicleSensInitNavStatusG(void);
-u_int8 VehicleSensSetNavStatusG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetNavStatusG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* U-BLOX_GPS NAV-SVINFO */
-void VehicleSensInitNavSvInfoG(void);
-u_int8 VehicleSensSetNavSvInfoG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetNavSvInfoG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* U-BLOX_GPS NAV-TIMEGPS */
-void VehicleSensInitNavTimeGpsG(void);
-u_int8 VehicleSensSetNavTimeGpsG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetNavTimeGpsG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* U-BLOX_GPS NAV-TIMEUTC */
-void VehicleSensInitNavTimeUtcG(void);
-u_int8 VehicleSensSetNavTimeUtcG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetNavTimeUtcG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* U-BLOX_GPS NAV-VELNED */
-void VehicleSensInitNavVelnedG(void);
-u_int8 VehicleSensSetNavVelnedG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetNavVelnedG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* DR SPEED_PULSE_FLAG */
-void VehicleSensInitSpeedPulseFlag(void);
-u_int8 VehicleSensSetSpeedPulseFlag(const LSDRV_LSDATA_G *pst_data);
-void VehicleSensGetSpeedPulseFlag(VEHICLESENS_DATA_MASTER *);
-
-/* DR GPS_INTERRUPT_FLAG */
-void VehicleSensInitGpsInterruptFlag(void);
-u_int8 VehicleSensSetGpsInterruptFlag(const LSDRV_LSDATA_G *pst_data);
-void VehicleSensGetGpsInterruptFlag(VEHICLESENS_DATA_MASTER *);
-
-/* GYRO_TROUBLE */
-void VehicleSensInitGyroTrouble(void);
-u_int8 VehicleSensSetGyroTrouble(const LSDRV_MSG_LSDATA_DAT_GYRO_TROUBLE *pst_data);
-void VehicleSensGetGyroTrouble(VEHICLESENS_DATA_MASTER_GYRO_TROUBLE *pst_data);
-
-/* MAIN_GPS_INTERRUPT_SIGNAL */
-void VehicleSensInitMainGpsInterruptSignal(void);
-u_int8 VehicleSensSetMainGpsInterruptSignal(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetMainGpsInterruptSignal(VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_data);
-
-/* SYS_GPS_INTERRUPT_SIGNAL */
-void VehicleSensInitSysGpsInterruptSignal(void);
-u_int8 VehicleSensSetSysGpsInterruptSignal(const LSDRV_MSG_LSDATA_DAT_GPS_INTERRUPT_SIGNAL *pst_data);
-void VehicleSensGetSysGpsInterruptSignal(VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_data);
-
-/* GYRO_CONNECT_STATUS */
-void VehicleSensInitGyroConnectStatus(void);
-u_int8 VehicleSensSetGyroConnectStatus(const LSDRV_MSG_LSDATA_DAT_GYRO_CONNECT_STATUS *pst_data);
-void VehicleSensGetGyroConnectStatus(VEHICLESENS_DATA_MASTER_GYRO_CONNECT_STATUS *pst_data);
-
-/* GPS_ANTENNA_STATUS */
-void VehicleSensInitGpsAntennaStatus(void);
-u_int8 VehicleSensSetGpsAntennaStatus(const LSDRV_MSG_LSDATA_DAT_GPS_ANTENNA_STATUS *pst_data);
-void VehicleSensGetGpsAntennaStatus(VEHICLESENS_DATA_MASTER_GPS_ANTENNA_STATUS *pst_data);
-
-/* -- PastModel002 support */
-
-/* GPS__CWORD82__FULLBINARY */
-void VehicleSensInitGps_CWORD82_FullBinaryG(void);
-u_int8 VehicleSensSetGps_CWORD82_FullBinaryG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetGps_CWORD82_FullBinaryG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* GPS__CWORD82__FULLBINARY */
-void VehicleSensInitGps_CWORD82__CWORD44_Gp4G(void);
-u_int8 VehicleSensSetGps_CWORD82__CWORD44_Gp4G(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetGps_CWORD82__CWORD44_Gp4G(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* GPS__CWORD82__NMEA */
-void VehicleSensInitGps_CWORD82_NmeaG(void);
-u_int8 VehicleSensSetGps_CWORD82_NmeaG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetGps_CWORD82_NmeaG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* GPS_NMEA */
-void VehicleSensInitGpsNmeaG(void);
-u_int8 VehicleSensSetGpsNmeaG(const SENSOR_MSG_GPSDATA_DAT *pst_data);
-void VehicleSensGetGpsNmeaG(SENSOR_MSG_GPSDATA_DAT *pst_data);
-
-/* LOCATION_LONLAT */
-void VehicleSensGetLocationLonLat(VEHICLESENS_DATA_MASTER *pst_data, u_int8);
-void VehicleSensInitLocationLonLatG(void);
-u_int8 VehicleSensSetLocationLonLatG(const SENSORLOCATION_LONLATINFO_DAT*);
-void VehicleSensGetLocationLonLatG(VEHICLESENS_DATA_MASTER*);
-void VehicleSensInitLocationLonLatN(void);
-u_int8 VehicleSensSetLocationLonLatN(const SENSORLOCATION_LONLATINFO_DAT*);
-void VehicleSensGetLocationLonLatN(VEHICLESENS_DATA_MASTER*);
-void VehicleSensGetLocationLonLatnUnitCnv(VEHICLESENS_DATA_MASTER*);
-
-/* LOCATION_ALTITUDE */
-void VehicleSensGetLocationAltitude(VEHICLESENS_DATA_MASTER *pst_data, u_int8);
-void VehicleSensInitLocationAltitudeG(void);
-u_int8 VehicleSensSetLocationAltitudeG(const SENSORLOCATION_ALTITUDEINFO_DAT*);
-void VehicleSensGetLocationAltitudeG(VEHICLESENS_DATA_MASTER*);
-void VehicleSensInitLocationAltitudeN(void);
-u_int8 VehicleSensSetLocationAltitudeN(const SENSORLOCATION_ALTITUDEINFO_DAT*);
-void VehicleSensGetLocationAltitudeN(VEHICLESENS_DATA_MASTER*);
-
-/* MOTION_SPEED */
-void VehicleSensGetMotionSpeed(VEHICLESENS_DATA_MASTER *pst_data, u_int8);
-void VehicleSensInitMotionSpeedG(void);
-u_int8 VehicleSensSetMotionSpeedG(const SENSORMOTION_SPEEDINFO_DAT*);
-void VehicleSensGetMotionSpeedG(VEHICLESENS_DATA_MASTER*);
-void VehicleSensInitMotionSpeedN(void);
-u_int8 VehicleSensSetMotionSpeedN(const SENSORMOTION_SPEEDINFO_DAT*);
-void VehicleSensGetMotionSpeedN(VEHICLESENS_DATA_MASTER*);
-void VehicleSensInitMotionSpeedI(void);
-u_int8 VehicleSensSetMotionSpeedI(const SENSORMOTION_SPEEDINFO_DAT*);
-void VehicleSensGetMotionSpeedI(VEHICLESENS_DATA_MASTER*);
-
-/* MOTION_HEADING */
-void VehicleSensGetMotionHeading(VEHICLESENS_DATA_MASTER *pst_data, u_int8);
-void VehicleSensInitMotionHeadingG(void);
-u_int8 VehicleSensSetMotionHeadingG(const SENSORMOTION_HEADINGINFO_DAT*);
-void VehicleSensGetMotionHeadingG(VEHICLESENS_DATA_MASTER*);
-void VehicleSensInitMotionHeadingN(void);
-u_int8 VehicleSensSetMotionHeadingN(const SENSORMOTION_HEADINGINFO_DAT*);
-void VehicleSensGetMotionHeadingN(VEHICLESENS_DATA_MASTER*);
-void VehicleSensGetMotionHeadingnCnvData(VEHICLESENS_DATA_MASTER*);
-
-/* GPS_TIME */
-void VehicleSensGetGpsTime(SENSOR_MSG_GPSDATA_DAT*, u_int8);
-void VehicleSensInitGpsTimeG(void);
-u_int8 VehicleSensSetGpsTimeG(const SENSOR_MSG_GPSTIME*);
-void VehicleSensGetGpsTimeG(SENSOR_MSG_GPSDATA_DAT*);
-
-/* GPS_TIME_RAW */
-void VehicleSensGetGpsTimeRaw(SENSOR_MSG_GPSDATA_DAT*, u_int8);
-void VehicleSensInitGpsTimeRawG(void);
-u_int8 VehicleSensSetGpsTimeRawG(const SENSOR_GPSTIME_RAW*);
-void VehicleSensGetGpsTimeRawG(SENSOR_MSG_GPSDATA_DAT*);
-
-/* GPS_WKNROLLOVER */
-void VehicleSensGetWknRollover(VEHICLESENS_DATA_MASTER*, u_int8);
-void VehicleSensInitWknRolloverG(void);
-u_int8 VehicleSensSetWknRolloverG(const SENSOR_WKNROLLOVER*);
-void VehicleSensGetWknRolloverG(SENSOR_MSG_GPSDATA_DAT*);
-
-/* DIAG_GPS */
-void VehicleSensInitNaviinfoDiagGPSg(void);
-u_int8 VehicleSensSetNaviinfoDiagGPSg(const NAVIINFO_DIAG_GPS*);
-void VehicleSensGetNaviinfoDiagGPSg(SENSOR_MSG_GPSDATA_DAT*);
-
-/* SETTINGTIME */
-void VehicleSensGetSettingTime(VEHICLESENS_DATA_MASTER *, u_int8);
-void VehicleSensInitSettingTimeclock(void);
-u_int8 VehicleSensSetSettingTimeclock(const POS_DATETIME*);
-void VehicleSensGetSettingTimeclock(VEHICLESENS_DATA_MASTER*);
-
-/* GPS_CLOCK_DRIFT */
-void VehicleSensGetGpsClockDrift(SENSOR_MSG_GPSDATA_DAT *, u_int8);
-void VehicleSensInitGpsClockDriftG(void);
-u_int8 VehicleSensSetGpsClockDriftG(const int32_t*);
-void VehicleSensGetGpsClockDriftG(SENSOR_MSG_GPSDATA_DAT*);
-
-/* GPS_CLOCK_FREQ */
-void VehicleSensGetGpsClockFreq(SENSOR_MSG_GPSDATA_DAT *, u_int8);
-void VehicleSensInitGpsClockFreqG(void);
-u_int8 VehicleSensSetGpsClockFreqG(const uint32_t*);
-void VehicleSensGetGpsClockFreqG(SENSOR_MSG_GPSDATA_DAT*);
-
-/* LOCATION INFORMATION (NMEA) */
-void VehicleSens_GetLocationInfoNmea(VEHICLESENS_DATA_MASTER_GPS_FORMAT *, u_int8 );
-void VehicleSens_InitLocationInfoNmea_n(void);
-u_int8 VehicleSens_SetLocationInfoNmea_n( const POS_LOCATIONINFO_NMEA * );
-void VehicleSens_GetLocationInfoNmea_n(VEHICLESENS_DATA_MASTER_GPS_FORMAT * );
-
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_DATAMASTER_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/VehicleSens_DeliveryCtrl.h b/vehicleservice/positioning/server/include/Sensor/VehicleSens_DeliveryCtrl.h
deleted file mode 100755
index 3fb7056..0000000
--- a/vehicleservice/positioning/server/include/Sensor/VehicleSens_DeliveryCtrl.h
+++ /dev/null
@@ -1,253 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_DELIVERYCTRL_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_DELIVERYCTRL_H_
-/******************************************************************************
- * File name :VehicleSens_DeliveryCtrl.h
- * System name :_CWORD107_
- * Subsystem name :
- ******************************************************************************/
-
-#include "Vehicle_API_Dummy.h"
-#include "Sensor_API.h"
-#include "Vehicle_API_private.h"
-#include "Sensor_API_private.h"
-#include "VehicleSens_SelectionItemList.h"
-#include "VehicleSens_DataMaster.h"
-#include "Dead_Reckoning_Local_Api.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-#define VEHICLESENS_CANID_EFFECTIVE 29 /* CAN ID Effective number */
-#define VEHICLESENS_CANID_RESERVE 11 /* CAN ID Reserved number */
-#define VEHICLESENS_SIGNAL VEHICLESENS_SELECTION_ITEM_LIST_LEN /* Number of vehicle signals */
-#define VEHICLESENS_DELIVERY 10 /* Number of delivery destinations */
-/* CAN ID Maximum number */
-#define VEHICLESENS_CANID_MAX (VEHICLESENS_CANID_EFFECTIVE + VEHICLESENS_CANID_RESERVE)
-/* Vehicle sensor information */
-#define VEHICLESENS_DELIVERY_INFO (VEHICLESENS_CANID_MAX + VEHICLESENS_SIGNAL)
-/* Maximum number of vehicle sensor information */
-#define VEHICLESENS_DELIVERY_INFO_MAX (VEHICLESENS_DELIVERY_INFO * VEHICLESENS_DELIVERY)
-/* Vehicle Sensor Information Valid Number */
-#define VEHICLESENS_DID_EFFECTIVE (VEHICLESENS_CANID_EFFECTIVE + VEHICLESENS_SIGNAL)
-#define VEHICLESENS_ACTION_TYPE_ADD 0 /* Vehicle sensor addition processing */
-#define VEHICLESENS_ACTION_TYPE_UPDATE 1 /* Vehicle sensor update processing */
-#define VEHICLESENS_LINK_INDEX_END 0xFFFF /* End of the link index */
-
-
-#define VEHICLESENS_PKG_DELIVERY_INFO_MAX 2560 /* Maximum number of vehicle sensor information */
-#define VEHICLESENS_DELIVERY_METHOD_NORMAL 0 /* Delivery system normal delivery */
-#define VEHICLESENS_DELIVERY_METHOD_PACKAGE 1 /* Delivery system package delivery */
-#define VEHICLESENS_PKG_EXT_SEND_MAX 10 /* Number of data master transmissions/onece */
-#define VEHICLESENS_PKG_EXT_SEND_MAX_10DATA 100 /* Number of data masters transmitted (GYRO),SPEED)/once */
-
-#define VEHICLESENS_DELIVERY_MAX_SIZE SENSOR_MSG_VSINFO_DSIZE /* Maximum Size of Delivery */
-#define VEHICLESENS_DELIVERY_FSTSNS_HDR_SIZE 8 /* Initial Sensor Data Delivery Data Header Size */
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-/*********************************************************************
-* TAG : VEHICLESENS_DELIVERY_LIST_CANID
-* ABSTRACT : CAN data delivery registration request information
-***********************************************************************/
-typedef struct {
- u_int8 uc_can_num; /* CANID delivery registrations */
- u_int8 uc_reserve[3];
- u_int32 ul_can_id[VEHICLESENS_CANID_MAX]; /* Delivery registrationCANID */ /* CANIF_API deletion */
-} VEHICLESENS_DELIVERY_LIST_CANID;
-
-/*********************************************************************
-* TAG :VEHICLESENS_DELIVERY_CTRL_TBL_DATA
-* ABSTRACT : Structure of each data of the vehicle sensor delivery destination management table
-***********************************************************************/
-typedef struct {
- DID ul_did; /* Data ID */
- PNO us_pno; /* Shipping PID */
- u_int8 uc_chg_type; /* Delivery timing */
- u_int8 uc_ctrl_flg; /* Delivery operation */
- u_int16 us_link_idx; /* Link index */
- u_int16 us_pkg_start_idx; /* Package Delivery Start Index */
- u_int16 us_pkg_end_idx; /* Package delivery end index */
- u_int8 uc_method; /* Delivery system */
- u_int8 uc_reserve; /* reserve */
- /* Modify to store the destination service name TODO */
- /* Add handles as needed TODO */
-} VEHICLESENS_DELIVERY_CTRL_TBL_DATA;
-
-/*********************************************************************
-* TAG : VEHICLESENS_DELIVERY_CTRL_TBL
-* ABSTRACT : Vehicle Sensor Delivery Destination Management Table Structure
-***********************************************************************/
-typedef struct {
- u_int16 us_dnum; /* Number of delivery destination management data items */
- u_int8 uc_reserve[2]; /* Reserved */
- /* Array of each data */
- VEHICLESENS_DELIVERY_CTRL_TBL_DATA st_ctrl_data[VEHICLESENS_DELIVERY_INFO_MAX];
-} VEHICLESENS_DELIVERY_CTRL_TBL;
-
-/*********************************************************************
-* TAG : VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA
-* ABSTRACT : Structure of each data of Vehicle Sensor Destination Management Table Management
-***********************************************************************/
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 us_start_idx; /* Start index */
- u_int16 us_end_idx; /* End index */
- u_int16 usdlvry_entry_num; /* Number of registered shipping addresses */
- u_int8 uc_reserve[2]; /* Reserved */
-} VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA;
-
-/*********************************************************************
-* TAG : VEHICLESENS_DELIVERY_CTRL_TBL_MNG
-* ABSTRACT : Structure of Vehicle Sensor Delivery Destination Management Table Management
-***********************************************************************/
-typedef struct {
- u_int16 us_dnum; /* Number of data items */
- u_int8 uc_reserve[2]; /* Reserved */
- /* Array of each data */
- VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA st_ctrl_tbl_mng_data[VEHICLESENS_DELIVERY_INFO];
-} VEHICLESENS_DELIVERY_CTRL_TBL_MNG;
-
-/*********************************************************************
-* TAG : VEHICLESENS_PKG_DELIVERY_TBL_MNG_DATA
-* ABSTRACT : Structure of each data of the vehicle sensor package delivery management table
-***********************************************************************/
-typedef struct {
- DID ul_did; /* Data ID */
- u_int16 usdlvry_idx; /* Delivery data index */
- u_int8 uc_reserve[2]; /* Reserved */
-} VEHICLESENS_PKG_DELIVERY_TBL_MNG_DATA;
-
-
-/*********************************************************************
-* TAG : VEHICLESENS_PKG_DELIVERY_TBL_MNG
-* ABSTRACT : Structure of Vehicle Sensor Package Delivery Management Table
-***********************************************************************/
-typedef struct {
- u_int16 us_dnum; /* Number of data items */
- u_int8 uc_reserve[2]; /* Reserved */
- /* Array of each data */
- VEHICLESENS_PKG_DELIVERY_TBL_MNG_DATA st_pkg_data[VEHICLESENS_PKG_DELIVERY_INFO_MAX];
-} VEHICLESENS_PKG_DELIVERY_TBL_MNG;
-
-/*********************************************************************
-* TAG : VEHICLESENS_DELIVERY_PNO_TBL
-* ABSTRACT : Vehicle Sensor Destination PNO Table
-***********************************************************************/
-typedef struct {
- PNO us_pno; /* Thread ID */
- u_int16 us_pkg_start_idx; /* Package Delivery Start Index */
- u_int16 us_pkg_end_idx; /* Package delivery end index */
- u_int8 uc_method; /* Delivery system */
- u_int8 uc_reserve; /* reserve */
-} VEHICLESENS_DELIVERY_PNO_TBL_DAT;
-
-typedef struct {
- u_int16 us_dnum; /* Number of data items */
- u_int8 uc_reserve[2]; /* reserve */
- VEHICLESENS_DELIVERY_PNO_TBL_DAT st_pno_data[VEHICLESENS_DELIVERY_INFO_MAX];
-} VEHICLESENS_DELIVERY_PNO_TBL;
-
-/*********************************************************************
-* TAG : VEHICLESENS_DELIVERY_HEADER
-* ABSTRACT : Delivery data header
-***********************************************************************/
-typedef struct {
- DID did; /* Data ID */
- u_int16 size; /* Size of the data */
- u_int8 rcv_flag; /* Receive flag */
- u_int8 sensor_cnt; /* Sensor Counter */
-} VEHICLESENS_DELIVERY_HEADER;
-
-/*********************************************************************
-* TAG : VEHICLESENS_DELIVERY_FORMAT
-* ABSTRACT : Delivery data format
-***********************************************************************/
-typedef struct {
- VEHICLESENS_DELIVERY_HEADER header; /* Header */
- u_int8 data[VEHICLESENS_DELIVERY_MAX_SIZE]; /* Data */
-} VEHICLESENS_DELIVERY_FORMAT;
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-void VehicleSensInitDeliveryCtrlTbl(void);
-void VehicleSensInitDeliveryCtrlTblMng(void);
-void VehicleSensInitPkgDeliveryTblMng(void);
-VEHICLE_RET_API VehicleSensEntryDeliveryCtrl(const VEHICLE_MSG_DELIVERY_ENTRY *);
-void VehicleSensAddDeliveryCtrlTbl(const VEHICLE_MSG_DELIVERY_ENTRY *);
-void VehicleSensUpdateDeliveryCtrlTbl(VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *);
-void VehicleSensUpdatePkgDeliveryCtrlTbl(u_int16, u_int16);
-void VehicleSensAddDeliveryCtrlTblMng(const VEHICLE_MSG_DELIVERY_ENTRY *);
-void VehicleSensUpdateDeliveryCtrlTblMng(VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *);
-void VehicleSensAddPkgDeliveryTblMng(const SENSOR_MSG_DELIVERY_ENTRY *);
-VEHICLE_RET_API VehicleSensEntryPkgDeliveryCtrl(const SENSOR_MSG_DELIVERY_ENTRY *, u_int8 uc_ext_chk);
-VEHICLESENS_DELIVERY_PNO_TBL* VehicleSensMakeDeliveryPnoTbl(DID ul_did, u_int8 change_type);
-void VehicleSensAddPnoTbl(u_int16);
-u_int8 VehicleSensDeliveryGPS(DID ul_did, u_int8 uc_get_method, u_int8 uc_current_get_method, int32 pno_index,
- u_int32* cid, VEHICLESENS_DATA_MASTER* stmaster,
- const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl);
-u_int8 VehicleSensDeliveryFst(DID ul_did, u_int8 uc_get_method, int32 pno_index,
- const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl);
-u_int8 VehicleSensDeliveryGyro(DID ul_did, u_int8 uc_current_get_method, int32 pno_index,
- const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl);
-void VehicleSensDeliveryAntenna(DID ul_did, u_int8 uc_current_get_method, int32 pno_index,
- const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl);
-u_int8 VehicleSensDeliveryOther(DID ul_did, u_int8 uc_current_get_method, int32 pno_index,
- u_int32* cid,
- VEHICLESENS_DATA_MASTER* stmaster,
- const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl);
-void VehicleSensDeliveryProc(DID ul_did, u_int8 uc_chg_type, u_int8 uc_get_method);
-u_int8 VehicleSensFirstDeliverySens(PNO us_pno, DID ul_did, u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_FST* stmaster_fst,
- VEHICLESENS_DATA_MASTER_FST* stmaster_fst_temp);
-u_int8 VehicleSensFirstDeliveryOther(PNO us_pno, DID ul_did, u_int8 uc_get_method,
- u_int32* cid,
- VEHICLESENS_DATA_MASTER* stmaster);
-void VehicleSensFirstDelivery(PNO us_pno, DID ul_did);
-void VehicleSensFirstPkgDelivery(const SENSOR_MSG_DELIVERY_ENTRY_DAT *);
-RET_API VehicleSensCanDeliveryEntry(void);
-void VehicleSensFirstPkgDelivery(const SENSOR_MSG_DELIVERY_ENTRY_DAT *);
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-void VehicleSensFirstPkgDeliveryExt(const SENSOR_MSG_DELIVERY_ENTRY_DAT *pst_data);
-#endif
-
-#if CONFIG_HW_PORTSET_TYPE_C
-void VehicleSensInitSeqNum(void);
-void VehicleSensDivideDeliveryProc(PNO, const void *);
-#endif
-
-/* ++ PastModel002 support DR */
-void VehicleSensInitDeliveryCtrlTblDR(void);
-void VehicleSensInitDeliveryCtrlTblMngDR(void);
-VEHICLE_RET_API VehicleSensEntryDeliveryCtrlDR(const DEADRECKONING_MSG_DELIVERY_ENTRY *);
-void VehicleSensAddDeliveryCtrlTblDR(const DEADRECKONING_MSG_DELIVERY_ENTRY *);
-void VehicleSensAddDeliveryCtrlTblMngDR(const DEADRECKONING_MSG_DELIVERY_ENTRY *);
-void VehicleSensUpdateDeliveryCtrlTblDR(VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *);
-void VehicleSensUpdateDeliveryCtrlTblMngDR(VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *);
-void VehicleSensDeliveryProcDR(DID ul_did, u_int8 uc_chg_type, u_int8 uc_get_method);
-VEHICLESENS_DELIVERY_PNO_TBL* VehicleSensMakeDeliveryPnoTblDR(DID ul_did, u_int8 change_type);
-void VehicleSensAddPnoTblDR(u_int16 us_index);
-void VehicleSensGetDebugDeliveryCtrlTbl(void* pbuf);
-void VehicleSensGetDebugDeliveryCtrlTblMng(void* pbuf);
-void VehicleSensGetDebugPkgDeliveryTblMng(void* pbuf);
-void VehicleSensGetDebugDeliveryPnoTbl(void* pbuf);
-/* -- PastModel002 supprt DR */
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_DELIVERYCTRL_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/VehicleSens_FromAccess.h b/vehicleservice/positioning/server/include/Sensor/VehicleSens_FromAccess.h
deleted file mode 100755
index e58b059..0000000
--- a/vehicleservice/positioning/server/include/Sensor/VehicleSens_FromAccess.h
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_FROMACCESS_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_FROMACCESS_H_
-/******************************************************************************
- * File name :VehicleSens_FromAccess.h
- * System name :PastModel002
- * Subsystem name :
- ******************************************************************************/
-
-#include <stdio.h>
-#include <stdint.h>
-#include "Sensor_API.h"
-#include "SensorLocation_API.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-#define NV_FILE_VEHICLESENS "/fs/tmpfs/VehicleSens_nv_data.bin"
-#define NV_FILE_VEHICLESENS_TEMP "/fs/tmpfs/VehicleSens_nv_data_temp.bin"
-#define NV_FILE_VEHICLESENS2 "/fs/tmpfs/VehicleSens_nv_data_2nd.bin"
-#define NV_FILE_VEHICLESENS2_TEMP "/fs/tmpfs/VehicleSens_nv_data_2nd_temp.bin"
-#define NV_LOAD_WAIT_TIME_VEHICLESENS 100U
-#define NV_UPDATE_CYCLE_LONLAT 100U
-#define NV_UPDATE_CYCLE_LOCALTIME 10U
-
-/************************************************************************
-* Typedef definitions *
-************************************************************************/
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-typedef struct {
- LOCALTIME localtime;
- LONLAT lonlat;
- int32 timediff;
- u_int32 update_counter;
- u_int8 reserve[2];
- u_int8 cka;
- u_int8 ckb;
-} NV_DATA_VEHICLESENS;
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-void VehicleSensFromAccessInitialize(void);
-RET_API VehicleSensRegistNvTag(void);
-RET_API VehicleSensReadNVLocalTime(LOCALTIME * local_time);
-RET_API VehicleSensReadNVLonLat(LONLAT * lonlat);
-RET_API VehicleSensReadNVTimeDiff(int32 * time_diff);
-void VehicleSensStoreLonlat(LONLAT * plonlat);
-RET_API VehicleSensWriteNVLocaltime(LOCALTIME * local_time, int32 * time_diff);
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_FROMACCESS_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/VehicleSens_SelectionItemList.h b/vehicleservice/positioning/server/include/Sensor/VehicleSens_SelectionItemList.h
deleted file mode 100755
index 15004e8..0000000
--- a/vehicleservice/positioning/server/include/Sensor/VehicleSens_SelectionItemList.h
+++ /dev/null
@@ -1,116 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_SELECTIONITEMLIST_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_SELECTIONITEMLIST_H_
-/****************************************************************************
- * File name :VehicleSens_SelectionItemList.h
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- ****************************************************************************/
-
-#include "Vehicle_API_Dummy.h"
-#include "Vehicle_API_private.h"
-#include "VehicleSens_Common.h"
-#include "VehicleIf.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/* ++ Addition of DID9 related to PastModel002 supported_UBX commands */
-/* ++ GPS _CWORD82_ support (To add the target DID 3) */
-#define VEHICLESENS_SELECTION_ITEM_LIST_LEN (87) /* Number of data in Vehicle Sensor Selection Item List */
-/* -- GPS _CWORD82_ support */
-#else
-#define VEHICLESENS_SELECTION_ITEM_LIST_LEN (63) /* Number of data in Vehicle Sensor Selection Item List */
-/* -- PastModel002 support */
-#endif
-/* Sum of bits 29 through 31*/
-#define VEHICLESENS_BIT31_29 (VEHICLESENS_BIT31 | VEHICLESENS_BIT30 | VEHICLESENS_BIT29)
-
-#define VEHICLESENS_ITEMLIST_APPLICATION 0x00 /* Application of electronic PF */
-#define VEHICLESENS_ITEMLIST_NON_APPLICATION 0x01 /* Electronic PF not applicable */
-#define VEHICLESENS_ITEMLIST_INVALID 0x02 /* Disabled */
-
-#define VEHICLE_COMM_WATCHTBL_DAT_NUM 64 /* Number of data held for communication discontinuation registration */
-#define VEHICLE_COMM_WATCHTBL_DID_NUM 2 /* Number of Disruption Monitoring Data Management */
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-
-/*********************************************************************
-* TAG : VEHICLESENS_SELECTION_ITEM_LIST
-* ABSTRACT : Managing a list of vehicle information choices
-***********************************************************************/
-
-typedef struct {
- DID ul_did; /* Data ID */
- u_int32 ul_canid; /* CAN ID */ /* CANIF_API deletion */
- u_int8 uc_get_method; /* Data acquisition source category */
- u_int8 reserve[3]; /* reserve */
-} VEHICLESENS_SELECTION_ITEM_LIST;
-
-/************************************************************************
-* TAG : VEHICLE_COMM_WATCH_TBL
-* ABSTRACT : Managing Vehicle Sensor Disruption Monitoring Data
-************************************************************************/
-typedef struct {
- PNO us_pno; /* Destination PNO */
- u_int16 us_watch_time; /* Interruption monitoring time(Units of 100 ms) */
-} VEHICLE_COMM_WATCH_DAT;
-
-typedef struct {
- DID ul_did; /* Data ID corresponding to vehicle sensor information */
- u_int8 uc_effective_flg; /* CANID Valid Flag */
- u_int8 uc_vehicle_comm_watch_cnt; /* Vehicle Sensor Information Disruption Monitoring Request Count */
- VEHICLE_COMM_WATCH_DAT st_comm_watch_dat[VEHICLE_COMM_WATCHTBL_DAT_NUM]; /* Communication disruption registration data */
-} VEHICLE_COMM_WATCH_TBL;
-
-/* ++ PastModel002 support */
-/************************************************************************
-* TAG : VEHICLE_MSG_WATCH_STOPPAGE
-* ABSTRACT : Vehicle Sensor Disruption Monitoring Message(-> Vehicle sensor)
-************************************************************************/
-typedef struct {
- DID ul_did; /* Data ID corresponding to vehicle sensor information */
- PNO us_pno; /* Destination PNO */
- u_int16 us_watch_time; /* Interruption monitoring time(Units of 100 ms) */
- u_int16 us_offset; /* Offset to shared memory storage area */
- u_int16 us_size; /* Size of shared memory storage area */
- EventID ul_eventid; /* Event ID */
-} VEHICLE_MSG_WATCH_STOPPAGE_DAT;
-
-typedef struct {
- T_APIMSG_MSGBUF_HEADER st_hdr; /* Message header */
- VEHICLE_MSG_WATCH_STOPPAGE_DAT st_data; /* Message data */
-} VEHICLE_MSG_WATCH_STOPPAGE;
-
-/* -- PastModel002 support */
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-void VehicleSensInitSelectionItemList(void);
-u_int8 VehicleSensGetSelectionItemList(DID);
-u_int32 VehicleSensGetSelectionItemListCanId(DID);
-BOOL VehicleSensSetSelectionItemListCanId(DID did, u_int32); /* CANIF_API deletion */
-void VehicleSensCommWatchTblInit(void);
-BOOL VehicleSensCommWatchTblSave(const VEHICLE_MSG_WATCH_STOPPAGE*);
-BOOL VehicleSensCommWatchTblRun(DID);
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_SELECTIONITEMLIST_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/VehicleSens_SharedMemory.h b/vehicleservice/positioning/server/include/Sensor/VehicleSens_SharedMemory.h
deleted file mode 100755
index 54878ec..0000000
--- a/vehicleservice/positioning/server/include/Sensor/VehicleSens_SharedMemory.h
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_SHAREDMEMORY_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_SHAREDMEMORY_H_
-/******************************************************************************
- * File name :VehicleSens_SharedMemory.h
- * System name :PastModel002
- * Subsystem name :
- ******************************************************************************/
-
-#include "Vehicle_API.h"
-#include "Sensor_Common_API.h"
-#include "VehicleSens_FromAccess.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-
-/************************************************************************
-* Typedef definitions *
-************************************************************************/
-
-/************************************************************************
-* Struct definitions *
-************************************************************************/
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-RET_API VehicleSensInitSharedMemory(void);
-void VehicleSensWriteSharedMemory(DID ul_did);
-RET_API VehicleSensWriteDataValidEphemerisNum(u_int8 valid_ephemer_isnum);
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_SHAREDMEMORY_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/VehicleSens_Thread.h b/vehicleservice/positioning/server/include/Sensor/VehicleSens_Thread.h
deleted file mode 100755
index 17a342d..0000000
--- a/vehicleservice/positioning/server/include/Sensor/VehicleSens_Thread.h
+++ /dev/null
@@ -1,185 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_THREAD_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_THREAD_H_
-/******************************************************************************
- * File name :VehicleSens_Thread.h
- * System name :_CWORD107_
- * Subsystem name :
- ******************************************************************************/
-
-#include "Vehicle_API_Dummy.h"
-#include "Sensor_API.h"
-#include "Vehicle_API_private.h"
-#include "Sensor_API_private.h"
-#include "VehicleSens_Common.h"
-#include "VehicleSens_SelectionItemList.h"
-#include "VehicleSens_DataMaster.h"
-#include "VehicleSens_DeliveryCtrl.h"
-#include "VehicleSens_SharedMemory.h"
-#include "CanInput_API.h"
-#include "CanInput_API_private.h"
-#include "VehicleDebug_API.h"
-#include "VehicleSens_FromAccess.h"
-#include "ClockDataMng.h"
-#include "gps_hal.h"
-#include "positioning_hal.h"
-#include "CommonDefine.h"
-
-/* ++ DR support */
-#include "DeadReckoning_main.h"
-#include "Dead_Reckoning_Local_Api.h"
-/* -- DR support */
-
-#include "POS_common_private.h"
-
-/************************************************************************
-* Macro definitions *
-************************************************************************/
-
-/* ++ Porting from PastModel002 enabled APIs */
-#define CID_VEHICLEIF_GET_VEHICLE_DATA 0x0102 /* Vehicle sensor information acquisition CID */
-#define CID_VEHICLEIF_COMM_WATCH 0x0103 /* Vehicle Sensor Information Disruption Monitoring CID */
-#define CID_SENSORIF__CWORD82__REQUEST 0x0800 /* Vehicle sensor information setting CID */
-
-#define VEHICLE_RET_ERROR_OUTOF_MEMORY (-8) /* Shared memory allocation failure */
-#define VEHICLE_RET_ERROR_INVALID (-10) /* CANID undetermined */
-
-/* -- Porting from PastModel002 enabled APIs */
-
-
-/* NMEA */
-#define VEHICLESENS_NMEA_LF "\n"
-#define VEHICLESENS_NMEA_CR "\r"
-#define VEHICLESENS_NMEA_FIELDDELIMITER ","
-#define VEHICLESENS_NMEA_DECIMALPOINT "."
-#define VEHICLESENS_NMEA_ASTARISK "*"
-
-#define VEHICLESENS_NMEA_PASCD_LEN_MAX 256
-
-#define VEHICLESENS_NMEA_PASCD_ID "$PASCD"
-
-#define VEHICLESENS_NMEA_PASCD_TS_MAX 86400
-#define VEHICLESENS_NMEA_PASCD_TS_INT_LEN_MAX 6 /* max length of integer part of timestamp */
-#define VEHICLESENS_NMEA_PASCD_TS_FRA_LEN_MAX 3 /* max length of fractional part of timestamp */
-
-#define VEHICLESENS_NMEA_PASCD_SENSORTYPE_C "C" /* Combined left and right wheel speed sensors */
-
-#define VEHICLESENS_NMEA_PASCD_TMS_U "U" /* Unkonwn */
-#define VEHICLESENS_NMEA_PASCD_TMS_P "P" /* Park */
-#define VEHICLESENS_NMEA_PASCD_TMS_R "R" /* Reverse */
-#define VEHICLESENS_NMEA_PASCD_TMS_D "D" /* Driving forword */
-#define VEHICLESENS_NMEA_PASCD_TMS_N "N" /* Neutral */
-
-#define VEHICLESNES_NMEA_PASCD_SLIP "1" /* 1 = a wheel speed slippage was detected */
-#define VEHICLESNES_NMEA_PASCD_NOSLIP "0" /* 0 = no slip was detected */
-
-#define VEHICLESENS_NMEA_PASCD_TO_FRA_LEN_MAX 2 /* max length of fractional part of timeoffset */
-
-#define VEHICLESENS_NMEA_PASCD_SPD_FRA_LEN_MAX 3 /* max length of fractional part of speed */
-
-#define VEHICLESENS_NMEA_PASCD_SAMPLECOUNT_MAX 50
-
-/************************************************************************
- * Struct definitions *
- ************************************************************************/
-
-/*!
- @brief Structure of Vehicle Speed and TimeSpec
- */
-typedef struct {
- timespec ts;
- uint16_t speed; /* [0.01m/s] */
-} VEHICLESENS_VEHICLE_SPEED_DAT;
-
-/*!
- @brief Structure of Vehilce Speeds and TimeSpecs
- */
-typedef struct {
- VEHICLESENS_VEHICLE_SPEED_DAT listSpd[VEHICLESENS_NMEA_PASCD_SAMPLECOUNT_MAX];
- uint8_t sampleCount;
-} VEHICLESENS_VEHICLE_SPEED_INFO;
-
-/*!
- @brief Structure for LUT to Derive Transmission State
- */
-typedef struct {
- uint8_t type; /* Transmission Type */
- uint8_t shift; /* Shift Position from Vehicle */
-
- uint8_t pkb; /* Parking Brake from Vehicle */
- char state[8]; /* Transmission State for _CWORD27_ */
-} VEHICLESENS_TRANSMISSION_PKG;
-
-/************************************************************************
- * TAG : VEHICLE_MSG_SEND_DAT
- * ABSTRACT : Vehicle sensor information setting message(-> Vehicle sensor)
- ************************************************************************/
-
-
-
-/************************************************************************
-* Function prototype *
-************************************************************************/
-EFrameworkunifiedStatus VehicleSensThread(HANDLE h_app);
-RET_API VehicleSensThreadInit(void);
-void VehicleSensDeliveryEntry(const VEHICLE_MSG_DELIVERY_ENTRY *);
-void VehicleSensGetVehicleData(const VEHICLE_MSG_GET_VEHICLE_DATA *);
-void VehicleSensWatchStopPage(const VEHICLE_MSG_WATCH_STOPPAGE *);
-void VehicleSensPkgDeliveryEntry(const SENSOR_MSG_DELIVERY_ENTRY *);
-void VehicleSensGetVehiclePkgData(const SENSOR_MSG_GET_SENSOR_DATA *);
-void VehicleSensLineSensDataDelivery(const LSDRV_MSG_LSDATA *, PFUNC_DMASTER_SET_N);
-void VehicleSensLineSensDataDeliveryG(const LSDRV_MSG_LSDATA_G *, PFUNC_DMASTER_SET_N);
-void VehicleSensLineSensDataDeliveryGyroTrouble(const LSDRV_MSG_LSDATA_GYRO_TROUBLE *msg,
- PFUNC_DMASTER_SET_N p_datamaster_set_n);
-void VehicleSensLineSensDataDeliverySysGpsInterruptSignal(const LSDRV_MSG_LSDATA_GPS_INTERRUPT_SIGNAL *msg,
- PFUNC_DMASTER_SET_SHARED_MEMORY p_datamaster_set_sharedmemory);
-void VehicleSensLineSensDataDeliveryGyroConnectStatus(const LSDRV_MSG_LSDATA_GYRO_CONNECT_STATUS *msg,
- PFUNC_DMASTER_SET_SHARED_MEMORY p_datamaster_set_sharedmemory);
-void VehicleSensLineSensDataDeliveryGpsAntennaStatus(const LSDRV_MSG_LSDATA_GPS_ANTENNA_STATUS *msg,
- PFUNC_DMASTER_SET_N p_datamaster_set_n);
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-void VehicleSensPkgDeliveryEntryExt(const SENSOR_MSG_DELIVERY_ENTRY *msg);
-void VehicleSensLineSensDataDeliveryFst(const LSDRV_MSG_LSDATA_FST *, PFUNC_DMASTER_SET_N);
-void VehicleSensLineSensDataDeliveryFstG(const LSDRV_MSG_LSDATA_FST *msg, PFUNC_DMASTER_SET_N p_datamaster_set_n);
-#else
-void VehicleSensPkgDeliveryEntryError(const SENSOR_MSG_DELIVERY_ENTRY *msg);
-#endif
-void VehicleSensGpsDataDelivery(SENSOR_MSG_GPSDATA *msg,
- PFUNC_DMASTER_SET_N p_datamaster_set_n,
- PFUNC_DMASTER_SET_SHARED_MEMORY p_datamaster_set_sharedmemory);
-
-void VehicleSensDataMasterSetN(DID did, u_int8 chg_type, u_int8 get_method);
-void VehicleSensDataMasterSetSharedMemory(DID did, u_int8 chg_type);
-/* ++ GPS _CWORD82_ support */
-void VehicleSensSetVehicleData(const VEHICLE_MSG_SEND *);
-/* -- GPS _CWORD82_ support */
-
-void VehicleSensDrDeliveryEntry(const VEHICLE_MSG_DELIVERY_ENTRY *);
-void VehicleSensGetLog(const VEHICLEDEBUG_MSG_BUF* msg);
-void VehicleSensSetLog(const VEHICLEDEBUG_MSG_BUF* msg);
-void VehicleSensWriteLocalTime(const CANINPUT_MSG_INFO *msg);
-void VehicleSensSetEphNumSharedMemory(const SENSOR_MSG_GPSDATA *msg);
-void VehicleSensDrRcvMsg(const DEAD_RECKONING_RCVDATA *msg);
-
-void VehicleSensCommonDataDelivery(const VEHICLE_MSG_BUF *msg, PFUNC_DMASTER_SET_N p_datamaster_set_n);
-void VehicleSensGpsTimeSndMsg(const POS_MSGINFO *pos_msg);
-void VehicleSensGpsTimeDelivery(const VEHICLE_MSG_BUF *msg);
-RET_API VehicleSensSendEvent(uint16_t snd_pno, int32_t event_val);
-void VehicleSensThreadStopProcess(void);
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENS_THREAD_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/VehicleSensor_Thread.h b/vehicleservice/positioning/server/include/Sensor/VehicleSensor_Thread.h
deleted file mode 100755
index f40f2a7..0000000
--- a/vehicleservice/positioning/server/include/Sensor/VehicleSensor_Thread.h
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/****************************************************************************
- * File name :vehiclesensor_thread.h
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Title :Prototype Declaration of Thread Entry Function of Vehicle Sensor Process
- ****************************************************************************/
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENSOR_THREAD_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENSOR_THREAD_H_
-
-#include <vehicle_service/positioning_base_library.h>
-
-/***********************************************************************
-* Thread entry function prototype *
-************************************************************************/
-EFrameworkunifiedStatus VehicleSensThread(HANDLE h_app);
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLESENSOR_THREAD_H_
diff --git a/vehicleservice/positioning/server/include/Sensor/VehicleUtility.h b/vehicleservice/positioning/server/include/Sensor/VehicleUtility.h
deleted file mode 100755
index e7ebef0..0000000
--- a/vehicleservice/positioning/server/include/Sensor/VehicleUtility.h
+++ /dev/null
@@ -1,128 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleUtility.h
-@detail Common processing function header file of Vehicle<BR>
- Vehicle Common Functions Header Files
-*****************************************************************************/
-#ifndef POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLEUTILITY_H_
-#define POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLEUTILITY_H_
-
-#include <stdint.h>
-#include <vehicle_service/positioning_base_library.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*------------------------------------------------------------------------------*
- * Definition *
- *------------------------------------------------------------------------------*/
-/* GPS-related timer value */
-#define TIMVAL_GPS_STARTUP 500 /* 5Sec Start confirmation monitoring timer */
-#define TIMVAL_GPS_RCVCYCLDAT 500 /* 5Sec Periodic reception data monitoring timer */
-#define TIMVAL_GPS_RCVACK 500 /* 5Sec ACK reception monitoring timer */
-#define TIMVAL_GPS_RCVDAT 500 /* 5Sec Data reception monitoring timer(Not used) */
-#define TIMVAL_GPS_NAVIFST 3000 /* 30sec Initial Navigation Monitoring Timer */
-#define TIMVAL_GPS_NAVICYCLE 300 /* 3sec Navi monitoring timer */
-#define TIMVAL_GPS_NAVIDISRPT 1000 /* 10Sec Navigation Monitoring Disruption Log Output Timer */
-#define TIMVAL_GPS_DIAGCLKGUARD 1000 /* 10sec Diag provision time guard monitoring timer */
-#define TIMVAL_GPS_NMEADATAGUARD 1000 /* 10sec NMEA data-providing guard monitoring timer */
-#define TIMVAL_GPS_RECOVERY 60000 /* 600sec GPS recovery timer */
-#define TIMVAL_GPS_RECEIVERERR 60000 /* 600sec GPS receiver anomaly detection timer */
-
-/* Sensor-related timer value */
-#define TIMVAL_SNS_RCVFSTDAT 3000 /* 30Sec Initial sensor data reception monitoring timer */
-#define TIMVAL_SNS_RCVCYCLDAT 300 /* 3Sec Cyclic sensor data reception monitoring timer */
-#define TIMVAL_SNS_RCVDISRPT 1000 /* 10Sec Cyclic sensor data interruption log output timer */
-
-/* Timer management table */
-#define TIM_NON 0x00 /* Timer counter initial value */
-#define TIM_CNTMIN 0x01 /* Timer counter minimum value */
-#define TIM_CNTMAX 0xff /* Maximum value of timer counter */
-#define TIMER_OFF 0 /* Timer enable flag OFF */
-#define TIMER_ON 1 /* Timer enable flag ON */
-
-/*------------------------------------------------------------------------------*
- * Structure *
- *------------------------------------------------------------------------------*/
-/*!
- @brief Timer type
- */
-typedef enum _VEHICLEUTILITY_TIM_KIND {
- GPS_STARTUP_TIMER = 0, /* 0 Start confirmation monitoring timer */
- GPS_CYCL_TIMER, /* 1 Cyclic GPS data reception monitoring timer */
- GPS_RECV_ACK_TIMER, /* 2 ACK reception monitoring timer */
- GPS_NAVIFST_TIMER, /* 3 Initial Navigation Monitoring Timer */
- GPS_NAVICYCLE_TIMER, /* 4 Navi monitoring timer */
- GPS_NAVIDISRPT_TIMER, /* 5 Navigation Monitoring Disruption Log Output Timer */
- GPS_DIAGCLK_GUARDTIMER, /* 6 Diag provision time guard monitoring timer */
- GPS_NMEADATA_GUARDTIMER, /* 7 NMEA data-providing guard monitoring timer */
- GPS_RECOVERY_TIMER, /* 8 GPS recovery timer */
- GPS_RECEIVERERR_TIMER, /* 9 GPS receiver anomaly detection timer */
- SNS_FST_TIMER, /* 10 Initial sensor data reception monitoring timer */
- SNS_CYCLE_TIMER, /* 11 Cyclic sensor data reception monitoring timer */
- SNS_DISRPT_TIMER, /* 12 Cyclic sensor data interruption log output timer */
- TIM_NUM /* 13 Number of timer types */
-} VEHICLEUTILITY_TIM_KIND;
-
-/*!
- @brief Master status
-*/
-typedef struct {
- u_int8 flag; /**< Timer flag OFF:Stop,ON:Start */
- u_int8 cnt; /**< Start counter */
- int8 rsv[2]; /**< Reserved */
-} VEHICLEUTILITY_TIM_STS;
-
-/*!
- @brief Master status management table
- */
-typedef struct {
- VEHICLEUTILITY_TIM_STS sts[TIM_NUM]; /**< Master status */
-} VEHICLEUTILITY_TIM_MNG;
-
-/*!
- @brief Timer setting information table
-*/
-typedef struct {
- uint32_t timer_val; /**< Timer value */
- PNO pno; /**< Event notification destination process number */
-} VEHICLEUTILITY_TIM_INFO;
-
-/*
- Function prototype declaration
- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-RET_API VehicleUtilitySndMsg(PNO pno, u_int16 size, void *msgbuf, u_int16 mode);
-RET_API VehicleUtilityRcvMsg(PNO pno, u_int16 size, void **msgbuf, u_int16 mode);
-void VehicleUtilityDiagCodePut(u_int32 err_id, u_int16 positioning_code);
-void VehicleUtilityInitTimer(void);
-BOOL VehicleUtilitySetTimer(VEHICLEUTILITY_TIM_KIND tim_kind);
-BOOL VehicleUtilityStopTimer(VEHICLEUTILITY_TIM_KIND tim_kind);
-BOOL VehicleUtilityTimeJdgKnd(uint16_t seqno);
-
-void LineSensDrvExtTermStsReq(void);
-RET_API DEVGpsSndBackupDataLoadReq(void);
-void DEVGpsGetDebugGpsFormatFailCnt(void* p_buf);
-u_int8 LineSensDrvGetSysRecvFlag(void);
-uint16_t DEVGpsGetWknRollover(void);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SENSOR_VEHICLEUTILITY_H_ */
diff --git a/vehicleservice/positioning/server/include/ServiceInterface/BackupMgrIf.h b/vehicleservice/positioning/server/include/ServiceInterface/BackupMgrIf.h
deleted file mode 100755
index 3e2e5e5..0000000
--- a/vehicleservice/positioning/server/include/ServiceInterface/BackupMgrIf.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * BackupMgrIf.h
- * @brief
- * BackupMgr service-to-service interface
- */
-#ifndef POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_BACKUPMGRIF_H_
-#define POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_BACKUPMGRIF_H_
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <native_service/frameworkunified_types.h>
-#include <native_service/frameworkunified_framework_if.h>
-#include <native_service/ns_backup.h>
-#include <native_service/ns_backup_id.h>
-
-#include <vehicle_service/positioning_base_library.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-EFrameworkunifiedStatus BackupMgrIfNotifyOnBackupMgrAvailability(CbFuncPtr fp_on_cmd);
-void BackupMgrIfSetAvailability(BOOL b_is_available);
-BOOL BackupMgrIf_GetAvailability(void);
-EFrameworkunifiedStatus BackupMgrIfBackupDataRd(PCSTR tag_id, uint32_t ui_offset, \
- void *pv_buf, uint32_t ui_size, BOOL* pb_is_available);
-EFrameworkunifiedStatus BackupMgrIfBackupDataWt(PCSTR tag_id, void *pv_buf, \
- uint32_t ui_offset, uint32_t ui_size, BOOL* pb_is_available);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_BACKUPMGRIF_H_
diff --git a/vehicleservice/positioning/server/include/ServiceInterface/ClockIf.h b/vehicleservice/positioning/server/include/ServiceInterface/ClockIf.h
deleted file mode 100755
index 5a2e976..0000000
--- a/vehicleservice/positioning/server/include/ServiceInterface/ClockIf.h
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * ClockIf.h
- * @brief
- * Clock service-to-service interface
- */
-#ifndef POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_CLOCKIF_H_
-#define POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_CLOCKIF_H_
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <native_service/frameworkunified_types.h>
-#include <native_service/frameworkunified_framework_if.h>
-
-#include <stub/DTime_Api.h>
-#include <vehicle_service/positioning_base_library.h>
-#include <vehicle_service/POS_gps_API.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-EFrameworkunifiedStatus ClockIfNotifyOnClockAvailability(CbFuncPtr fp_on_cmd);
-void ClockIfSetAvailability(BOOL b_is_available);
-EFrameworkunifiedStatus ClockIfDtimeSetGpsTime(const SENSOR_MSG_GPSTIME *pst_gps_time, BOOL* pb_is_available);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_CLOCKIF_H_
diff --git a/vehicleservice/positioning/server/include/ServiceInterface/CommUsbIf.h b/vehicleservice/positioning/server/include/ServiceInterface/CommUsbIf.h
deleted file mode 100755
index cbc947c..0000000
--- a/vehicleservice/positioning/server/include/ServiceInterface/CommUsbIf.h
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * CommUsbIf.h
- * @brief
- * CommUSB service-to-service interface
- */
-#ifndef POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_COMMUSBIF_H_
-#define POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_COMMUSBIF_H_
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <native_service/frameworkunified_types.h>
-#include <native_service/frameworkunified_framework_if.h>
-#include <stub/commusb_api.h>
-#include <stub/commusb_notifications.h>
-
-#include <vehicle_service/positioning_base_library.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-EFrameworkunifiedStatus CommUsbIfAttachCallbacksToDispatcher( // NOLINT(readability/nolint)
- _FrameworkunifiedProtocolCallbackHandler const* p_msg_handler,
- unsigned int ui_handler_count);
-EFrameworkunifiedStatus CommUsbIfDetachCallbacksFromDispatcher(const PUI_32 pui_cmd_array, UI_32 ui_command_count);
-EFrameworkunifiedStatus CommUsbIfNotifyOnCommUSBAvailability(CbFuncPtr fp_on_cmd);
-void CommUsbIfSetAvailability(BOOL b_is_available);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_COMMUSBIF_H_
diff --git a/vehicleservice/positioning/server/include/ServiceInterface/DevDetectSrvIf.h b/vehicleservice/positioning/server/include/ServiceInterface/DevDetectSrvIf.h
deleted file mode 100755
index 8829123..0000000
--- a/vehicleservice/positioning/server/include/ServiceInterface/DevDetectSrvIf.h
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * DevDetectSrvIf.h
- * @brief
- * DevDetectSrv service-to-service interface
- */
-#ifndef POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_DEVDETECTSRVIF_H_
-#define POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_DEVDETECTSRVIF_H_
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <native_service/frameworkunified_types.h>
-#include <system_service/ss_devicedetection_service_ifc.h>
-#include <system_service/ss_devicedetection_service_protocol.h>
-
-#include <vehicle_service/positioning_base_library.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-void DevDetectSrvIfSetAvailability(BOOL b_is_available);
-EFrameworkunifiedStatus DevDetectSrvIfInitialize(void);
-EFrameworkunifiedStatus DevDetectSrvIfNotifyOnDeviceDetectionAvailability(CbFuncPtr fp_call_back_fn);
-EFrameworkunifiedStatus DevDetectSrvIfNotifyOnOpenSessionAck(CbFuncPtr fp_call_back_fn, BOOL* pb_is_available);
-EFrameworkunifiedStatus DevDetectSrvIfNotifyOnCloseSessionAck(CbFuncPtr fp_call_back_fn, BOOL* pb_is_available);
-EFrameworkunifiedStatus DevDetectSrvIfOpenSessionRequest(BOOL* pb_is_available);
-EFrameworkunifiedStatus DevDetectSrvIfDecodeOpenSessionResponse(BOOL* pb_is_available);
-EFrameworkunifiedStatus DevDetectSrvIfRegisterForDeviceDetectionEvent(SS_DeviceDetectionServerEvents fe_dev_detect_event, \
- CbFuncPtr fp_call_back_fn, PCSTR p_file_path, BOOL* pb_is_available);
-EFrameworkunifiedStatus DevDetectSrvIfUnRegisterForDeviceDetectionEvent(SS_DeviceDetectionServerEvents fe_dev_detect_event, \
- BOOL* pb_is_available);
-EFrameworkunifiedStatus DevDetectSrvIfCloseSessionRequest(BOOL* pb_is_available);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_DEVDETECTSRVIF_H_
diff --git a/vehicleservice/positioning/server/include/ServiceInterface/DiagSrvIf.h b/vehicleservice/positioning/server/include/ServiceInterface/DiagSrvIf.h
deleted file mode 100755
index a6bcd77..0000000
--- a/vehicleservice/positioning/server/include/ServiceInterface/DiagSrvIf.h
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * DiagSrvIf.h
- * @brief
- * DiagSrv service-to-service interface
- */
-#ifndef POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_DIAGSRVIF_H_
-#define POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_DIAGSRVIF_H_
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <native_service/frameworkunified_types.h>
-#include <vehicle_service/positioning_base_library.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-void DiagSrvIfSetRegistrationPermission(BOOL b_is_true);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_DIAGSRVIF_H_
diff --git a/vehicleservice/positioning/server/include/ServiceInterface/PSMShadowIf.h b/vehicleservice/positioning/server/include/ServiceInterface/PSMShadowIf.h
deleted file mode 100755
index 8cdb1f8..0000000
--- a/vehicleservice/positioning/server/include/ServiceInterface/PSMShadowIf.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * PSMShadow.h
- * @brief
- * PSMShadow service-to-service interface
- */
-#ifndef POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_PSMSHADOWIF_H_
-#define POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_PSMSHADOWIF_H_
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <native_service/frameworkunified_types.h>
-#include <native_service/frameworkunified_framework_if.h>
-#include <vehicle_service/positioning_base_library.h>
-#include "ps_psmshadow_notifications.h"
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-EFrameworkunifiedStatus PSMShadowIfNotifyOnPSMShadowAvailability(CbFuncPtr fp_on_cmd);
-EFrameworkunifiedStatus PSMShadowIfNotifyOnPSMShadowInitComp(CbFuncPtr fp_on_cmd);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_PSMSHADOWIF_H_
diff --git a/vehicleservice/positioning/server/include/ServiceInterface/VehicleIf.h b/vehicleservice/positioning/server/include/ServiceInterface/VehicleIf.h
deleted file mode 100755
index 28c05fb..0000000
--- a/vehicleservice/positioning/server/include/ServiceInterface/VehicleIf.h
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_VEHICLEIF_H_
-#define POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_VEHICLEIF_H_
-
-/*---------------------------------------------------------------------------------*
- * Incluce *
- *---------------------------------------------------------------------------------*/
-#include <native_service/frameworkunified_types.h>
-#include <native_service/frameworkunified_framework_if.h>
-
-#include <vehicle_service/positioning_base_library.h>
-#include <stub/vehicle_notifications.h>
-#include <stub/Vehicle_Sensor_Common_API.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-/* Transmission Type */
-#define VEHICLEIF_TRANSMISSION_TYPE_MT 0
-#define VEHICLEIF_TRANSMISSION_TYPE_AT 1
-#define VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN 2
-#define VEHICLEIF_TRANSMISSION_TYPE_NUM 3 /* Number of Transmission Types */
-
-/* Shift Position (CAUTION: These values depend on Vehicle I/F) */
-#define VEHICLEIF_SHIFT_POSITION_U 0
-#define VEHICLEIF_SHIFT_POSITION_R 1
-#define VEHICLEIF_SHIFT_POSITION_P 2
-#define VEHICLEIF_SHIFT_POSITION_N 4
-#define VEHICLEIF_SHIFT_POSITION_D 8
-#define VEHICLEIF_SHIFT_POSITION_NUM 5 /* Number of Shift Position Types */
-
-/* Parking Brake (CAUTION: These values depend on Vehicle I/F) */
-#define VEHICLEIF_PKB_OFF 0
-#define VEHICLEIF_PKB_ON 1
-#define VEHICLEIF_PKB_UNKNOWN 2
-#define VEHICLEIF_PKB_NUM 3
-
-/*---------------------------------------------------------------------------------*
- * Typedef declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Struct declaration *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Prototype Declaration *
- *---------------------------------------------------------------------------------*/
-#ifdef __cplusplus
-extern "C" {
-#endif
-void VehicleIf_SetAvailability(BOOL bIsAvailable);
-
-//EFrameworkunifiedStatus VehicleIf_GetTypeOfTransmission(uint8_t* pType, BOOL* pbIsAvailable);
-EFrameworkunifiedStatus VehicleIf_GetTypeOfTransmission(uint8_t* pType, uint8_t* pPkb, BOOL* pbIsAvailable);
-EFrameworkunifiedStatus VehicleIf_GetShiftPosition(uint8_t* pShift, BOOL* pbIsAvailable);
-EFrameworkunifiedStatus VehicleIfAttachCallbacksToDispatcher( // NOLINT(readability/nolint)
- _FrameworkunifiedProtocolCallbackHandler const* p_msg_handler,
- unsigned int ui_handlercount);
-EFrameworkunifiedStatus VehicleIfDetachCallbacksFromDispatcher(const PUI_32 pui_cmd_array, UI_32 ui_command_count);
-EFrameworkunifiedStatus VehicleIfNotifyOnVehicleAvailability(CbFuncPtr fp_on_cmd);
-EFrameworkunifiedStatus VehicleIfDeliveryEntry(uint32_t ul_did);
-#ifdef __cplusplus
-}
-#endif
-
-#endif // POSITIONING_SERVER_INCLUDE_SERVICEINTERFACE_VEHICLEIF_H_
diff --git a/vehicleservice/positioning/server/include/ServiceInterface/ps_psmshadow_notifications.h b/vehicleservice/positioning/server/include/ServiceInterface/ps_psmshadow_notifications.h
deleted file mode 100755
index 24a513a..0000000
--- a/vehicleservice/positioning/server/include/ServiceInterface/ps_psmshadow_notifications.h
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file ps_psmshadow_notifications.h
- */
-
-#ifndef PS_PSM_SHADOW_NOTIFICATIONS_H_ // NOLINT(build/header_guard)
-
-#include "agl_thread.h"
-
-/** @addtogroup BaseSystem
- * @{
- */
-/** @addtogroup peripheralservice
- * @ingroup BaseSystem
- * @{
- */
-/** @addtogroup PS_PSMShadow
- * @ingroup peripheralservice
- * @{
- */
-
-/**
- * \~english PS_PSMShadow service availability notify.
- */
-#define NTFY_PSMShadowService_Availability MN_PS_PSMSHADOW"/Availability"
-
-/**
- * \~english init complete notify.
- */
-#define NTFY_PSM_INITCOMP MN_PS_PSMSHADOW"/InitComp"
-
-/**
- * \~english init complete2 notify.
- */
-#define NTFY_PSM_INITCOMP2 MN_PS_PSMSHADOW"/InitComp2"
-
-// to be delete code.
-// Voltage, temperature and fan data to DIAG / HMI.
-#define NTFY_PSM_VTG_TEMP_FAN_DATA MN_PS_PSMSHADOW"/VolTempFanInfo"
-// Audio High Temp notification to Audio service.
-#define NTFY_PSM_AUDIO_HIGH_TEMP MN_PS_PSMSHADOW"/AudioHighTemp"
-
-/** @}*/ // end of PS_PSMShadow
-/** @}*/ // end of peripheralservice
-/** @}*/ // end of BaseSystem
-
-#endif // PS_PSM_SHADOW_NOTIFICATIONS_H_
diff --git a/vehicleservice/positioning/server/include/ServiceInterface/ps_version.h b/vehicleservice/positioning/server/include/ServiceInterface/ps_version.h
deleted file mode 100755
index f28982f..0000000
--- a/vehicleservice/positioning/server/include/ServiceInterface/ps_version.h
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/// \session
-/// \internal
-//////////////////////////////////////////////////////////////////////////////////////////////////
-/// \file ps_services.h
-/// \ingroup tag_PeripheralServices
-/// \brief Peripheral Services Version Information Support.
-///
-//////////////////////////////////////////////////////////////////////////////////////////////////
-
-//////////////////////////////////////////////////////////////////////////////////////////////////
-// File name : ps_version.h
-// Module : PeripheralServices
-// Description : Peripheral Services Version Information Support.
-// Scope : PeripheralServices
-// Platform : Global Platform Framework (GPF)
-//
-// Customer : General
-// System : PosixBasedOS001
-// Reference : PeripheralServices
-//////////////////////////////////////////////////////////////////////////////////////////////////
-
-#ifndef PS_VERSION_H_ // NOLINT(build/header_guard)
-
-#define PS_VERSION_MAJOR (1u)
-#define PS_VERSION_MINOR (0u)
-#define PS_VERSION_REV (0u)
-
-#endif /* PS_VERSION_H_ */
-
diff --git a/vehicleservice/positioning/server/include/nsfw/positioning_common.h b/vehicleservice/positioning/server/include/nsfw/positioning_common.h
deleted file mode 100755
index 538630d..0000000
--- a/vehicleservice/positioning/server/include/nsfw/positioning_common.h
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * positioning_common.h
- * @brief
- * Positioing NSFW Dependency Section Common Headers
- */
-#ifndef POSITIONING_SERVER_INCLUDE_NSFW_POSITIONING_COMMON_H_
-#define POSITIONING_SERVER_INCLUDE_NSFW_POSITIONING_COMMON_H_
-
-#include <positioning_hal.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-/* Thread control command ID */
-#define CID_EXTTERM_REQ (0x0011) /* External pin status request */
-
-/* Internal thread activation status determination */
-#define THREAD_STS_MSK_POS_MAIN (0x01)
-#define THREAD_STS_MSK_POS_SENS (0x02)
-#define THREAD_STS_MSK_POS_GPS (0x04)
-#define THREAD_STS_MSK_POS_GPS_RECV (0x08)
-#define THREAD_STS_MSK_POS_GPS_ROLLOVER (0x10)
-
-
-/*---------------------------------------------------------------------------------*
- * ENUMERATION *
- *---------------------------------------------------------------------------------*/
-/*!
- @brief Positioning operating status definitions
-*/
-typedef enum {
- EPOS_EXE_STS_STOP = 0, /* Stopped */
- EPOS_EXE_STS_RUNNING, /* Running (From FrameworkunifiedOnStart to FrameworkunifiedOnStop) */
- EPOS_EXE_STS_RUNNING_COLDSTART /* Running after cold start */
-} EnumExeSts_POS;
-
-/*!
- @brief Positioning Thread Startup Modes
-*/
-typedef enum {
- EPOS_SETUP_MODE_NORMAL = 0, /* Normal start */
- EPOS_SETUP_MODE_DATA_RESET /* Data reset start */ /* QAC 930 */
-} EnumSetupMode_POS;
-
-/*---------------------------------------------------------------------------------*
- * STRUCTURE *
- *---------------------------------------------------------------------------------*/
-/*!
- @brief Thread activation information
-*/
-typedef struct {
- EnumSetupMode_POS e_mode; /* Thread activation mode */
-} ST_THREAD_SETUP_INFO;
-
-/*---------------------------------------------------------------------------------*
- * Prototype *
- *---------------------------------------------------------------------------------*/
-#ifdef __cplusplus
-extern "C" {
-#endif
- EnumSetupMode_POS PosSetupThread(HANDLE h_app, EnumTID_POS e_tid);
- void PosTeardownThread(EnumTID_POS e_tid);
-#ifdef __cplusplus
-}
-#endif
-
-/*---------------------------------------------------------------------------------*
- * Extern *
- *---------------------------------------------------------------------------------*/
-extern BOOL g_thread_stop_req; /* Pos_Gps_Recv Thread Stop Flag */
-
-
-#endif // POSITIONING_SERVER_INCLUDE_NSFW_POSITIONING_COMMON_H_
diff --git a/vehicleservice/positioning/server/include/nsfw/vehicle_version.h b/vehicleservice/positioning/server/include/nsfw/vehicle_version.h
deleted file mode 100755
index b397b68..0000000
--- a/vehicleservice/positioning/server/include/nsfw/vehicle_version.h
+++ /dev/null
@@ -1,29 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#ifndef POSITIONING_SERVER_INCLUDE_NSFW_VEHICLE_VERSION_H_
-#define POSITIONING_SERVER_INCLUDE_NSFW_VEHICLE_VERSION_H_
-
-#define MAJORNO 0x01
-#define MINORNO 0x00
-#define REVISION 0x00
-
-/*
- * ChangeLog : This section describes all the changes done to the project.
- *
- * - Initial
- */
-
-#endif // POSITIONING_SERVER_INCLUDE_NSFW_VEHICLE_VERSION_H_
diff --git a/vehicleservice/positioning/server/src/Sensor/ClockUtility.cpp b/vehicleservice/positioning/server/src/Sensor/ClockUtility.cpp
deleted file mode 100755
index 2e9639a..0000000
--- a/vehicleservice/positioning/server/src/Sensor/ClockUtility.cpp
+++ /dev/null
@@ -1,414 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*************************************************************************
-@file ClockUtility.cpp
-@detail Common processing function concerning clock
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "ClockUtility.h"
-#include "ClockUtility_private.h"
-
-/*
- Global Constant Definitions
-* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-static const u_int16 kUsMonth[3][12] = { /* Mnumonic For Remembering The Months With Fewer Than 31 Days Table(Leap year version) Task_31499 */
- {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}, /* Number of days per month(If it is not a leap year) */
- {31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}, /* Number of days per month(For leap years) */
- {0, 31, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334} /* Cumulative number of days per month(If it is not a leap year) */
-};
-
-static const ClockDayCntTbl kUlDayCntTbl = {
- /* 1970 Year */ {{0x000007B2U, 0x00000000U, {0x00000000U, 0x0028DE80U, 0x004DC880U, 0x0076A700U, 0x009E3400U, 0x00C71280U, 0x00EE9F80U, 0x01177E00U, 0x01405C80U, 0x0167E980U, 0x0190C800U, 0x01B85500U}}, // NOLINT(whitespace/line_length)
- /* 1971 Year */ {0x000007B3U, 0x01E13380U, {0x01E13380U, 0x020A1200U, 0x022EFC00U, 0x0257DA80U, 0x027F6780U, 0x02A84600U, 0x02CFD300U, 0x02F8B180U, 0x03219000U, 0x03491D00U, 0x0371FB80U, 0x03998880U}}, // NOLINT(whitespace/line_length)
- /* 1972 Year */ {0x000007B4U, 0x03C26700U, {0x03C26700U, 0x03EB4580U, 0x04118100U, 0x043A5F80U, 0x0461EC80U, 0x048ACB00U, 0x04B25800U, 0x04DB3680U, 0x05041500U, 0x052BA200U, 0x05548080U, 0x057C0D80U}}, // NOLINT(whitespace/line_length)
- /* 1973 Year */ {0x000007B5U, 0x05A4EC00U, {0x05A4EC00U, 0x05CDCA80U, 0x05F2B480U, 0x061B9300U, 0x06432000U, 0x066BFE80U, 0x06938B80U, 0x06BC6A00U, 0x06E54880U, 0x070CD580U, 0x0735B400U, 0x075D4100U}}, // NOLINT(whitespace/line_length)
- /* 1974 Year */ {0x000007B6U, 0x07861F80U, {0x07861F80U, 0x07AEFE00U, 0x07D3E800U, 0x07FCC680U, 0x08245380U, 0x084D3200U, 0x0874BF00U, 0x089D9D80U, 0x08C67C00U, 0x08EE0900U, 0x0916E780U, 0x093E7480U}}, // NOLINT(whitespace/line_length)
- /* 1975 Year */ {0x000007B7U, 0x09675300U, {0x09675300U, 0x09903180U, 0x09B51B80U, 0x09DDFA00U, 0x0A058700U, 0x0A2E6580U, 0x0A55F280U, 0x0A7ED100U, 0x0AA7AF80U, 0x0ACF3C80U, 0x0AF81B00U, 0x0B1FA800U}}, // NOLINT(whitespace/line_length)
- /* 1976 Year */ {0x000007B8U, 0x0B488680U, {0x0B488680U, 0x0B716500U, 0x0B97A080U, 0x0BC07F00U, 0x0BE80C00U, 0x0C10EA80U, 0x0C387780U, 0x0C615600U, 0x0C8A3480U, 0x0CB1C180U, 0x0CDAA000U, 0x0D022D00U}}, // NOLINT(whitespace/line_length)
- /* 1977 Year */ {0x000007B9U, 0x0D2B0B80U, {0x0D2B0B80U, 0x0D53EA00U, 0x0D78D400U, 0x0DA1B280U, 0x0DC93F80U, 0x0DF21E00U, 0x0E19AB00U, 0x0E428980U, 0x0E6B6800U, 0x0E92F500U, 0x0EBBD380U, 0x0EE36080U}}, // NOLINT(whitespace/line_length)
- /* 1978 Year */ {0x000007BAU, 0x0F0C3F00U, {0x0F0C3F00U, 0x0F351D80U, 0x0F5A0780U, 0x0F82E600U, 0x0FAA7300U, 0x0FD35180U, 0x0FFADE80U, 0x1023BD00U, 0x104C9B80U, 0x10742880U, 0x109D0700U, 0x10C49400U}}, // NOLINT(whitespace/line_length)
- /* 1979 Year */ {0x000007BBU, 0x10ED7280U, {0x10ED7280U, 0x11165100U, 0x113B3B00U, 0x11641980U, 0x118BA680U, 0x11B48500U, 0x11DC1200U, 0x1204F080U, 0x122DCF00U, 0x12555C00U, 0x127E3A80U, 0x12A5C780U}}, // NOLINT(whitespace/line_length)
- /* 1980 Year */ {0x000007BCU, 0x12CEA600U, {0x12CEA600U, 0x12F78480U, 0x131DC000U, 0x13469E80U, 0x136E2B80U, 0x13970A00U, 0x13BE9700U, 0x13E77580U, 0x14105400U, 0x1437E100U, 0x1460BF80U, 0x14884C80U}}, // NOLINT(whitespace/line_length)
- /* 1981 Year */ {0x000007BDU, 0x14B12B00U, {0x14B12B00U, 0x14DA0980U, 0x14FEF380U, 0x1527D200U, 0x154F5F00U, 0x15783D80U, 0x159FCA80U, 0x15C8A900U, 0x15F18780U, 0x16191480U, 0x1641F300U, 0x16698000U}}, // NOLINT(whitespace/line_length)
- /* 1982 Year */ {0x000007BEU, 0x16925E80U, {0x16925E80U, 0x16BB3D00U, 0x16E02700U, 0x17090580U, 0x17309280U, 0x17597100U, 0x1780FE00U, 0x17A9DC80U, 0x17D2BB00U, 0x17FA4800U, 0x18232680U, 0x184AB380U}}, // NOLINT(whitespace/line_length)
- /* 1983 Year */ {0x000007BFU, 0x18739200U, {0x18739200U, 0x189C7080U, 0x18C15A80U, 0x18EA3900U, 0x1911C600U, 0x193AA480U, 0x19623180U, 0x198B1000U, 0x19B3EE80U, 0x19DB7B80U, 0x1A045A00U, 0x1A2BE700U}}, // NOLINT(whitespace/line_length)
- /* 1984 Year */ {0x000007C0U, 0x1A54C580U, {0x1A54C580U, 0x1A7DA400U, 0x1AA3DF80U, 0x1ACCBE00U, 0x1AF44B00U, 0x1B1D2980U, 0x1B44B680U, 0x1B6D9500U, 0x1B967380U, 0x1BBE0080U, 0x1BE6DF00U, 0x1C0E6C00U}}, // NOLINT(whitespace/line_length)
- /* 1985 Year */ {0x000007C1U, 0x1C374A80U, {0x1C374A80U, 0x1C602900U, 0x1C851300U, 0x1CADF180U, 0x1CD57E80U, 0x1CFE5D00U, 0x1D25EA00U, 0x1D4EC880U, 0x1D77A700U, 0x1D9F3400U, 0x1DC81280U, 0x1DEF9F80U}}, // NOLINT(whitespace/line_length)
- /* 1986 Year */ {0x000007C2U, 0x1E187E00U, {0x1E187E00U, 0x1E415C80U, 0x1E664680U, 0x1E8F2500U, 0x1EB6B200U, 0x1EDF9080U, 0x1F071D80U, 0x1F2FFC00U, 0x1F58DA80U, 0x1F806780U, 0x1FA94600U, 0x1FD0D300U}}, // NOLINT(whitespace/line_length)
- /* 1987 Year */ {0x000007C3U, 0x1FF9B180U, {0x1FF9B180U, 0x20229000U, 0x20477A00U, 0x20705880U, 0x2097E580U, 0x20C0C400U, 0x20E85100U, 0x21112F80U, 0x213A0E00U, 0x21619B00U, 0x218A7980U, 0x21B20680U}}, // NOLINT(whitespace/line_length)
- /* 1988 Year */ {0x000007C4U, 0x21DAE500U, {0x21DAE500U, 0x2203C380U, 0x2229FF00U, 0x2252DD80U, 0x227A6A80U, 0x22A34900U, 0x22CAD600U, 0x22F3B480U, 0x231C9300U, 0x23442000U, 0x236CFE80U, 0x23948B80U}}, // NOLINT(whitespace/line_length)
- /* 1989 Year */ {0x000007C5U, 0x23BD6A00U, {0x23BD6A00U, 0x23E64880U, 0x240B3280U, 0x24341100U, 0x245B9E00U, 0x24847C80U, 0x24AC0980U, 0x24D4E800U, 0x24FDC680U, 0x25255380U, 0x254E3200U, 0x2575BF00U}}, // NOLINT(whitespace/line_length)
- /* 1990 Year */ {0x000007C6U, 0x259E9D80U, {0x259E9D80U, 0x25C77C00U, 0x25EC6600U, 0x26154480U, 0x263CD180U, 0x2665B000U, 0x268D3D00U, 0x26B61B80U, 0x26DEFA00U, 0x27068700U, 0x272F6580U, 0x2756F280U}}, // NOLINT(whitespace/line_length)
- /* 1991 Year */ {0x000007C7U, 0x277FD100U, {0x277FD100U, 0x27A8AF80U, 0x27CD9980U, 0x27F67800U, 0x281E0500U, 0x2846E380U, 0x286E7080U, 0x28974F00U, 0x28C02D80U, 0x28E7BA80U, 0x29109900U, 0x29382600U}}, // NOLINT(whitespace/line_length)
- /* 1992 Year */ {0x000007C8U, 0x29610480U, {0x29610480U, 0x2989E300U, 0x29B01E80U, 0x29D8FD00U, 0x2A008A00U, 0x2A296880U, 0x2A50F580U, 0x2A79D400U, 0x2AA2B280U, 0x2ACA3F80U, 0x2AF31E00U, 0x2B1AAB00U}}, // NOLINT(whitespace/line_length)
- /* 1993 Year */ {0x000007C9U, 0x2B438980U, {0x2B438980U, 0x2B6C6800U, 0x2B915200U, 0x2BBA3080U, 0x2BE1BD80U, 0x2C0A9C00U, 0x2C322900U, 0x2C5B0780U, 0x2C83E600U, 0x2CAB7300U, 0x2CD45180U, 0x2CFBDE80U}}, // NOLINT(whitespace/line_length)
- /* 1994 Year */ {0x000007CAU, 0x2D24BD00U, {0x2D24BD00U, 0x2D4D9B80U, 0x2D728580U, 0x2D9B6400U, 0x2DC2F100U, 0x2DEBCF80U, 0x2E135C80U, 0x2E3C3B00U, 0x2E651980U, 0x2E8CA680U, 0x2EB58500U, 0x2EDD1200U}}, // NOLINT(whitespace/line_length)
- /* 1995 Year */ {0x000007CBU, 0x2F05F080U, {0x2F05F080U, 0x2F2ECF00U, 0x2F53B900U, 0x2F7C9780U, 0x2FA42480U, 0x2FCD0300U, 0x2FF49000U, 0x301D6E80U, 0x30464D00U, 0x306DDA00U, 0x3096B880U, 0x30BE4580U}}, // NOLINT(whitespace/line_length)
- /* 1996 Year */ {0x000007CCU, 0x30E72400U, {0x30E72400U, 0x31100280U, 0x31363E00U, 0x315F1C80U, 0x3186A980U, 0x31AF8800U, 0x31D71500U, 0x31FFF380U, 0x3228D200U, 0x32505F00U, 0x32793D80U, 0x32A0CA80U}}, // NOLINT(whitespace/line_length)
- /* 1997 Year */ {0x000007CDU, 0x32C9A900U, {0x32C9A900U, 0x32F28780U, 0x33177180U, 0x33405000U, 0x3367DD00U, 0x3390BB80U, 0x33B84880U, 0x33E12700U, 0x340A0580U, 0x34319280U, 0x345A7100U, 0x3481FE00U}}, // NOLINT(whitespace/line_length)
- /* 1998 Year */ {0x000007CEU, 0x34AADC80U, {0x34AADC80U, 0x34D3BB00U, 0x34F8A500U, 0x35218380U, 0x35491080U, 0x3571EF00U, 0x35997C00U, 0x35C25A80U, 0x35EB3900U, 0x3612C600U, 0x363BA480U, 0x36633180U}}, // NOLINT(whitespace/line_length)
- /* 1999 Year */ {0x000007CFU, 0x368C1000U, {0x368C1000U, 0x36B4EE80U, 0x36D9D880U, 0x3702B700U, 0x372A4400U, 0x37532280U, 0x377AAF80U, 0x37A38E00U, 0x37CC6C80U, 0x37F3F980U, 0x381CD800U, 0x38446500U}}, // NOLINT(whitespace/line_length)
- /* 2000 Year */ {0x000007D0U, 0x386D4380U, {0x386D4380U, 0x38962200U, 0x38BC5D80U, 0x38E53C00U, 0x390CC900U, 0x3935A780U, 0x395D3480U, 0x39861300U, 0x39AEF180U, 0x39D67E80U, 0x39FF5D00U, 0x3A26EA00U}}, // NOLINT(whitespace/line_length)
- /* 2001 Year */ {0x000007D1U, 0x3A4FC880U, {0x3A4FC880U, 0x3A78A700U, 0x3A9D9100U, 0x3AC66F80U, 0x3AEDFC80U, 0x3B16DB00U, 0x3B3E6800U, 0x3B674680U, 0x3B902500U, 0x3BB7B200U, 0x3BE09080U, 0x3C081D80U}}, // NOLINT(whitespace/line_length)
- /* 2002 Year */ {0x000007D2U, 0x3C30FC00U, {0x3C30FC00U, 0x3C59DA80U, 0x3C7EC480U, 0x3CA7A300U, 0x3CCF3000U, 0x3CF80E80U, 0x3D1F9B80U, 0x3D487A00U, 0x3D715880U, 0x3D98E580U, 0x3DC1C400U, 0x3DE95100U}}, // NOLINT(whitespace/line_length)
- /* 2003 Year */ {0x000007D3U, 0x3E122F80U, {0x3E122F80U, 0x3E3B0E00U, 0x3E5FF800U, 0x3E88D680U, 0x3EB06380U, 0x3ED94200U, 0x3F00CF00U, 0x3F29AD80U, 0x3F528C00U, 0x3F7A1900U, 0x3FA2F780U, 0x3FCA8480U}}, // NOLINT(whitespace/line_length)
- /* 2004 Year */ {0x000007D4U, 0x3FF36300U, {0x3FF36300U, 0x401C4180U, 0x40427D00U, 0x406B5B80U, 0x4092E880U, 0x40BBC700U, 0x40E35400U, 0x410C3280U, 0x41351100U, 0x415C9E00U, 0x41857C80U, 0x41AD0980U}}, // NOLINT(whitespace/line_length)
- /* 2005 Year */ {0x000007D5U, 0x41D5E800U, {0x41D5E800U, 0x41FEC680U, 0x4223B080U, 0x424C8F00U, 0x42741C00U, 0x429CFA80U, 0x42C48780U, 0x42ED6600U, 0x43164480U, 0x433DD180U, 0x4366B000U, 0x438E3D00U}}, // NOLINT(whitespace/line_length)
- /* 2006 Year */ {0x000007D6U, 0x43B71B80U, {0x43B71B80U, 0x43DFFA00U, 0x4404E400U, 0x442DC280U, 0x44554F80U, 0x447E2E00U, 0x44A5BB00U, 0x44CE9980U, 0x44F77800U, 0x451F0500U, 0x4547E380U, 0x456F7080U}}, // NOLINT(whitespace/line_length)
- /* 2007 Year */ {0x000007D7U, 0x45984F00U, {0x45984F00U, 0x45C12D80U, 0x45E61780U, 0x460EF600U, 0x46368300U, 0x465F6180U, 0x4686EE80U, 0x46AFCD00U, 0x46D8AB80U, 0x47003880U, 0x47291700U, 0x4750A400U}}, // NOLINT(whitespace/line_length)
- /* 2008 Year */ {0x000007D8U, 0x47798280U, {0x47798280U, 0x47A26100U, 0x47C89C80U, 0x47F17B00U, 0x48190800U, 0x4841E680U, 0x48697380U, 0x48925200U, 0x48BB3080U, 0x48E2BD80U, 0x490B9C00U, 0x49332900U}}, // NOLINT(whitespace/line_length)
- /* 2009 Year */ {0x000007D9U, 0x495C0780U, {0x495C0780U, 0x4984E600U, 0x49A9D000U, 0x49D2AE80U, 0x49FA3B80U, 0x4A231A00U, 0x4A4AA700U, 0x4A738580U, 0x4A9C6400U, 0x4AC3F100U, 0x4AECCF80U, 0x4B145C80U}}, // NOLINT(whitespace/line_length)
- /* 2010 Year */ {0x000007DAU, 0x4B3D3B00U, {0x4B3D3B00U, 0x4B661980U, 0x4B8B0380U, 0x4BB3E200U, 0x4BDB6F00U, 0x4C044D80U, 0x4C2BDA80U, 0x4C54B900U, 0x4C7D9780U, 0x4CA52480U, 0x4CCE0300U, 0x4CF59000U}}, // NOLINT(whitespace/line_length)
- /* 2011 Year */ {0x000007DBU, 0x4D1E6E80U, {0x4D1E6E80U, 0x4D474D00U, 0x4D6C3700U, 0x4D951580U, 0x4DBCA280U, 0x4DE58100U, 0x4E0D0E00U, 0x4E35EC80U, 0x4E5ECB00U, 0x4E865800U, 0x4EAF3680U, 0x4ED6C380U}}, // NOLINT(whitespace/line_length)
- /* 2012 Year */ {0x000007DCU, 0x4EFFA200U, {0x4EFFA200U, 0x4F288080U, 0x4F4EBC00U, 0x4F779A80U, 0x4F9F2780U, 0x4FC80600U, 0x4FEF9300U, 0x50187180U, 0x50415000U, 0x5068DD00U, 0x5091BB80U, 0x50B94880U}}, // NOLINT(whitespace/line_length)
- /* 2013 Year */ {0x000007DDU, 0x50E22700U, {0x50E22700U, 0x510B0580U, 0x512FEF80U, 0x5158CE00U, 0x51805B00U, 0x51A93980U, 0x51D0C680U, 0x51F9A500U, 0x52228380U, 0x524A1080U, 0x5272EF00U, 0x529A7C00U}}, // NOLINT(whitespace/line_length)
- /* 2014 Year */ {0x000007DEU, 0x52C35A80U, {0x52C35A80U, 0x52EC3900U, 0x53112300U, 0x533A0180U, 0x53618E80U, 0x538A6D00U, 0x53B1FA00U, 0x53DAD880U, 0x5403B700U, 0x542B4400U, 0x54542280U, 0x547BAF80U}}, // NOLINT(whitespace/line_length)
- /* 2015 Year */ {0x000007DFU, 0x54A48E00U, {0x54A48E00U, 0x54CD6C80U, 0x54F25680U, 0x551B3500U, 0x5542C200U, 0x556BA080U, 0x55932D80U, 0x55BC0C00U, 0x55E4EA80U, 0x560C7780U, 0x56355600U, 0x565CE300U}}, // NOLINT(whitespace/line_length)
- /* 2016 Year */ {0x000007E0U, 0x5685C180U, {0x5685C180U, 0x56AEA000U, 0x56D4DB80U, 0x56FDBA00U, 0x57254700U, 0x574E2580U, 0x5775B280U, 0x579E9100U, 0x57C76F80U, 0x57EEFC80U, 0x5817DB00U, 0x583F6800U}}, // NOLINT(whitespace/line_length)
- /* 2017 Year */ {0x000007E1U, 0x58684680U, {0x58684680U, 0x58912500U, 0x58B60F00U, 0x58DEED80U, 0x59067A80U, 0x592F5900U, 0x5956E600U, 0x597FC480U, 0x59A8A300U, 0x59D03000U, 0x59F90E80U, 0x5A209B80U}}, // NOLINT(whitespace/line_length)
- /* 2018 Year */ {0x000007E2U, 0x5A497A00U, {0x5A497A00U, 0x5A725880U, 0x5A974280U, 0x5AC02100U, 0x5AE7AE00U, 0x5B108C80U, 0x5B381980U, 0x5B60F800U, 0x5B89D680U, 0x5BB16380U, 0x5BDA4200U, 0x5C01CF00U}}, // NOLINT(whitespace/line_length)
- /* 2019 Year */ {0x000007E3U, 0x5C2AAD80U, {0x5C2AAD80U, 0x5C538C00U, 0x5C787600U, 0x5CA15480U, 0x5CC8E180U, 0x5CF1C000U, 0x5D194D00U, 0x5D422B80U, 0x5D6B0A00U, 0x5D929700U, 0x5DBB7580U, 0x5DE30280U}}, // NOLINT(whitespace/line_length)
- /* 2020 Year */ {0x000007E4U, 0x5E0BE100U, {0x5E0BE100U, 0x5E34BF80U, 0x5E5AFB00U, 0x5E83D980U, 0x5EAB6680U, 0x5ED44500U, 0x5EFBD200U, 0x5F24B080U, 0x5F4D8F00U, 0x5F751C00U, 0x5F9DFA80U, 0x5FC58780U}}, // NOLINT(whitespace/line_length)
- /* 2021 Year */ {0x000007E5U, 0x5FEE6600U, {0x5FEE6600U, 0x60174480U, 0x603C2E80U, 0x60650D00U, 0x608C9A00U, 0x60B57880U, 0x60DD0580U, 0x6105E400U, 0x612EC280U, 0x61564F80U, 0x617F2E00U, 0x61A6BB00U}}, // NOLINT(whitespace/line_length)
- /* 2022 Year */ {0x000007E6U, 0x61CF9980U, {0x61CF9980U, 0x61F87800U, 0x621D6200U, 0x62464080U, 0x626DCD80U, 0x6296AC00U, 0x62BE3900U, 0x62E71780U, 0x630FF600U, 0x63378300U, 0x63606180U, 0x6387EE80U}}, // NOLINT(whitespace/line_length)
- /* 2023 Year */ {0x000007E7U, 0x63B0CD00U, {0x63B0CD00U, 0x63D9AB80U, 0x63FE9580U, 0x64277400U, 0x644F0100U, 0x6477DF80U, 0x649F6C80U, 0x64C84B00U, 0x64F12980U, 0x6518B680U, 0x65419500U, 0x65692200U}}, // NOLINT(whitespace/line_length)
- /* 2024 Year */ {0x000007E8U, 0x65920080U, {0x65920080U, 0x65BADF00U, 0x65E11A80U, 0x6609F900U, 0x66318600U, 0x665A6480U, 0x6681F180U, 0x66AAD000U, 0x66D3AE80U, 0x66FB3B80U, 0x67241A00U, 0x674BA700U}}, // NOLINT(whitespace/line_length)
- /* 2025 Year */ {0x000007E9U, 0x67748580U, {0x67748580U, 0x679D6400U, 0x67C24E00U, 0x67EB2C80U, 0x6812B980U, 0x683B9800U, 0x68632500U, 0x688C0380U, 0x68B4E200U, 0x68DC6F00U, 0x69054D80U, 0x692CDA80U}}, // NOLINT(whitespace/line_length)
- /* 2026 Year */ {0x000007EAU, 0x6955B900U, {0x6955B900U, 0x697E9780U, 0x69A38180U, 0x69CC6000U, 0x69F3ED00U, 0x6A1CCB80U, 0x6A445880U, 0x6A6D3700U, 0x6A961580U, 0x6ABDA280U, 0x6AE68100U, 0x6B0E0E00U}}, // NOLINT(whitespace/line_length)
- /* 2027 Year */ {0x000007EBU, 0x6B36EC80U, {0x6B36EC80U, 0x6B5FCB00U, 0x6B84B500U, 0x6BAD9380U, 0x6BD52080U, 0x6BFDFF00U, 0x6C258C00U, 0x6C4E6A80U, 0x6C774900U, 0x6C9ED600U, 0x6CC7B480U, 0x6CEF4180U}}, // NOLINT(whitespace/line_length)
- /* 2028 Year */ {0x000007ECU, 0x6D182000U, {0x6D182000U, 0x6D40FE80U, 0x6D673A00U, 0x6D901880U, 0x6DB7A580U, 0x6DE08400U, 0x6E081100U, 0x6E30EF80U, 0x6E59CE00U, 0x6E815B00U, 0x6EAA3980U, 0x6ED1C680U}}, // NOLINT(whitespace/line_length)
- /* 2029 Year */ {0x000007EDU, 0x6EFAA500U, {0x6EFAA500U, 0x6F238380U, 0x6F486D80U, 0x6F714C00U, 0x6F98D900U, 0x6FC1B780U, 0x6FE94480U, 0x70122300U, 0x703B0180U, 0x70628E80U, 0x708B6D00U, 0x70B2FA00U}}, // NOLINT(whitespace/line_length)
- /* 2030 Year */ {0x000007EEU, 0x70DBD880U, {0x70DBD880U, 0x7104B700U, 0x7129A100U, 0x71527F80U, 0x717A0C80U, 0x71A2EB00U, 0x71CA7800U, 0x71F35680U, 0x721C3500U, 0x7243C200U, 0x726CA080U, 0x72942D80U}}, // NOLINT(whitespace/line_length)
- /* 2031 Year */ {0x000007EFU, 0x72BD0C00U, {0x72BD0C00U, 0x72E5EA80U, 0x730AD480U, 0x7333B300U, 0x735B4000U, 0x73841E80U, 0x73ABAB80U, 0x73D48A00U, 0x73FD6880U, 0x7424F580U, 0x744DD400U, 0x74756100U}}, // NOLINT(whitespace/line_length)
- /* 2032 Year */ {0x000007F0U, 0x749E3F80U, {0x749E3F80U, 0x74C71E00U, 0x74ED5980U, 0x75163800U, 0x753DC500U, 0x7566A380U, 0x758E3080U, 0x75B70F00U, 0x75DFED80U, 0x76077A80U, 0x76305900U, 0x7657E600U}}, // NOLINT(whitespace/line_length)
- /* 2033 Year */ {0x000007F1U, 0x7680C480U, {0x7680C480U, 0x76A9A300U, 0x76CE8D00U, 0x76F76B80U, 0x771EF880U, 0x7747D700U, 0x776F6400U, 0x77984280U, 0x77C12100U, 0x77E8AE00U, 0x78118C80U, 0x78391980U}}, // NOLINT(whitespace/line_length)
- /* 2034 Year */ {0x000007F2U, 0x7861F800U, {0x7861F800U, 0x788AD680U, 0x78AFC080U, 0x78D89F00U, 0x79002C00U, 0x79290A80U, 0x79509780U, 0x79797600U, 0x79A25480U, 0x79C9E180U, 0x79F2C000U, 0x7A1A4D00U}}, // NOLINT(whitespace/line_length)
- /* 2035 Year */ {0x000007F3U, 0x7A432B80U, {0x7A432B80U, 0x7A6C0A00U, 0x7A90F400U, 0x7AB9D280U, 0x7AE15F80U, 0x7B0A3E00U, 0x7B31CB00U, 0x7B5AA980U, 0x7B838800U, 0x7BAB1500U, 0x7BD3F380U, 0x7BFB8080U}}, // NOLINT(whitespace/line_length)
- /* 2036 Year */ {0x000007F4U, 0x7C245F00U, {0x7C245F00U, 0x7C4D3D80U, 0x7C737900U, 0x7C9C5780U, 0x7CC3E480U, 0x7CECC300U, 0x7D145000U, 0x7D3D2E80U, 0x7D660D00U, 0x7D8D9A00U, 0x7DB67880U, 0x7DDE0580U}}, // NOLINT(whitespace/line_length)
- /* 2037 Year */ {0x000007F5U, 0x7E06E400U, {0x7E06E400U, 0x7E2FC280U, 0x7E54AC80U, 0x7E7D8B00U, 0x7EA51800U, 0x7ECDF680U, 0x7EF58380U, 0x7F1E6200U, 0x7F474080U, 0x7F6ECD80U, 0x7F97AC00U, 0x7FBF3900U}}, // NOLINT(whitespace/line_length)
- /* 2038 Year */ {0x000007F6U, 0x7FE81780U, {0x7FE81780U, 0x8010F600U, 0x8035E000U, 0x805EBE80U, 0x80864B80U, 0x80AF2A00U, 0x80D6B700U, 0x80FF9580U, 0x81287400U, 0x81500100U, 0x8178DF80U, 0x81A06C80U}}, // NOLINT(whitespace/line_length)
- /* 2039 Year */ {0x000007F7U, 0x81C94B00U, {0x81C94B00U, 0x81F22980U, 0x82171380U, 0x823FF200U, 0x82677F00U, 0x82905D80U, 0x82B7EA80U, 0x82E0C900U, 0x8309A780U, 0x83313480U, 0x835A1300U, 0x8381A000U}}, // NOLINT(whitespace/line_length)
- /* 2040 Year */ {0x000007F8U, 0x83AA7E80U, {0x83AA7E80U, 0x83D35D00U, 0x83F99880U, 0x84227700U, 0x844A0400U, 0x8472E280U, 0x849A6F80U, 0x84C34E00U, 0x84EC2C80U, 0x8513B980U, 0x853C9800U, 0x85642500U}}, // NOLINT(whitespace/line_length)
- /* 2041 Year */ {0x000007F9U, 0x858D0380U, {0x858D0380U, 0x85B5E200U, 0x85DACC00U, 0x8603AA80U, 0x862B3780U, 0x86541600U, 0x867BA300U, 0x86A48180U, 0x86CD6000U, 0x86F4ED00U, 0x871DCB80U, 0x87455880U}}, // NOLINT(whitespace/line_length)
- /* 2042 Year */ {0x000007FAU, 0x876E3700U, {0x876E3700U, 0x87971580U, 0x87BBFF80U, 0x87E4DE00U, 0x880C6B00U, 0x88354980U, 0x885CD680U, 0x8885B500U, 0x88AE9380U, 0x88D62080U, 0x88FEFF00U, 0x89268C00U}}, // NOLINT(whitespace/line_length)
- /* 2043 Year */ {0x000007FBU, 0x894F6A80U, {0x894F6A80U, 0x89784900U, 0x899D3300U, 0x89C61180U, 0x89ED9E80U, 0x8A167D00U, 0x8A3E0A00U, 0x8A66E880U, 0x8A8FC700U, 0x8AB75400U, 0x8AE03280U, 0x8B07BF80U}}, // NOLINT(whitespace/line_length)
- /* 2044 Year */ {0x000007FCU, 0x8B309E00U, {0x8B309E00U, 0x8B597C80U, 0x8B7FB800U, 0x8BA89680U, 0x8BD02380U, 0x8BF90200U, 0x8C208F00U, 0x8C496D80U, 0x8C724C00U, 0x8C99D900U, 0x8CC2B780U, 0x8CEA4480U}}, // NOLINT(whitespace/line_length)
- /* 2045 Year */ {0x000007FDU, 0x8D132300U, {0x8D132300U, 0x8D3C0180U, 0x8D60EB80U, 0x8D89CA00U, 0x8DB15700U, 0x8DDA3580U, 0x8E01C280U, 0x8E2AA100U, 0x8E537F80U, 0x8E7B0C80U, 0x8EA3EB00U, 0x8ECB7800U}}, // NOLINT(whitespace/line_length)
- /* 2046 Year */ {0x000007FEU, 0x8EF45680U, {0x8EF45680U, 0x8F1D3500U, 0x8F421F00U, 0x8F6AFD80U, 0x8F928A80U, 0x8FBB6900U, 0x8FE2F600U, 0x900BD480U, 0x9034B300U, 0x905C4000U, 0x90851E80U, 0x90ACAB80U}}, // NOLINT(whitespace/line_length)
- /* 2047 Year */ {0x000007FFU, 0x90D58A00U, {0x90D58A00U, 0x90FE6880U, 0x91235280U, 0x914C3100U, 0x9173BE00U, 0x919C9C80U, 0x91C42980U, 0x91ED0800U, 0x9215E680U, 0x923D7380U, 0x92665200U, 0x928DDF00U}}, // NOLINT(whitespace/line_length)
- /* 2048 Year */ {0x00000800U, 0x92B6BD80U, {0x92B6BD80U, 0x92DF9C00U, 0x9305D780U, 0x932EB600U, 0x93564300U, 0x937F2180U, 0x93A6AE80U, 0x93CF8D00U, 0x93F86B80U, 0x941FF880U, 0x9448D700U, 0x94706400U}}, // NOLINT(whitespace/line_length)
- /* 2049 Year */ {0x00000801U, 0x94994280U, {0x94994280U, 0x94C22100U, 0x94E70B00U, 0x950FE980U, 0x95377680U, 0x95605500U, 0x9587E200U, 0x95B0C080U, 0x95D99F00U, 0x96012C00U, 0x962A0A80U, 0x96519780U}}, // NOLINT(whitespace/line_length)
- /* 2050 Year */ {0x00000802U, 0x967A7600U, {0x967A7600U, 0x96A35480U, 0x96C83E80U, 0x96F11D00U, 0x9718AA00U, 0x97418880U, 0x97691580U, 0x9791F400U, 0x97BAD280U, 0x97E25F80U, 0x980B3E00U, 0x9832CB00U}}, // NOLINT(whitespace/line_length)
- /* 2051 Year */ {0x00000803U, 0x985BA980U, {0x985BA980U, 0x98848800U, 0x98A97200U, 0x98D25080U, 0x98F9DD80U, 0x9922BC00U, 0x994A4900U, 0x99732780U, 0x999C0600U, 0x99C39300U, 0x99EC7180U, 0x9A13FE80U}}, // NOLINT(whitespace/line_length)
- /* 2052 Year */ {0x00000804U, 0x9A3CDD00U, {0x9A3CDD00U, 0x9A65BB80U, 0x9A8BF700U, 0x9AB4D580U, 0x9ADC6280U, 0x9B054100U, 0x9B2CCE00U, 0x9B55AC80U, 0x9B7E8B00U, 0x9BA61800U, 0x9BCEF680U, 0x9BF68380U}}, // NOLINT(whitespace/line_length)
- /* 2053 Year */ {0x00000805U, 0x9C1F6200U, {0x9C1F6200U, 0x9C484080U, 0x9C6D2A80U, 0x9C960900U, 0x9CBD9600U, 0x9CE67480U, 0x9D0E0180U, 0x9D36E000U, 0x9D5FBE80U, 0x9D874B80U, 0x9DB02A00U, 0x9DD7B700U}}, // NOLINT(whitespace/line_length)
- /* 2054 Year */ {0x00000806U, 0x9E009580U, {0x9E009580U, 0x9E297400U, 0x9E4E5E00U, 0x9E773C80U, 0x9E9EC980U, 0x9EC7A800U, 0x9EEF3500U, 0x9F181380U, 0x9F40F200U, 0x9F687F00U, 0x9F915D80U, 0x9FB8EA80U}}, // NOLINT(whitespace/line_length)
- /* 2055 Year */ {0x00000807U, 0x9FE1C900U, {0x9FE1C900U, 0xA00AA780U, 0xA02F9180U, 0xA0587000U, 0xA07FFD00U, 0xA0A8DB80U, 0xA0D06880U, 0xA0F94700U, 0xA1222580U, 0xA149B280U, 0xA1729100U, 0xA19A1E00U}}, // NOLINT(whitespace/line_length)
- /* 2056 Year */ {0x00000808U, 0xA1C2FC80U, {0xA1C2FC80U, 0xA1EBDB00U, 0xA2121680U, 0xA23AF500U, 0xA2628200U, 0xA28B6080U, 0xA2B2ED80U, 0xA2DBCC00U, 0xA304AA80U, 0xA32C3780U, 0xA3551600U, 0xA37CA300U}}, // NOLINT(whitespace/line_length)
- /* 2057 Year */ {0x00000809U, 0xA3A58180U, {0xA3A58180U, 0xA3CE6000U, 0xA3F34A00U, 0xA41C2880U, 0xA443B580U, 0xA46C9400U, 0xA4942100U, 0xA4BCFF80U, 0xA4E5DE00U, 0xA50D6B00U, 0xA5364980U, 0xA55DD680U}}, // NOLINT(whitespace/line_length)
- /* 2058 Year */ {0x0000080AU, 0xA586B500U, {0xA586B500U, 0xA5AF9380U, 0xA5D47D80U, 0xA5FD5C00U, 0xA624E900U, 0xA64DC780U, 0xA6755480U, 0xA69E3300U, 0xA6C71180U, 0xA6EE9E80U, 0xA7177D00U, 0xA73F0A00U}}, // NOLINT(whitespace/line_length)
- /* 2059 Year */ {0x0000080BU, 0xA767E880U, {0xA767E880U, 0xA790C700U, 0xA7B5B100U, 0xA7DE8F80U, 0xA8061C80U, 0xA82EFB00U, 0xA8568800U, 0xA87F6680U, 0xA8A84500U, 0xA8CFD200U, 0xA8F8B080U, 0xA9203D80U}}, // NOLINT(whitespace/line_length)
- /* 2060 Year */ {0x0000080CU, 0xA9491C00U, {0xA9491C00U, 0xA971FA80U, 0xA9983600U, 0xA9C11480U, 0xA9E8A180U, 0xAA118000U, 0xAA390D00U, 0xAA61EB80U, 0xAA8ACA00U, 0xAAB25700U, 0xAADB3580U, 0xAB02C280U}}, // NOLINT(whitespace/line_length)
- /* 2061 Year */ {0x0000080DU, 0xAB2BA100U, {0xAB2BA100U, 0xAB547F80U, 0xAB796980U, 0xABA24800U, 0xABC9D500U, 0xABF2B380U, 0xAC1A4080U, 0xAC431F00U, 0xAC6BFD80U, 0xAC938A80U, 0xACBC6900U, 0xACE3F600U}}, // NOLINT(whitespace/line_length)
- /* 2062 Year */ {0x0000080EU, 0xAD0CD480U, {0xAD0CD480U, 0xAD35B300U, 0xAD5A9D00U, 0xAD837B80U, 0xADAB0880U, 0xADD3E700U, 0xADFB7400U, 0xAE245280U, 0xAE4D3100U, 0xAE74BE00U, 0xAE9D9C80U, 0xAEC52980U}}, // NOLINT(whitespace/line_length)
- /* 2063 Year */ {0x0000080FU, 0xAEEE0800U, {0xAEEE0800U, 0xAF16E680U, 0xAF3BD080U, 0xAF64AF00U, 0xAF8C3C00U, 0xAFB51A80U, 0xAFDCA780U, 0xB0058600U, 0xB02E6480U, 0xB055F180U, 0xB07ED000U, 0xB0A65D00U}}, // NOLINT(whitespace/line_length)
- /* 2064 Year */ {0x00000810U, 0xB0CF3B80U, {0xB0CF3B80U, 0xB0F81A00U, 0xB11E5580U, 0xB1473400U, 0xB16EC100U, 0xB1979F80U, 0xB1BF2C80U, 0xB1E80B00U, 0xB210E980U, 0xB2387680U, 0xB2615500U, 0xB288E200U}}, // NOLINT(whitespace/line_length)
- /* 2065 Year */ {0x00000811U, 0xB2B1C080U, {0xB2B1C080U, 0xB2DA9F00U, 0xB2FF8900U, 0xB3286780U, 0xB34FF480U, 0xB378D300U, 0xB3A06000U, 0xB3C93E80U, 0xB3F21D00U, 0xB419AA00U, 0xB4428880U, 0xB46A1580U}}, // NOLINT(whitespace/line_length)
- /* 2066 Year */ {0x00000812U, 0xB492F400U, {0xB492F400U, 0xB4BBD280U, 0xB4E0BC80U, 0xB5099B00U, 0xB5312800U, 0xB55A0680U, 0xB5819380U, 0xB5AA7200U, 0xB5D35080U, 0xB5FADD80U, 0xB623BC00U, 0xB64B4900U}}, // NOLINT(whitespace/line_length)
- /* 2067 Year */ {0x00000813U, 0xB6742780U, {0xB6742780U, 0xB69D0600U, 0xB6C1F000U, 0xB6EACE80U, 0xB7125B80U, 0xB73B3A00U, 0xB762C700U, 0xB78BA580U, 0xB7B48400U, 0xB7DC1100U, 0xB804EF80U, 0xB82C7C80U}}, // NOLINT(whitespace/line_length)
- /* 2068 Year */ {0x00000814U, 0xB8555B00U, {0xB8555B00U, 0xB87E3980U, 0xB8A47500U, 0xB8CD5380U, 0xB8F4E080U, 0xB91DBF00U, 0xB9454C00U, 0xB96E2A80U, 0xB9970900U, 0xB9BE9600U, 0xB9E77480U, 0xBA0F0180U}}, // NOLINT(whitespace/line_length)
- /* 2069 Year */ {0x00000815U, 0xBA37E000U, {0xBA37E000U, 0xBA60BE80U, 0xBA85A880U, 0xBAAE8700U, 0xBAD61400U, 0xBAFEF280U, 0xBB267F80U, 0xBB4F5E00U, 0xBB783C80U, 0xBB9FC980U, 0xBBC8A800U, 0xBBF03500U}}, // NOLINT(whitespace/line_length)
- /* 2070 Year */ {0x00000816U, 0xBC191380U, {0xBC191380U, 0xBC41F200U, 0xBC66DC00U, 0xBC8FBA80U, 0xBCB74780U, 0xBCE02600U, 0xBD07B300U, 0xBD309180U, 0xBD597000U, 0xBD80FD00U, 0xBDA9DB80U, 0xBDD16880U}}, // NOLINT(whitespace/line_length)
- /* 2071 Year */ {0x00000817U, 0xBDFA4700U, {0xBDFA4700U, 0xBE232580U, 0xBE480F80U, 0xBE70EE00U, 0xBE987B00U, 0xBEC15980U, 0xBEE8E680U, 0xBF11C500U, 0xBF3AA380U, 0xBF623080U, 0xBF8B0F00U, 0xBFB29C00U}}, // NOLINT(whitespace/line_length)
- /* 2072 Year */ {0x00000818U, 0xBFDB7A80U, {0xBFDB7A80U, 0xC0045900U, 0xC02A9480U, 0xC0537300U, 0xC07B0000U, 0xC0A3DE80U, 0xC0CB6B80U, 0xC0F44A00U, 0xC11D2880U, 0xC144B580U, 0xC16D9400U, 0xC1952100U}}, // NOLINT(whitespace/line_length)
- /* 2073 Year */ {0x00000819U, 0xC1BDFF80U, {0xC1BDFF80U, 0xC1E6DE00U, 0xC20BC800U, 0xC234A680U, 0xC25C3380U, 0xC2851200U, 0xC2AC9F00U, 0xC2D57D80U, 0xC2FE5C00U, 0xC325E900U, 0xC34EC780U, 0xC3765480U}}, // NOLINT(whitespace/line_length)
- /* 2074 Year */ {0x0000081AU, 0xC39F3300U, {0xC39F3300U, 0xC3C81180U, 0xC3ECFB80U, 0xC415DA00U, 0xC43D6700U, 0xC4664580U, 0xC48DD280U, 0xC4B6B100U, 0xC4DF8F80U, 0xC5071C80U, 0xC52FFB00U, 0xC5578800U}}, // NOLINT(whitespace/line_length)
- /* 2075 Year */ {0x0000081BU, 0xC5806680U, {0xC5806680U, 0xC5A94500U, 0xC5CE2F00U, 0xC5F70D80U, 0xC61E9A80U, 0xC6477900U, 0xC66F0600U, 0xC697E480U, 0xC6C0C300U, 0xC6E85000U, 0xC7112E80U, 0xC738BB80U}}, // NOLINT(whitespace/line_length)
- /* 2076 Year */ {0x0000081CU, 0xC7619A00U, {0xC7619A00U, 0xC78A7880U, 0xC7B0B400U, 0xC7D99280U, 0xC8011F80U, 0xC829FE00U, 0xC8518B00U, 0xC87A6980U, 0xC8A34800U, 0xC8CAD500U, 0xC8F3B380U, 0xC91B4080U}}, // NOLINT(whitespace/line_length)
- /* 2077 Year */ {0x0000081DU, 0xC9441F00U, {0xC9441F00U, 0xC96CFD80U, 0xC991E780U, 0xC9BAC600U, 0xC9E25300U, 0xCA0B3180U, 0xCA32BE80U, 0xCA5B9D00U, 0xCA847B80U, 0xCAAC0880U, 0xCAD4E700U, 0xCAFC7400U}}, // NOLINT(whitespace/line_length)
- /* 2078 Year */ {0x0000081EU, 0xCB255280U, {0xCB255280U, 0xCB4E3100U, 0xCB731B00U, 0xCB9BF980U, 0xCBC38680U, 0xCBEC6500U, 0xCC13F200U, 0xCC3CD080U, 0xCC65AF00U, 0xCC8D3C00U, 0xCCB61A80U, 0xCCDDA780U}}, // NOLINT(whitespace/line_length)
- /* 2079 Year */ {0x0000081FU, 0xCD068600U, {0xCD068600U, 0xCD2F6480U, 0xCD544E80U, 0xCD7D2D00U, 0xCDA4BA00U, 0xCDCD9880U, 0xCDF52580U, 0xCE1E0400U, 0xCE46E280U, 0xCE6E6F80U, 0xCE974E00U, 0xCEBEDB00U}}, // NOLINT(whitespace/line_length)
- /* 2080 Year */ {0x00000820U, 0xCEE7B980U, {0xCEE7B980U, 0xCF109800U, 0xCF36D380U, 0xCF5FB200U, 0xCF873F00U, 0xCFB01D80U, 0xCFD7AA80U, 0xD0008900U, 0xD0296780U, 0xD050F480U, 0xD079D300U, 0xD0A16000U}}, // NOLINT(whitespace/line_length)
- /* 2081 Year */ {0x00000821U, 0xD0CA3E80U, {0xD0CA3E80U, 0xD0F31D00U, 0xD1180700U, 0xD140E580U, 0xD1687280U, 0xD1915100U, 0xD1B8DE00U, 0xD1E1BC80U, 0xD20A9B00U, 0xD2322800U, 0xD25B0680U, 0xD2829380U}}, // NOLINT(whitespace/line_length)
- /* 2082 Year */ {0x00000822U, 0xD2AB7200U, {0xD2AB7200U, 0xD2D45080U, 0xD2F93A80U, 0xD3221900U, 0xD349A600U, 0xD3728480U, 0xD39A1180U, 0xD3C2F000U, 0xD3EBCE80U, 0xD4135B80U, 0xD43C3A00U, 0xD463C700U}}, // NOLINT(whitespace/line_length)
- /* 2083 Year */ {0x00000823U, 0xD48CA580U, {0xD48CA580U, 0xD4B58400U, 0xD4DA6E00U, 0xD5034C80U, 0xD52AD980U, 0xD553B800U, 0xD57B4500U, 0xD5A42380U, 0xD5CD0200U, 0xD5F48F00U, 0xD61D6D80U, 0xD644FA80U}}, // NOLINT(whitespace/line_length)
- /* 2084 Year */ {0x00000824U, 0xD66DD900U, {0xD66DD900U, 0xD696B780U, 0xD6BCF300U, 0xD6E5D180U, 0xD70D5E80U, 0xD7363D00U, 0xD75DCA00U, 0xD786A880U, 0xD7AF8700U, 0xD7D71400U, 0xD7FFF280U, 0xD8277F80U}}, // NOLINT(whitespace/line_length)
- /* 2085 Year */ {0x00000825U, 0xD8505E00U, {0xD8505E00U, 0xD8793C80U, 0xD89E2680U, 0xD8C70500U, 0xD8EE9200U, 0xD9177080U, 0xD93EFD80U, 0xD967DC00U, 0xD990BA80U, 0xD9B84780U, 0xD9E12600U, 0xDA08B300U}}, // NOLINT(whitespace/line_length)
- /* 2086 Year */ {0x00000826U, 0xDA319180U, {0xDA319180U, 0xDA5A7000U, 0xDA7F5A00U, 0xDAA83880U, 0xDACFC580U, 0xDAF8A400U, 0xDB203100U, 0xDB490F80U, 0xDB71EE00U, 0xDB997B00U, 0xDBC25980U, 0xDBE9E680U}}, // NOLINT(whitespace/line_length)
- /* 2087 Year */ {0x00000827U, 0xDC12C500U, {0xDC12C500U, 0xDC3BA380U, 0xDC608D80U, 0xDC896C00U, 0xDCB0F900U, 0xDCD9D780U, 0xDD016480U, 0xDD2A4300U, 0xDD532180U, 0xDD7AAE80U, 0xDDA38D00U, 0xDDCB1A00U}}, // NOLINT(whitespace/line_length)
- /* 2088 Year */ {0x00000828U, 0xDDF3F880U, {0xDDF3F880U, 0xDE1CD700U, 0xDE431280U, 0xDE6BF100U, 0xDE937E00U, 0xDEBC5C80U, 0xDEE3E980U, 0xDF0CC800U, 0xDF35A680U, 0xDF5D3380U, 0xDF861200U, 0xDFAD9F00U}}, // NOLINT(whitespace/line_length)
- /* 2089 Year */ {0x00000829U, 0xDFD67D80U, {0xDFD67D80U, 0xDFFF5C00U, 0xE0244600U, 0xE04D2480U, 0xE074B180U, 0xE09D9000U, 0xE0C51D00U, 0xE0EDFB80U, 0xE116DA00U, 0xE13E6700U, 0xE1674580U, 0xE18ED280U}}, // NOLINT(whitespace/line_length)
- /* 2090 Year */ {0x0000082AU, 0xE1B7B100U, {0xE1B7B100U, 0xE1E08F80U, 0xE2057980U, 0xE22E5800U, 0xE255E500U, 0xE27EC380U, 0xE2A65080U, 0xE2CF2F00U, 0xE2F80D80U, 0xE31F9A80U, 0xE3487900U, 0xE3700600U}}, // NOLINT(whitespace/line_length)
- /* 2091 Year */ {0x0000082BU, 0xE398E480U, {0xE398E480U, 0xE3C1C300U, 0xE3E6AD00U, 0xE40F8B80U, 0xE4371880U, 0xE45FF700U, 0xE4878400U, 0xE4B06280U, 0xE4D94100U, 0xE500CE00U, 0xE529AC80U, 0xE5513980U}}, // NOLINT(whitespace/line_length)
- /* 2092 Year */ {0x0000082CU, 0xE57A1800U, {0xE57A1800U, 0xE5A2F680U, 0xE5C93200U, 0xE5F21080U, 0xE6199D80U, 0xE6427C00U, 0xE66A0900U, 0xE692E780U, 0xE6BBC600U, 0xE6E35300U, 0xE70C3180U, 0xE733BE80U}}, // NOLINT(whitespace/line_length)
- /* 2093 Year */ {0x0000082DU, 0xE75C9D00U, {0xE75C9D00U, 0xE7857B80U, 0xE7AA6580U, 0xE7D34400U, 0xE7FAD100U, 0xE823AF80U, 0xE84B3C80U, 0xE8741B00U, 0xE89CF980U, 0xE8C48680U, 0xE8ED6500U, 0xE914F200U}}, // NOLINT(whitespace/line_length)
- /* 2094 Year */ {0x0000082EU, 0xE93DD080U, {0xE93DD080U, 0xE966AF00U, 0xE98B9900U, 0xE9B47780U, 0xE9DC0480U, 0xEA04E300U, 0xEA2C7000U, 0xEA554E80U, 0xEA7E2D00U, 0xEAA5BA00U, 0xEACE9880U, 0xEAF62580U}}, // NOLINT(whitespace/line_length)
- /* 2095 Year */ {0x0000082FU, 0xEB1F0400U, {0xEB1F0400U, 0xEB47E280U, 0xEB6CCC80U, 0xEB95AB00U, 0xEBBD3800U, 0xEBE61680U, 0xEC0DA380U, 0xEC368200U, 0xEC5F6080U, 0xEC86ED80U, 0xECAFCC00U, 0xECD75900U}}, // NOLINT(whitespace/line_length)
- /* 2096 Year */ {0x00000830U, 0xED003780U, {0xED003780U, 0xED291600U, 0xED4F5180U, 0xED783000U, 0xED9FBD00U, 0xEDC89B80U, 0xEDF02880U, 0xEE190700U, 0xEE41E580U, 0xEE697280U, 0xEE925100U, 0xEEB9DE00U}}, // NOLINT(whitespace/line_length)
- /* 2097 Year */ {0x00000831U, 0xEEE2BC80U, {0xEEE2BC80U, 0xEF0B9B00U, 0xEF308500U, 0xEF596380U, 0xEF80F080U, 0xEFA9CF00U, 0xEFD15C00U, 0xEFFA3A80U, 0xF0231900U, 0xF04AA600U, 0xF0738480U, 0xF09B1180U}}, // NOLINT(whitespace/line_length)
- /* 2098 Year */ {0x00000832U, 0xF0C3F000U, {0xF0C3F000U, 0xF0ECCE80U, 0xF111B880U, 0xF13A9700U, 0xF1622400U, 0xF18B0280U, 0xF1B28F80U, 0xF1DB6E00U, 0xF2044C80U, 0xF22BD980U, 0xF254B800U, 0xF27C4500U}}, // NOLINT(whitespace/line_length)
- /* 2099 Year */ {0x00000833U, 0xF2A52380U, {0xF2A52380U, 0xF2CE0200U, 0xF2F2EC00U, 0xF31BCA80U, 0xF3435780U, 0xF36C3600U, 0xF393C300U, 0xF3BCA180U, 0xF3E58000U, 0xF40D0D00U, 0xF435EB80U, 0xF45D7880U}}, // NOLINT(whitespace/line_length)
- /* 2100 Year */ {0x00000834U, 0xF4865700U, {0xF4865700U, 0xF4AF3580U, 0xF4D41F80U, 0xF4FCFE00U, 0xF5248B00U, 0xF54D6980U, 0xF574F680U, 0xF59DD500U, 0xF5C6B380U, 0xF5EE4080U, 0xF6171F00U, 0xF63EAC00U}}, // NOLINT(whitespace/line_length)
- /* 2101 Year */ {0x00000835U, 0xF6678A80U, {0xF6678A80U, 0xF6906900U, 0xF6B55300U, 0xF6DE3180U, 0xF705BE80U, 0xF72E9D00U, 0xF7562A00U, 0xF77F0880U, 0xF7A7E700U, 0xF7CF7400U, 0xF7F85280U, 0xF81FDF80U}}, // NOLINT(whitespace/line_length)
- /* 2102 Year */ {0x00000836U, 0xF848BE00U, {0xF848BE00U, 0xF8719C80U, 0xF8968680U, 0xF8BF6500U, 0xF8E6F200U, 0xF90FD080U, 0xF9375D80U, 0xF9603C00U, 0xF9891A80U, 0xF9B0A780U, 0xF9D98600U, 0xFA011300U}}, // NOLINT(whitespace/line_length)
- /* 2103 Year */ {0x00000837U, 0xFA29F180U, {0xFA29F180U, 0xFA52D000U, 0xFA77BA00U, 0xFAA09880U, 0xFAC82580U, 0xFAF10400U, 0xFB189100U, 0xFB416F80U, 0xFB6A4E00U, 0xFB91DB00U, 0xFBBAB980U, 0xFBE24680U}}, // NOLINT(whitespace/line_length)
- /* 2104 Year */ {0x00000838U, 0xFC0B2500U, {0xFC0B2500U, 0xFC340380U, 0xFC5A3F00U, 0xFC831D80U, 0xFCAAAA80U, 0xFCD38900U, 0xFCFB1600U, 0xFD23F480U, 0xFD4CD300U, 0xFD746000U, 0xFD9D3E80U, 0xFDC4CB80U}}, // NOLINT(whitespace/line_length)
- /* 2105 Year */ {0x00000839U, 0xFDEDAA00U, {0xFDEDAA00U, 0xFE168880U, 0xFE3B7280U, 0xFE645100U, 0xFE8BDE00U, 0xFEB4BC80U, 0xFEDC4980U, 0xFF052800U, 0xFF2E0680U, 0xFF559380U, 0xFF7E7200U, 0xFFA5FF00U}}, // NOLINT(whitespace/line_length)
- /* 2106 Year */ {0x0000083AU, 0xFFCEDD80U, {0xFFCEDD80U, 0xFFF7BC00U, 0x001CA600U, 0x00458480U, 0x006D1180U, 0x0095F000U, 0x00BD7D00U, 0x00E65B80U, 0x010F3A00U, 0x0136C700U, 0x015FA580U, 0x01873280U}} // NOLINT(whitespace/line_length)
- }
-};
-
-/*************************************************************************
-@brief The date is converted at the multiplication second.
-@outline The specified time and date is converted at the multiplication second
- from epoch time(0:0:0 January 1, 1970. )
-@type Completion return type<BR>
-@param[in] const LPSYSTEMTIME lp_st : Converted time and date
-@param[out] u_int32* uli_sec : Multiplication second from epoch time
-@threshold lp_st != NULL, uli_sec != NULL <BR>
- 1970 <= lp_st.wYear <= 2105 <BR>
- 1 <= lp_st.wMonth <= 12 <BR>
- 1 <= lp_st.wDay <= 31 <BR>
- 0 <= lp_st.wHour <= 23 <BR>
- 0 <= lp_st.wMinute <= 59 <BR>
- 0 <= lp_st.wSecond <= 59 <BR>
-@return RET_API
-@retval RET_NORMAL : Normal end
-@retval RET_ERROR : Abnormal end
-*****************************************************************************/
-RET_API ClockUtilityConvertDateToSecond(const LPSYSTEMTIME lp_st, u_int32* uli_sec) {
- u_int8 imflg; /* Leap year determination flag 0:Not a leap year 1:Leap year */
- u_int32 ui_day;
- int32 century;
- RET_API ret = RET_NORMAL;
-
- /* Checking the NULL of Pointer Arguments */
- if ((lp_st == NULL) || (uli_sec == NULL)) {
- ret = RET_ERROR;
- } else {
- *uli_sec = 0; /* Reset accumulated seconds to 0 */
-
- /* Parameter check */
- if (((lp_st->wYear < 1970) || (2105 < lp_st->wYear)) || /* Check Year to Convert */
- ((lp_st->wMonth < 1) || (12 < lp_st->wMonth))) { /* Check month to convert */
- ret = RET_ERROR;
- } else {
- /* Determine the leap year and select the "Mnumonic For Remembering The Months With Fewer Than 31 Days" table. */
- imflg = 0; /* Set the default to a non-leap year */
- if ((lp_st->wYear % 4) == 0) { /* If the year is divisible by 4, */
- imflg = 1; /* Be a leap year */
- }
- if ((lp_st->wYear % 100) == 0) { /* However,If the year is divisible by 100 */
- imflg = 0; /* Not leap years */
- }
- if ((lp_st->wYear % 400) == 0) { /* However,If the year is divisible by 400 */
- imflg = 1; /* Be a leap year */
- }
-
- /* Parameter check again */
- if (((lp_st->wDay < 1) || (kUsMonth[imflg][lp_st->wMonth - 1] < lp_st->wDay)) || /* Check date to convert */
- (23 < lp_st->wHour) || /* Check when converting */
- (59 < lp_st->wMinute) || /* Check the minutes to convert */
- (59 < lp_st->wSecond) ) { /* Check the seconds to convert */
- ret = RET_ERROR;
- } else {
- /* Converting Hours, Minutes, and Seconds to Seconds */
- *uli_sec = lp_st->wSecond; /* The specified seconds are stored as is. */
- *uli_sec += lp_st->wMinute * SEC_PER_MIN; /* Convert specified minutes to seconds and add */
- *uli_sec += lp_st->wHour * SEC_PER_HOUR; /* Convert specified hour to second and add */
-
- /* Convert a date to the number of days since January 1, 1970 */ /* Task_31499 */
- ui_day = 0;
- ui_day += (lp_st->wYear - 1970) * 365;
-
- /* Because years divisible by 100 are not counted as leap years,Calculate the number of times */
- century = lp_st->wYear / 100;
- /* Add the number of days added for the leap year up to the previous year */
- /* Shift year to right by 2 bits until last year(Divide by 4) -
- Exclude years divisible by 100(century) + Shift century right by 2 bits(Divide by 4
- -> If it is divisible by 4, it is counted as a leap year */
- ui_day += ((lp_st->wYear - 1) >> 2) - century + (century >> 2) - 477; /* 477 -> Number of leap years up to 1970 */
- /* Add the number of days up to the previous month of the current year */
- ui_day += kUsMonth[2][lp_st->wMonth - 1] + ((lp_st->wMonth > 2) ? imflg : 0);
-
- ui_day += (lp_st->wDay - 1); /* Add the number of elapsed days */
-
- *uli_sec += (ui_day * SEC_PER_DAY); /* Convert the number of days to seconds and add */
- }
- }
- }
-
- return ret;
-}
-
-/*************************************************************************
-@brief The multiplication second is converted at the date.
-@outline The specified multiplication second is converted as a multiplication second from epoch time(0:0:0 January 1, 1970.) at time and date.
-@type Completion return type
-@param[in] const u_int32*uli_sec : Converted multiplication second from epoch time
-@param[out] LPSYSTEMTIME lp_st : Time after it converts it of date
-@threshold lp_st != NULL, uli_sec != NULL <BR>
- uli_sec < 0xFFCEDD80
-@return RET_API
-@retval RET_NORMAL : Normal end
-@retval RET_ERROR : Abnormal end
-*****************************************************************************/
-
-RET_API ClockUtilityConvertSecondToDate(const u_int32* uli_sec, LPSYSTEMTIME lp_st) {
- u_int32 i; /* Loop control */
- u_int32 j; /* Loop control */
- u_int32 uli_sec_wk; /* Total value save */
- RET_API ret = RET_NORMAL; /* return value */
- u_int8 complete_cnv = FALSE; /* Conversion completion flag */
- u_int8 valid_date; /* Date Valid Value Flag */
-
- /* Checking the NULL of Pointer Arguments */
- if ((uli_sec == NULL) || (lp_st == NULL)) {
- ret = RET_ERROR;
- } else {
- /* Back up the accumulated seconds to the work. */
- uli_sec_wk = static_cast<u_int32>(*uli_sec);
-
- /* Parameter check processing */
- if (uli_sec_wk >= kUlDayCntTbl.st_tbl[CNV_YEAR_MAX].ulCount) {
- ret = RET_ERROR;
- } else {
- /* Initialize */
- lp_st->wYear = (WORD)(kUlDayCntTbl.st_tbl[0].ulYear);
- lp_st->wMonth = (WORD)(1); /* Month Settings */
- lp_st->wDay = (WORD)(1); /* Day Settings */
- lp_st->wDayOfWeek = (WORD)(4); /* Setting the day of the week(Note : Corrected in cases other than 1970) */
- lp_st->wHour = (WORD)(0); /* Time setting */
- lp_st->wMinute = (WORD)(0); /* Minute setting */
- lp_st->wSecond = (WORD)(0); /* Set Seconds */
- lp_st->wMilliseconds = (WORD)(0); /* Set msec. */
-
- /* Search time accumulated seconds conversion table */
- for (i = 0; i < CNV_YEAR_MAX; i++) {
- /* Set the year(Maximum value) */
- if ((kUlDayCntTbl.st_tbl[i + 1].ulCount > uli_sec_wk) || (i == (CNV_YEAR_MAX - 1))) {
- lp_st->wYear = (WORD)kUlDayCntTbl.st_tbl[i].ulYear;
-
- /* Set the month(Maximum value) */
- j = 0;
- while ((j < 12) && (complete_cnv == FALSE)) {
- /* Prevent 12Month(j=11)ulMonth[12] access */
- valid_date = FALSE;
- if (j == (MONTH_MAX - 1)) {
- valid_date = TRUE;
- } else {
- if (kUlDayCntTbl.st_tbl[i].ulMonth[j + 1] > uli_sec_wk) {
- valid_date = TRUE;
- }
- }
-
- if (valid_date == TRUE) {
- lp_st->wMonth = (WORD)(j + 1);
-
- /* Day-of-week,Set Date Hour Minute Second */
- lp_st->wDayOfWeek = (WORD)((lp_st->wDayOfWeek +
- (WORD)((uli_sec_wk / SEC_PER_DAY) % 7)) % 7); /* Setting the day of the week */
- uli_sec_wk = uli_sec_wk - (u_int32)(kUlDayCntTbl.st_tbl[i].ulMonth[j]);
- lp_st->wDay = (WORD)((uli_sec_wk / SEC_PER_DAY) + 1); /* Day Settings */
- lp_st->wSecond = (WORD)(uli_sec_wk % SEC_PER_MIN); /* Set Seconds */
- lp_st->wMinute = (WORD)((uli_sec_wk % SEC_PER_HOUR) / SEC_PER_MIN); /* Minute setting */
- lp_st->wHour = (WORD)((uli_sec_wk % SEC_PER_DAY) / SEC_PER_HOUR); /* Time setting */
-
- complete_cnv = TRUE; /* Completion */
- }
- j++;
- }
- }
-
- if (complete_cnv != FALSE) {
- break;
- }
- }
- }
- }
-
- return ret;
-}
-
-/*************************************************************************
-@brief Type conversion is done.
-@outline It converts it from the TimeData type to the SYSTEMTIME type.
-@type Completion return type
-@param[in] const TimeData* base_time : Time of conversion origin
-@param[out] const SYSTEMTIME* result_time : Time after it converts it
-@threshold base_time != NULL<BR>
-@threshold result_time != NULL
-@return CLOCK_RETURN
-@retval CLOCK_OK : Normal end
-@retval CLOCK_ERROR : Abnormal end
-@retval CLOCK_ERROR_ARGUMENTS : The argument is wrong
-@trace
-*****************************************************************************/
-CLOCK_RETURN ClockApiConvertTimeDataToSYSTEMTIME(const TimeData* base_time, SYSTEMTIME* result_time) {
- CLOCK_RETURN ret = CLOCK_ERROR;
- RET_API ret_cnv = RET_ERROR;
- u_int32 total_sec = 0;
-
- if ((base_time != NULL) && (result_time != NULL)) {
- /* Converting TimeData Types to SYSTEMTIME Types */
- result_time->wYear = static_cast<WORD>(base_time->year);
- result_time->wMonth = static_cast<WORD>(base_time->month);
- result_time->wDay = static_cast<WORD>(base_time->day);
- result_time->wHour = static_cast<WORD>(base_time->hour);
- result_time->wMinute = static_cast<WORD>(base_time->minute);
- result_time->wSecond = static_cast<WORD>(base_time->second);
- result_time->wMilliseconds = 0; /* 0 because there is no corresponding parameter */
- result_time->wDayOfWeek = CLKMNG_SUN; /* 0 because there is no corresponding parameter */
-
- ret_cnv = ClockUtilityConvertDateToSecond(result_time, &total_sec);
- if (ret_cnv == RET_NORMAL) {
- /* Calculate the day of the week from the cumulative second. */
- ret_cnv = ClockUtilityConvertSecondToDate(&total_sec, result_time);
- if (ret_cnv == RET_NORMAL) {
- ret = CLOCK_OK;
- } else {
- ret = CLOCK_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ClockUtility.lib:%s:LINE:%d\r\nClockApiConvertTimeDataToSYSTEMTIME"\
- "ClockUtilityConvertSecondToDate ERROR!![%d]\r\n",
- LTEXT(__FILE__),
- __LINE__,
- ret);
- }
- } else {
- ret = CLOCK_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ClockUtility.lib:%s:LINE:%d\r\nClockApiConvertTimeDataToSYSTEMTIME"\
- "ClockUtilityConvertDateToSecond ERROR!![%d]\r\n",
- LTEXT(__FILE__),
- __LINE__,
- ret);
- }
-
- } else {
- /* Invalid argument */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ClockUtility.lib:%s:LINE:%d\r\nClockApiConvertTimeDataToSYSTEMTIME"\
- "Arguments ERROR!![%d]\r\n",
- LTEXT(__FILE__),
- __LINE__,
- ret);
- ret = CLOCK_ERROR_ARGUMENTS;
- }
- return ret;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Common.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Common.cpp
deleted file mode 100755
index 9503b34..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Common.cpp
+++ /dev/null
@@ -1,127 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :DeadReckoning_Common.cpp
- * System name :PastModel002
- * Subsystem name :DeadReckoning processes
- * Program name :DeadReckoning shared process(DEADRECKONING_COMMON)
- * Module configuration DeadReckoningMemcmp() Functions for Common Processing Memory Block Comparisons
- * DeadReckoningCheckDid() Common Processing Data ID Check Function
- * DeadReckoningGetDataMasterOffset() Get function for common processing data master offset value
- ******************************************************************************/
-#include "DeadReckoning_Common.h"
-#include <vehicle_service/positioning_base_library.h>
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static const DEADRECKONING_DID_OFFSET_TBL kGstDidListS[] = {
- /* Data ID Offset size Reserved */
- { VEHICLE_DID_DR_LONGITUDE, DEADRECKONING_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_DR_LATITUDE, DEADRECKONING_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_DR_ALTITUDE, DEADRECKONING_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_DR_SPEED, DEADRECKONING_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_DR_HEADING, DEADRECKONING_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_DR_GYRO_OFFSET, DEADRECKONING_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_DR_GYRO_SCALE_FACTOR, DEADRECKONING_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL, DEADRECKONING_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR, DEADRECKONING_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL, DEADRECKONING_OFFSET_NORMAL, {0, 0} },
- { 0, 0, {0, 0} } /* Termination code */
-};
-
-/*******************************************************************************
-* MODULE : DeadReckoningMemcmp
-* ABSTRACT : Functions for Common Processing Memory Block Comparisons
-* FUNCTION : Memory block comparison processing
-* ARGUMENT : *vp_data1 : Comparison target address 1
-* : *vp_data2 : Comparison target address 2
-* : uc_size : Comparison Size
-* NOTE :
-* RETURN : DEADRECKONING_EQ : No data change
-* : DEADRECKONING_NEQ : Data change
-******************************************************************************/
-u_int8 DeadReckoningMemcmp(const void *vp_data1, const void *vp_data2, size_t uc_size) { // LCOV_EXCL_START 8: dead code. // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 l_ret = DEADRECKONING_EQ;
- const u_int8 *p_data1 = (const u_int8 *)vp_data1;
- const u_int8 *p_data2 = (const u_int8 *)vp_data1;
-
- /* Loop by data size */
- while (uc_size > 0) {
- if (*p_data1 != *p_data2) {
- /* Data mismatch */
- l_ret = DEADRECKONING_NEQ;
- break;
- }
- p_data1++;
- p_data2++;
- uc_size--;
- }
- return(l_ret);
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningCheckDid
-* ABSTRACT : Common Processing Data ID Check Function
-* FUNCTION : Check if the specified DID corresponds to the vehicle sensor information
-* ARGUMENT : ul_did : Data ID
-* NOTE :
-* RETURN : DEADRECKONING_INVALID :Disabled
-* : DEADRECKONING_EFFECTIVE :Enabled
-******************************************************************************/
-int32 DeadReckoningCheckDid(DID ul_did) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- int32 i = 0;
- int32 l_ret = DEADRECKONING_INVALID;
-
- while (0 != kGstDidListS[i].ul_did) {
- if (kGstDidListS[i].ul_did == ul_did) {
- /* DID enabled */
- l_ret = DEADRECKONING_EFFECTIVE;
- break;
- }
- i++;
- }
- return(l_ret);
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningGetDataMasterOffset
-* ABSTRACT : Get function for common processing data master offset value
-* FUNCTION : Get the fixed offset value for a given DID
-* ARGUMENT : ul_did : Data ID
-* NOTE :
-* RETURN : Offset value(Returns 0 if DID is invalid)
-* :
-******************************************************************************/
-u_int16 DeadReckoningGetDataMasterOffset(DID ul_did) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- int32 i = 0; /* Generic counters */
- u_int16 us_ret = 0; /* Return value of this function */
-
- while (0 != kGstDidListS[i].ul_did) {
- if (kGstDidListS[i].ul_did == ul_did) {
- /* DID enabled */
- us_ret = kGstDidListS[i].us_offset;
- break;
- }
- i++;
- }
- return(us_ret);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_DataMasterMain.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_DataMasterMain.cpp
deleted file mode 100755
index 93adda0..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_DataMasterMain.cpp
+++ /dev/null
@@ -1,298 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :DeadReckoning_DataMasterMain.cpp
- * System name :GPF
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle SW Data Master
- * Module configuration :DeadReckoningInitDataMaster() Guess Navigation Data Master Initialization Function
- * :DeadReckoningSetDataMaster() Estimated Navigational Data Master SW Data Set Processing
- * :DeadReckoningGetDataMaster() Estimated Navigational Data Master Get Processing
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-#define DR_DEBUG 0
-
-/*******************************************************************************
-* MODULE : DeadReckoningInitDataMaster
-* ABSTRACT : Initialization of Guess Navigation Data Master
-* FUNCTION : Initialize the estimated navigation data master
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningInitDataMaster(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Vehicle sensor data master initialization */
- DeadReckoningInitLongitudeDr();
- DeadReckoningInitLatitudeDr();
- DeadReckoningInitAltitudeDr();
- DeadReckoningInitSpeedDr();
- DeadReckoningInitHeadingDr();
- DeadReckoningInitSnsCounterDr();
- DeadReckoningInitGyroOffsetDr();
- DeadReckoningInitGyroScaleFactorDr();
- DeadReckoningInitGyroScaleFactorLevelDr();
- DeadReckoningInitSpeedPulseScaleFactorDr();
- DeadReckoningInitSpeedPulseScaleFactorLevelDr();
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoning_SetDataMaster_Sub
-* ABSTRACT : Estimated Navigational Data Master SW Data Set Processing
-* FUNCTION : Set estimated navigation data
-* ARGUMENT : *p_data : SW vehicle signal notification data
-* : p_datamaster_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningSetDataMaster(const DEADRECKONING_DATA_MASTER *p_data,
- PFUNC_DR_DMASTER_SET_N p_datamaster_set_n) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 chg_type;
-
- static u_int8 gyro_parameter_chg_type = 0;
- static u_int8 speedpulse_parameter_chg_type = 0;
-
- /*------------------------------------------------------*/
- /* Call the data set processing associated with the DID */
- /* Call the data master set notification process */
- /*------------------------------------------------------*/
- switch (p_data->ul_did) {
- case VEHICLE_DID_DR_LONGITUDE:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetLongitudeDr(p_data);
- /* Implementation of delivery process at LATITUDE updating timings */
- /* Since the order of transmission (updating) at the main receiver is fixed, there is no problem. */
- break;
- }
- case VEHICLE_DID_DR_LATITUDE:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetLatitudeDr(p_data);
- (*p_datamaster_set_n)(p_data->ul_did, chg_type, DEADRECKONING_GETMETHOD_DR);
- break;
- }
- case VEHICLE_DID_DR_ALTITUDE:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetAltitudeDr(p_data);
- (*p_datamaster_set_n)(p_data->ul_did, chg_type, DEADRECKONING_GETMETHOD_DR);
- break;
- }
- case VEHICLE_DID_DR_SPEED:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetSpeedDr(p_data);
- (*p_datamaster_set_n)(p_data->ul_did, chg_type, DEADRECKONING_GETMETHOD_DR);
- break;
- }
- case VEHICLE_DID_DR_HEADING:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetHeadingDr(p_data);
- (*p_datamaster_set_n)(p_data->ul_did, chg_type, DEADRECKONING_GETMETHOD_DR);
- break;
- }
- case VEHICLE_DID_DR_SNS_COUNTER:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetSnsCounterDr(p_data);
- (*p_datamaster_set_n)(p_data->ul_did, chg_type, DEADRECKONING_GETMETHOD_DR);
- break;
- }
- case VEHICLE_DID_DR_GYRO_OFFSET:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetGyroOffsetDr(p_data);
- /* Distribution processing not performed in this DID */
- /* Delivery processing is executed when VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL is updated. */
- /* The GyroParameter order is defined by DeadReckoning_RcvMsg(). */
- if (chg_type == DEADRECKONING_NEQ) {
- gyro_parameter_chg_type = DEADRECKONING_NEQ;
- }
- break;
- }
- case VEHICLE_DID_DR_GYRO_SCALE_FACTOR:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetGyroScaleFactorDr(p_data);
- /* Distribution processing not performed in this DID */
- /* Delivery processing is executed when VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL is updated. */
- /* The GyroParameter order is defined by DeadReckoning_RcvMsg(). */
- if (chg_type == DEADRECKONING_NEQ) {
- gyro_parameter_chg_type = DEADRECKONING_NEQ;
- }
- break;
- }
- case VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetGyroScaleFactorLevelDr(p_data);
- if (gyro_parameter_chg_type == DEADRECKONING_NEQ) {
- chg_type = DEADRECKONING_NEQ;
- gyro_parameter_chg_type = DEADRECKONING_EQ;
- }
- (*p_datamaster_set_n)(p_data->ul_did, chg_type, DEADRECKONING_GETMETHOD_DR);
- break;
- }
- case VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetSpeedPulseScaleFactorDr(p_data);
- /* Distribution processing not performed in this DID */
- /* Delivery processing is executed when VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL is updated. */
- /* The SpeedPulseParameter order is defined by DeadReckoning_RcvMsg(). */
- if (chg_type == DEADRECKONING_NEQ) {
- speedpulse_parameter_chg_type = DEADRECKONING_NEQ;
- }
- break;
- }
- case VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningSetDataMaster DID=[0x%08X] DSIZE=[%d] \r\n",
- p_data->ul_did, p_data->us_size);
-#endif
- chg_type = DeadReckoningSetSpeedPulseScaleFactorLevelDr(p_data);
- if (speedpulse_parameter_chg_type == DEADRECKONING_NEQ) {
- chg_type = DEADRECKONING_NEQ;
- speedpulse_parameter_chg_type = DEADRECKONING_EQ;
- }
- (*p_datamaster_set_n)(p_data->ul_did, chg_type, DEADRECKONING_GETMETHOD_DR);
- break;
- }
- default:
- break;
- }
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningGetDataMaster
-* ABSTRACT : Estimated Navigational Data Master Get Processing
-* FUNCTION : Provide an estimated navigation data master
-* ARGUMENT : ul_did : Data ID corresponding to the vehicle information
-* : *p_data : Pointer to the data master provider
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningGetDataMaster(DID ul_did, DEADRECKONING_DATA_MASTER *p_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /*------------------------------------------------------*/
- /* Call the data Get processing associated with the DID */
- /*------------------------------------------------------*/
- switch (ul_did) {
- /*------------------------------------------------------*/
- /* Vehicle sensor data group */
- /*------------------------------------------------------*/
- case VEHICLE_DID_DR_LONGITUDE:
- {
- DeadReckoningGetLongitudeDr(p_data);
- break;
- }
- case VEHICLE_DID_DR_LATITUDE:
- {
- DeadReckoningGetLatitudeDr(p_data);
- break;
- }
- case VEHICLE_DID_DR_ALTITUDE:
- {
- DeadReckoningGetAltitudeDr(p_data);
- break;
- }
- case VEHICLE_DID_DR_SPEED:
- {
- DeadReckoningGetSpeedDr(p_data);
- break;
- }
- case VEHICLE_DID_DR_HEADING:
- {
- DeadReckoningGetHeadingDr(p_data);
- break;
- }
- case VEHICLE_DID_DR_SNS_COUNTER:
- {
- DeadReckoningGetSnsCounterDr(p_data);
- break;
- }
- case VEHICLE_DID_DR_GYRO_OFFSET:
- {
- DeadReckoningGetGyroOffsetDr(p_data);
- break;
- }
- case VEHICLE_DID_DR_GYRO_SCALE_FACTOR:
- {
- DeadReckoningGetGyroScaleFactorDr(p_data);
- break;
- }
- case VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL:
- {
- DeadReckoningGetGyroScaleFactorLevelDr(p_data);
- break;
- }
- case VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR:
- {
- DeadReckoningGetSpeedPulseScaleFactorDr(p_data);
- break;
- }
- case VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL:
- {
- DeadReckoningGetSpeedPulseScaleFactorLevelDr(p_data);
- break;
- }
- default:
- break;
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_DeliveryCtrl.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_DeliveryCtrl.cpp
deleted file mode 100755
index 0a08f5f..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_DeliveryCtrl.cpp
+++ /dev/null
@@ -1,835 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :DeadReckoning_DeliveryCtrl.cpp
- * System name :GPF
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle Sensor Destination Management(
- * Module configuration DeadReckoningInitDeliveryCtrlTbl() Vehicle sensor delivery destination management table initialization function
- * DeadReckoningInitDeliveryCtrlTblMng() Vehicle sensor delivery destination management table management area initialization function
- * DeadReckoningEntryDeliveryCtrl() Vehicle sensor delivery destination management registration function
- * :DeadReckoningAddDeliveryCtrlTbl() Vehicle sensor delivery destination management table addition function
- * :DeadReckoningUpdateDeliveryCtrlTbl() Vehicle sensor delivery destination management table update function
- * :DeadReckoning_DeliveryEntry_Delete() Vehicle sensor delivery destination management table deletion function
- * :DeadReckoningAddDeliveryCtrlTblMng() Vehicle sensor delivery destination management table management addition function
- * :DeadReckoningUpdateDeliveryCtrlTblMng() Vehicle sensor delivery destination management table management update function
- * :DeadReckoning_DeleteDeliveryCtrlTblMng_Touch() Vehicle sensor delivery destination management table management deletion (touch panel) function
- * DeadReckoningMakeDeliveryPnoTbl() Vehicle Sensor Destination PNO Table Creation Function
- * :DeadReckoningAddPnoTbl() Vehicle Sensor Destination PNO Table Addition Function
- * :DeadReckoningDeliveryProc() Vehicle Sensor Data Delivery Process
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DeliveryCtrl.h"
-#include "Vehicle_API.h"
-#include "Vehicle_API_Dummy.h"
-#include "Dead_Reckoning_Local_Api.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DELIVERY_CTRL_TBL g_delivery_dr_ctrltbl;
-static DEADRECKONING_DELIVERY_CTRL_TBL_MNG g_delivery_dr_ctrltbl_mng;
-static DEADRECKONING_DELIVERY_PNO_TBL g_delivery_dr_pnotbl;
-
-/* Stored data count */
-int32 g_delivery_dr_ctrl_num = 0;
-
-/* PastModel002 support DR */
-/*******************************************************************************
-* MODULE : DeadReckoningInitDeliveryCtrlTbl
-* ABSTRACT : Vehicle sensor delivery destination management table initialization function
-* FUNCTION : Delivery destination management table initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningInitDeliveryCtrlTbl(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&g_delivery_dr_ctrltbl, 0x00, sizeof(DEADRECKONING_DELIVERY_CTRL_TBL));
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningInitDeliveryCtrlTblMng
-* ABSTRACT : Vehicle sensor delivery destination management table management area initialization function
-* FUNCTION : Delivery destination management table management area initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningInitDeliveryCtrlTblMng(void) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&g_delivery_dr_ctrltbl_mng, 0x00, sizeof(DEADRECKONING_DELIVERY_CTRL_TBL_MNG));
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningEntryDeliveryCtrl
-* ABSTRACT : Vehicle sensor delivery destination management registration function
-* FUNCTION : Shipping management table,Update the shipping management table management.
-* ARGUMENT : p_st_delivery_entry : Pointer to the delivery registration information
-* NOTE :
-* RETURN : VEHICLE_RET_NORMAL :Successful registration
-******************************************************************************/
-DEAD_RECKONING_RET_API DeadReckoningEntryDeliveryCtrl(const DEADRECKONING_MSG_DELIVERY_ENTRY *p_st_delivery_entry) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- int32 i;
- u_int8 uc_action_type = DEADRECKONING_ACTION_TYPE_ADD;
- int32 uc_did_flag;
- DID ul_entry_did = p_st_delivery_entry->data.did;
- DEADRECKONING_DELIVERY_CTRL_TBL_MNG_DATA *p_st_existing_mng_data = NULL;
- /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- DEAD_RECKONING_RET_API ret = DEAD_RECKONING_RET_NORMAL;
-
- /* Check if the data ID exists. */
- uc_did_flag = DeadReckoningCheckDid(ul_entry_did);
- if (uc_did_flag == 0) {
- ret = DEADRECKONING_RET_ERROR_DID; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- }
-
- /* Check the number of registered shipments. */
- if ((ret == DEAD_RECKONING_RET_NORMAL) &&/* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- (g_delivery_dr_ctrltbl.us_num >= DEADRECKONING_DELIVERY_INFO_MAX)) {
- /* Return the FULL of delivery registrations*/
- ret = DEADRECKONING_RET_ERROR_BUFFULL; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- }
- /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- if (ret == DEAD_RECKONING_RET_NORMAL) {
- /* By searching for the delivery registration of the relevant DID,Hold the address. */
- for (i = 0; i < g_delivery_dr_ctrltbl_mng.us_num; i++) {
- if (g_delivery_dr_ctrltbl_mng.st_ctrl_tbl_mng_data[i].ul_did == ul_entry_did) {
- uc_action_type = DEADRECKONING_ACTION_TYPE_UPDATE;
- p_st_existing_mng_data = &g_delivery_dr_ctrltbl_mng.st_ctrl_tbl_mng_data[i];
- }
- }
-
- /* Add to the shipping management table.*/
- DeadReckoningAddDeliveryCtrlTbl(p_st_delivery_entry);
-
- /* Processing when updating existing data*/
- if (uc_action_type == DEADRECKONING_ACTION_TYPE_UPDATE) {
- /* Update the shipping management table.*/
- DeadReckoningUpdateDeliveryCtrlTbl(p_st_existing_mng_data);
-
- /* Update the shipping destination management table management information.*/
- DeadReckoningUpdateDeliveryCtrlTblMng(p_st_existing_mng_data);
- } else { /* Newly added processing*/
- /* Add to the shipping management table management information.*/
- DeadReckoningAddDeliveryCtrlTblMng(p_st_delivery_entry);
- }
- }
- return ret; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningAddDeliveryCtrlTbl
-* ABSTRACT : Vehicle sensor delivery destination management table addition function
-* FUNCTION : Add to the shipping management table.
-* ARGUMENT : *p_st_delivery_entry : Pointer to the delivery registration information
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningAddDeliveryCtrlTbl(const DEADRECKONING_MSG_DELIVERY_ENTRY *p_st_delivery_entry) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- DEADRECKONING_DELIVERY_CTRL_TBL_DATA *p_st_ctrl_data;
-
- p_st_ctrl_data = &g_delivery_dr_ctrltbl.st_ctrl_data[g_delivery_dr_ctrltbl.us_num];
- p_st_ctrl_data->ul_did = p_st_delivery_entry->data.did;
- p_st_ctrl_data->us_pno = p_st_delivery_entry->data.pno;
- p_st_ctrl_data->uc_chg_type = p_st_delivery_entry->data.delivery_timing;
- p_st_ctrl_data->uc_ctrl_flg = p_st_delivery_entry->data.ctrl_flg;
- p_st_ctrl_data->us_link_idx = DEADRECKONING_LINK_INDEX_END;
- p_st_ctrl_data->uc_method = DEADRECKONING_DELIVERY_METHOD_NORMAL;
-
- g_delivery_dr_ctrltbl.us_num = static_cast<u_int16>(g_delivery_dr_ctrltbl.us_num + 1);
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningUpdateDeliveryCtrlTbl
-* ABSTRACT : Vehicle sensor delivery destination management table update function
-* FUNCTION : Update the shipping management table.
-* ARGUMENT : *p_st_existing_mng_data : Pointer to the previous data information with the same data ID
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningUpdateDeliveryCtrlTbl(DEADRECKONING_DELIVERY_CTRL_TBL_MNG_DATA *p_st_existing_mng_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Update Link Index Only.
- For the index of the value of us_end_idx that matches the data ID of the distribution target management table management information
- Make us_link_idx a registered index */
- g_delivery_dr_ctrltbl.st_ctrl_data[p_st_existing_mng_data->us_end_idx].us_link_idx =
- static_cast<u_int16>(g_delivery_dr_ctrltbl.us_num - 1);
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningAddDeliveryCtrlTblMng
-* ABSTRACT : Vehicle sensor delivery destination management table management addition function
-* FUNCTION : Add to the shipping management table management.
-* ARGUMENT : *p_st_delivery_entry : Pointer to the delivery registration information
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningAddDeliveryCtrlTblMng(const DEADRECKONING_MSG_DELIVERY_ENTRY *p_st_delivery_entry) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- DEADRECKONING_DELIVERY_CTRL_TBL_MNG_DATA *p_st_ctr_mng_data;
-
- p_st_ctr_mng_data = &g_delivery_dr_ctrltbl_mng.st_ctrl_tbl_mng_data[g_delivery_dr_ctrltbl_mng.us_num];
- p_st_ctr_mng_data->ul_did = p_st_delivery_entry->data.did;
- p_st_ctr_mng_data->us_start_idx = static_cast<u_int16>(g_delivery_dr_ctrltbl.us_num - 1);
- p_st_ctr_mng_data->us_end_idx = static_cast<u_int16>(g_delivery_dr_ctrltbl.us_num - 1);
- p_st_ctr_mng_data->us_dlvry_entry_num++;
- g_delivery_dr_ctrltbl_mng.us_num++;
- g_delivery_dr_ctrl_num++;
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningUpdateDeliveryCtrlTblMng
-* ABSTRACT : Vehicle sensor delivery destination management table management update function
-* FUNCTION : Update the shipping management table management.
-* ARGUMENT : *p_st_existing_mng_data : Pointer to the previous data information with the same data ID
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningUpdateDeliveryCtrlTblMng(DEADRECKONING_DELIVERY_CTRL_TBL_MNG_DATA *p_st_existing_mng_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Update only the end index and the number of registered shipping destinations. */
- p_st_existing_mng_data->us_end_idx = static_cast<u_int16>(g_delivery_dr_ctrltbl.us_num - 1);
- p_st_existing_mng_data->us_dlvry_entry_num++;
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningMakeDeliveryPnoTbl
-* ABSTRACT : Vehicle sensor delivery destination PNO table creation function
-* FUNCTION : Create the shipping destination PNO table
-* ARGUMENT : ul_did Data ID
-* Change_type Delivery Trigger
-* NOTE :
-* RETURN : DEADRECKONING_DELIVERY_PNO_TBL* Pointer to the shipping PNO table
-******************************************************************************/
-DEADRECKONING_DELIVERY_PNO_TBL* DeadReckoningMakeDeliveryPnoTbl(DID ul_did, u_int8 change_type) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- int32 i;
- u_int16 us_index = 0;
- u_int16 us_num = 0;
-
- /* Get the start index and count of the corresponding data ID. */
- for (i = 0; i < g_delivery_dr_ctrl_num; i++) {
- /* Stores the information of the corresponding DID.. */
- if (g_delivery_dr_ctrltbl_mng.st_ctrl_tbl_mng_data[i].ul_did == ul_did) {
- us_index = g_delivery_dr_ctrltbl_mng.st_ctrl_tbl_mng_data[i].us_start_idx;
- us_num = g_delivery_dr_ctrltbl_mng.st_ctrl_tbl_mng_data[i].us_dlvry_entry_num;
- break;
- }
- }
-
- /* Create a PNO list */
- g_delivery_dr_pnotbl.us_num = 0;
- if (change_type == DEADRECKONING_CHGTYPE_CHG) {
- /* Processing when delivery timing is changed*/
- for (i = 0; i < us_num; i++) {
- /* Functionalization by Increasing Structure Members */
- DeadReckoningAddPnoTbl(us_index);
-
- us_index = g_delivery_dr_ctrltbl.st_ctrl_data[us_index].us_link_idx;
- }
- } else {
- /* Processing when delivery timing is update */
- for (i = 0; i < us_num; i++) {
- if (DEADRECKONING_DELIVERY_TIMING_UPDATE == g_delivery_dr_ctrltbl.st_ctrl_data[us_index].uc_chg_type) {
- /* Functionalization by Increasing Structure Members */
- DeadReckoningAddPnoTbl(us_index);
- }
- us_index = g_delivery_dr_ctrltbl.st_ctrl_data[us_index].us_link_idx;
- }
- }
- return (&g_delivery_dr_pnotbl);
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningAddPnoTbl
-* ABSTRACT : Vehicle Sensor Destination PNO Table Addition Function
-* FUNCTION : Add to the shipping PNO table.
-* ARGUMENT : us_index : Index of the referenced destination management table
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningAddPnoTbl(u_int16 us_index) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int16 us_pno_tbl_idx;
-
- us_pno_tbl_idx = g_delivery_dr_pnotbl.us_num;
- g_delivery_dr_pnotbl.st_pno_data[us_pno_tbl_idx].us_pno = g_delivery_dr_ctrltbl.st_ctrl_data[us_index].us_pno;
- /* Save the relevant INDEX in the delivery control table */
- g_delivery_dr_pnotbl.st_pno_data[us_pno_tbl_idx].us_index = us_index;
- g_delivery_dr_pnotbl.st_pno_data[us_pno_tbl_idx].uc_method =
- g_delivery_dr_ctrltbl.st_ctrl_data[us_index].uc_method;
- g_delivery_dr_pnotbl.us_num++;
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningDeliveryProc
-* ABSTRACT : Vehicle Sensor Data Delivery Process
-* FUNCTION : Deliver data to a destination.
-* ARGUMENT : ul_did :Data ID
-* uc_chg_type :Delivery timing
-* uc_get_method :Acquisition method
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningDeliveryProc(DID ul_did, u_int8 uc_chg_type, u_int8 uc_get_method) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- int32 i; /* Generic counters */
- DEADRECKONING_DATA_MASTER st_master; /* Data master of normal data */
-
-
- /* Defines the data master for each API. */
- SENSORLOCATION_MSG_LONLATINFO_DAT st_msg_lonlat_info;
- SENSORLOCATION_MSG_ALTITUDEINFO_DAT st_msg_altitude_info;
- SENSORMOTION_MSG_SPEEDINFO_DAT st_msg_speed_info;
- SENSORMOTION_MSG_HEADINGINFO_DAT st_msg_heading_info;
-
-
- const DEADRECKONING_DELIVERY_PNO_TBL *p_st_pno_tbl; /* Vehicle Sensor Destination PNO Table Pointer */
-
- /* Initialization */
- st_msg_lonlat_info.reserve[0] = 0;
- st_msg_lonlat_info.reserve[1] = 0;
- st_msg_lonlat_info.reserve[2] = 0;
- st_msg_altitude_info.reserve[0] = 0;
- st_msg_altitude_info.reserve[1] = 0;
- st_msg_altitude_info.reserve[2] = 0;
- st_msg_speed_info.reserve = 0;
- st_msg_heading_info.reserve = 0;
-
- /* Obtain the shipping destination PNO */
- p_st_pno_tbl =
- reinterpret_cast<DEADRECKONING_DELIVERY_PNO_TBL*>(DeadReckoningMakeDeliveryPnoTbl(ul_did, uc_chg_type));
-
- if ((p_st_pno_tbl->us_num) > 0) {
- /* When there is a shipping destination PNO registration */
- /* Vehicle sensor information notification transmission process */
- for (i = 0; i < (p_st_pno_tbl->us_num); i++) {
- /* Acquire the applicable data information from the data master..*/
- DeadReckoningGetDataMaster(ul_did, &st_master);
-
- /* Align data from the data master for API I/F */
- switch (ul_did) {
- /* Describes the process for each DID. */
- case VEHICLE_DID_DR_LATITUDE:
- {
- /* Size storage(LONLAT) */
- st_msg_lonlat_info.size = (u_int16)sizeof(SENSORLOCATION_MSG_LONLATINFO_DAT);
-
- /* DR status setting */
- st_msg_lonlat_info.dr_status = st_master.dr_status;
-
- /* The DR enable flag is set to enabled. */
- st_msg_lonlat_info.is_exist_dr = SENSORLOCATION_EXISTDR_DR;
-
- /* Set the Latitude */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_lonlat_info.latitude)),
- (const void *)(&(st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- /* Obtain the data master Longitude */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_LONGITUDE, &st_master);
-
- /* Set the Longitude */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_lonlat_info.longitude)),
- (const void *)(&(st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- /* Acquire data master SensorCnt */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &st_master);
-
- /* Set the SensorCnt */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_lonlat_info.sensor_cnt)),
- (const void *)(&( st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- p_st_pno_tbl->st_pno_data[i].us_pno,
- CID_VEHICLE_SENSORLOCATION_LONLAT,
- sizeof(SENSORLOCATION_MSG_LONLATINFO_DAT),
- (const void *)&st_msg_lonlat_info);
- break;
- }
- case VEHICLE_DID_DR_ALTITUDE:
- {
- /* Size storage(ALTITUDE) */
- st_msg_altitude_info.size = (u_int16)sizeof(SENSORLOCATION_MSG_ALTITUDEINFO_DAT);
-
- /* The DR enable flag is set to enabled. */
- st_msg_altitude_info.is_exist_dr = SENSORLOCATION_EXISTDR_DR;
-
- /* DR status setting */
- st_msg_altitude_info.dr_status = st_master.dr_status;
-
-
- /* Set the Altitude */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_altitude_info.altitude)),
- (const void *)(&(st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- /* Acquire data master SensorCnt */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &st_master);
-
- /* Set the SensorCnt */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_altitude_info.sensor_cnt)),
- (const void *)(&(st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- p_st_pno_tbl->st_pno_data[i].us_pno,
- CID_VEHICLE_SENSORLOCATION_ALTITUDE,
- sizeof(SENSORLOCATION_MSG_ALTITUDEINFO_DAT),
- (const void *)&st_msg_altitude_info);
-
- break;
- }
- case VEHICLE_DID_DR_SPEED:
- {
- /* Size storage(SPEED) */
- st_msg_speed_info.size = (u_int16)sizeof(SENSORMOTION_MSG_SPEEDINFO_DAT);
-
- /* The DR enable flag is set to enabled. */
- st_msg_speed_info.is_exist_dr = SENSORMOTION_EXISTDR_DR;
-
- /* DR status setting */
- st_msg_speed_info.dr_status = st_master.dr_status;
-
-
- /* Set the Speed */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_speed_info.speed)),
- (const void *)(&(st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- /* Acquire data master SensorCnt */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &st_master);
- /* Set the SensorCnt */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_speed_info.sensor_cnt)),
- (const void *)(&(st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- p_st_pno_tbl->st_pno_data[i].us_pno,
- CID_VEHICLE_SENSORMOTION_SPEED,
- sizeof(SENSORMOTION_MSG_SPEEDINFO_DAT),
- (const void *)&st_msg_speed_info);
- break;
- }
- case VEHICLE_DID_DR_HEADING:
- {
- /* Size storage(HEADING) */
- st_msg_heading_info.size = (u_int16)sizeof(SENSORMOTION_MSG_HEADINGINFO_DAT);
-
- /* The DR enable flag is set to enabled. */
- st_msg_heading_info.is_exist_dr = SENSORMOTION_EXISTDR_DR;
-
- /* DR status setting */
- st_msg_heading_info.dr_status = st_master.dr_status;
-
- /* Set the Heading */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_heading_info.heading)),
- (const void *)(&(st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- /* Acquire data master SensorCnt */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &st_master);
- /* Set the SensorCnt */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_heading_info.sensor_cnt)),
- (const void *)(&(st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- p_st_pno_tbl->st_pno_data[i].us_pno,
- CID_VEHICLE_SENSORMOTION_HEADING,
- sizeof(SENSORMOTION_MSG_HEADINGINFO_DAT),
- (const void *)&st_msg_heading_info);
- break;
- }
- case VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL:
- {
- SENSORMOTION_MSG_GYROPARAMETERINFO_DAT stMsgGyroParameterInfo;
- /* Initialization */
- stMsgGyroParameterInfo.reserve[0] = 0;
- stMsgGyroParameterInfo.reserve[1] = 0;
-
- /* GyroOffset/GyroScaleFactor/GyroScaleFactorLevel data master */
- /* setup must be completed before data delivery of this DID */
- /* The order of processing is defined by DeadReckoning_RcvMsg().,Be careful when changing */
-
- /* Size storage(GYROPARAMETER) */
- stMsgGyroParameterInfo.size = (u_int16)sizeof(stMsgGyroParameterInfo);
-
- /* GyroOffset acuisition/setting */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_GYRO_OFFSET, &st_master);
-
- (void)memcpy(reinterpret_cast<void *>(&(stMsgGyroParameterInfo.gyro_offset)),
- reinterpret_cast<void *>(&(st_master.uc_data[0])),
- sizeof(stMsgGyroParameterInfo.gyro_offset));
-
- /* GyroScaleFactor acuisition/setting */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_GYRO_SCALE_FACTOR, &st_master);
-
- (void)memcpy(reinterpret_cast<void *>(&(stMsgGyroParameterInfo.gyro_scale_factor)),
- reinterpret_cast<void *>(&(st_master.uc_data[0])),
- sizeof(stMsgGyroParameterInfo.gyro_scale_factor));
-
- /* GyroScaleFactorLevel acuisition/setting */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL, &st_master);
-
- (void)memcpy(reinterpret_cast<void *>(&(stMsgGyroParameterInfo.gyro_scale_factor_level)),
- reinterpret_cast<void *>(&(st_master.uc_data[0])),
- sizeof(stMsgGyroParameterInfo.gyro_scale_factor_level));
-
- /* Data transmission */
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- p_st_pno_tbl->st_pno_data[i].us_pno,
- CID_VEHICLE_SENSORMOTION_GYROPARAMETER,
- sizeof(stMsgGyroParameterInfo),
- (const void *)&stMsgGyroParameterInfo);
- }
- break;
- case VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL:
- {
- SENSORMOTION_MSG_SPEEDPULSEPARAMETERINFO_DAT stMsgSpeedPulseParameterInfo;
-
- /* Initialization */
- stMsgSpeedPulseParameterInfo.reserve[0] = 0;
- stMsgSpeedPulseParameterInfo.reserve[1] = 0;
- stMsgSpeedPulseParameterInfo.reserve[2] = 0;
-
- /* GyroOffset/GyroScaleFactor/GyroScaleFactorLevel data master */
- /* setup must be completed before data delivery of this DID */
- /* The order of processing is defined by DeadReckoning_RcvMsg().,Be careful when changing */
-
- /* Size storage(SPEEDPULSEPARAMETER) */
- stMsgSpeedPulseParameterInfo.size = (u_int16)sizeof(stMsgSpeedPulseParameterInfo);
-
- /* SpeedPulseScaleFactor acuisition/setting */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR, &st_master);
-
- (void)memcpy(reinterpret_cast<void *>(&(stMsgSpeedPulseParameterInfo.speed_pulse_scale_factor)),
- reinterpret_cast<void *>(&(st_master.uc_data[0])),
- sizeof(stMsgSpeedPulseParameterInfo.speed_pulse_scale_factor));
-
- /* SpeedPulseScaleFactorLevel acuisition/setting */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL, &st_master);
-
- (void)memcpy(reinterpret_cast<void *>(&(stMsgSpeedPulseParameterInfo.speed_pulse_scale_factor_level)),
- reinterpret_cast<void *>(&(st_master.uc_data[0])),
- sizeof(stMsgSpeedPulseParameterInfo.speed_pulse_scale_factor_level));
-
- /* Data transmission */
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- p_st_pno_tbl->st_pno_data[i].us_pno,
- CID_VEHICLE_SENSORMOTION_SPEEDPULSEPARAMETER,
- sizeof(stMsgSpeedPulseParameterInfo),
- (const void *)&stMsgSpeedPulseParameterInfo);
- }
- break;
- /* Other than the above */
- default:
- /* Do not edit. */
- break;
- }
- }
- }
-}
-
-/*******************************************************************************
- * MODULE : DRManagerSndMsg
- * ABSTRACT : Message transmission processing
- * FUNCTION : Send a message to the specified PNO
- * ARGUMENT : us_pno_src : Source PNO
- * : us_pno_dest : Destination PNO
- * : us_cid : Command ID
- * : us_msg_len : Message data body length
- * : *p_msg_data : Pointer to message data
- * NOTE :
- * RETURN : RET_NORMAL : Normal completion
- * : RET_ERRNOTRDY : Destination process is not wakeup
- * : RET_ERRMSGFULL : Message queue overflows
- * : RET_ERRPARAM : Buffer size error
- ******************************************************************************/
-RET_API DRManagerSndMsg(PNO us_pno_src, PNO us_pno_dest, CID us_cid, u_int16 us_msg_len, const void *p_msg_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- DEADRECKONING_MSG_BUF st_msg_buf; /* message buffer */
- T_APIMSG_MSGBUF_HEADER *p_st_msg_hdr; /* Pointer to the message header */
- RET_API l_ret_api; /* Return value */
-
- /* Message buffer initialization */
- memset(reinterpret_cast<void *>(&st_msg_buf), 0, sizeof(DEADRECKONING_MSG_BUF));
-
- /* Get pointer to send buffer */
- p_st_msg_hdr = reinterpret_cast<T_APIMSG_MSGBUF_HEADER *>(reinterpret_cast<void *>(&st_msg_buf));
-
- /*--------------------------------------------------------------*
- * Create message headers *
- *--------------------------------------------------------------*/
- p_st_msg_hdr->hdr.sndpno = us_pno_src; /* Source PNO */
- p_st_msg_hdr->hdr.cid = us_cid; /* Command ID */
- p_st_msg_hdr->hdr.msgbodysize = us_msg_len; /* Message data body length */
-
- /*--------------------------------------------------------------*
- * Create message data *
- *--------------------------------------------------------------*/
- if ((0 != p_msg_data) && (0 != us_msg_len)) {
- /* Set the message data */
- memcpy(reinterpret_cast<void *>(st_msg_buf.data), p_msg_data, (size_t)us_msg_len);
- }
- /*--------------------------------------------------------------*
- * Send messages *
- *--------------------------------------------------------------*/
- l_ret_api = _pb_SndMsg(us_pno_dest,
- (u_int16)(sizeof(T_APIMSG_MSGBUF_HEADER) + us_msg_len),
- reinterpret_cast<void *>(&st_msg_buf),
- 0);
- return (l_ret_api);
-}
-
-
-/*******************************************************************************
-* MODULE : DeadReckoningFirstDelivery
-* ABSTRACT : Vehicle Sensor Initial Data Delivery Process
-* FUNCTION : Deliver the initial data to the destination.
-* ARGUMENT : us_pno :Addresses for delivery NO
-* ul_did :Data ID
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningFirstDelivery(PNO us_pno, DID ul_did) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- DEADRECKONING_DATA_MASTER st_master; /* Data master of normal data */
-
- /* Defines the data master for each API. */
- SENSORLOCATION_MSG_LONLATINFO_DAT st_msg_lonlat_info;
- SENSORLOCATION_MSG_ALTITUDEINFO_DAT st_msg_altitude_info;
- SENSORMOTION_MSG_SPEEDINFO_DAT st_msg_speed_info;
- SENSORMOTION_MSG_HEADINGINFO_DAT st_msg_heading_info;
-
- /* Initialization */
- st_msg_lonlat_info.reserve[0] = 0;
- st_msg_lonlat_info.reserve[1] = 0;
- st_msg_lonlat_info.reserve[2] = 0;
- st_msg_altitude_info.reserve[0] = 0;
- st_msg_altitude_info.reserve[1] = 0;
- st_msg_altitude_info.reserve[2] = 0;
- st_msg_speed_info.reserve = 0;
- st_msg_heading_info.reserve = 0;
-
- /* Align data from the data master for API I/F */
- switch (ul_did) {
- /* Describes the process for each DID. */
- case VEHICLE_DID_DR_LATITUDE:
- {
- DeadReckoningGetDataMaster(ul_did, &st_master);
-
- /* Size storage(LONLAT) */
- st_msg_lonlat_info.size = (u_int16)sizeof(SENSORLOCATION_MSG_LONLATINFO_DAT);
-
- /* DR status setting */
- st_msg_lonlat_info.dr_status = st_master.dr_status;
-
- /* The DR enable flag is set to enabled. */
- st_msg_lonlat_info.is_exist_dr = SENSORLOCATION_EXISTDR_DR;
-
- /* Set the Latitude */
- memcpy(&(st_msg_lonlat_info.latitude), &(st_master.uc_data[0]), st_master.us_size);
-
- /* Obtain the data master Longitude */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_LONGITUDE, &st_master);
-
- /* Set the Longitude */
- memcpy(&(st_msg_lonlat_info.longitude), &(st_master.uc_data[0]), st_master.us_size);
-
- /* Acquire data master SensorCnt */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &st_master);
-
- /* Set the SensorCnt */
- memcpy(&(st_msg_lonlat_info.sensor_cnt), &(st_master.uc_data[0]), st_master.us_size);
-
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLE_SENSORLOCATION_LONLAT,
- sizeof(SENSORLOCATION_MSG_LONLATINFO_DAT),
- (const void *)&st_msg_lonlat_info);
- break;
- }
- case VEHICLE_DID_DR_ALTITUDE:
- {
- DeadReckoningGetDataMaster(ul_did, &st_master);
-
- /* Size storage(ALTITUDE) */
- st_msg_altitude_info.size = (u_int16)sizeof(SENSORLOCATION_MSG_ALTITUDEINFO_DAT);
-
- /* The DR enable flag is set to enabled. */
- st_msg_altitude_info.is_exist_dr = SENSORLOCATION_EXISTDR_DR;
-
- /* DR status setting */
- st_msg_altitude_info.dr_status = st_master.dr_status;
-
-
- /* Set the Altitude */
- memcpy(&(st_msg_altitude_info.altitude), &(st_master.uc_data[0]), st_master.us_size);
-
- /* Acquire data master SensorCnt */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &st_master);
-
- /* Set the SensorCnt */
- memcpy(&(st_msg_altitude_info.sensor_cnt), &(st_master.uc_data[0]), st_master.us_size);
-
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLE_SENSORLOCATION_ALTITUDE,
- sizeof(SENSORLOCATION_MSG_ALTITUDEINFO_DAT),
- (const void *)&st_msg_altitude_info);
-
- break;
- }
- case VEHICLE_DID_DR_SPEED:
- {
- DeadReckoningGetDataMaster(ul_did, &st_master);
-
- /* Size storage(SPEED) */
- st_msg_speed_info.size = (u_int16)sizeof(SENSORMOTION_MSG_SPEEDINFO_DAT);
-
- /* The DR enable flag is set to enabled. */
- st_msg_speed_info.is_exist_dr = SENSORMOTION_EXISTDR_DR;
-
- /* DR status setting */
- st_msg_speed_info.dr_status = st_master.dr_status;
-
-
- /* Set the Speed */
- memcpy(&(st_msg_speed_info.speed), &(st_master.uc_data[0]), st_master.us_size);
-
- /* Acquire data master SensorCnt */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &st_master);
- /* Set the SensorCnt */
- memcpy(&(st_msg_speed_info.sensor_cnt), &(st_master.uc_data[0]), st_master.us_size);
-
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLE_SENSORMOTION_SPEED,
- sizeof(SENSORMOTION_MSG_SPEEDINFO_DAT),
- (const void *)&st_msg_speed_info);
- break;
- }
- case VEHICLE_DID_DR_HEADING:
- {
- DeadReckoningGetDataMaster(ul_did, &st_master);
-
- /* Size storage(HEADING) */
- st_msg_heading_info.size = (u_int16)sizeof(SENSORMOTION_MSG_HEADINGINFO_DAT);
-
- /* The DR enable flag is set to enabled. */
- st_msg_heading_info.is_exist_dr = SENSORMOTION_EXISTDR_DR;
-
- /* DR status setting */
- st_msg_heading_info.dr_status = st_master.dr_status;
-
-
- /* Set the Heading */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_heading_info.heading)),
- (const void *)(&(st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- /* Acquire data master SensorCnt */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &st_master);
- /* Set the SensorCnt */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_heading_info.sensor_cnt)),
- (const void *)(&(st_master.uc_data[0])), (size_t)(st_master.us_size));
-
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLE_SENSORMOTION_HEADING,
- sizeof(SENSORMOTION_MSG_HEADINGINFO_DAT),
- (const void *)&st_msg_heading_info);
- break;
- }
- case VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL:
- {
- SENSORMOTION_MSG_GYROPARAMETERINFO_DAT stMsgGyroParameterInfo;
-
- /* Initialization */
- stMsgGyroParameterInfo.reserve[0] = 0;
- stMsgGyroParameterInfo.reserve[1] = 0;
-
- /* Size storage(GYROPARAMETER) */
- stMsgGyroParameterInfo.size = (u_int16)sizeof(stMsgGyroParameterInfo);
-
- /* GyroOffset acuisition/setting */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_GYRO_OFFSET, &st_master);
-
- (void)memcpy(reinterpret_cast<void *>(&(stMsgGyroParameterInfo.gyro_offset)),
- reinterpret_cast<void *>(&(st_master.uc_data[0])),
- sizeof( stMsgGyroParameterInfo.gyro_offset));
-
- /* GyroScaleFactor acuisition/setting */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_GYRO_SCALE_FACTOR, &st_master);
-
- (void)memcpy(reinterpret_cast<void *>(&(stMsgGyroParameterInfo.gyro_scale_factor)),
- reinterpret_cast<void *>(&(st_master.uc_data[0])),
- sizeof(stMsgGyroParameterInfo.gyro_scale_factor));
-
- /* GyroScaleFactorLevel acuisition/setting */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL, &st_master);
-
- (void)memcpy(reinterpret_cast<void *>(&(stMsgGyroParameterInfo.gyro_scale_factor_level)),
- reinterpret_cast<void *>(&(st_master.uc_data[0])),
- sizeof(stMsgGyroParameterInfo.gyro_scale_factor_level));
-
- /* Data transmission */
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLE_SENSORMOTION_GYROPARAMETER,
- sizeof(stMsgGyroParameterInfo),
- (const void *)&stMsgGyroParameterInfo);
- }
- break;
- case VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL:
- {
- SENSORMOTION_MSG_SPEEDPULSEPARAMETERINFO_DAT stMsgSpeedPulseParameterInfo;
-
- /* Initialization */
- stMsgSpeedPulseParameterInfo.reserve[0] = 0;
- stMsgSpeedPulseParameterInfo.reserve[1] = 0;
- stMsgSpeedPulseParameterInfo.reserve[2] = 0;
-
- /* Size storage(SPEEDPULSEPARAMETER) */
- stMsgSpeedPulseParameterInfo.size = (u_int16)sizeof(stMsgSpeedPulseParameterInfo);
-
- /* SpeedPulseScaleFactor acuisition/setting */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR, &st_master);
-
- (void)memcpy(reinterpret_cast<void *>(&(stMsgSpeedPulseParameterInfo.speed_pulse_scale_factor)),
- reinterpret_cast<void *>(&(st_master.uc_data[0])),
- sizeof(stMsgSpeedPulseParameterInfo.speed_pulse_scale_factor));
-
- /* SpeedPulseScaleFactorLevel acuisition/setting */
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL, &st_master);
-
- (void)memcpy(reinterpret_cast<void *>(&(stMsgSpeedPulseParameterInfo.speed_pulse_scale_factor_level)),
- reinterpret_cast<void *>(&(st_master.uc_data[0])),
- sizeof(stMsgSpeedPulseParameterInfo.speed_pulse_scale_factor_level));
-
- /* Data transmission */
- (void)DRManagerSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLE_SENSORMOTION_SPEEDPULSEPARAMETER,
- sizeof(stMsgSpeedPulseParameterInfo),
- (const void *)&stMsgSpeedPulseParameterInfo);
- }
- break;
- /* Other than the above */
- default:
- /* Do not edit. */
- break;
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Altitude_dr.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Altitude_dr.cpp
deleted file mode 100755
index acd5f6d..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Altitude_dr.cpp
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*************************************************************************
-@file DeadReckoning_Did_Altitude.cpp
-@detail DeadReckoning data Master(VEHICLE_DID_DR_ALTITUDE)<BR>
- DeadReckoning data master(VEHICLE_DID_DR_ALTITUDE)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_altitude; // NOLINT(readability/nolint)
-
-/************************************************************************
-@brief Altitude Dead Reckoning initialization function
-@outline Altitude initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-**************************************************************************** */
-void DeadReckoningInitAltitudeDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&(gst_altitude), 0x00, sizeof(DEADRECKONING_DATA_MASTER));
- gst_altitude.ul_did = VEHICLE_DID_DR_ALTITUDE;
- gst_altitude.us_size = VEHICLE_DSIZE_ALTITUDE;
- gst_altitude.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_altitude.dr_status = SENSORLOCATION_DRSTATUS_INVALID;
- gst_altitude.uc_data[0] = VEHICLE_DINIT_ALTITUDE;
-}
-
-/***********************************************************************
-@brief Altitude Dead Reckoning SET function
-@outline To update the master data Altitude.
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval DEADRECKONING_EQ : No data changes
-@retval DEADRECKONING_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 DeadReckoningSetAltitudeDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_altitude;
-
- /** Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- /** Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = p_st_data->dr_status;
-
- memcpy(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- return (uc_ret);
-}
-
-/************************************************************************
-@brief Altitude Dead Reckoning GET function
-@outline Master Data provides the Altitude
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void DeadReckoningGetAltitudeDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_altitude;
-
- /** Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status;
- memcpy(p_st_data->uc_data, p_st_master->uc_data, p_st_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroOffset_dr.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroOffset_dr.cpp
deleted file mode 100755
index f295f8d..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroOffset_dr.cpp
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*************************************************************************
-@file DeadReckoning_Did_GyroScaleFactor_dr.cpp
-@detail DeadReckoning data Master(VEHICLE_DID_DR_GYRO_OFFSET)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_gyrooffset; // NOLINT(readability/nolint)
-
-/************************************************************************
-@brief GyroOffset initialization function
-@outline GyroOffset initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-**************************************************************************** */
-void DeadReckoningInitGyroOffsetDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- (void)memset(reinterpret_cast<void *>(&gst_gyrooffset), 0x00, sizeof(gst_gyrooffset));
- gst_gyrooffset.ul_did = VEHICLE_DID_DR_GYRO_OFFSET;
- gst_gyrooffset.us_size = VEHICLE_DSIZE_GYRO_OFFSET;
- gst_gyrooffset.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_gyrooffset.dr_status = 0U; /* Not used */
-}
-
-/************************************************************************
-@brief GyroOffset SET function
-@outline To update the master data GyroOffset
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : The pointer to incoming message data
-@threshold none
-@return u_int8
-@retval DEADRECKONING_EQ : No data changes
-@retval DEADRECKONING_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 DeadReckoningSetGyroOffsetDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret = DEADRECKONING_EQ;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- if (p_st_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "p_st_data == NULL\r\n");
- } else {
- p_st_master = &gst_gyrooffset;
-
- /** Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(reinterpret_cast<void *>(&(p_st_master->uc_data)),
- (const void *)(&(p_st_data->uc_data)), (size_t)(p_st_data->us_size));
-
- /** Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = 0U; /* Not used */
-
- (void)memcpy(reinterpret_cast<void *>(&(p_st_master->uc_data)),
- (const void *)(&(p_st_data->uc_data) ), sizeof(p_st_master->uc_data));
- }
-
- return (uc_ret);
-}
-
-/************************************************************************
-@brief GyroOffset GET function
-@outline Master Data provides the GyroOffset
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void DeadReckoningGetGyroOffsetDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- if (p_st_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "p_st_data == NULL\r\n");
- } else {
- p_st_master = &gst_gyrooffset;
-
- /** Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status; /* Not used(Set DataMaster defaults) */
- (void)memcpy(reinterpret_cast<void *>(&(p_st_data->uc_data)),
- (const void *)(&(p_st_master->uc_data)), (size_t)p_st_master->us_size);
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroScaleFactorLevel_dr.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroScaleFactorLevel_dr.cpp
deleted file mode 100755
index dff0913..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroScaleFactorLevel_dr.cpp
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*************************************************************************
-@file DeadReckoning_Did_GyroScaleFactorLevel_dr.cpp
-@detail DeadReckoning data Master(VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_gyroscalefactor_level; // NOLINT(readability/nolint)
-
-/************************************************************************
-@brief GyroScaleFactorLevel initialization function
-@outline GyroScaleFactorLevel initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-**************************************************************************** */
-void DeadReckoningInitGyroScaleFactorLevelDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- (void)memset(reinterpret_cast<void *>(&gst_gyroscalefactor_level), 0x00, sizeof(gst_gyroscalefactor_level));
- gst_gyroscalefactor_level.ul_did = VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL;
- gst_gyroscalefactor_level.us_size = VEHICLE_DSIZE_GYRO_SCALE_FACTOR_LEVEL;
- gst_gyroscalefactor_level.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_gyroscalefactor_level.dr_status = 0U; /* Not used */
-}
-
-/*************************************************************************
-@brief GyroScaleFactorLevel SET function
-@outline To update the master data GyroScaleFactorLevel
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : The pointer to incoming message data
-@threshold none
-@return u_int8
-@retval DEADRECKONING_EQ : No data changes<BR>
-@retval DEADRECKONING_NEQ : With data changes<BR>
-@trace
-*****************************************************************************/
-u_int8 DeadReckoningSetGyroScaleFactorLevelDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret = DEADRECKONING_EQ;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- if (p_st_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "p_st_data == NULL\r\n");
- } else {
- p_st_master = &gst_gyroscalefactor_level;
-
- /** Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(reinterpret_cast<void *>(&(p_st_master->uc_data)),
- (const void *)( &(p_st_data->uc_data)), (size_t)(p_st_data->us_size));
-
- /** Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = 0U; /* Not used */
-
- (void)memcpy(reinterpret_cast<void *>(&(p_st_master->uc_data)),
- (const void *)(&(p_st_data->uc_data)), sizeof(p_st_master->uc_data));
- }
-
- return (uc_ret);
-}
-
-/*************************************************************************
-@brief GyroScaleFactorLevel GET function
-@outline Master Data provides the GyroScaleFactorLevel
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void DeadReckoningGetGyroScaleFactorLevelDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- if (p_st_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "p_st_data == NULL\r\n");
- } else {
- p_st_master = &gst_gyroscalefactor_level;
-
- /** Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status; /* Not used(Set DataMaster defaults) */
- (void)memcpy(reinterpret_cast<void *>(&(p_st_data->uc_data)),
- (const void *)(&(p_st_master->uc_data)), (size_t)p_st_master->us_size);
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroScaleFactor_dr.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroScaleFactor_dr.cpp
deleted file mode 100755
index d05ef5c..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_GyroScaleFactor_dr.cpp
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/************************************************************************
-@file DeadReckoning_Did_GyroScaleFactor_dr.cpp
-@detail DeadReckoning data Master(VEHICLE_DID_DR_GYRO_SCALE_FACTOR)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_gyroscalefactor; // NOLINT(readability/nolint)
-
-/************************************************************************
-@brief GyroScaleFactor initialization function
-@outline GyroScaleFactor initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-**************************************************************************** */
-void DeadReckoningInitGyroScaleFactorDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- (void)memset(reinterpret_cast<void *>(&gst_gyroscalefactor), 0x00, sizeof(gst_gyroscalefactor));
- gst_gyroscalefactor.ul_did = VEHICLE_DID_DR_GYRO_SCALE_FACTOR;
- gst_gyroscalefactor.us_size = VEHICLE_DSIZE_GYRO_SCALE_FACTOR;
- gst_gyroscalefactor.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_gyroscalefactor.dr_status = 0U; /* Not used */
-}
-
-/************************************************************************
-@brief GyroScaleFactor SET function
-@outline To update the master data GyroScaleFactor
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : The pointer to incoming message data
-@threshold none
-@return u_int8
-@retval DEADRECKONING_EQ : No data changes
-@retval DEADRECKONING_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 DeadReckoningSetGyroScaleFactorDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret = DEADRECKONING_EQ;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- if (p_st_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "p_st_data == NULL\r\n");
- } else {
- p_st_master = &gst_gyroscalefactor;
-
- /** Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(reinterpret_cast<void *>(&(p_st_master->uc_data)),
- (const void *)(&(p_st_data->uc_data)), (size_t)(p_st_data->us_size));
-
- /** Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = 0U; /* Not used */
-
- (void)memcpy(reinterpret_cast<void *>(&(p_st_master->uc_data)),
- (const void *)(&(p_st_data->uc_data) ), sizeof(p_st_master->uc_data));
- }
-
- return (uc_ret);
-}
-
-/************************************************************************
-@brief GyroScaleFactor GET function
-@outline Master Data provides the GyroScaleFactor
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void DeadReckoningGetGyroScaleFactorDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- if (p_st_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "p_st_data == NULL\r\n");
- } else {
- p_st_master = &gst_gyroscalefactor;
-
- /** Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status; /* Not used(Set DataMaster defaults) */
- (void)memcpy(reinterpret_cast<void *>(&(p_st_data->uc_data)),
- (const void *)(&(p_st_master->uc_data)), (size_t)p_st_master->us_size);
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Heading_dr.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Heading_dr.cpp
deleted file mode 100755
index 451b133..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Heading_dr.cpp
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/************************************************************************
-@file DeadReckoning_Did_Heading.cpp
-@detail DeadReckoning data Master(VEHICLE_DID_DR_HEADING)<BR>
- DeadReckoning data master(VEHICLE_DID_DR_HEADING)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_heading; // NOLINT(readability/nolint)
-
-/************************************************************************
-@brief Heading Dead Reckoning initialization function
-@outline Heading initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-**************************************************************************** */
-void DeadReckoningInitHeadingDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&(gst_heading), 0x00, sizeof(DEADRECKONING_DATA_MASTER));
- gst_heading.ul_did = VEHICLE_DID_DR_HEADING;
- gst_heading.us_size = VEHICLE_DSIZE_HEADING;
- gst_heading.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_heading.dr_status = SENSORMOTION_DRSTATUS_INVALID;
- gst_heading.uc_data[0] = VEHICLE_DINIT_HEADING;
-}
-
-/*************************************************************************
-@brief Heading Dead Reckoning SET function
-@outline To update the master data Heading.
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval DEADRECKONING_EQ : No data changes
-@retval DEADRECKONING_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 DeadReckoningSetHeadingDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_heading;
-
- /** Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- /** Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = p_st_data->dr_status;
-
- memcpy(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- return (uc_ret);
-}
-
-/************************************************************************
-@brief Heading Dead Reckoning GET function
-@outline Master Data provides the Heading
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void DeadReckoningGetHeadingDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_heading;
-
- /** Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status;
- memcpy(p_st_data->uc_data, p_st_master->uc_data, p_st_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Latitude_dr.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Latitude_dr.cpp
deleted file mode 100755
index 9d06e7a..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Latitude_dr.cpp
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/************************************************************************
-@file DeadReckoning_Did_Latitude.cpp
-@detail DeadReckoning data Master(VEHICLE_DID_DR_LATITUDE)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_latitude; // NOLINT(readability/nolint)
-
-/***********************************************************************
-@brief Latitude Dead Reckoning initialization function
-@outline Latitude initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-**************************************************************************** */
-void DeadReckoningInitLatitudeDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&(gst_latitude), 0x00, sizeof(DEADRECKONING_DATA_MASTER));
- gst_latitude.ul_did = VEHICLE_DID_DR_LATITUDE;
- gst_latitude.us_size = VEHICLE_DSIZE_LATITUDE;
- gst_latitude.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_latitude.dr_status = SENSORLOCATION_DRSTATUS_INVALID;
- gst_latitude.uc_data[0] = VEHICLE_DINIT_LATITUDE;
-}
-
-/************************************************************************
-@brief Latitude Dead Reckoning SET function
-@outline To update the master data Latitude.
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval DEADRECKONING_EQ : No data changes
-@retval DEADRECKONING_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 DeadReckoningSetLatitudeDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_latitude;
-
- /** Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- /** Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = p_st_data->dr_status;
-
- memcpy(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- return (uc_ret);
-}
-
-/************************************************************************
-@brief Latitude Dead Reckoning GET function
-@outline Master Data provides the Latitude
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void DeadReckoningGetLatitudeDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_latitude;
-
- /** Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status;
- memcpy(p_st_data->uc_data, p_st_master->uc_data, p_st_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Longitude_dr.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Longitude_dr.cpp
deleted file mode 100755
index 38a6351..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Longitude_dr.cpp
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/************************************************************************
-@file DeadReckoning_Did_Longitude.cpp
-@detail DeadReckoning data Master(VEHICLE_DID_DR_LONGITUDE)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_longitude; // NOLINT(readability/nolint)
-
-/***********************************************************************
-@brief Longitude Dead Reckoning initialization function
-@outline Longitude initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-**************************************************************************** */
-void DeadReckoningInitLongitudeDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&(gst_longitude), 0x00, sizeof(DEADRECKONING_DATA_MASTER));
- gst_longitude.ul_did = VEHICLE_DID_DR_LONGITUDE;
- gst_longitude.us_size = VEHICLE_DSIZE_LONGITUDE;
- gst_longitude.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_longitude.dr_status = SENSORLOCATION_DRSTATUS_INVALID;
- gst_longitude.uc_data[0] = VEHICLE_DINIT_LONGITUDE;
-}
-
-/************************************************************************
-@brief Longitude Dead Reckoning SET function
-@outline To update the master data Longitude.
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval DEADRECKONING_EQ : No data changes
-@retval DEADRECKONING_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 DeadReckoningSetLongitudeDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_longitude;
-
- /** Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- /** Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = p_st_data->dr_status;
-
- memcpy(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- return (uc_ret);
-}
-
-/************************************************************************
-@brief Longitude Dead Reckoning GET function
-@outline Master Data provides the Longitude
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void DeadReckoningGetLongitudeDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_longitude;
-
- /** Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status;
- memcpy(p_st_data->uc_data, p_st_master->uc_data, p_st_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SnsCounter.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SnsCounter.cpp
deleted file mode 100755
index 6bf3ed7..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SnsCounter.cpp
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :DeadReckoning_Did_SnsCounter.cpp
- * System name :PastModel002
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_SNS_COUNTER)
- * Module configuration :DeadReckoningInitSnsCounterDr() Vehicle sensor SNS_COUNTER initialization function
- * :DeadReckoningSetSnsCounterDr() Vehicle sensor SNS_COUNTER SET function
- * :DeadReckoningGetSnsCounterDr() Vehicle sensor SNS_COUNTER GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_snscounter_dr; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : DeadReckoningInitSnsCounterDr
-* ABSTRACT : Vehicle sensor SNS_COUNTER initialization function
-* FUNCTION : SNS_COUNTER data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningInitSnsCounterDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&(gst_snscounter_dr), 0x00, sizeof(DEADRECKONING_DATA_MASTER));
- gst_snscounter_dr.ul_did = VEHICLE_DID_DR_SNS_COUNTER;
- gst_snscounter_dr.us_size = VEHICLE_DSIZE_DR_SNS_COUNTER;
- gst_snscounter_dr.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_snscounter_dr.dr_status = SENSORLOCATION_DRSTATUS_INVALID;
- gst_snscounter_dr.uc_data[0] = VEHICLE_DINIT_DR_SNS_COUNTER;
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningSetSnsCounterDr
-* ABSTRACT : Vehicle sensor SNS_COUNTER SET function
-* FUNCTION : Update the SNS_COUNTER data master
-* ARGUMENT : *p_st_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 DeadReckoningSetSnsCounterDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_snscounter_dr;
-
- /* Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- /* Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = p_st_data->dr_status;
- memcpy(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- return (uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningGetSnsCounterDr
-* ABSTRACT : Vehicle sensor SNS_COUNTER GET function
-* FUNCTION : Provide the SNS_COUNTER data master
-* ARGUMENT : *p_st_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningGetSnsCounterDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_snscounter_dr;
-
- /* Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status;
- memcpy(p_st_data->uc_data, p_st_master->uc_data, p_st_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SpeedPulseScaleFactorLevel_dr.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SpeedPulseScaleFactorLevel_dr.cpp
deleted file mode 100755
index dc7022f..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SpeedPulseScaleFactorLevel_dr.cpp
+++ /dev/null
@@ -1,116 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/************************************************************************
-@file DeadReckoning_Did_SpeedPulseScaleFactorLevel_dr.cpp
-@detail DeadReckoning data Master(VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_speedpulsescalefactor_level; // NOLINT(readability/nolint)
-
-/************************************************************************
-@brief SpeedPulseScaleFactorLevel initialization function
-@outline SpeedPulseScaleFactorLevel initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-**************************************************************************** */
-void DeadReckoningInitSpeedPulseScaleFactorLevelDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- (void)memset(reinterpret_cast<void *>(&gst_speedpulsescalefactor_level), 0x00,
- sizeof(gst_speedpulsescalefactor_level));
- gst_speedpulsescalefactor_level.ul_did = VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL;
- gst_speedpulsescalefactor_level.us_size = VEHICLE_DSIZE_SPEED_PULSE_SCALE_FACTOR_LEVEL;
- gst_speedpulsescalefactor_level.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_speedpulsescalefactor_level.dr_status = 0U; /* Not used */
-}
-
-/************************************************************************
-@brief SpeedPulseScaleFactorLevel SET function
-@outline To update the master data SpeedPulseScaleFactorLevel
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : The pointer to incoming message data
-@threshold none
-@return u_int8
-@retval DEADRECKONING_EQ : No data changes
-@retval DEADRECKONING_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 DeadReckoningSetSpeedPulseScaleFactorLevelDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret = DEADRECKONING_EQ;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- if (p_st_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "p_st_data == NULL\r\n");
- } else {
- p_st_master = &gst_speedpulsescalefactor_level;
-
- /** Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(reinterpret_cast<void *>(&(p_st_master->uc_data)),
- (const void *)(&(p_st_data->uc_data)), (size_t)(p_st_data->us_size));
-
- /** Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = 0U; /* Not used */
-
- (void)memcpy(reinterpret_cast<void *>(&(p_st_master->uc_data)),
- (const void *)(&(p_st_data->uc_data)), sizeof(p_st_master->uc_data));
- }
-
- return (uc_ret);
-}
-
-/************************************************************************
-@brief SpeedPulseScaleFactorLevel GET function
-@outline Master Data provides the SpeedPulseScaleFactorLevel
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void DeadReckoningGetSpeedPulseScaleFactorLevelDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- if (p_st_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "p_st_data == NULL\r\n");
- } else {
- p_st_master = &gst_speedpulsescalefactor_level;
-
- /** Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status; /* Not used(Set DataMaster defaults) */
- (void)memcpy(reinterpret_cast<void *>(&(p_st_data->uc_data)),
- (const void *)(&(p_st_master->uc_data)), (size_t)p_st_master->us_size);
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SpeedPulseScaleFactor_dr.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SpeedPulseScaleFactor_dr.cpp
deleted file mode 100755
index cd27141..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_SpeedPulseScaleFactor_dr.cpp
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*************************************************************************
-@file DeadReckoning_Did_SpeedPulseScaleFactor_dr.cpp
-@detail DeadReckoning data Master(VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_speedpulsescalefactor; // NOLINT(readability/nolint)
-
-/***********************************************************************
-@brief SpeedPulseScaleFactor initialization function
-@outline SpeedPulseScaleFactor initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-**************************************************************************** */
-void DeadReckoningInitSpeedPulseScaleFactorDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- (void)memset(reinterpret_cast<void *>(&gst_speedpulsescalefactor), 0x00, sizeof(gst_speedpulsescalefactor));
- gst_speedpulsescalefactor.ul_did = VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR;
- gst_speedpulsescalefactor.us_size = VEHICLE_DSIZE_SPEED_PULSE_SCALE_FACTOR;
- gst_speedpulsescalefactor.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_speedpulsescalefactor.dr_status = 0U; /* Not used */
-}
-
-/*************************************************************************
-@brief SpeedPulseScaleFactor SET function
-@outline To update the master data SpeedPulseScaleFactor
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : The pointer to incoming message data
-@threshold none
-@return u_int8
-@retval DEADRECKONING_EQ : No data changes
-@retval DEADRECKONING_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 DeadReckoningSetSpeedPulseScaleFactorDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret = DEADRECKONING_EQ;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- if (p_st_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "p_st_data == NULL\r\n");
- } else {
- p_st_master = &gst_speedpulsescalefactor;
-
- /** Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(reinterpret_cast<void *>(&(p_st_master->uc_data)),
- (const void *)(&(p_st_data->uc_data) ), (size_t)(p_st_data->us_size));
-
- /** Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = 0U; /* Not used */
-
- (void)memcpy(reinterpret_cast<void *>(&(p_st_master->uc_data)),
- (const void *)(&(p_st_data->uc_data)), sizeof(p_st_master->uc_data));
- }
-
- return (uc_ret);
-}
-
-/************************************************************************
-@brief SpeedPulseScaleFactor GET function
-@outline Master Data provides the SpeedPulseScaleFactor
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void DeadReckoningGetSpeedPulseScaleFactorDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- if (p_st_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "p_st_data == NULL\r\n");
- } else {
- p_st_master = &gst_speedpulsescalefactor;
-
- /** Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status; /* Not used(Set DataMaster defaults) */
- (void)memcpy(reinterpret_cast<void *>(&(p_st_data->uc_data)),
- (const void *)(&(p_st_master->uc_data)), (size_t)p_st_master->us_size);
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Speed_dr.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Speed_dr.cpp
deleted file mode 100755
index b2b1f88..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_Did_Speed_dr.cpp
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*************************************************************************
-@file DeadReckoning_Did_Speed.cpp
-@detail DeadReckoning data Master(VEHICLE_DID_DR_SPEED)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "DeadReckoning_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static DEADRECKONING_DATA_MASTER gst_speed; // NOLINT(readability/nolint)
-
-/************************************************************************
-@brief Speed Dead Reckoning initialization function
-@outline Speed initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-**************************************************************************** */
-void DeadReckoningInitSpeedDr(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&(gst_speed), 0x00, sizeof(DEADRECKONING_DATA_MASTER));
- gst_speed.ul_did = VEHICLE_DID_DR_SPEED;
- gst_speed.us_size = VEHICLE_DSIZE_SPEED;
- gst_speed.uc_rcv_flag = DEADRECKONING_RCVFLAG_OFF;
- gst_speed.dr_status = SENSORMOTION_DRSTATUS_INVALID;
- gst_speed.uc_data[0] = VEHICLE_DINIT_SPEED;
-}
-
-/************************************************************************
-@brief Speed Dead Reckoning SET function
-@outline To update the master data Speed.
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval DEADRECKONING_EQ : No data changes
-@retval DEADRECKONING_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 DeadReckoningSetSpeedDr(const DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_speed;
-
- /** Compare data master and received data */
- uc_ret = DeadReckoningMemcmp(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- /** Received data is set in the data master. */
- p_st_master->ul_did = p_st_data->ul_did;
- p_st_master->us_size = p_st_data->us_size;
- p_st_master->uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- p_st_master->dr_status = p_st_data->dr_status;
-
- memcpy(p_st_master->uc_data, p_st_data->uc_data, p_st_data->us_size);
-
- return (uc_ret);
-}
-
-/*************************************************************************
-@brief Speed Dead Reckoning GET function
-@outline Master Data provides the Speed
-@type Completion return type
-@param[in] DEADRECKONING_DATA_MASTER *p_st_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void DeadReckoningGetSpeedDr(DEADRECKONING_DATA_MASTER *p_st_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const DEADRECKONING_DATA_MASTER *p_st_master;
-
- p_st_master = &gst_speed;
-
- /** Store the data master in the specified destination. */
- p_st_data->ul_did = p_st_master->ul_did;
- p_st_data->us_size = p_st_master->us_size;
- p_st_data->uc_rcv_flag = p_st_master->uc_rcv_flag;
- p_st_data->dr_status = p_st_master->dr_status;
- memcpy(p_st_data->uc_data, p_st_master->uc_data, p_st_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_main.cpp b/vehicleservice/positioning/server/src/Sensor/DeadReckoning_main.cpp
deleted file mode 100755
index 1d956b7..0000000
--- a/vehicleservice/positioning/server/src/Sensor/DeadReckoning_main.cpp
+++ /dev/null
@@ -1,1086 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :DeadReckoning_Main.cpp
- * System name :_CWORD107_
- * Subsystem name :DeadReckoning Mains
- * Program name :DeadReckoning Mains
- * Module configuration :DeadReckoningInit() Guessed navigation initialization processing
- * :DeadReckoningRcvMsg() DR Component MSG Receive Processing
- ******************************************************************************/
-
-#include <positioning_hal.h>
-
-#include "DeadReckoning_main.h"
-
-#include "Sensor_Common_API.h"
-#include "DeadReckoning_DataMaster.h"
-#include "Dead_Reckoning_Local_Api.h"
-
-#include "DeadReckoning_DbgLogSim.h"
-
-#include "POS_private.h"
-
-static RET_API DeadReckoningWriteSharedMemory(VEHICLEDEBUG_MSG_LOGINFO_DAT* loginfo);
-static void DeadReckoningSetEvent(PNO pno, RET_API ret);
-static void DeadReckoningLinkSharedMemory(char *shared_memory_name, void **share_addr);
-
-#define DEAD_RECKONING_MAIN_DEBUG 0
-#define DR_DEBUG 0
-#define DR_DEBUG_ENG_MODE 0
-
-/*************************************************/
-/* Constant */
-/*************************************************/
-
-#define DEAD_RECKONING_BUF_SIZE 7
-#define DR_MASK_WORD_L 0x00FF
-#define DR_MASK_WORD_U 0xFF00
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/* Data receive confirmation flag */
-BOOL g_gps_data_get_flg = FALSE;
-BOOL g_sens_data_get_flg = FALSE;
-BOOL g_fst_sens_data_get_flg = FALSE;
-
-/* Reception flag for each data */
-BOOL g_sens_data_get_sns_cnt_flg = FALSE;
-BOOL g_sens_data_get_gyro_x_flg = FALSE;
-BOOL g_sens_data_get_gyro_y_flg = FALSE;
-BOOL g_sens_data_get_gyro_z_flg = FALSE;
-BOOL g_sens_data_get_rev_flg = FALSE;
-BOOL g_sens_data_get_spdpulse_flg = FALSE;
-BOOL g_sens_data_get_spdpulse_chk_flg = FALSE;
-
-BOOL g_sens_data_get_gyro_x_fst_flg = FALSE;
-BOOL g_sens_data_get_gyro_y_fst_flg = FALSE;
-BOOL g_sens_data_get_gyro_z_fst_flg = FALSE;
-BOOL g_sens_data_get_rev_fst_flg = FALSE;
-BOOL g_sens_data_get_spdpulse_fst_flg = FALSE;
-BOOL g_sens_data_get_spdpulse_chk_fst_flg = FALSE;
-
-/* Receive data storage buffer */
-/* [0]:SNS_COUNTER [1]:REV [2]:SPEED_PULSE_FLAG [3]:SPEED_PULSE [4]:GYRO_X [5]:GYRO_Y [6]:GYRO_Z */
-DEAD_RECKONING_RCVDATA_SENSOR g_sns_buf[DEAD_RECKONING_BUF_SIZE];
-DEAD_RECKONING_SAVEDATA_SENSOR_FIRST g_fst_sns_buf;
-
-/*******************************************************************************
- * MODULE : DeadReckoningInit
- * ABSTRACT : Guessed navigation initialization processing
- * FUNCTION : Initialize inferred navigation processing
- * ARGUMENT : None
- * NOTE :
- * RETURN : RET_NORMAL :Success in initialization
- * RET_ERROR :Master Clear failed
- ******************************************************************************/
-int32 DeadReckoningInit(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- return RET_NORMAL;
-}
-
-/*******************************************************************************
- * MODULE : DeadReckoningRcvMsg
- * ABSTRACT : DR Component MSG Receive Processing
- * FUNCTION : Receive the DR component MSG
- * ARGUMENT : *msg : message buffer
- * NOTE :
- * RETURN : None
- ******************************************************************************/
-void DeadReckoningRcvMsg(const DEAD_RECKONING_RCVDATA *msg, DEAD_RECKONING_LONLAT_INFO *location_info) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- if ((msg == NULL) || (location_info == NULL)) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "msg == NULL\r\n");
- } else {
- const SENSOR_MSG_GPSDATA_DAT *rcv_gps_msg = NULL;
- const VEHICLESENS_DATA_MASTER *rcv_sensor_msg = NULL;
- const VEHICLESENS_DATA_MASTER_FST *rcv_sensor_msg_fst = NULL;
-
- Struct_GpsData send_gps_msg;
- Struct_SensData send_sensor_msg;
-
- /* Initialization */
- (void)memset(reinterpret_cast<void *>(&send_gps_msg), 0, sizeof(Struct_GpsData));
- (void)memset(reinterpret_cast<void *>(&send_sensor_msg), 0, sizeof(Struct_SensData));
-
- /* Flag is set to FALSE */
- location_info->calc_called = static_cast<u_int8>(FALSE);
- location_info->available = static_cast<u_int8>(FALSE);
-
- if (CID_DEAD_RECKONING_GPS_DATA == msg->hdr.hdr.cid) {
- rcv_gps_msg = (const SENSOR_MSG_GPSDATA_DAT *)(&(msg->data[0]));
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
-
- /* Receiving GPS Data for DR */
- switch (rcv_gps_msg->ul_did) {
- case VEHICLE_DID_GPS_UBLOX_NAV_POSLLH :
- case VEHICLE_DID_GPS_UBLOX_NAV_STATUS :
- case VEHICLE_DID_GPS_UBLOX_NAV_TIMEUTC :
- case VEHICLE_DID_GPS_UBLOX_NAV_VELNED :
- case VEHICLE_DID_GPS_UBLOX_NAV_DOP :
- case VEHICLE_DID_GPS_UBLOX_NAV_SVINFO :
- case VEHICLE_DID_GPS_UBLOX_NAV_CLOCK :
- {
- g_gps_data_get_flg = TRUE;
- break;
- }
- default:
- break;
- }
- } else if (CID_DEAD_RECKONING_SENS_DATA == msg->hdr.hdr.cid) {
- rcv_sensor_msg = (const VEHICLESENS_DATA_MASTER *)(&(msg->data[0]));
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
-
- /* Sensor data reception for DR */
- switch (rcv_sensor_msg->ul_did) {
- case POSHAL_DID_SNS_COUNTER :
- {
- g_sns_buf[0].did = rcv_sensor_msg->ul_did;
- g_sns_buf[0].size = static_cast<u_int8>(rcv_sensor_msg->us_size);
- g_sns_buf[0].data[0] = rcv_sensor_msg->uc_data[0];
- g_sens_data_get_sns_cnt_flg = TRUE;
- break;
- }
- case POSHAL_DID_REV :
- {
- g_sns_buf[1].did = rcv_sensor_msg->ul_did;
- g_sns_buf[1].size = static_cast<u_int8>(rcv_sensor_msg->us_size);
- (void)memcpy(reinterpret_cast<void *>(&(g_sns_buf[1].data[0])),
- (const void *)(&(rcv_sensor_msg->uc_data[0])), (size_t)rcv_sensor_msg->us_size);
- g_sens_data_get_rev_flg = TRUE;
- break;
- }
- case POSHAL_DID_SPEED_PULSE_FLAG :
- {
- g_sns_buf[2].did = rcv_sensor_msg->ul_did;
- g_sns_buf[2].size = static_cast<u_int8>(rcv_sensor_msg->us_size);
- (void)memcpy(reinterpret_cast<void *>(&(g_sns_buf[2].data[0])),
- (const void *)(&(rcv_sensor_msg->uc_data[0])), (size_t)rcv_sensor_msg->us_size);
- g_sens_data_get_spdpulse_chk_flg = TRUE;
- break;
- }
- case POSHAL_DID_SPEED_PULSE :
- {
- g_sns_buf[3].did = rcv_sensor_msg->ul_did;
- g_sns_buf[3].size = static_cast<u_int8>(rcv_sensor_msg->us_size);
- (void)memcpy(reinterpret_cast<void *>(&(g_sns_buf[3].data[0])),
- (const void *)(&(rcv_sensor_msg->uc_data[0])), (size_t)rcv_sensor_msg->us_size);
- g_sens_data_get_spdpulse_flg = TRUE;
- break;
- }
- case POSHAL_DID_GYRO_X :
- {
- g_sns_buf[4].did = rcv_sensor_msg->ul_did;
- g_sns_buf[4].size = static_cast<u_int8>(rcv_sensor_msg->us_size);
- (void)memcpy(reinterpret_cast<void *>(&(g_sns_buf[4].data[0])),
- (const void *)(&(rcv_sensor_msg->uc_data[0])), (size_t)rcv_sensor_msg->us_size);
- g_sens_data_get_gyro_x_flg = TRUE;
- break;
- }
- case POSHAL_DID_GYRO_Y :
- {
- g_sns_buf[5].did = rcv_sensor_msg->ul_did;
- g_sns_buf[5].size = static_cast<u_int8>(rcv_sensor_msg->us_size);
- (void)memcpy(reinterpret_cast<void *>(&(g_sns_buf[5].data[0])),
- (const void *)(&(rcv_sensor_msg->uc_data[0])), (size_t)rcv_sensor_msg->us_size);
- g_sens_data_get_gyro_y_flg = TRUE;
- break;
- }
- case POSHAL_DID_GYRO_Z :
- {
- g_sns_buf[6].did = rcv_sensor_msg->ul_did;
- g_sns_buf[6].size = static_cast<u_int8>(rcv_sensor_msg->us_size);
- (void)memcpy(reinterpret_cast<void *>(&(g_sns_buf[6].data[0])),
- (const void *)(&(rcv_sensor_msg->uc_data[0])), (size_t)rcv_sensor_msg->us_size);
- g_sens_data_get_gyro_z_flg = TRUE;
- break;
- }
- default:
- break;
- }
- } else if (CID_DEAD_RECKONING_SENS_FST_DATA == msg->hdr.hdr.cid) {
- u_int16 rev_data_size;
-
- rcv_sensor_msg_fst = (const VEHICLESENS_DATA_MASTER_FST *)(&(msg->data[0]));
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
- rev_data_size = static_cast<u_int16>(msg->hdr.hdr.msgbodysize - VEHICLESENS_DELIVERY_FSTSNS_HDR_SIZE);
-
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, " DID = %08X, rev_data_size = %d ",
- rcv_sensor_msg_fst->ul_did, rev_data_size);
-#endif
-
- /* Sensor data reception for DR */
- switch (rcv_sensor_msg_fst->ul_did) {
- case POSHAL_DID_REV_FST :
- {
- (void)memcpy(
- reinterpret_cast<void *>(&(g_fst_sns_buf.rev_data[g_fst_sns_buf.rev_rcv_size
- / sizeof(g_fst_sns_buf.rev_data[0])])),
- (const void *)(&(rcv_sensor_msg_fst->uc_data[0])),
- (size_t)(rev_data_size));
-
- g_fst_sns_buf.rev_rcv_size = static_cast<u_int16>(
- g_fst_sns_buf.rev_rcv_size + rev_data_size);
-
- if (g_fst_sns_buf.rev_rcv_size == rcv_sensor_msg_fst->us_size) {
- g_sens_data_get_rev_fst_flg = TRUE;
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, " REV receive flag = TRUE ");
-#endif
- }
- break;
- }
- case POSHAL_DID_SPEED_PULSE_FLAG_FST :
- {
- (void)memcpy(
- reinterpret_cast<void *>(&(g_fst_sns_buf.spd_pulse_check_data[g_fst_sns_buf.spd_pulse_check_rcv_size
- / sizeof(g_fst_sns_buf.spd_pulse_check_data[0])])),
- (const void *)(&(rcv_sensor_msg_fst->uc_data[0])),
- (size_t)(rev_data_size));
-
- g_fst_sns_buf.spd_pulse_check_rcv_size = static_cast<u_int16>(
- g_fst_sns_buf.spd_pulse_check_rcv_size + rev_data_size);
-
- if (g_fst_sns_buf.spd_pulse_check_rcv_size == rcv_sensor_msg_fst->us_size) {
- g_sens_data_get_spdpulse_chk_fst_flg = TRUE;
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, " SPF receive flag = TRUE ");
-#endif
- }
- break;
- }
- case POSHAL_DID_SPEED_PULSE_FST :
- {
- (void)memcpy(
- reinterpret_cast<void *>(&(g_fst_sns_buf.spd_pulse_data[g_fst_sns_buf.spd_pulse_rcv_size
- / sizeof(g_fst_sns_buf.spd_pulse_data[0])])),
- (const void *)(&(rcv_sensor_msg_fst->uc_data[0])),
- (size_t)(rev_data_size));
-
- g_fst_sns_buf.spd_pulse_rcv_size = static_cast<u_int16>(g_fst_sns_buf.spd_pulse_rcv_size + \
- rev_data_size);
-
- if (g_fst_sns_buf.spd_pulse_rcv_size == rcv_sensor_msg_fst->us_size) {
- g_sens_data_get_spdpulse_fst_flg = TRUE;
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, " SP receive flag = TRUE ");
-#endif
- }
- break;
- }
- case POSHAL_DID_GYRO_X_FST :
- {
- (void)memcpy(
- reinterpret_cast<void *>(&(g_fst_sns_buf.gyro_x_data[g_fst_sns_buf.gyro_x_rcv_size
- / sizeof(g_fst_sns_buf.gyro_x_data[0])])),
- (const void *)(&(rcv_sensor_msg_fst->uc_data[0])),
- (size_t)(rev_data_size));
-
- g_fst_sns_buf.gyro_x_rcv_size = static_cast<u_int16>(g_fst_sns_buf.gyro_x_rcv_size + rev_data_size);
-
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- " g_fst_sns_buf.gyro_x_rcv_size = %d, rcv_sensor_msg_fst->us_size = %d ",
- g_fst_sns_buf.gyro_x_rcv_size, rcv_sensor_msg_fst->us_size);
-#endif
- if (g_fst_sns_buf.gyro_x_rcv_size == rcv_sensor_msg_fst->us_size) {
- g_sens_data_get_gyro_x_fst_flg = TRUE;
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, " GYRO_X receive flag = TRUE ");
-#endif
- }
- break;
- }
- case POSHAL_DID_GYRO_Y_FST :
- {
- (void)memcpy(
- reinterpret_cast<void *>(&(g_fst_sns_buf.gyro_y_data[g_fst_sns_buf.gyro_y_rcv_size
- / sizeof(g_fst_sns_buf.gyro_y_data[0])])),
- (const void *)(&(rcv_sensor_msg_fst->uc_data[0])),
- (size_t)(rev_data_size));
-
- g_fst_sns_buf.gyro_y_rcv_size = static_cast<u_int16>(g_fst_sns_buf.gyro_y_rcv_size + rev_data_size);
-
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- " g_fst_sns_buf.gyro_y_rcv_size = %d, rcv_sensor_msg_fst->us_size = %d ",
- g_fst_sns_buf.gyro_y_rcv_size, rcv_sensor_msg_fst->us_size);
-#endif
- if (g_fst_sns_buf.gyro_y_rcv_size == rcv_sensor_msg_fst->us_size) {
- g_sens_data_get_gyro_y_fst_flg = TRUE;
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, " GYRO_Y receive flag = TRUE ");
-#endif
- }
- break;
- }
- case POSHAL_DID_GYRO_Z_FST :
- {
- (void)memcpy(
- reinterpret_cast<void *>(&(g_fst_sns_buf.gyro_z_data[g_fst_sns_buf.gyro_z_rcv_size
- / sizeof(g_fst_sns_buf.gyro_z_data[0])])),
- (const void *)(&(rcv_sensor_msg_fst->uc_data[0])),
- (size_t)(rev_data_size));
-
- g_fst_sns_buf.gyro_z_rcv_size = static_cast<u_int16>(g_fst_sns_buf.gyro_z_rcv_size + rev_data_size);
-
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- " g_fst_sns_buf.gyro_z_rcv_size = %d, rcv_sensor_msg_fst->us_size = %d ",
- g_fst_sns_buf.gyro_z_rcv_size, rcv_sensor_msg_fst->us_size);
-#endif
- if (g_fst_sns_buf.gyro_z_rcv_size == rcv_sensor_msg_fst->us_size) {
- g_sens_data_get_gyro_z_fst_flg = TRUE;
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, " GYRO_Z receive flag = TRUE ");
-#endif
- }
- break;
- }
- default:
- break;
- }
- } else {
- /* nop */
- }
-
- /* 4 data received? */
- if ((g_sens_data_get_sns_cnt_flg == TRUE) &&
- (g_sens_data_get_rev_flg == TRUE) &&
- (g_sens_data_get_gyro_x_flg == TRUE) &&
- (g_sens_data_get_gyro_y_flg == TRUE) &&
- (g_sens_data_get_gyro_z_flg == TRUE) &&
- (g_sens_data_get_spdpulse_flg == TRUE) &&
- (g_sens_data_get_spdpulse_chk_flg == TRUE)) {
- /* Sensor data acquisition flag ON */
- g_sens_data_get_flg = TRUE;
-
- /* Set all flags to FALSE */
- g_sens_data_get_sns_cnt_flg = FALSE;
- g_sens_data_get_gyro_x_flg = FALSE;
- g_sens_data_get_gyro_y_flg = FALSE;
- g_sens_data_get_gyro_z_flg = FALSE;
- g_sens_data_get_rev_flg = FALSE;
- g_sens_data_get_spdpulse_flg = FALSE;
- g_sens_data_get_spdpulse_chk_flg = FALSE;
- }
-
- /* 4 data received? */
- if ((g_sens_data_get_rev_fst_flg == TRUE) &&
- (g_sens_data_get_gyro_x_fst_flg == TRUE) &&
- (g_sens_data_get_gyro_y_fst_flg == TRUE) &&
- (g_sens_data_get_gyro_z_fst_flg == TRUE) &&
- (g_sens_data_get_spdpulse_fst_flg == TRUE) &&
- (g_sens_data_get_spdpulse_chk_fst_flg == TRUE)) {
- /* Initial sensor data acquisition flag ON */
- g_fst_sens_data_get_flg = TRUE;
-
- /* Set all flags to FALSE */
- g_sens_data_get_gyro_x_fst_flg = FALSE;
- g_sens_data_get_gyro_y_fst_flg = FALSE;
- g_sens_data_get_gyro_z_fst_flg = FALSE;
- g_sens_data_get_rev_fst_flg = FALSE;
- g_sens_data_get_spdpulse_fst_flg = FALSE;
- g_sens_data_get_spdpulse_chk_fst_flg = FALSE;
- }
-
- DeadReckoningRcvMsgFstSens(msg, location_info, rcv_gps_msg, &send_gps_msg, &send_sensor_msg);
- }
-}
-
-void DeadReckoningRcvMsgFstSens(const DEAD_RECKONING_RCVDATA *msg, DEAD_RECKONING_LONLAT_INFO *location_info,
- const SENSOR_MSG_GPSDATA_DAT *rcv_gps_msg, Struct_GpsData* send_gps_msg,
- Struct_SensData* send_sensor_msg) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Verifying Debug Log Simulator Mode
- Perform packet reading here to match some timing.
- However,,Differ between GPS and SENSOR.
- */
- u_int8 fst_sens_send_num = 0U;
- /* For GPS data */
- if (g_gps_data_get_flg == TRUE) {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "DeadReckoningRcvMsg SEND GPS_DATA: DID[0x%08X] DSIZE[%d] MSG_SIZE[%d] SNS_CNT[%d] \r\n",
- rcv_gps_msg.ulDid, rcv_gps_msg.ucData[4], msg->hdr.hdr.msgbodysize, rcv_gps_msg.ucSnsCnt);
-#endif
-
- if (1) {
- rcv_gps_msg = (const SENSOR_MSG_GPSDATA_DAT *)(&(msg->data[0]));
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
-
- /* Set and pass the data part except header/footer */
- send_gps_msg->sens_cnt = rcv_gps_msg->uc_sns_cnt;
- send_gps_msg->sens_cnt_flag = rcv_gps_msg->uc_gps_cnt_flag;
- send_gps_msg->gps_data_size = rcv_gps_msg->us_size;
- send_gps_msg->did = rcv_gps_msg->ul_did;
- send_gps_msg->gps_data = (const void *)(&rcv_gps_msg->uc_data[0]);
- }
-
- /* Providing GPS data to DR_Lib */
-
- g_gps_data_get_flg = FALSE;
-
- } else if (g_sens_data_get_flg == TRUE) {
- Struct_DR_DATA rcv_dr_data;
- DR_CALC_INFO rcv_dr_calc_info;
- DEADRECKONING_DATA_MASTER send_data_master;
-
- if (1) {
- /* Each data is stored in the data format for transmission. */
- send_sensor_msg->sens_cnt_flag = 1U;
- send_sensor_msg->sens_cnt = g_sns_buf[0].data[0];
- send_sensor_msg->pulse_rev_tbl.reverse_flag = g_sns_buf[1].data[0];
- send_sensor_msg->pulse_rev_tbl.pulse_flag = g_sns_buf[2].data[0];
- send_sensor_msg->pulse_rev_tbl.pulse_sum_cyclic = static_cast<u_int16>(
- ((((u_int16)g_sns_buf[3].data[0] << 0) & DR_MASK_WORD_L) |
- (((u_int16)g_sns_buf[3].data[1] << 8) & DR_MASK_WORD_U)));
- /* ToDo */
- (void)memcpy(reinterpret_cast<void *>(&(send_sensor_msg->gyro_x_tbl.gyro_data[0])),
- (const void *)(&(g_sns_buf[4].data[0])), sizeof(u_int16) * NUM_OF_100msData);
- (void)memcpy(reinterpret_cast<void *>(&(send_sensor_msg->gyro_y_tbl.gyro_data[0])),
- (const void *)(&(g_sns_buf[5].data[0])), sizeof(u_int16) * NUM_OF_100msData);
- (void)memcpy(reinterpret_cast<void *>(&(send_sensor_msg->gyro_z_tbl.gyro_data[0])),
- (const void *)(&(g_sns_buf[6].data[0])), sizeof(u_int16) * NUM_OF_100msData);
- }
-
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningRcvMsg SEND SENSOR_COUNTER %d \r\n",
- send_sensor_msg->sens_cnt);
-#endif
-
- /* When the sensor data are ready, Call the DR-calculation process. */
- memset(&rcv_dr_data, 0x00, sizeof(rcv_dr_data)); /* Coverity CID:18805 compliant */
- memset(&rcv_dr_calc_info, 0x00, sizeof(rcv_dr_calc_info)); /* Coverity CID:18806 compliant */
-
- location_info->calc_called = static_cast<u_int8>(TRUE);
- location_info->lonlat.latitude = static_cast<int32>(rcv_dr_data.latitude);
- location_info->lonlat.longitude = static_cast<int32>(rcv_dr_data.longitude);
-
- if (rcv_dr_data.dr_status != static_cast<u_int8>(SENSORLOCATION_DRSTATUS_INVALID)) {
- location_info->available = static_cast<u_int8>(TRUE);
- } else {
- location_info->available = static_cast<u_int8>(FALSE);
- }
-
- /* Changing the order of registration and delivery of the out structure to the data master for DR */
-
- send_data_master.ul_did = VEHICLE_DID_DR_SNS_COUNTER;
- send_data_master.us_size = VEHICLE_DSIZE_DR_SNS_COUNTER;
- send_data_master.uc_rcv_flag = 1;
- send_data_master.dr_status = rcv_dr_data.dr_status;
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- (const void *)(&(rcv_dr_data.positioning_time)), (size_t)VEHICLE_DSIZE_DR_SNS_COUNTER);
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- send_data_master.ul_did = VEHICLE_DID_DR_LONGITUDE;
- send_data_master.us_size = VEHICLE_DSIZE_LONGITUDE;
- send_data_master.uc_rcv_flag = 1;
- send_data_master.dr_status = rcv_dr_data.dr_status;
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- (const void *)(&(rcv_dr_data.longitude)), (size_t)VEHICLE_DSIZE_LONGITUDE);
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- send_data_master.ul_did = VEHICLE_DID_DR_LATITUDE;
- send_data_master.us_size = VEHICLE_DSIZE_LATITUDE;
- send_data_master.uc_rcv_flag = 1;
- send_data_master.dr_status = rcv_dr_data.dr_status;
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- (const void *)(&(rcv_dr_data.latitude)), (size_t)VEHICLE_DSIZE_LATITUDE);
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- send_data_master.ul_did = VEHICLE_DID_DR_ALTITUDE;
- send_data_master.us_size = VEHICLE_DSIZE_ALTITUDE;
- send_data_master.uc_rcv_flag = 1;
- send_data_master.dr_status = rcv_dr_data.dr_status;
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- (const void *)(&(rcv_dr_data.altitude)), (size_t)VEHICLE_DSIZE_ALTITUDE);
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- send_data_master.ul_did = VEHICLE_DID_DR_SPEED;
- send_data_master.us_size = VEHICLE_DSIZE_SPEED;
- send_data_master.uc_rcv_flag = 1;
- send_data_master.dr_status = rcv_dr_data.dr_status;
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- (const void *)(&(rcv_dr_data.rate)), (size_t)VEHICLE_DSIZE_SPEED);
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- send_data_master.ul_did = VEHICLE_DID_DR_HEADING;
- send_data_master.us_size = VEHICLE_DSIZE_HEADING;
- send_data_master.uc_rcv_flag = 1;
- send_data_master.dr_status = rcv_dr_data.dr_status;
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- (const void *)(&(rcv_dr_data.heading)), (size_t)VEHICLE_DSIZE_HEADING);
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- /* Data master setting,Data delivery(GyroParameter) */
- /* As it is registered for delivery with DID = VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL */
- /* Process in GyroOffset-> GyroScaleFactor-> GyroScelFactorLevel order(Processing order cannot be changed.) */
- send_data_master.ul_did = VEHICLE_DID_DR_GYRO_OFFSET;
- send_data_master.us_size = VEHICLE_DSIZE_GYRO_OFFSET;
- send_data_master.uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- send_data_master.dr_status = 0U; /* Not used */
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- reinterpret_cast<void *>(&(rcv_dr_calc_info.gyro_offset)), (size_t)send_data_master.us_size);
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- send_data_master.ul_did = VEHICLE_DID_DR_GYRO_SCALE_FACTOR;
- send_data_master.us_size = VEHICLE_DSIZE_GYRO_SCALE_FACTOR;
- send_data_master.uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- send_data_master.dr_status = 0U; /* Not used */
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- reinterpret_cast<void *>(&(rcv_dr_calc_info.gyro_scale_factor)),
- (size_t)send_data_master.us_size);
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- send_data_master.ul_did = VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL;
- send_data_master.us_size = VEHICLE_DSIZE_GYRO_SCALE_FACTOR_LEVEL;
- send_data_master.uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- send_data_master.dr_status = 0U; /* Not used */
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- reinterpret_cast<void *>(&(rcv_dr_calc_info.gyro_scale_factor_level)),
- (size_t)(send_data_master.us_size));
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- /* Data master setting,Data delivery(SpeedPulseParameter) */
- /* As it is registered for delivery with DID = VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL */
- /* Process in SpeedPulseScaleFactor-> SpeedPulseScaleFactorLevel order(Processing order cannot be changed.) */
- send_data_master.ul_did = VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR;
- send_data_master.us_size = VEHICLE_DSIZE_SPEED_PULSE_SCALE_FACTOR;
- send_data_master.uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- send_data_master.dr_status = 0U; /* Not used */
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- reinterpret_cast<void *>(&(rcv_dr_calc_info.speed_pulse_scale_factor)),
- (size_t)(send_data_master.us_size));
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- send_data_master.ul_did = VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL;
- send_data_master.us_size = VEHICLE_DSIZE_SPEED_PULSE_SCALE_FACTOR_LEVEL;
- send_data_master.uc_rcv_flag = DEADRECKONING_RCVFLAG_ON;
- send_data_master.dr_status = 0U; /* Not used */
- (void)memcpy(reinterpret_cast<void *>(&(send_data_master.uc_data[0])),
- reinterpret_cast<void *>(&(rcv_dr_calc_info.speed_pulse_scale_factor_level)),
- (size_t)(send_data_master.us_size));
- DeadReckoningSetDataMaster(&send_data_master, (PFUNC_DR_DMASTER_SET_N)DeadReckoningDeliveryProc);
-
- g_sens_data_get_flg = FALSE;
- } else if (g_fst_sens_data_get_flg == TRUE) {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningRcvMsg FstSnsData -> DeadReckoningLibrary. \r\n");
-#endif
- for (fst_sens_send_num = 0; fst_sens_send_num < g_fst_sns_buf.data_num; fst_sens_send_num++) {
- /* Each data is stored in the data format for transmission. */
- send_sensor_msg->sens_cnt_flag = 0U;
- send_sensor_msg->sens_cnt = 0U;
- send_sensor_msg->pulse_rev_tbl.reverse_flag = g_fst_sns_buf.rev_data[fst_sens_send_num];
- send_sensor_msg->pulse_rev_tbl.pulse_flag = g_fst_sns_buf.spd_pulse_check_data[fst_sens_send_num];
- send_sensor_msg->pulse_rev_tbl.pulse_sum_cyclic = g_fst_sns_buf.spd_pulse_data[fst_sens_send_num];
- (void)memcpy(reinterpret_cast<void *>(&(send_sensor_msg->gyro_x_tbl.gyro_data[0])),
- (const void *)(&(g_fst_sns_buf.gyro_x_data[fst_sens_send_num * NUM_OF_100msData])),
- (size_t)((sizeof(g_fst_sns_buf.gyro_x_data[fst_sens_send_num])) * NUM_OF_100msData));
- (void)memcpy(reinterpret_cast<void *>(&(send_sensor_msg->gyro_y_tbl.gyro_data[0])),
- (const void *)(&(g_fst_sns_buf.gyro_y_data[fst_sens_send_num * NUM_OF_100msData])),
- (size_t)((sizeof(g_fst_sns_buf.gyro_y_data[fst_sens_send_num])) * NUM_OF_100msData));
- (void)memcpy(reinterpret_cast<void *>(&(send_sensor_msg->gyro_z_tbl.gyro_data[0])),
- (const void *)(&(g_fst_sns_buf.gyro_z_data[fst_sens_send_num * NUM_OF_100msData])),
- (size_t)((sizeof(g_fst_sns_buf.gyro_z_data[fst_sens_send_num])) * NUM_OF_100msData));
-
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningRcvMsg send_sensor_msg.sens_cnt_flag %d \r\n",
- send_sensor_msg->sens_cnt_flag);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DeadReckoningRcvMsg SEND SENSOR_COUNTER %d \r\n",
- send_sensor_msg->sens_cnt);
-#endif
-
- /* Sleep to reduce CPU load */
- MilliSecSleep(DR_FST_SENS_CALC_SLEEP_TIME);
-
- /* When the sensor data are ready, Call the DR-calculation process. */
- }
-
- g_sens_data_get_flg = FALSE;
-
- g_fst_sens_data_get_flg = FALSE;
-
- } else {
- /* nop */
- }
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningGetDRData
-* ABSTRACT : Vehicle sensor information acquisition
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningGetDRData(const DEADRECKONING_MSG_GET_DR_DATA *msg) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- void *share_top; /* Start address of shared memory */
- u_int32 share_size; /* Size of shared memory area */
- RET_API ret_api;
- int32 ret;
- int32 event_val = VEHICLE_RET_NORMAL;
- EventID event_id;
- DEADRECKONING_DATA_MASTER dr_master; /* GPS Data Master */
-
- DEADRECKONING_MSG_GET_DR_DATA msg_buf;
-
- /* Defines the data master for each API. */
- SENSORLOCATION_MSG_LONLATINFO_DAT msg_lonlat_info;
- SENSORLOCATION_MSG_ALTITUDEINFO_DAT msg_altitude_info;
- SENSORMOTION_MSG_SPEEDINFO_DAT msg_speed_info;
- SENSORMOTION_MSG_HEADINGINFO_DAT msg_heading_info;
-
- (void)memset(reinterpret_cast<void *>(&msg_buf), 0, sizeof(DEADRECKONING_MSG_GET_DR_DATA));
- memcpy(&(msg_buf), msg, sizeof(DEADRECKONING_MSG_GET_DR_DATA));
-
- /* Check the DID */
- ret = DeadReckoningCheckDid(msg_buf.data.did);
-
- if (VEHICLESENS_INVALID != ret) {
- /* DID normal */
-
- /* Link to shared memory */
- ret_api = _pb_LinkShareData(const_cast<char *>(VEHICLE_SHARE_NAME), &share_top, &share_size);
- if (RET_NORMAL == ret_api) {
- /* Acquire the specified data from the data master. */
- (void)memset(reinterpret_cast<void *>(&dr_master), 0, sizeof(DEADRECKONING_DATA_MASTER));
- DeadReckoningGetDataMaster(msg_buf.data.did, &dr_master);
-
- /* Align data from the data master for API I/F */
- switch ((u_int32)(msg_buf.data.did)) {
- /* Describes the process for each DID. */
- case VEHICLE_DID_DR_LATITUDE:
- {
- (void)memset(reinterpret_cast<void *>(&msg_lonlat_info),
- 0, sizeof(SENSORLOCATION_MSG_LONLATINFO_DAT));
-
- /* Size storage(LATITUDE) */
- msg_lonlat_info.size = static_cast<u_int16>(sizeof(SENSORLOCATION_MSG_LONLATINFO_DAT));
-
- /* DR status setting */
- msg_lonlat_info.dr_status = dr_master.dr_status;
-
- /* The DR enable flag is set to DR status. */
- msg_lonlat_info.is_exist_dr = dr_master.dr_status;
-
- /* Set the Latitude */
- memcpy(&(msg_lonlat_info.latitude), &(dr_master.uc_data[0]), dr_master.us_size);
-
- /* Obtain the data master Longitude */
- (void)memset(reinterpret_cast<void *>(&dr_master), 0, sizeof(DEADRECKONING_DATA_MASTER));
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_LONGITUDE, &dr_master);
-
- /* Set the Longitude */
- memcpy(&(msg_lonlat_info.longitude), &(dr_master.uc_data[0]), dr_master.us_size);
-
- /* Acquire data master SensorCnt */
- (void)memset(reinterpret_cast<void *>(&dr_master), 0, sizeof(DEADRECKONING_DATA_MASTER));
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &dr_master);
-
- /* Set the SensorCnt */
- memcpy(&(msg_lonlat_info.sensor_cnt), &(dr_master.uc_data[0]), dr_master.us_size);
-
- /* Write data master to shared memory */
- PosSetShareData(share_top,
- msg_buf.data.offset,
- (const void *)&msg_lonlat_info,
- sizeof(msg_lonlat_info));
-
- /* Set Successful Completion */
- event_val = VEHICLE_RET_NORMAL;
-
- break;
- }
- case VEHICLE_DID_DR_ALTITUDE:
- {
- (void)memset(reinterpret_cast<void *>(&msg_altitude_info),
- 0, sizeof(SENSORLOCATION_MSG_ALTITUDEINFO_DAT));
-
- msg_altitude_info.size = static_cast<u_int16>(sizeof(SENSORLOCATION_MSG_ALTITUDEINFO_DAT));
- /* The DR enable flag is set to DR status. */
- msg_altitude_info.is_exist_dr = dr_master.dr_status;
- msg_altitude_info.dr_status = dr_master.dr_status;
-
- /* Set the Speed */
- memcpy(&(msg_altitude_info.altitude), &(dr_master.uc_data[0]), dr_master.us_size);
-
- /* Acquire data master SensorCnt */
- (void)memset(reinterpret_cast<void *>(&dr_master), 0, sizeof(DEADRECKONING_DATA_MASTER));
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &dr_master);
-
- /* Set the SensorCnt */
- memcpy(&(msg_altitude_info.sensor_cnt), &(dr_master.uc_data[0]), dr_master.us_size);
-
- /* Write data master to shared memory */
- PosSetShareData(share_top,
- msg_buf.data.offset,
- (const void *)&msg_altitude_info,
- sizeof(msg_altitude_info));
-
- /* Set Successful Completion */
- event_val = VEHICLE_RET_NORMAL;
-
- break;
- }
- case VEHICLE_DID_DR_SPEED:
- {
- (void)memset(reinterpret_cast<void *>(&msg_speed_info),
- 0, sizeof(SENSORMOTION_MSG_SPEEDINFO_DAT));
-
- msg_speed_info.size = static_cast<u_int16>(sizeof(SENSORMOTION_MSG_SPEEDINFO_DAT));
- /* The DR enable flag is set to DR status. */
- msg_speed_info.is_exist_dr = dr_master.dr_status;
- msg_speed_info.dr_status = dr_master.dr_status;
-
- /* Set the Speed */
- memcpy(&(msg_speed_info.speed), &(dr_master.uc_data[0]), dr_master.us_size);
-
- /* Acquire data master SensorCnt */
- (void)memset(reinterpret_cast<void *>(&dr_master), 0, sizeof(DEADRECKONING_DATA_MASTER));
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &dr_master);
- /* Set the SensorCnt */
- memcpy(&(msg_speed_info.sensor_cnt), &(dr_master.uc_data[0]), dr_master.us_size);
-
- /* Write data master to shared memory */
- PosSetShareData(share_top,
- msg_buf.data.offset,
- (const void *)&msg_speed_info,
- sizeof(msg_speed_info));
-
- /* Set Successful Completion */
- event_val = VEHICLE_RET_NORMAL;
-
- break;
- }
- case VEHICLE_DID_DR_HEADING:
- {
- (void)memset(reinterpret_cast<void *>(&msg_heading_info),
- 0, sizeof(SENSORMOTION_MSG_HEADINGINFO_DAT));
-
- msg_heading_info.size = static_cast<u_int16>(sizeof(SENSORMOTION_MSG_HEADINGINFO_DAT));
- /* The DR enable flag is set to DR status. */
- msg_heading_info.is_exist_dr = dr_master.dr_status;
- msg_heading_info.dr_status = dr_master.dr_status;
-
- /* Set the Heading */
- memcpy(&(msg_heading_info.heading), &(dr_master.uc_data[0]), dr_master.us_size);
-
- /* Acquire data master SensorCnt */
- (void)memset(reinterpret_cast<void *>(&dr_master), 0, sizeof(DEADRECKONING_DATA_MASTER));
- DeadReckoningGetDataMaster(VEHICLE_DID_DR_SNS_COUNTER, &dr_master);
- /* Set the SensorCnt */
- memcpy(&(msg_heading_info.sensor_cnt), &(dr_master.uc_data[0]), dr_master.us_size);
-
- /* Write data master to shared memory */
- PosSetShareData(share_top,
- msg_buf.data.offset,
- (const void *)&msg_heading_info,
- sizeof(msg_heading_info));
- /* Set Successful Completion */
- event_val = VEHICLE_RET_NORMAL;
-
- break;
- }
- /* Other than the above */
- default:
- /* Do not edit. */
- break;
- }
-
- /* Check the data size */
- if (msg_buf.data.size < dr_master.us_size) {
- /* Shared memory error(Insufficient storage size) */
- event_val = VEHICLE_RET_ERROR_OUTOF_MEMORY;
- }
- } else {
- /* Shared memory error */
- event_val = VEHICLE_RET_ERROR_OUTOF_MEMORY;
- }
- } else {
- /* DID error */
- event_val = VEHICLE_RET_ERROR_DID;
- }
-
- /* Event Generation */
- event_id = VehicleCreateEvent(msg_buf.data.pno);
-
- /* Publish Events */
- ret_api = _pb_SetEvent(event_id, SAPI_EVSET_ABSOLUTE, event_val);
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningSetMapMatchingData
-* ABSTRACT : Map-Matching information setting
-* FUNCTION : Setting Map-Matching Information
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningSetMapMatchingData(const DR_MSG_MAP_MATCHING_DATA *msg) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningClearBackupData
-* ABSTRACT : Backup data clear function CALL
-* FUNCTION : Call the backup data clear function.
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : None
-******************************************************************************/
-void DeadReckoningClearBackupData(const DR_MSG_CLEAR_BACKUP_DATA *msg) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- char event_name[32]; /* Event name character string buffer */
- EventID event_id; /* Event ID */
- int32 event_val; /* Event value to set*/
- RET_API ret_api; /* System API return value */
-
- if (msg != NULL) {
- /* DR backup data initialization function call */
- event_val = RET_NORMAL;
-
- /* Initialization of event name character string buffer */
- (void)memset(reinterpret_cast<void *>(event_name), 0, sizeof(event_name));
-
- /* Event name creation */
- snprintf(event_name, sizeof(event_name), "DR_API_%X", msg->hdr.hdr.sndpno);
- /* Match DR_API.cpp side with name */
-
- /* Event Generation */
- event_id = _pb_CreateEvent(_CWORD64_EVENT_MANUALRESET_OFF, DR_EVENT_VAL_INIT, event_name);
-
- if (event_id != 0) {
- /* For successful event generation */
- /* Set the event */
- ret_api = _pb_SetEvent(event_id, SAPI_EVSET_ABSOLUTE, event_val);
-
- if (ret_api == RET_NORMAL) {
- /* Successful event set */
- } else {
- /* Event set failed */
- /* Delete Event and Return Event Generation Failed */
- ret_api = _pb_DeleteEvent(event_id);
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SetEvent Failed\r\n");
- }
- }
- }
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningSetEvent
-* ABSTRACT : Set of events
-* FUNCTION : Set event to return successful or unsuccessful log configuration retrieval
-* ARGUMENT : PNO pno : Caller Pno
-* : RET_API ret : Log setting acquisition Success/Fail
-* : RET_NORMAL: Log setting acquisition success
-* : RET_ERROR: Log setting acquisition failure
-* NOTE :
-* RETURN : None
-******************************************************************************/
-static void DeadReckoningSetEvent(PNO pno, RET_API ret) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- char event_name[32]; /* Event name character string buffer */
- EventID event_id; /* Event ID */
- RET_API ret_api; /* System API return value */
-
- /* Initialization of event name character string buffer */
- (void)memset(reinterpret_cast<void *>(event_name), 0, sizeof(event_name));
-
- /* Event name creation */
- snprintf(event_name, sizeof(event_name), "VehicleDebug_%X", pno);
- /* Event name should match VehicleDebug_API.cpp */
-
- /* Event Generation */
- event_id = _pb_CreateEvent(_CWORD64_EVENT_MANUALRESET_OFF, VEHICLEDEBUG_EVENT_VAL_INIT, event_name);
-
- if (event_id != 0) {
- /* For successful event generation */
- /* Set the event */
- ret_api = _pb_SetEvent(event_id, SAPI_EVSET_ABSOLUTE, ret);
-
- if (ret_api == RET_NORMAL) {
- /* Successful event set */
- } else {
- /* Event set failed */
- /* Delete Event */
- ret_api = _pb_DeleteEvent(event_id);
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SetEvent Failed\r\n");
- }
- }
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningLinkSharedMemory
-* ABSTRACT : Shared memory link
-* FUNCTION : Link to shared memory
-* ARGUMENT : char *shared_memory_name : Name of shared memory to link
-* : void **share_addr : Pointer to a variable that stores the address of the linked shared memory.
-* NOTE :
-* RETURN : None
-******************************************************************************/
-static void DeadReckoningLinkSharedMemory(char *shared_memory_name, void **share_addr) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API ret_api;
- void *pv_share_mem; /* Store Shared Memory Address */
- u_int32 share_mem_size; /* Size of the linked shared memory */
-
- if ((shared_memory_name != NULL) && (share_addr != NULL)) {
- /* Link to the handle storage area */
- ret_api = _pb_LinkShareData(shared_memory_name, &pv_share_mem, &share_mem_size);
-
- if (ret_api == RET_NORMAL) {
- /* If the link is successful */
- if (share_mem_size == VEHICLEDEBUG_MSGBUF_DSIZE) {
- /* When the size of the linked shared memory is correct */
- *share_addr = pv_share_mem; /* Set the address */
- } else {
- /* The size of the linked shared memory is incorrect. */
- *share_addr = NULL;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Bad shared memory size\r\n");
- }
- } else {
- /* If the link fails */
- *share_addr = NULL;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Can't link shared memory\r\n");
- }
- }
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningWriteSharedMemory
-* ABSTRACT : Write Shared Memory
-* FUNCTION : Write Shared Memory
-* ARGUMENT : VEHICLEDEBUG_MSG_LOGINFO_DAT* loginfo : Logging information
-* RETURN : RET_API : Whether writing to shared memory was successful
-* : : RET_NORMAL Success
-* : : RET_ERROR Failed
-* NOTE :
-******************************************************************************/
-static RET_API DeadReckoningWriteSharedMemory(VEHICLEDEBUG_MSG_LOGINFO_DAT* loginfo) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static VEHICLEDEBUG_MSG_LOGINFO_DAT *share_addr = NULL; /* Store Shared Memory Address */
- static SemID sem_id = 0; /* ID of shared memory exclusive semaphore */
-
- RET_API ret = RET_NORMAL; /* Return of the functions */
- RET_API ret_api; /* Return of the functions */
-
-#if DEAD_RECKONING_MAIN_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "Call %s\r\n", __func__);
-#endif
-
- /* Get Semaphore ID */
- if (sem_id == 0) {
- sem_id = _pb_CreateSemaphore(const_cast<char *>(SENSOR_LOG_SETTING_SEMAPHO_NAME));
- }
-
- if (sem_id != 0) {
- /* Semaphore ID successfully acquired */
- ret_api = _pb_SemLock(sem_id); /* Semaphore Lock */
-
- if (ret_api == RET_NORMAL) {
- /* Semaphore lock successful */
-
- /* When the shared memory is not linked */
- if (share_addr == NULL) {
- /* Link to shared memory */
- DeadReckoningLinkSharedMemory(const_cast<char *>(LOG_SETTING_SHARE_MEMORY_NAME),
- reinterpret_cast<void **>(&share_addr));
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
- }
-
- if (share_addr != NULL) {
- /* The link to shared memory is successful. */
- /* Writing Data to Shared Memory */
- share_addr->log_sw = loginfo->log_sw;
- (void)memcpy(reinterpret_cast<void *>(share_addr->severity),
- (const void *)(loginfo->severity), sizeof(share_addr->severity));
- } else {
- /* Failed to link to shared memory */
- ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "DeadReckoningLinkSharedMemory Failed");
- }
- /* Semaphore unlock */
- (void)_pb_SemUnlock(sem_id);
- } else {
- /* Semaphore lock failed */
- ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SemLock Failed");
- }
- } else {
- ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "sem_id == 0");
- }
-
- return ret;
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningGetLocationLogStatus
-* ABSTRACT : CALL of functions for acquiring logging settings
-* FUNCTION : Call the log setting acquisition function.
-* ARGUMENT : None
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningGetLocationLogStatus(PNO pno) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API ret_api; /* System API return value */
- RET_API ret;
- VEHICLEDEBUG_MSG_LOGINFO_DAT loginfo; /* Logging information */
- BOOL log_sw = FALSE;
-
- /* CALL of functions for acquiring logging settings */
- ret_api = RET_NORMAL;
-
- if (ret_api == RET_NORMAL) {
- /* Log setting acquisition function succeeded */
- loginfo.log_sw = (u_int32)(log_sw);
-
- /* Write to shared memory */
- ret = DeadReckoningWriteSharedMemory(&loginfo);
-
- /* Event publishing */
- DeadReckoningSetEvent(pno, ret);
- } else {
- /* Log setting acquisition function failed */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "GetLocationLogSetting Failed");
-
- /* Event publishing */
- DeadReckoningSetEvent(pno, RET_ERROR);
- }
-}
-
-/*******************************************************************************
-* MODULE : DeadReckoningSetLocationLogStatus
-* ABSTRACT : CALL of log-setting-request-function
-* FUNCTION : Call the log setting request function.
-* ARGUMENT : u_int32 log_sw : Log type
-* : u_int8 severity : Output level
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void DeadReckoningSetLocationLogStatus(BOOL log_sw, u_int8 severity) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-}
-
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/GpsInt.cpp b/vehicleservice/positioning/server/src/Sensor/GpsInt.cpp
deleted file mode 100755
index 75fb890..0000000
--- a/vehicleservice/positioning/server/src/Sensor/GpsInt.cpp
+++ /dev/null
@@ -1,171 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :GpsInt.cpp
- * System name :PastModel002
- * Subsystem name :GPS interrupt thread
- ******************************************************************************/
-
-/*******************************************************************************
-* Include File
-*******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "POS_private.h"
-#include "GpsInt.h"
-
-#define RD_REG32(reg) \
- (*(volatile ULONG * const)(reg))
-
-#define COMREGMSK_OR 1
-#define ALLINTMASK 0x0f
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-void com_regmsk_dword(ULONG *, ULONG, UCHAR, UCHAR); // NOLINT(readability/nolint)
-#ifdef __cplusplus
-}
-#endif
-
-/*******************************************************************************
-* Define
-*******************************************************************************/
-#define GPS_INT_THREAD_DEBUG_SWITCH 0 /* 0:OFF 1:ON */
-
-/*******************************************************************************
-* Global Parameter
-*******************************************************************************/
-GPS_INT_DATA g_gps_int_data;
-
-/*******************************************************************************
-* Module
-*******************************************************************************/
-/*******************************************************************************
- * MODULE : DEVGpsIntUnMapDevice
- * ABSTRACT : Register mapping release processing
- * FUNCTION : Release the register mapping
- * ARGUMENT : None
- * NOTE :
- * RETURN : None
- ******************************************************************************/
-void DEVGpsIntUnMapDevice(void) {
- /* Release GPIO Register Mapping */
- if ((g_gps_int_data.irq_status_reg != 0)
- || (g_gps_int_data.irq_status_set_reg != 0)
- || (g_gps_int_data.rising_detect_reg != 0)) {
- /* When GPIO registers are mapped */
- /* #QAC confirmation Rule11.3 Data Size Equivalent (4Byte),No problem due to unsigned relation */
- MunMapDeviceIo((HANDLE)g_gps_int_data.irq_status_reg, sizeof(g_gps_int_data.irq_status_reg));
- /* #QAC confirmation Rule11.3 Data Size Equivalent (4Byte),No problem due to unsigned relation */
- MunMapDeviceIo((HANDLE)g_gps_int_data.irq_status_set_reg, sizeof(g_gps_int_data.irq_status_set_reg));
- /* #QAC confirmation Rule11.3 Data Size Equivalent (4Byte),No problem due to unsigned relation */
- MunMapDeviceIo((HANDLE)g_gps_int_data.rising_detect_reg, sizeof(g_gps_int_data.rising_detect_reg));
-
- g_gps_int_data.irq_status_reg = 0;
- g_gps_int_data.irq_status_set_reg = 0;
- g_gps_int_data.rising_detect_reg = 0;
- }
-}
-
-/*******************************************************************************
- * MODULE : DEVGpsIntSetInterupt
- * ABSTRACT : GPS interrupt setting
- * FUNCTION : Setting GPS Interrupt
- * ARGUMENT : None
- * NOTE :
- * RETURN : TRUE : Interrupt setting success
- * : FALSE : Interrupt setting failure
- ******************************************************************************/
-void DEVGpsIntSetInterupt(void) {
-#if GPS_INT_THREAD_DEBUG_SWITCH
- /* Dummy read */
- itr_ret = RD_REG32(g_gps_int_data.irq_status_set_reg);
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "GpsInt.cpp, IRQSTATUS_SET reg value(before) = 0x%08X ", itr_ret);
-#endif
-
- /* GPS interrupt Enable setting */
- /* Dummy read */
- /* #QAC confirmation Rule11.3 Data Size Equivalent (4Byte),No problem due to unsigned relation */
- (void)RD_REG32(g_gps_int_data.irq_status_set_reg);
-
-#if GPS_INT_THREAD_DEBUG_SWITCH
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "GpsInt.cpp, IRQSTATUS_SET reg value(after) = 0x%08X ", itr_ret);
-#endif
-
-
-
-#if GPS_INT_THREAD_DEBUG_SWITCH
- /* Dummy read */
- itr_ret = RD_REG32(g_gps_int_data.rising_detect_reg);
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "GpsInt.cpp, RISINGDETECT reg value(before) = 0x%08X ", itr_ret);
-#endif
-
- /* GPS Interrupt Detection Method Setting */
- /* #QAC confirmation Rule11.3 Data Size Equivalent (4Byte),No problem due to unsigned relation */
- com_regmsk_dword(reinterpret_cast<ULONG *>(g_gps_int_data.rising_detect_reg), \
- GPS_MASK_6BIT, COMREGMSK_OR, ALLINTMASK);
-
- /* Dummy read */
- /* #QAC confirmation Rule11.3 Data Size Equivalent (4Byte),No problem due to unsigned relation */
- (void)RD_REG32(g_gps_int_data.rising_detect_reg);
-
-#if GPS_INT_THREAD_DEBUG_SWITCH
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "GpsInt.cpp, RISINGDETECT reg value(after) = 0x%08X ", itr_ret);
-#endif
-}
-
-/*******************************************************************************
- * MODULE : DEVGpsIntIntRegClear
- * ABSTRACT : Interrupt cause register clear processing
- * FUNCTION : Clear the interrupt cause register
- * ARGUMENT : None
- * NOTE :
- * RETURN : None
- ******************************************************************************/
-void DEVGpsIntIntRegClear(void) {
-#if GPS_INT_THREAD_DEBUG_SWITCH
- /* Dummy read */
- itr_ret = RD_REG32(g_gps_int_data.irq_status_reg);
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "GpsInt.cpp, IRQSTATUS reg value(before) = 0x%08X ", itr_ret);
-#endif
-
- /* Clear Interrupt Source Register */
- /* Dummy read */
- /* #QAC confirmation Rule11.3 Data Size Equivalent (4Byte),No problem due to unsigned relation */
- (void)RD_REG32(g_gps_int_data.irq_status_reg);
-
-#if GPS_INT_THREAD_DEBUG_SWITCH
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "GpsInt.cpp, IRQSTATUS reg value(after) = 0x%08X ", itr_ret);
-#endif
-}
-
-/*******************************************************************************
- * MODULE : DEVGpsIntSndMsg
- * ABSTRACT : Send GPS interrupt occurrence notification
- * FUNCTION : Notify GPS communication management that an interrupt has occurred.
- * ARGUMENT : None
- * NOTE :
- * RETURN : RET_NORMAL : Normal completion
- * : Other than the above : Processing error
- ******************************************************************************/
-RET_API DEVGpsIntSndMsg(void) {
- return RET_NORMAL;
-}
-
diff --git a/vehicleservice/positioning/server/src/Sensor/Makefile b/vehicleservice/positioning/server/src/Sensor/Makefile
deleted file mode 100755
index bb70229..0000000
--- a/vehicleservice/positioning/server/src/Sensor/Makefile
+++ /dev/null
@@ -1,181 +0,0 @@
-#
-# @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-######### installed library(*.a) #############
-INST_LIBS = libPOS_Sensor
-
-######### compiled sources #############
-libPOS_Sensor_SRCS += DeadReckoning_main.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Common.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_GyroScaleFactorLevel_dr.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_Heading_dr.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_GyroOffset_dr.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_Speed_dr.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_Longitude_dr.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_SnsCounter.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_Altitude_dr.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_GyroScaleFactor_dr.cpp
-libPOS_Sensor_SRCS += DeadReckoning_DataMasterMain.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_Latitude_dr.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_SpeedPulseScaleFactor_dr.cpp
-libPOS_Sensor_SRCS += DeadReckoning_Did_SpeedPulseScaleFactorLevel_dr.cpp
-libPOS_Sensor_SRCS += DeadReckoning_DeliveryCtrl.cpp
-libPOS_Sensor_SRCS += ClockUtility.cpp
-libPOS_Sensor_SRCS += VehicleUtility.cpp
-libPOS_Sensor_SRCS += GpsInt.cpp
-libPOS_Sensor_SRCS += VehicleSens_Thread.cpp
-libPOS_Sensor_SRCS += VehicleSens_FromAccess.cpp
-libPOS_Sensor_SRCS += VehicleSens_Common.cpp
-libPOS_Sensor_SRCS += VehicleSens_SelectionItemList.cpp
-libPOS_Sensor_SRCS += VehicleSens_SharedMemory.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_MainGpsInterruptSignal.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsAntennaStatus.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Rev.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsCounter_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SpeedPulse_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Rev_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SpeedPulseExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Mon_Hw_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Nav_Clock_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SysGpsInterruptSignal.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SnsCounter_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroYExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroZExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroX.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroY.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroZ.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Nav_Dop_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroTrouble.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SnsCounterExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Gps_CWORD82__CWORD44_Gp4_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroX_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroY_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroZ_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroConnectStatus.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_RevFst_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_RevExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Nav_SvInfo_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Gps_CWORD82_FullBinary_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GPSInterruptFlag.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SpeedPulseFlag.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Nav_TimeGps_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Nav_TimeUtc_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SpeedPulseFlagFst_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SnsCounter.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SpeedPulseFst_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroXFst_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroYFst_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroZFst_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Nav_Status_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Gps_CWORD82_Nmea_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SpeedPulse.cpp
-libPOS_Sensor_SRCS += VehicleSens_DataMasterMain.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Nav_Velned_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_Nav_Posllh_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsAntenna.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsAntenna_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SpeedKmph.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SpeedKmph_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_LocationLonLat.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_LocationLonLat_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_LocationAltitude.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_LocationAltitude_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_MotionSpeed.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_MotionSpeed_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_MotionSpeed_n.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_MotionSpeed_i.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_MotionHeading.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_MotionHeading_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsTime.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsTime_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsTimeRaw.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsTimeRaw_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_NaviinfoDiagGPS_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsX.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsX_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsXExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsXFst_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsY.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsY_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsYExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsYFst_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsZ.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsZ_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsZExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GsnsZFst_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroTemp.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroTemp_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroTempExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GyroTempFst_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsNmea_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_LocationLonLat_n.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_LocationAltitude_n.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_MotionSpeed_n.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_MotionHeading_n.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SettingTime.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_SettingTime_clock.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_PulseTime.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_PulseTime_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_PulseTimeExt_l.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_WknRollover.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_WknRollover_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsClockDrift.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsClockDrift_g.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsClockFreq.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_GpsClockFreq_g.cpp
-
-libPOS_Sensor_SRCS += VehicleSens_Did_LocationInfoNmea.cpp
-libPOS_Sensor_SRCS += VehicleSens_Did_LocationInfoNmea_n.cpp
-
-libPOS_Sensor_SRCS += VehicleSens_CanDeliveryEntry.cpp
-libPOS_Sensor_SRCS += VehicleSens_DeliveryCtrl.cpp
-libPOS_Sensor_SRCS += SensorLog.cpp
-
-######### add include path #############
-CPPFLAGS += -I../../include/Sensor
-CPPFLAGS += -I../../include/nsfw
-CPPFLAGS += -I../../include/ServiceInterface
-CPPFLAGS += -I../../../client/include
-
-CPPFLAGS += -I../ServiceInterface/VehicleIf
-CPPFLAGS += -I../nsfw/include
-#CPPFLAGS += -I../../../../diag_code/library/include
-
-CPPFLAGS += -I$(SDKTARGETSYSROOT)/usr/agl/include/vehicle_service
-
-######### add compile option #############
-CPPFLAGS += -DLINUX
-
-LDFLAGS += -Wl,--no-undefined
-LDFLAGS += -Wl,--no-as-needed
-CPPFLAGS += -Werror=implicit-function-declaration
-CPPFLAGS += -Werror=format-security
-CPPFLAGS += -Wconversion
-CPPFLAGS += -Wint-to-pointer-cast
-CPPFLAGS += -Wpointer-arith
-CPPFLAGS += -Wformat
-
-######### add library path #############
-LDFLAGS +=
-
-INSTALL = install
-CREATE_DIR = $(DESTDIR)/nv/BS/vs/positioning/rwdata
-install-data:
- $(INSTALL) -d -m 775 $(CREATE_DIR)
-
-include ../../../../vehicle_service.mk
-
diff --git a/vehicleservice/positioning/server/src/Sensor/SensorLog.cpp b/vehicleservice/positioning/server/src/Sensor/SensorLog.cpp
deleted file mode 100755
index eed514f..0000000
--- a/vehicleservice/positioning/server/src/Sensor/SensorLog.cpp
+++ /dev/null
@@ -1,1307 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * SensorLog.cpp
- * @brief
- * Sensor Logging service functionality
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-
-#include <positioning_hal.h>
-#include <unistd.h>
-#include "SensorLog.h"
-#include "Sensor_Common_API.h"
-#include <zlib.h>
-#include "POS_private.h"
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-/* Sensor Log Type */
-typedef enum {
- SENSLOG_TYPE_SYS_INPUT = 0, /* Sensor Log Type-SYS (INPUT) */
- SENSLOG_TYPE_SYS_OUTPUT, /* Sensor Log Type-SYS (OUTPUT) */
- SENSLOG_TYPE_GPS_INPUT, /* Sensor Log Type-GPS (INPUT) */
- SENSLOG_TYPE_GPS_OUTPUT, /* Sensor Log Type-GPS (OUTPUT) */
- SENSLOG_TYPE_NAVI_INPUT, /* Sensor Log Type-NAVI(INPUT) */
- SENSLOG_TYPE_NAVI_OUTPUT, /* Sensor Log Type-NAVI(OUTPUT) */
- SENSLOG_TYPE_POS_OUTPUT, /* Sensor Log Type-POS (OUTPUT) */
- SENSLOG_TYPE_CMD_INPUT, /* Sensor Log Type-CMD (INPUT) */
- SENSLOG_TYPE_CMD_OUTPUT, /* Sensor Log Type-CMD (OUTPUT) */
-
- SENSLOG_TYPE_COUNT /* Sensor Log Type-Counting */
-} SENSLOG_TYPE;
-
-#define SENSLOG_VALIDFLAG_ON (1) /* Effective specific flag ON */
-#define SENSLOG_VALIDFLAG_OFF (0) /* Enable flag OFF */
-#define SENSLOG_FILEPATH_SIZE (128) /* Output path size */
-#define SENSLOG_FILENAME_SIZE (64) /* Output file name size */
-#define SENSLOG_CONFIG_TEXT_SIZE (128) /* config file size/line */
-#define SENSLOG_LEN_MIN (1) /* Record Length-Minimum */
-#define SENSLOG_LEN_MAX (900) /* Record Length-Maximum */
-#define SENSLOG_LEN_DEFAULT (300) /* Record length-default value */
-#define SENSLOG_GEN_MIN (1) /* Number of generations-minimum value */
-#define SENSLOG_GEN_MAX (999) /* Number of generations-maximum value */
-#define SENSLOG_GEN_DEFAULT (100) /* Number of generations-default value */
-#define SENSLOG_BUF_MIN (2272) /* Buffer Size-Minimum */
-#define SENSLOG_BUF_MAX (11360) /* Buffer size-maximum value */
-#define SENSLOG_BUF_DEFAULT (4544) /* Buffer size-default value */
-#define SENSLOG_OUTPUTFLAG_NEW (0) /* Output Flag-New */
-#define SENSLOG_OUTPUTFLAG_ADD (1) /* Output Flag-Add */
-#define SENSLOG_PNAME_MAX (16) /* Maximum number of characters of process name */
-
-#define SENSLOG_SEMAPHO_NAME ("SENSLOG_SEMAPHO") /* Semaphore name(MAX 32Byte) */
-
-#define SENSLOG_CONFIG_FILE_PATH_1 "/nv/BS/vs/positioning/rwdata/" /* Sensor log-Config filepath-1 */
-#define SENSLOG_CONFIG_FILE_PATH_2 "/mnt/sda1/" /* Sensor log-Config filepath-2 */
-#define SENSLOG_CONFIG_FILE_NAME_SYS "POS_sys_log.cfg" /* Sensor log-Config filename-SYS */
-#define SENSLOG_CONFIG_FILE_NAME_GPS "POS_gps_log.cfg" /* Sensor log-Config filename-GPS */
-#define SENSLOG_CONFIG_FILE_NAME_NAVI "POS_nav_log.cfg" /* Sensor log-Config filename-NAVI */
-#define SENSLOG_CONFIG_FILE_NAME_POS "POS_pos_log.cfg" /* Sensor log-Config filename-POS */
-#define SENSLOG_CONFIG_FILE_NAME_CMD "POS_cmd_log.cfg" /* Sensor log-Config filename-CMD */
-#define SENSLOG_CONFIG_KEY_LEN "POS_log_len" /* Sensor log-config file-Record length */
-#define SENSLOG_CONFIG_KEY_GEN "POS_log_gen" /* Sensor log-config file-Number of generations */
-#define SENSLOG_CONFIG_KEY_BUF "POS_log_buf" /* Sensor log-config file-Buffer size */
-#define SENSLOG_NAV_SVINFO_FILE_NAME "POS_NAV_SVINFO" /* Sensor log-NAV-SVINFOFile name(Log output when file exists)*/
-#define SENSLOG_SEQ_START ">>>>" /* Sensor log sequence(Start) */
-#define SENSLOG_SEQ_END "<<<<" /* Sensor log sequence(End) */
-#define SENSLOG_SEQ_SIZE (4) /* Sensor Log Sequence Size */
-
-/*---------------------------------------------------------------------------------*
- * Structre *
- *---------------------------------------------------------------------------------*/
-/*!
- @brief Structure to create SensorLog data
-*/
-typedef struct {
- uint16_t us_len; /* Number of records */
- uint16_t uc_gen; /* Number of generations */
-} SENSLOG_GEN;
-
-/*!
- @brief Structure to create SensorLog data
-*/
-typedef struct {
- uint8_t uc_valid_flag; /* Output enable flag */
- SENSLOG_GEN st_gen; /* Generation information */
- uint16_t us_file_rec_count; /* Number of file output records */
- uint16_t us_rec_count; /* Number of output records */
- uint16_t us_gen_count; /* Number of generations */
- uint8_t uc_file_path[SENSLOG_FILEPATH_SIZE]; /* Output path */
- uint8_t uc_file_name[SENSLOG_FILENAME_SIZE]; /* Output file name */
- uint8_t uc_gen_fname[SENSLOG_FILENAME_SIZE]; /* Generation information output file name */
- uint8_t uc_text_buf[SENSLOG_BUF_MAX]; /* Buffering area(Static) */
- uint32_t ul_text_buf_size; /* Buffering area size */
- uint32_t ul_text_buf_len; /* Data size in the buffer */
- uint8_t uc_output_flag; /* Output flag */
- uint8_t uc_temp_buf[SENSLOG_BUF_MAX]; /* Output data temporary area */
- uint8_t uc_positioninglog_buf[SENSLOG_BUF_MAX]; /* FRAMEWORKUNIFIEDLOG outputs */
-} SENSLOG_INFO;
-
-/*!
- @brief Structure to get System time
-*/
-typedef struct {
- uint16_t us_year;
- uint16_t us_month;
- uint16_t us_day_of_week;
- uint16_t us_day;
- uint16_t us_hour;
- uint16_t us_minute;
- uint16_t us_second;
- uint16_t us_milli_seconds;
-} SENSLOG_SYSTEMTIME;
-
-/*!
- @brief Structure to create SensorLog data
-*/
-typedef struct {
- uint16_t us_data_type; /* Data type */
- SENSLOG_SYSTEMTIME st_sys_time; /* Current time */
- DID ul_did; /* Data ID */
- int8_t c_pname[SENSLOG_PNAME_MAX]; /* Destination information */
- uint8_t uc_unit_type; /* Hardware configuration type(GRADE1 / GRADE2) */
- uint8_t uc_result; /* Send/Receive result(Success:0 / Fail:1) */
- uint16_t us_data_size; /* Size of the data */
-} SENSLOG_DATA_HEADER;
-
-
-/*!
- @brief Structure to create SensorLog ID table
-*/
-typedef struct {
- uint16_t us_data_type; /* Data type */
- DID ul_did; /* Data ID */
- uint16_t us_file_type; /* Sensor Log Type */
- uint16_t us_write_type; /* FRAMEWORKUNIFIEDLOG Output Type */
-} SENSLOG_ID_TBL;
-
-/*---------------------------------------------------------------------------------*
- * Local Function Prototype *
- *---------------------------------------------------------------------------------*/
-static void SensLogGetConfig(const uint8_t*, SENSLOG_INFO*);
-static void SensLogGetConfigVal(uint8_t*, uint8_t*);
-static void SensLogCheckNAVSVINFOFile(void);
-static void SensLogWrite(uint16_t, uint16_t, uint16_t, DID did, PNO pno, uint8_t*, uint16_t, uint8_t, uint8_t, uint8_t);
-static uint16_t SensLogGetFileType(const SENSLOG_ID_TBL*, uint16_t*, uint16_t*, DID did);
-static void SensLogOutputFile(uint8_t);
-static void SensLogOutputGenFile(uint8_t);
-static void SensLogGetSystemTime(SENSLOG_SYSTEMTIME*);
-static void Num2String2Digit(uint8_t* buf, uint32_t num);
-static void Num2String3Digit(uint8_t* buf, uint32_t num);
-static void Num2String4Digit(uint8_t* buf, uint32_t num);
-static void Num2HexString(uint8_t* buf, uint8_t digits, uint32_t num);
-static void SensLogmakeHeader(uint8_t* buf, SENSLOG_DATA_HEADER data_header);
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-/* Sensor log information */
-static SENSLOG_INFO g_sens_log_info[SENSLOG_TYPE_COUNT]; // NOLINT(readability/nolint)
-static uint8_t g_navsv_info_flag = FALSE;
-uint8_t g_mount_path[SENSLOG_FILEPATH_SIZE]; /* Mount path */
-UNIT_TYPE g_unit_type = UNIT_TYPE_NONE; /* HW configuration type */
-SemID g_sem_id = 0; /* Lock semaphore ID */
-
-/* Sensor log type definition table */
-const SENSLOG_ID_TBL kSensLogInputTbl[] = {
- /* Data type DID Sensor Log Type FRAMEWORKUNIFIEDLOG Output Type */
- {SENSLOG_DATA_I_SYS, 0, SENSLOG_TYPE_SYS_INPUT, POS_SENSLOG_TYPE_SYS },
- {SENSLOG_DATA_I_SYS_STS, 0, SENSLOG_TYPE_SYS_INPUT, POS_SENSLOG_TYPE_SYS },
- {SENSLOG_DATA_I_GPS, 0, SENSLOG_TYPE_GPS_INPUT, POS_SENSLOG_TYPE_GPS },
- {SENSLOG_DATA_I_LOC, POSHAL_DID_GPS_CUSTOMDATA_NAVI, SENSLOG_TYPE_NAVI_INPUT, POS_SENSLOG_TYPE_NAV },
- {SENSLOG_DATA_I_SPEED, VEHICLE_DID_MOTION_SPEED_NAVI, SENSLOG_TYPE_NAVI_INPUT, POS_SENSLOG_TYPE_NAV },
- {SENSLOG_DATA_I_TIME, VEHICLE_DID_SETTINGTIME, SENSLOG_TYPE_NAVI_INPUT, POS_SENSLOG_TYPE_NAV },
- {SENSLOG_DATA_I_TIME, POSHAL_DID_GPS_TIME, SENSLOG_TYPE_GPS_INPUT, POS_SENSLOG_TYPE_GPS },
- {SENSLOG_DATA_I_GPSINF, 0, SENSLOG_TYPE_NAVI_INPUT, POS_SENSLOG_TYPE_NAV },
- {SENSLOG_DATA_I_GPSRST, 0, SENSLOG_TYPE_CMD_INPUT, POS_SENSLOG_TYPE_CMD },
- {SENSLOG_DATA_I_GPSSET, 0, SENSLOG_TYPE_CMD_INPUT, POS_SENSLOG_TYPE_CMD },
- {SENSLOG_DATA_I_NAVSVINFO, 0, SENSLOG_TYPE_GPS_INPUT, POS_SENSLOG_TYPE_GPS },
- {SENSLOG_DATA_I_SYS_ABNORMAL, 0, SENSLOG_TYPE_SYS_INPUT, POS_SENSLOG_TYPE_SYS },
- {SENSLOG_DATA_I_UNSPECIFIED, 0, SENSLOG_TYPE_COUNT, POS_SENSLOG_TYPE_NONE }
-};
-
-const SENSLOG_ID_TBL kSensLogOutputTbl[] = {
- /* Data type DID Sensor Log Type FRAMEWORKUNIFIEDLOG Output Type */
- {SENSLOG_DATA_O_SYS, POSHAL_DID_SPEED_PULSE, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_SPEED_KMPH, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GYRO_X, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GYRO_Y, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GYRO_Z, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GSNS_X, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GSNS_Y, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GSNS_Z, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GPS_ANTENNA, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_SNS_COUNTER, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_SPEED_PULSE_FST, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GYRO_X_FST, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GYRO_Y_FST, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GYRO_Z_FST, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, VEHICLE_DID_GPS__CWORD82__NMEA, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GPS__CWORD82___CWORD44_GP4, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GPS__CWORD82__FULLBINARY, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GPS_NMEA, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_REV, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_REV_FST, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GYRO_TEMP, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GYRO_TEMP_FST, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GSNS_X_FST, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GSNS_Y_FST, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GSNS_Z_FST, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_PULSE_TIME, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GPS_CLOCK_DRIFT, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS, POSHAL_DID_GPS_CLOCK_FREQ, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SYS_PKG, 0, SENSLOG_TYPE_SYS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_GPS, 0, SENSLOG_TYPE_CMD_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_LONLAT_N, VEHICLE_DID_LOCATION_LONLAT_NAVI, SENSLOG_TYPE_NAVI_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_LONLAT_G, VEHICLE_DID_LOCATION_LONLAT, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_ALT, VEHICLE_DID_LOCATION_ALTITUDE, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SPEED_N, VEHICLE_DID_MOTION_SPEED_NAVI, SENSLOG_TYPE_NAVI_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_SPEED_P, VEHICLE_DID_MOTION_SPEED_INTERNAL, SENSLOG_TYPE_POS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_HEAD_N, VEHICLE_DID_MOTION_HEADING_NAVI, SENSLOG_TYPE_NAVI_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_HEAD_G, VEHICLE_DID_MOTION_HEADING, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_TIME_SETREQ, VEHICLE_DID_SETTINGTIME, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_TIME, POSHAL_DID_GPS_TIME, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_GPSINF, VEHICLE_DID_NAVIINFO_DIAG_GPS, SENSLOG_TYPE_NAVI_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_TIME_CS, 0, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
- {SENSLOG_DATA_O_GPSRST, 0, SENSLOG_TYPE_GPS_OUTPUT, POS_SENSLOG_TYPE_NONE },
-
- {SENSLOG_DATA_O_UNSPECIFIED, 0, SENSLOG_TYPE_COUNT, POS_SENSLOG_TYPE_NONE }
-};
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Sensor Log Initial Processing
- *
- * @param[in] p_mount_path Mount path
- */
-void SensLogInitialize(uint8_t *p_mount_path) {
- static SENSLOG_INFO st_sens_log_info; /* Coverity CID:23609 compliant */
- uint8_t uc_hw[16]; /* HW name */
- uint8_t ret = 0;
- uint8_t i;
- static uint8_t tzset_flag = 0; /* Not initialized */
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- /* Not initialized */
- if (tzset_flag == 0) {
- tzset();
- tzset_flag = 1; /* Initialization complete */
- }
-
- /* Initialization of sensor log information structure */
- memset(&g_sens_log_info, 0, sizeof(g_sens_log_info));
-
- /* Get mount path */
- memset(&g_mount_path[0], 0, sizeof(g_mount_path));
- if (NULL == p_mount_path) {
- snprintf(reinterpret_cast<char*>(&g_mount_path[0]), sizeof(g_mount_path), SENSLOG_CONFIG_FILE_PATH_2);
- } else {
- snprintf(reinterpret_cast<char*>(&g_mount_path[0]), sizeof(g_mount_path), "%s/", p_mount_path);
- }
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "mount path[%s]", g_mount_path);
-
- /* HW judgment */
- memset(&uc_hw[0], 0, sizeof(uc_hw));
- g_unit_type = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == g_unit_type) {
- /* GRADE1 */
- snprintf(reinterpret_cast<char*>(&uc_hw[0]), sizeof(uc_hw), "GRADE1");
- } else if (UNIT_TYPE_GRADE2 == g_unit_type) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- } else {
- /* Environment error */
- /* Do not output sensor log */
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "Environment Error.");
- ret = 1;
- }
-
- /* Get Semaphore ID */
- g_sem_id = _pb_CreateSemaphore(const_cast<char *>(SENSLOG_SEMAPHO_NAME));
- if (g_sem_id == 0) { // LCOV_EXCL_BR_LINE 200: can not return zero
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "Semaphore create Error.(ID = 0)");
- ret = 1;
- // LCOV_EXCL_STOP
- }
-
- if (ret == 0) {
- /* Read config files */
- /* SYS */
- memset(&st_sens_log_info, 0, sizeof(SENSLOG_INFO));
- SensLogGetConfig((const uint8_t*)SENSLOG_CONFIG_FILE_NAME_SYS, &st_sens_log_info);
- if (st_sens_log_info.uc_valid_flag == SENSLOG_VALIDFLAG_ON) {
- st_sens_log_info.us_gen_count = 1;
- memcpy(&g_sens_log_info[SENSLOG_TYPE_SYS_INPUT], &st_sens_log_info, sizeof(SENSLOG_INFO));
- memcpy(&g_sens_log_info[SENSLOG_TYPE_SYS_OUTPUT], &st_sens_log_info, sizeof(SENSLOG_INFO));
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_SYS_INPUT].uc_file_name[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_SYS_INPUT].uc_file_name), "POS_%s_sys_i_%%03d.log", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_SYS_OUTPUT].uc_file_name[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_SYS_OUTPUT].uc_file_name), "POS_%s_sys_o_%%03d.log", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_SYS_INPUT].uc_gen_fname[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_SYS_INPUT].uc_gen_fname), "POS_%s_sys_i_gen.dat", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_SYS_OUTPUT].uc_gen_fname[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_SYS_OUTPUT].uc_gen_fname), "POS_%s_sys_o_gen.dat", uc_hw);
- SensLogOutputGenFile(SENSLOG_TYPE_SYS_INPUT);
- SensLogOutputGenFile(SENSLOG_TYPE_SYS_OUTPUT);
- }
-
- /* GPS */
- memset(&st_sens_log_info, 0, sizeof(SENSLOG_INFO));
- SensLogGetConfig((const uint8_t*)SENSLOG_CONFIG_FILE_NAME_GPS, &st_sens_log_info);
- if (st_sens_log_info.uc_valid_flag == SENSLOG_VALIDFLAG_ON) {
- st_sens_log_info.us_gen_count = 1;
- memcpy(&g_sens_log_info[SENSLOG_TYPE_GPS_INPUT], &st_sens_log_info, sizeof(SENSLOG_INFO));
- memcpy(&g_sens_log_info[SENSLOG_TYPE_GPS_OUTPUT], &st_sens_log_info, sizeof(SENSLOG_INFO));
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_GPS_INPUT].uc_file_name[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_GPS_INPUT].uc_file_name), "POS_%s_gps_i_%%03d.log", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_GPS_OUTPUT].uc_file_name[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_GPS_OUTPUT].uc_file_name), "POS_%s_gps_o_%%03d.log", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_GPS_INPUT].uc_gen_fname[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_GPS_INPUT].uc_gen_fname), "POS_%s_gps_i_gen.dat", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_GPS_OUTPUT].uc_gen_fname[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_GPS_OUTPUT].uc_gen_fname), "POS_%s_gps_o_gen.dat", uc_hw);
- SensLogOutputGenFile(SENSLOG_TYPE_GPS_INPUT);
- SensLogOutputGenFile(SENSLOG_TYPE_GPS_OUTPUT);
- }
-
- /* NAVI */
- memset(&st_sens_log_info, 0, sizeof(SENSLOG_INFO));
- SensLogGetConfig((const uint8_t*)SENSLOG_CONFIG_FILE_NAME_NAVI, &st_sens_log_info);
- if (st_sens_log_info.uc_valid_flag == SENSLOG_VALIDFLAG_ON) {
- st_sens_log_info.us_gen_count = 1;
- memcpy(&g_sens_log_info[SENSLOG_TYPE_NAVI_INPUT], &st_sens_log_info, sizeof(SENSLOG_INFO));
- memcpy(&g_sens_log_info[SENSLOG_TYPE_NAVI_OUTPUT], &st_sens_log_info, sizeof(SENSLOG_INFO));
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_NAVI_INPUT].uc_file_name[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_NAVI_INPUT].uc_file_name), "POS_%s_nav_i_%%03d.log", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_NAVI_OUTPUT].uc_file_name[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_NAVI_OUTPUT].uc_file_name), "POS_%s_nav_o_%%03d.log", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_NAVI_INPUT].uc_gen_fname[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_NAVI_INPUT].uc_gen_fname), "POS_%s_nav_i_gen.dat", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_NAVI_OUTPUT].uc_gen_fname[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_NAVI_OUTPUT].uc_gen_fname), "POS_%s_nav_o_gen.dat", uc_hw);
- SensLogOutputGenFile(SENSLOG_TYPE_NAVI_INPUT);
- SensLogOutputGenFile(SENSLOG_TYPE_NAVI_OUTPUT);
- }
-
- /* POS */
- memset(&st_sens_log_info, 0, sizeof(SENSLOG_INFO));
- SensLogGetConfig((const uint8_t*)SENSLOG_CONFIG_FILE_NAME_POS, &st_sens_log_info);
- if (st_sens_log_info.uc_valid_flag == SENSLOG_VALIDFLAG_ON) {
- st_sens_log_info.us_gen_count = 1;
- memcpy(&g_sens_log_info[SENSLOG_TYPE_POS_OUTPUT], &st_sens_log_info, sizeof(SENSLOG_INFO));
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_POS_OUTPUT].uc_file_name[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_POS_OUTPUT].uc_file_name), "POS_%s_pos_o_%%03d.log", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_POS_OUTPUT].uc_gen_fname[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_POS_OUTPUT].uc_gen_fname), "POS_%s_pos_o_gen.dat", uc_hw);
- SensLogOutputGenFile(SENSLOG_TYPE_POS_OUTPUT);
- }
-
- /* CMD */
- memset(&st_sens_log_info, 0, sizeof(SENSLOG_INFO));
- SensLogGetConfig((const uint8_t*)SENSLOG_CONFIG_FILE_NAME_CMD, &st_sens_log_info);
- if (st_sens_log_info.uc_valid_flag == SENSLOG_VALIDFLAG_ON) {
- st_sens_log_info.us_gen_count = 1;
- memcpy(&g_sens_log_info[SENSLOG_TYPE_CMD_INPUT], &st_sens_log_info, sizeof(SENSLOG_INFO));
- memcpy(&g_sens_log_info[SENSLOG_TYPE_CMD_OUTPUT], &st_sens_log_info, sizeof(SENSLOG_INFO));
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_CMD_INPUT].uc_file_name[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_CMD_INPUT].uc_file_name), "POS_%s_cmd_i_%%03d.log", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_CMD_OUTPUT].uc_file_name[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_CMD_OUTPUT].uc_file_name), "POS_%s_cmd_o_%%03d.log", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_CMD_INPUT].uc_gen_fname[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_CMD_INPUT].uc_gen_fname), "POS_%s_cmd_i_gen.dat", uc_hw);
- snprintf(reinterpret_cast<char*>(&(g_sens_log_info[SENSLOG_TYPE_CMD_OUTPUT].uc_gen_fname[0])),
- sizeof(g_sens_log_info[SENSLOG_TYPE_CMD_OUTPUT].uc_gen_fname), "POS_%s_cmd_o_gen.dat", uc_hw);
- SensLogOutputGenFile(SENSLOG_TYPE_CMD_INPUT);
- SensLogOutputGenFile(SENSLOG_TYPE_CMD_OUTPUT);
- }
-
- /* NAV-SVINFO */
- SensLogCheckNAVSVINFOFile();
- }
-
- for (i = 0; i < SENSLOG_TYPE_COUNT; i++) {
- if (g_sens_log_info[i].uc_valid_flag == SENSLOG_VALIDFLAG_ON) {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "g_sens_log_info[%d].uc_valid_flag:%d", i, g_sens_log_info[i].uc_valid_flag);
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "g_sens_log_info[%d].st_gen.us_len:%d", i, g_sens_log_info[i].st_gen.us_len);
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "g_sens_log_info[%d].st_gen.uc_gen:%d", i, g_sens_log_info[i].st_gen.uc_gen);
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "g_sens_log_info[%d].us_file_rec_count:%d", i, g_sens_log_info[i].us_file_rec_count);
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "g_sens_log_info[%d].us_rec_count:%d", i, g_sens_log_info[i].us_rec_count);
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "g_sens_log_info[%d].us_gen_count:%d", i, g_sens_log_info[i].us_gen_count);
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "g_sens_log_info[%d].uc_file_path:%s", i, g_sens_log_info[i].uc_file_path);
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "g_sens_log_info[%d].uc_file_name:%s", i, g_sens_log_info[i].uc_file_name);
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "g_sens_log_info[%d].uc_gen_fname:%s", i, g_sens_log_info[i].uc_gen_fname);
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "g_sens_log_info[%d].ul_text_buf_size:%d", i, g_sens_log_info[i].ul_text_buf_size);
- }
- }
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- return;
-}
-
-/**
- * @brief
- * Sensor log stop processing
- */
-void SensLogTerminate(void) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- /* Initialization of sensor log information structure */
- memset(&g_sens_log_info, 0, sizeof(g_sens_log_info));
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
-
- return;
-}
-
-/**
- * @brief
- * Sensor log saving process
- */
-void SensLogStore(void) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- uint8_t i;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- for (i = 0; i < SENSLOG_TYPE_COUNT; i++) {
- /* Output buffering log */
- if ((g_sens_log_info[i].uc_valid_flag == SENSLOG_VALIDFLAG_ON) &&
- (g_sens_log_info[i].ul_text_buf_len > 0)) {
- SensLogOutputFile(i);
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
- return;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Sensor log config file information acquisition
- *
- * @param[in] uc_config_file Config filename
- * @param[out] st_sens_log_info Sensor log information
- */
-static void SensLogGetConfig(const uint8_t* uc_config_file, SENSLOG_INFO* st_sens_log_info) {
- FILE* fp;
- uint8_t uc_file_path[SENSLOG_FILEPATH_SIZE];
- uint8_t uc_file_name[SENSLOG_FILEPATH_SIZE + SENSLOG_FILENAME_SIZE];
- uint8_t ucBuf[SENSLOG_CONFIG_TEXT_SIZE];
- uint8_t uc_val[SENSLOG_CONFIG_TEXT_SIZE];
- uint8_t flag = 0;
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "+");
-
- if ((uc_config_file == NULL) || (st_sens_log_info == NULL)) { // LCOV_EXCL_BR_LINE 200: can not NULL
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Unprocessed if the argument is invalid. */
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "Parameter Error.");
- // LCOV_EXCL_STOP
- } else {
- memset(&uc_file_path, 0, sizeof(uc_file_path));
- memset(&uc_file_name, 0, sizeof(uc_file_name));
-
- /* Refer to the config files in the built-in memory. */
- snprintf(reinterpret_cast<char*>(&uc_file_path[0]), sizeof(uc_file_path), \
- SENSLOG_CONFIG_FILE_PATH_1);
- snprintf(reinterpret_cast<char*>(&uc_file_name[0]), sizeof(uc_file_name), \
- "%s%s", uc_file_path, uc_config_file);
- fp = fopen(reinterpret_cast<char*>(&uc_file_name[0]), "r");
- if (NULL == fp) {
- /* If there are no config files in the built-in memory, refer to the USB memory. */
- snprintf(reinterpret_cast<char*>(&uc_file_path[0]), sizeof(uc_file_path), \
- "%s", (const char*)&g_mount_path[0]);
- snprintf(reinterpret_cast<char*>(&uc_file_name[0]), sizeof(uc_file_name), \
- "%s%s", uc_file_path, uc_config_file);
- fp = fopen(reinterpret_cast<char*>(&uc_file_name[0]), "r");
- }
-
- if (NULL == fp) {
- /* Do not print when there are no config files.(Console log output)*/
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "Not SensorLog config file. [%s]", uc_file_name);
- } else {
- /* Read config files */
- for (;;) {
- if (fgets(reinterpret_cast<char*>(&ucBuf), SENSLOG_CONFIG_TEXT_SIZE, fp) == NULL) {
- /* EOF detection(Fail-safe:Normally it does not pass because it is break at the flag judgment place.)*/
- break;
- }
- memset(&uc_val, 0, sizeof(uc_val));
- if ((strncmp(reinterpret_cast<char*>(&ucBuf), SENSLOG_CONFIG_KEY_LEN, \
- strlen(SENSLOG_CONFIG_KEY_LEN)) == 0) && ((flag & 0x01) != 0x01)) {
- /* Get record length */
- SensLogGetConfigVal(ucBuf, uc_val);
- st_sens_log_info->st_gen.us_len = static_cast<uint16_t>(atoi((const char *)uc_val));
- flag ^= 0x01;
- } else if ((strncmp(reinterpret_cast<char*>(&ucBuf), SENSLOG_CONFIG_KEY_GEN, \
- strlen(SENSLOG_CONFIG_KEY_GEN)) == 0) && ((flag & 0x02) != 0x02)) {
- /* Get number of generations */
- SensLogGetConfigVal(ucBuf, uc_val);
- st_sens_log_info->st_gen.uc_gen = static_cast<uint16_t>(atoi((const char *)uc_val));
- flag ^= 0x02;
- } else {
- /* nop */
- }
-
- if (flag == 0x03) {
- break;
- }
- }
- fclose(fp);
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, \
- "SensorLog read : file[%s] : config[0x%02x]", uc_file_name, flag);
-
- if ((st_sens_log_info->st_gen.us_len < SENSLOG_LEN_MIN) \
- || (st_sens_log_info->st_gen.us_len > SENSLOG_LEN_MAX)) {
- /* The default value is applied if it is outside the valid range. */
- st_sens_log_info->st_gen.us_len = SENSLOG_LEN_DEFAULT;
- }
- if ((st_sens_log_info->st_gen.uc_gen < SENSLOG_GEN_MIN) \
- || (st_sens_log_info->st_gen.uc_gen > SENSLOG_GEN_MAX)) {
- /* The default value is applied if it is outside the valid range. */
- st_sens_log_info->st_gen.uc_gen = SENSLOG_GEN_DEFAULT;
- }
- st_sens_log_info->ul_text_buf_size = SENSLOG_BUF_MAX; /* Static area(Maximum security) */
-
- st_sens_log_info->uc_valid_flag = SENSLOG_VALIDFLAG_ON;
- st_sens_log_info->uc_output_flag = SENSLOG_OUTPUTFLAG_NEW;
- /* The log output path should be the same path as the config file. */
- memcpy(st_sens_log_info->uc_file_path, uc_file_path, SENSLOG_FILEPATH_SIZE);
- }
- }
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "-");
-
- return;
-}
-
-/**
- * @brief
- * Sensor log config file setting value acquisition
- *
- * @param[in] uc_text Config setting information
- * @param[out] uc_val Config setting
- */
-static void SensLogGetConfigVal(uint8_t* uc_text, uint8_t* uc_val) {
- uint8_t ucBuf[SENSLOG_CONFIG_TEXT_SIZE];
- uint16_t i = 0;
- uint16_t j = 0;
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "+");
-
- if ((uc_text == NULL) || (uc_val == NULL)) { // LCOV_EXCL_BR_LINE 200: can not NULL
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Unprocessed if the argument is invalid. */
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "Parameter Error.");
- // LCOV_EXCL_STOP
- } else {
- memset(ucBuf, 0, sizeof(ucBuf));
- while ((*uc_text != ':') && (*uc_text != '\0')) {
- uc_text++;
- i++;
- if (i >= (SENSLOG_CONFIG_TEXT_SIZE - 1)) {
- break;
- }
- }
- while ((*uc_text != '\r') && (*uc_text != '\n') && (*uc_text != '\0')) {
- uc_text++;
- i++;
- ucBuf[j++] = *uc_text;
- if (i >= SENSLOG_CONFIG_TEXT_SIZE) { // LCOV_EXCL_BR_LINE 200: can not exceed size
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&ucBuf, 0, sizeof(ucBuf));
- break;
- // LCOV_EXCL_STOP
- }
- }
- memcpy(uc_val, ucBuf, sizeof(ucBuf));
- }
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "-");
-
- return;
-}
-
-/**
- * @brief
- * Acquisition of sensor log NAV-SVINFO file information
- *
- * @param[in] none
- */
-static void SensLogCheckNAVSVINFOFile(void) {
- FILE* fp;
- const uint8_t* uc_config_file;
- uint8_t uc_file_path[SENSLOG_FILEPATH_SIZE];
- uint8_t uc_file_name[SENSLOG_FILEPATH_SIZE + SENSLOG_FILENAME_SIZE];
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "+");
-
- uc_config_file = (const uint8_t*)SENSLOG_NAV_SVINFO_FILE_NAME;
-
- memset(&uc_file_path, 0, sizeof(uc_file_path));
- memset(&uc_file_name, 0, sizeof(uc_file_name));
-
- /* Refer to the config files in the built-in memory. */
- snprintf(reinterpret_cast<char*>(&uc_file_path[0]), sizeof(uc_file_path), SENSLOG_CONFIG_FILE_PATH_1);
- snprintf(reinterpret_cast<char*>(&uc_file_name[0]), sizeof(uc_file_name), "%s%s", uc_file_path, uc_config_file);
- fp = fopen(reinterpret_cast<char*>(&uc_file_name[0]), "r");
- if (NULL == fp) {
- /* If there are no config files in the built-in memory, refer to the USB memory. */
- snprintf(reinterpret_cast<char*>(&uc_file_path[0]), sizeof(uc_file_path), \
- "%s", (const char*)&g_mount_path[0]);
- snprintf(reinterpret_cast<char*>(&uc_file_name[0]), sizeof(uc_file_name), \
- "%s%s", uc_file_path, uc_config_file);
- fp = fopen(reinterpret_cast<char*>(&uc_file_name[0]), "r");
- }
-
- if (NULL == fp) {
- /* Do not print when there are no config files.(Console log output)*/
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "Not SensorLog config file. [%s]", uc_file_name);
- g_navsv_info_flag = FALSE;
- } else {
- fclose(fp);
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "SensorLog read : file[%s]", uc_file_name);
- g_navsv_info_flag = TRUE;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "-");
-
- return;
-}
-
-/**
- * @brief
- * Acquisition of sensor log NAV-SVINFO file information
- *
- * @param[in] none
- *
- * @return Destination sensor log file type
- */
-uint8_t SensLogGetNavSvinfoFlag(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- return g_navsv_info_flag;
-}
-// LCOV_EXCL_STOP
-/**
- * @brief
- * Sensor log output(Input information)
- *
- * Writes the specified log (input information) to the buffer area
- *
- * @param[in] us_data_type Data type
- * @param[in] ul_did Data ID
- * @param[in] us_pno Destination PNO
- * @param[in] p_data Write data pointer
- * @param[in] us_size Write data size
- * @param[in] uc_result Reception result
- * @param[in] u_write_flag ability to write sensor log
- * @param[in] u_write_abnormal_flag When an error occurs ability to write sensor log
- */
-void SensLogWriteInputData(uint16_t us_data_type, DID ul_did, PNO us_pno, uint8_t *p_data, \
- uint16_t us_size, uint8_t uc_result, uint8_t u_write_flag, uint8_t u_write_abnormal_flag) {
- uint16_t file_type = 0;
- uint16_t data_type = us_data_type;
- uint16_t write_type = POS_SENSLOG_TYPE_NONE;
- RET_API lret_sem = RET_ERROR;
-
- /* Sensor log file type determination */
- file_type = SensLogGetFileType(kSensLogInputTbl, &data_type, &write_type, ul_did);
-
- /* For the target type,Perform exclusive control */
- /* Currently, only GPS input can be written from multiple threads. */
- if (file_type == SENSLOG_TYPE_GPS_INPUT) {
- /* Semaphore ID determination */
- if (g_sem_id != 0) { // LCOV_EXCL_BR_LINE 200: can not zero
- lret_sem = _pb_SemLock(g_sem_id); /* Semaphore Lock */
- if (lret_sem != RET_NORMAL) { // LCOV_EXCL_BR_LINE 200: can not return error
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "SemLock Error.");
- // LCOV_EXCL_STOP
- } else {
- /* Sensor log output */
- SensLogWrite(file_type, data_type, write_type, ul_did, us_pno, p_data, \
- us_size, uc_result, u_write_flag, u_write_abnormal_flag);
- (void)_pb_SemUnlock(g_sem_id); /* Semaphore unlock */
- }
- }
- } else {
- /* Sensor log output */
- SensLogWrite(file_type, data_type, write_type, ul_did, us_pno, p_data, us_size, \
- uc_result, u_write_flag, u_write_abnormal_flag);
- }
-
- return;
-}
-
-/**
- * @brief
- * Sensor log output(Outputs the information)
- *
- * Writes the specified log (output information) to the buffer area
- *
- * @param[in] us_data_type Data type
- * @param[in] ul_did Data ID
- * @param[in] us_pno Destination PNO
- * @param[in] p_data Write data pointer
- * @param[in] us_size Write data size
- * @param[in] uc_result Reception result
- */
-void SensLogWriteOutputData(uint16_t us_data_type, DID ul_did, PNO us_pno, uint8_t *p_data, \
- uint16_t us_size, uint8_t uc_result) {
- uint16_t file_type = 0;
- uint16_t data_type = us_data_type;
- uint16_t write_type = POS_SENSLOG_TYPE_NONE;
- RET_API lret_sem = RET_ERROR;
-
- /* Sensor log file type determination */
- file_type = SensLogGetFileType(kSensLogOutputTbl, &data_type, &write_type, ul_did);
-
- /* For the target type,Perform exclusive control */
- /* Currently, only GPS output can be written from multiple threads. */
- if (file_type == SENSLOG_TYPE_GPS_OUTPUT) {
- /* Semaphore ID determination */
- if (g_sem_id != 0) { // LCOV_EXCL_BR_LINE 200: can not zero
- lret_sem = _pb_SemLock(g_sem_id); /* Semaphore Lock */
- if (lret_sem != RET_NORMAL) { // LCOV_EXCL_BR_LINE 200: can not return error
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "SemLock Error.");
- // LCOV_EXCL_STOP
- } else {
- /* Sensor log output */
- SensLogWrite(file_type, data_type, write_type, ul_did, us_pno, p_data, \
- us_size, uc_result, SENSLOG_ON, SENSLOG_OFF);
- (void)_pb_SemUnlock(g_sem_id); /* Semaphore unlock */
- }
- }
- } else {
- /* Sensor log output */
- SensLogWrite(file_type, data_type, write_type, ul_did, us_pno, p_data, us_size, \
- uc_result, SENSLOG_ON, SENSLOG_OFF);
- }
- return;
-}
-
-/**
- * @brief
- * Convert number to ASCII code(For two digits,Fill up to zero)
- *
- * @param[out] buf Data saving
- * @param[in] num Numbers to be converted
- */
-static void Num2String2Digit(uint8_t* buf, uint32_t num) {
- int8_t c;
- if (num >= 100) { // LCOV_EXCL_BR_LINE 200: can not exceed size
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- *buf++ = '0';
- *buf = '0';
- // LCOV_EXCL_STOP
- } else {
- c = static_cast<int8_t>(num / 10);
- *buf++ = static_cast<uint8_t>(c + '0');
- *buf = static_cast<uint8_t>(num - (c * 10) + '0');
- }
-}
-
-/**
- * @brief
- * Convert number to ASCII code(For 3 digits,Fill up to zero)
- *
- * @param[out] buf Data saving
- * @param[in] num Numbers to be converted
- */
-static void Num2String3Digit(uint8_t* buf, uint32_t num) {
- int8_t c;
- if (num >= 1000) { // LCOV_EXCL_BR_LINE 200: can not exceed size
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- *buf++ = '0';
- *buf++ = '0';
- *buf = '0';
- // LCOV_EXCL_STOP
- } else {
- c = static_cast<int8_t>(num / 100);
- *buf++ = static_cast<uint8_t>(c + '0');
- num = num - (c * 100);
- c = static_cast<int8_t>(num / 10);
- *buf++ = static_cast<uint8_t>(c + '0');
- *buf = static_cast<uint8_t>(num - (c * 10) + '0');
- }
-}
-
-/**
- * @brief
- * Convert number to ASCII code(For 4 digits,Fill up to zero)
- *
- * @param[out] buf Data saving
- * @param[in] num Numbers to be converted
- */
-static void Num2String4Digit(uint8_t* buf, uint32_t num) {
- int8_t c;
- if (num >= 10000) { // LCOV_EXCL_BR_LINE 200: can not exceed size
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- *buf++ = '0';
- *buf++ = '0';
- *buf++ = '0';
- *buf = '0';
- // LCOV_EXCL_STOP
- } else {
- c = static_cast<int8_t>(num / 1000);
- *buf++ = static_cast<uint8_t>(c + '0');
- num = num - (c * 1000);
- c = static_cast<int8_t>(num / 100);
- *buf++ = static_cast<uint8_t>(c + '0');
- num = num - (c * 100);
- c = static_cast<int8_t>(num / 10);
- *buf++ = static_cast<uint8_t>(c + '0');
- *buf = static_cast<uint8_t>(num - (c * 10) + '0');
- }
-}
-
-/**
- * @brief
- * Convert digits to hexadecimal ASCII code(Fill up to zero)
- *
- * @param[out] buf Data saving
- * @param[in] Number of digits to be converted to digits
- * @param[in] num Numbers to be converted
- */
-static void Num2HexString(uint8_t* buf, uint8_t digits, uint32_t num) {
- uint8_t* p = buf + digits;
- uint8_t calc;
- int32_t i;
-
- /* Only within the displayable range,Convert */
- if ((digits == 8) || (num < (uint32_t)(1 << (4 *digits)))) {
- while (num) {
- calc = num % 16;
- if (10 > calc) {
- calc = static_cast<uint8_t>(calc + 0x30); // 0x30 is 0 character
- } else {
- calc = static_cast<uint8_t>(calc + (0x61 - 0x0A)); // 0x41 is the letter of a
- }
- *(--p) = calc;
- num /= 16;
- digits--;
- }
- }
-
- /* Insert 0 in the remaining significant digits. */
- for (i = 0; i < digits; i++) {
- *(--p) = '0';
- }
-}
-
-/**
- * @brief
- * Sensor Log Header Creation
- *
- * @param[out] buf Data saving
- * @param[in] DataHeader data headers
- * @note For buf, Up to 62 bytes are used. As 64 bytes are allocated in the upper digit, Without current problems, dataHeader.c_pname size increase,
- * Need to be reviewed when changing the format.
- */
-static void SensLogmakeHeader(uint8_t* buf, SENSLOG_DATA_HEADER dataHeader) {
- /* "%02d %04d/%02d/%02d %02d:%02d:%02d.%03d %08x %s %01x %01x %04d " */
- int8_t *p;
- uint16_t i = 0;
- Num2String2Digit(buf, dataHeader.us_data_type);
- buf += 2;
- *(buf++) = ' ';
- Num2String4Digit(buf, dataHeader.st_sys_time.us_year);
- buf += 4;
- *(buf++) = '/';
- Num2String2Digit(buf, dataHeader.st_sys_time.us_month);
- buf += 2;
- *(buf++) = '/';
- Num2String2Digit(buf, dataHeader.st_sys_time.us_day);
- buf += 2;
- *(buf++) = ' ';
- Num2String2Digit(buf, dataHeader.st_sys_time.us_hour);
- buf += 2;
- *(buf++) = ':';
- Num2String2Digit(buf, dataHeader.st_sys_time.us_minute);
- buf += 2;
- *(buf++) = ':';
- Num2String2Digit(buf, dataHeader.st_sys_time.us_second);
- buf += 2;
- *(buf++) = '.';
- Num2String3Digit(buf, dataHeader.st_sys_time.us_milli_seconds);
- buf += 3;
- *(buf++) = ' ';
- Num2HexString(buf, 8, dataHeader.ul_did);
- buf += 8;
- *(buf++) = ' ';
- p = dataHeader.c_pname;
- for (i = 0; i < sizeof(dataHeader.c_pname); i++) {
- if (*p == 0) {
- break;
- }
- *(buf++) = *(p++);
- }
- *(buf++) = ' ';
- Num2HexString((buf++), 1, dataHeader.uc_unit_type);
- *(buf++) = ' ';
- Num2HexString((buf++), 1, dataHeader.uc_result);
- *(buf++) = ' ';
- Num2String4Digit(buf, dataHeader.us_data_size);
- buf += 4;
- *(buf++) = ' ';
-
- return;
-}
-
-/**
- * @brief
- * Sensor log output
- *
- * Write specified log to buffer area(Common process)
- *
- * @param[in] us_file_type File type
- * @param[in] us_data_type Data type
- * @param[in] us_write_type FRAMEWORKUNIFIEDLOG Output Type
- * @param[in] ul_did Data ID
- * @param[in] us_pno Destination PNO
- * @param[in] p_data Write data pointer
- * @param[in] us_size Write data size
- * @param[in] uc_result Reception result
- * @param[in] uWriteFlag ability to write sensor log
- * @param[in] u_write_abnormal_flag When an error occursability to write sensor log
- */
-static void SensLogWrite(uint16_t us_file_type, uint16_t us_data_type, uint16_t us_write_type, \
- DID ul_did, PNO us_pno, uint8_t *p_data, uint16_t us_size, uint8_t uc_result, uint8_t uWriteFlag, \
- uint8_t u_write_abnormal_flag) {
- uint32_t len = 0;
- SENSLOG_DATA_HEADER dataHeader;
- uint16_t headSize = sizeof(SENSLOG_DATA_HEADER);
- uint16_t i = 0;
- uint8_t workBuf[64];
- uint16_t workBufLen = 0;
- PCSTR pPname = NULL;
- uint32_t ulTempBufLen;
- uint32_t ulPositioninglogBufLen = SENSLOG_BUF_MAX;
- uint32_t retComp;
-
- if ((p_data == NULL) || (us_size == 0) || (us_size > SENSLOG_BUF_MIN)) { // LCOV_EXCL_BR_LINE 200: can not NULL
- /* Unprocessed if write specified log data is invalid */
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__,
- "Parameter Error. File[%d] Data[%d] DID[%d] Size[%d]",
- us_file_type, us_data_type, ul_did, us_size);
- } else {
- /* Sensor log file type determination */
- if (us_file_type < SENSLOG_TYPE_COUNT) {
- if ((g_sens_log_info[us_file_type].uc_valid_flag == SENSLOG_VALIDFLAG_ON) ||
- (us_write_type != POS_SENSLOG_TYPE_NONE)) {
- /* Setting of header information */
- memset(&dataHeader, 0x00, sizeof(dataHeader));
- dataHeader.us_data_type = us_data_type;
- SensLogGetSystemTime(&dataHeader.st_sys_time);
- dataHeader.ul_did = ul_did;
- pPname = _pb_CnvPno2Name(us_pno);
- if (pPname == NULL) {
- dataHeader.c_pname[0] = '-';
- } else {
- snprintf(reinterpret_cast<char *>(&(dataHeader.c_pname[0])), \
- sizeof(dataHeader.c_pname), "%s", pPname);
- }
- dataHeader.uc_unit_type = (uint8_t)g_unit_type;
- dataHeader.uc_result = uc_result;
- dataHeader.us_data_size = us_size;
-
- /* Buffer storage(Header)*/
- memset(&workBuf[0], 0x00, sizeof(workBuf));
- SensLogmakeHeader(workBuf, dataHeader);
- workBufLen = static_cast<uint16_t>(strlen(reinterpret_cast<char *>(&(workBuf[0]))));
- memcpy(reinterpret_cast<char *>(&(g_sens_log_info[us_file_type].uc_temp_buf[0])), \
- &workBuf[0], workBufLen);
-
- /* Buffer storage(Data portion)*/
- for (i = 0; i < us_size; i++) {
- Num2HexString(&(g_sens_log_info[us_file_type].uc_temp_buf[workBufLen + i * 3]), 2, *p_data);
- g_sens_log_info[us_file_type].uc_temp_buf[workBufLen + i * 3 + 2] = ' ';
- g_sens_log_info[us_file_type].uc_temp_buf[workBufLen + i * 3 + 3] = 0; /* NULL */
- p_data++;
- }
- g_sens_log_info[us_file_type].uc_temp_buf[workBufLen + (us_size * 3)] = '\r';
- g_sens_log_info[us_file_type].uc_temp_buf[workBufLen + (us_size * 3) + 1] = '\n';
- ulTempBufLen = workBufLen + (us_size * 3) + 2;
-
- /* FRAMEWORKUNIFIEDLOG out */
- if ((us_file_type == SENSLOG_TYPE_NAVI_INPUT) || (us_file_type == SENSLOG_TYPE_NAVI_OUTPUT)) {
- if (g_unit_type != UNIT_TYPE_GRADE1) {
- /* Sensor log is not output when an error occurs except for _CWORD80_ in NAV. */
- u_write_abnormal_flag = 0;
- }
- }
- if ((us_write_type != POS_SENSLOG_TYPE_NONE) && (u_write_abnormal_flag == SENSLOG_ON)) {
- /* Data compression */
- retComp = compress2(reinterpret_cast<Bytef*>(&(g_sens_log_info[us_file_type]. \
- uc_positioninglog_buf[SENSLOG_SEQ_SIZE + sizeof(ulPositioninglogBufLen)])), \
- reinterpret_cast<uLongf*>(&ulPositioninglogBufLen), \
- reinterpret_cast<Bytef*>(&(g_sens_log_info[us_file_type].uc_temp_buf[0])), \
- ulTempBufLen, Z_DEFAULT_COMPRESSION);
-
- if (retComp == Z_OK) {
- memcpy(&(g_sens_log_info[us_file_type].uc_positioninglog_buf[0]), \
- SENSLOG_SEQ_START, SENSLOG_SEQ_SIZE);
- memcpy(&(g_sens_log_info[us_file_type].uc_positioninglog_buf[SENSLOG_SEQ_SIZE]), \
- &ulPositioninglogBufLen, sizeof(ulPositioninglogBufLen));
- memcpy(&(g_sens_log_info[us_file_type].uc_positioninglog_buf[SENSLOG_SEQ_SIZE \
- + sizeof(ulPositioninglogBufLen) + ulPositioninglogBufLen]), SENSLOG_SEQ_END, SENSLOG_SEQ_SIZE);
- g_sens_log_info[us_file_type].uc_positioninglog_buf[SENSLOG_SEQ_SIZE + sizeof(ulPositioninglogBufLen) \
- + ulPositioninglogBufLen + SENSLOG_SEQ_SIZE] = '\n';
- ulPositioninglogBufLen = static_cast<uint32_t>(SENSLOG_SEQ_SIZE + sizeof(ulPositioninglogBufLen) \
- + ulPositioninglogBufLen + SENSLOG_SEQ_SIZE + 1);
- POS_SENSLOG(us_write_type, (PCSTR)&(g_sens_log_info[us_file_type].uc_positioninglog_buf[0]), \
- ulPositioninglogBufLen);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, \
- "compress error[retComp = %d]", retComp);
- }
- }
-
- if ((g_sens_log_info[us_file_type].uc_valid_flag == SENSLOG_VALIDFLAG_ON) \
- && (uWriteFlag == SENSLOG_ON)) {
- /* For executing file output */
- /* Buffer size determination */
- len = g_sens_log_info[us_file_type].ul_text_buf_len;
- if (g_sens_log_info[us_file_type].ul_text_buf_size <= (len + ((headSize + us_size) * 3))) {
- FRAMEWORKUNIFIEDLOG(ZONE_WARN, __FUNCTION__, "[%d]:DataSize[%d]/BufLen[%d]",
- us_data_type, us_size, len);
-
- /* In case of buffer upper limit,Write File */
- SensLogOutputFile(static_cast<uint8_t>(us_file_type));
-
- /* Buffer clear */
- memset(&(g_sens_log_info[us_file_type].uc_text_buf[0]), 0x00,
- g_sens_log_info[us_file_type].ul_text_buf_size);
- len = 0;
- }
-
- /* Buffer storage */
- memcpy(reinterpret_cast<char*>(&(g_sens_log_info[us_file_type].uc_text_buf[len])), \
- &g_sens_log_info[us_file_type].uc_temp_buf[0], ulTempBufLen);
- g_sens_log_info[us_file_type].ul_text_buf_len = len + ulTempBufLen;
- g_sens_log_info[us_file_type].us_rec_count++;
-
- /* Determining whether the number of file write records is the upper limit (the number of records per file) */
- if (g_sens_log_info[us_file_type].st_gen.us_len <= g_sens_log_info[us_file_type].us_rec_count) {
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "[%d]:RecCnt[%d/%d]",
- us_data_type, g_sens_log_info[us_file_type].us_rec_count, \
- g_sens_log_info[us_file_type].st_gen.us_len);
-
- /* In case of buffer upper limit,Write File */
- SensLogOutputFile(static_cast<uint8_t>(us_file_type));
-
- /* Buffer clear */
- memset(&(g_sens_log_info[us_file_type].uc_text_buf[0]), 0x00, \
- g_sens_log_info[us_file_type].ul_text_buf_size);
- g_sens_log_info[us_file_type].ul_text_buf_len = 0;
- g_sens_log_info[us_file_type].us_rec_count = 0;
- /* Update the number of generations */
- g_sens_log_info[us_file_type].us_gen_count++;
- if (g_sens_log_info[us_file_type].st_gen.uc_gen < g_sens_log_info[us_file_type].us_gen_count) {
- g_sens_log_info[us_file_type].us_gen_count = 1;
- }
- g_sens_log_info[us_file_type].uc_output_flag = SENSLOG_OUTPUTFLAG_NEW;
- }
- }
- }
- }
- }
-
- return;
-}
-
-/**
- * @brief
- * Sensor log file type determination
- *
- * Determine the type of the output destination sensor log file
- *
- * @param[in] pstTbl Sensor log type definition table
- * @param[in] Pus_data_type Data type
- * @param[out] pus_write_type FRAMEWORKUNIFIEDLOG Output Type
- * @param[in] ul_did Data ID
- *
- * @return Destination sensor log file type
- */
-static uint16_t SensLogGetFileType(const SENSLOG_ID_TBL *pstTbl, uint16_t *pus_data_type, \
- uint16_t *pus_write_type, DID ul_did) {
- uint16_t file_type = SENSLOG_TYPE_COUNT;
- uint16_t cnt = 0;
-
- /* Determination of output log file type */
- /* DID,Prioritize the beginning of the table for both data types. */
- /* If DID is specified, it is judged by DID.*/
- if (ul_did != 0) {
- for (cnt = 0; pstTbl[cnt].us_file_type != SENSLOG_TYPE_COUNT; cnt++) {
- if (pstTbl[cnt].ul_did == ul_did) {
- *pus_data_type = pstTbl[cnt].us_data_type;
- file_type = pstTbl[cnt].us_file_type;
- *pus_write_type = pstTbl[cnt].us_write_type;
- break;
- }
- }
- }
- /* If no DID is specified or cannot be found, judge according to the data type. */
- if (file_type == SENSLOG_TYPE_COUNT) {
- for (cnt = 0; pstTbl[cnt].us_file_type != SENSLOG_TYPE_COUNT; cnt++) {
- if (pstTbl[cnt].us_data_type == *pus_data_type) {
- file_type = pstTbl[cnt].us_file_type;
- *pus_write_type = pstTbl[cnt].us_write_type;
- break;
- }
- }
- }
- return file_type;
-}
-
-/**
- * @brief
- * Sensor log file output
- *
- * Write the log data in the buffer area to a file
- *
- * @param[in] ucFileType File type
- */
-static void SensLogOutputFile(uint8_t ucFileType) {
- FILE *fp;
- int fd;
- uint8_t uc_file_name_base[SENSLOG_FILEPATH_SIZE + SENSLOG_FILENAME_SIZE];
- uint8_t uc_file_name[SENSLOG_FILEPATH_SIZE + SENSLOG_FILENAME_SIZE];
-
- if (ucFileType < SENSLOG_TYPE_COUNT) { // LCOV_EXCL_BR_LINE 200: can not exceed type
- /* File path generation */
- snprintf(reinterpret_cast<char*>(&uc_file_name_base[0]), sizeof(uc_file_name_base),
- "%s%s",
- g_sens_log_info[ucFileType].uc_file_path, g_sens_log_info[ucFileType].uc_file_name);
- snprintf(reinterpret_cast<char*>(&uc_file_name[0]), sizeof(uc_file_name),
- reinterpret_cast<char*>(&uc_file_name_base[0]),
- g_sens_log_info[ucFileType].us_gen_count);
-
- /* Writing to a File */
- if (g_sens_log_info[ucFileType].uc_output_flag == SENSLOG_OUTPUTFLAG_NEW) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, \
- "SensLog create file. : file[%s] : uc_output_flag[%d]", \
- uc_file_name, g_sens_log_info[ucFileType].uc_output_flag);
-
- /* Export New File(Write From Beginning)*/
- fp = fopen(reinterpret_cast<char*>(&uc_file_name[0]), "w+");
- g_sens_log_info[ucFileType].uc_output_flag = SENSLOG_OUTPUTFLAG_ADD;
-
- /* Update generation information file */
- SensLogOutputGenFile(ucFileType);
- } else {
- /* Append export */
- fp = fopen(reinterpret_cast<char*>(&uc_file_name[0]), "a+");
- }
-
- if (NULL != fp) { // LCOV_EXCL_BR_LINE 200: can not NULL
- /* Log file output(ASCII)*/
- fd = fileno(fp);
- fwrite(&(g_sens_log_info[ucFileType].uc_text_buf[0]), g_sens_log_info[ucFileType].ul_text_buf_len, 1, fp);
- fflush(fp); /* Flush the userspace buffers provided by the C library */
- fdatasync(fd); /* Flush cache of files referenced by fd to disk */
- fclose(fp); /* Coverity CID:23371 compliant */
- } else {
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, \
- "SensLog fopen fail. : file[%s] : uc_output_flag[%d]", \
- uc_file_name, g_sens_log_info[ucFileType].uc_output_flag);
- // LCOV_EXCL_STOP
- }
- }
- return;
-}
-
-/**
- * @brief
- * Generation information file output
- *
- * Holds the number of generations being output in the generation information file.
- *
- * @param[in] ucFileType File type
- */
-static void SensLogOutputGenFile(uint8_t ucFileType) {
- FILE *fp;
- int fd;
- uint8_t uc_file_name_base[SENSLOG_FILEPATH_SIZE + SENSLOG_FILENAME_SIZE];
- uint8_t uc_file_name[SENSLOG_FILEPATH_SIZE + SENSLOG_FILENAME_SIZE];
-
- if (ucFileType < SENSLOG_TYPE_COUNT) { // LCOV_EXCL_BR_LINE 200: can not exceed type
- /* File path generation */
- snprintf(reinterpret_cast<char*>(&uc_file_name_base[0]), sizeof(uc_file_name_base),
- "%s%s",
- g_sens_log_info[ucFileType].uc_file_path, g_sens_log_info[ucFileType].uc_gen_fname);
- snprintf(reinterpret_cast<char*>(&uc_file_name[0]), sizeof(uc_file_name),
- reinterpret_cast<char*>(&uc_file_name_base[0]),
- g_sens_log_info[ucFileType].us_gen_count);
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "SensLog create file. : file[%s] : us_gen_count[%d]",
- uc_file_name, g_sens_log_info[ucFileType].us_gen_count);
-
- /* Export New File(Write From Beginning)*/
- fp = fopen(reinterpret_cast<char*>(&uc_file_name[0]), "w+");
- if (NULL != fp) { // LCOV_EXCL_BR_LINE 200: can not NULL
- /* Generation control number output */
- fd = fileno(fp);
- fprintf(fp, "%03d", g_sens_log_info[ucFileType].us_gen_count);
- fflush(fp); /* Flush the userspace buffers provided by the C library */
- fdatasync(fd); /* Flush cache of files referenced by fd to disk */
- fclose(fp); /* Coverity CID:23372 compliant */
- } else {
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, \
- "SensLog fopen fail. : file[%s] : us_gen_count[%d]", \
- uc_file_name, g_sens_log_info[ucFileType].us_gen_count);
- // LCOV_EXCL_STOP
- }
- }
- return;
-}
-
-/**
- * @brief
- * Get system time
- *
- * Get the system time(Millisecond)
- *
- * @param[out] st_sys_time System time
- */
-void SensLogGetSystemTime(SENSLOG_SYSTEMTIME *st_sys_time) {
- time_t time_sec = 0;
- struct timespec tp = {0};
- struct tm time_cal= {0};
-
- if (NULL != st_sys_time) { // LCOV_EXCL_BR_LINE 200: not NULL
- if (0 == clock_gettime(CLOCK_REALTIME, &tp)) {
- time_sec = tp.tv_sec;
- localtime_r(&time_sec, &time_cal);
- st_sys_time->us_year = static_cast<uint16_t>((WORD)time_cal.tm_year + 1900);
- st_sys_time->us_month = static_cast<uint16_t>((WORD)time_cal.tm_mon + 1);
- st_sys_time->us_day_of_week = (WORD)time_cal.tm_wday;
- st_sys_time->us_day = (WORD)time_cal.tm_mday;
- st_sys_time->us_hour = (WORD)time_cal.tm_hour;
- st_sys_time->us_minute = (WORD)time_cal.tm_min;
- st_sys_time->us_second = (WORD)time_cal.tm_sec;
- st_sys_time->us_milli_seconds = (WORD)(static_cast<double>(tp.tv_nsec) * 1e-6); /* Calculating milliseconds */
- }
- }
- return;
-}
-
-/* end of file */
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_CanDeliveryEntry.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_CanDeliveryEntry.cpp
deleted file mode 100755
index f1cd695..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_CanDeliveryEntry.cpp
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSensCanDeliveryEntry.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :CAN data delivery registration
- * Module configuration :VehicleSensCanDeliveryEntry() CAN data delivery registration
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DeliveryCtrl.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensCanDeliveryEntry
-* ABSTRACT : CAN data delivery registration
-* FUNCTION : Register delivery of CAN data required as vehicle sensor middleware
-* ARGUMENT : void
-* NOTE :
-* RETURN : CANIF_RET_NORMAL :Normal completion
-* CANIF_RET_ERROR_CREATE_EVENT :Event generation failure
-* CANIF_RET_ERROR_PARAM :Parameter error
-* CANIF_RET_ERROR_BUFFULL :FULL of delivery registers
-* CANIF_RET_ERROR_CANIDFULL :FULL of delivery CAN ID numbers
-******************************************************************************/
-RET_API VehicleSensCanDeliveryEntry(void) {
- return RET_NORMAL;
-}
-
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Common.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Common.cpp
deleted file mode 100755
index aeb180e..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Common.cpp
+++ /dev/null
@@ -1,429 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Common.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor common processing(VEHICLE_COMMON)
- * Module configuration :VehicleSensmemcmp() Functions for Common Processing Memory Block Comparisons
- * VehicleSensCheckDid() Common Processing Data ID Check Function
- * VehicleSensGetDataMasterOffset() Get function for common processing data master offset value
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_Common.h"
-#include "POS_private.h"
-#include <system_service/ss_ver.h>
-#include <system_service/ss_package.h>
-#include "gps_hal.h"
-#include "VehicleSens_DataMaster.h"
-
-
-#define _pb_strcat(pdest, psrc, size) (strncat(pdest, psrc, size) , (0))
-
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static const VEHICLESENS_DID_OFFSET_TBL kGstDidList[] = {
- /* Data ID Offset size Reserved */
- { VEHICLE_DID_DESTINATION, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_HV, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_STEERING_WHEEL, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_VB, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_IG, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_MIC, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_BACKDOOR, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_PKB, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_ADIM, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_ILL, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_RHEOSTAT, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_SYSTEMP, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_SPEED_PULSE, VEHICLESENS_OFFSET_20WORD, {0, 0} },
- { POSHAL_DID_SPEED_PULSE_FLAG, VEHICLESENS_OFFSET_20WORD, {0, 0} },
- { POSHAL_DID_SPEED_KMPH, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GYRO_X, VEHICLESENS_OFFSET_20WORD, {0, 0} },
- { POSHAL_DID_GYRO_Y, VEHICLESENS_OFFSET_20WORD, {0, 0} },
- { POSHAL_DID_GYRO_Z, VEHICLESENS_OFFSET_20WORD, {0, 0} },
- { POSHAL_DID_GSNS_X, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GSNS_Y, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GSNS_Z, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_REV, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GPS_ANTENNA, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_SNS_COUNTER, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_GPS_COUNTER, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GPS_VERSION, VEHICLESENS_OFFSET_GPS_FORMAT, {0, 0} },
- { VEHICLE_DID_LOCATION, VEHICLESENS_OFFSET_GPS_FORMAT, {0, 0} },
- /* ++GPS _CWORD82_ support */
- { POSHAL_DID_GPS__CWORD82___CWORD44_GP4, VEHICLESENS_OFFSET_GPS_FORMAT, {0, 0} },
- { VEHICLE_DID_GPS__CWORD82__NMEA, VEHICLESENS_OFFSET_GPS_NMEA, {0, 0} },
- { POSHAL_DID_GPS_NMEA, VEHICLESENS_OFFSET_GPS_NMEA, {0, 0} },
- { POSHAL_DID_GPS__CWORD82__FULLBINARY, VEHICLESENS_OFFSET_GPS_FORMAT, {0, 0} },
- /* --GPS _CWORD82_ support */
- { VEHICLE_DID_REV_LINE, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_REV_CAN, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
- { POSHAL_DID_GYRO_EXT, VEHICLESENS_OFFSET_20WORD, {0, 0} },
- { POSHAL_DID_SPEED_PULSE_FST, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GYRO_X_FST, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GYRO_Y_FST, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GYRO_Z_FST, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_SPEED_PULSE_FLAG_FST, VEHICLESENS_OFFSET_20WORD_FST, {0, 0} },
- { POSHAL_DID_REV_FST, VEHICLESENS_OFFSET_20WORD_FST, {0, 0} },
-#endif
- /* ++ PastModel002 support */
- { VEHICLE_DID_GPS_UBLOX_NAV_POSLLH, VEHICLESENS_OFFSET_GPS_UBLOX, {0, 0} },
- { VEHICLE_DID_GPS_UBLOX_NAV_STATUS, VEHICLESENS_OFFSET_GPS_UBLOX, {0, 0} },
- { VEHICLE_DID_GPS_UBLOX_NAV_TIMEUTC, VEHICLESENS_OFFSET_GPS_UBLOX, {0, 0} },
- { VEHICLE_DID_GPS_UBLOX_NAV_VELNED, VEHICLESENS_OFFSET_GPS_UBLOX, {0, 0} },
- { VEHICLE_DID_GPS_UBLOX_NAV_DOP, VEHICLESENS_OFFSET_GPS_UBLOX, {0, 0} },
- { VEHICLE_DID_GPS_UBLOX_NAV_TIMEGPS, VEHICLESENS_OFFSET_GPS_UBLOX, {0, 0} },
- { VEHICLE_DID_GPS_UBLOX_NAV_SVINFO, VEHICLESENS_OFFSET_GPS_UBLOX, {0, 0} },
- { VEHICLE_DID_GPS_UBLOX_NAV_CLOCK, VEHICLESENS_OFFSET_GPS_UBLOX, {0, 0} },
- { VEHICLE_DID_GPS_UBLOX_MON_HW, VEHICLESENS_OFFSET_GPS_UBLOX, {0, 0} },
- { VEHICLE_DID_GYRO_TROUBLE, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_SYS_GPS_INTERRUPT_SIGNAL, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_GYRO_CONNECT_STATUS, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- /* -- PastModel002 support */
- { POSHAL_DID_GPS_TIME, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GPS_TIME_RAW, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GPS_WKNROLLOVER, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_NAVIINFO_DIAG_GPS, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GYRO_TEMP, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GYRO_TEMP_FST, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GSNS_X_FST, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GSNS_Y_FST, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GSNS_Z_FST, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_PULSE_TIME, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_LOCATION_LONLAT, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_LOCATION_ALTITUDE, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_MOTION_SPEED, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_MOTION_HEADING, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_LOCATION_LONLAT_NAVI, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_LOCATION_ALTITUDE_NAVI, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_MOTION_SPEED_NAVI, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_MOTION_HEADING_NAVI, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_SETTINGTIME, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { VEHICLE_DID_MOTION_SPEED_INTERNAL, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GPS_CLOCK_DRIFT, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { POSHAL_DID_GPS_CLOCK_FREQ, VEHICLESENS_OFFSET_NORMAL, {0, 0} },
- { 0, 0, {0, 0} } /* Termination code */
-};
-
-/*******************************************************************************
-* MODULE : VehicleSensmemcmp
-* ABSTRACT : Functions for Common Processing Memory Block Comparisons
-* FUNCTION : Memory block comparison processing
-* ARGUMENT : *vp_data1 : Comparison target address 1
-* : *vp_data2 : Comparison target address 2
-* : uc_size : Comparison Size
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* : VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensmemcmp(const void *vp_data1, const void *vp_data2, size_t uc_size) {
- u_int8 ret = VEHICLESENS_EQ;
- const u_int8 *ucp_data1 = (const u_int8 *)vp_data1;
- const u_int8 *ucp_data2 = (const u_int8 *)vp_data2;
-
- /* Loop by data size */
- while (uc_size > 0) {
- if (*ucp_data1 != *ucp_data2) {
- /* Data mismatch */
- ret = VEHICLESENS_NEQ;
- break;
- }
- ucp_data1++;
- ucp_data2++;
- uc_size--;
- }
- return( ret );
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensCheckDid
-* ABSTRACT : Common Processing Data ID Check Function
-* FUNCTION : Check if the specified DID corresponds to the vehicle sensor information
-* ARGUMENT : ul_did : Data ID
-* NOTE :
-* RETURN : VEHICLESENS_INVALID :Disabled
-* : VEHICLESENS_EFFECTIVE :Enabled
-******************************************************************************/
-int32 VehicleSensCheckDid(DID ul_did) {
- int32 i = 0;
- int32 ret = VEHICLESENS_INVALID;
-
- while (0 != kGstDidList[i].ul_did) { // LCOV_EXCL_BR_LINE 200: did always valid
- if (kGstDidList[i].ul_did == ul_did) {
- /* DID enabled */
- ret = VEHICLESENS_EFFECTIVE;
- break;
- }
- i++;
- }
- return( ret );
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetDataMasterOffset
-* ABSTRACT : Get function for common processing data master offset value
-* FUNCTION : Get the fixed offset value for a given DID
-* ARGUMENT : ul_did : Data ID
-* NOTE :
-* RETURN : Offset value(Returns 0 if DID is invalid)
-******************************************************************************/
-u_int16 VehicleSensGetDataMasterOffset(DID ul_did) {
- int32 i = 0; /* Generic counters */
- u_int16 ret = 0; /* Return value of this function */
-
- while (0 != kGstDidList[i].ul_did) { // LCOV_EXCL_BR_LINE 200: did always valid
- if (kGstDidList[i].ul_did == ul_did) {
- /* DID enabled */
- ret = kGstDidList[i].us_offset;
- break;
- }
- i++;
- }
- return( ret );
-}
-
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetDataMasterExtOffset
-* ABSTRACT : Get function for common processing data master offset value
-* FUNCTION : Get the fixed offset value for the first package delivery of the specified DID
-* ARGUMENT : ul_did : Data ID
-* NOTE :
-* RETURN : Offset value(Returns 0 for unspecified DID)
-******************************************************************************/
-u_int16 VehicleSensGetDataMasterExtOffset(DID ul_did) {
- u_int16 usRet = 0; /* Return value of this function */
-
- switch (ul_did) {
- case POSHAL_DID_GYRO_EXT:
- case POSHAL_DID_GYRO_X:
- case POSHAL_DID_GYRO_Y:
- case POSHAL_DID_GYRO_Z:
- case POSHAL_DID_GSNS_X: /* Ignore->MISRA-C++:2008 Rule 2-7-2 */
- case POSHAL_DID_GSNS_Y: /* Ignore->MISRA-C++:2008 Rule 2-7-2 */
- case POSHAL_DID_GSNS_Z:
- case POSHAL_DID_SPEED_PULSE:
- {
- /* Returns the extended package size (one data 2byte) at the time of initial delivery */
- usRet = VEHICLESENS_OFFSET_10WORD_PKG_EXT;
- break;
- }
- case POSHAL_DID_SNS_COUNTER:
- case POSHAL_DID_REV:
- {
- /* Returns the extended package size (one data 1byte) at the time of initial delivery */
- usRet = VEHICLESENS_OFFSET_BYTE_PKG_EXT;
- break;
- }
- case POSHAL_DID_GYRO_TEMP:
- {
- /* Returns the extended package size (one data 2byte) at the time of initial delivery */
- usRet = VEHICLESENS_OFFSET_WORD_PKG_EXT;
- break;
- }
- case POSHAL_DID_PULSE_TIME:
- {
- /* Returns the expansion package size (132 bytes per data) at the time of initial delivery */
- usRet = VEHICLESENS_OFFSET_32LONG_PKG_EXT;
- break;
- }
- default: /* Other than the above */ /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
- return( usRet );
-}
-#endif
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-
-/**
- * @brief
- * GPS version information setting request
- *
- * Request to set GPS version information to SS
- *
- * @param[in] pstData Pointer to received message data
- */
-void VehicleSensSetGpsVersion(const SENSOR_MSG_GPSDATA_DAT *pstData) {
- static BOOL isExistGpsVersion = FALSE;
- SSVER_PkgInfo info;
- CSSVer cssVer;
- UNIT_TYPE eType = UNIT_TYPE_NONE; /* Supported HW Configuration Type */
- EFrameworkunifiedStatus ret;
-
- if (isExistGpsVersion == FALSE) {
- memset(&info, 0x00, sizeof(info));
- /* Supported HW Configuration Check */
- eType = GetEnvSupportInfo();
- if (UNIT_TYPE_GRADE1 == eType) { // LCOV_EXCL_BR_LINE 6:cannot be this env
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* GRADE1 */
- memcpy(info.version, pstData->uc_data, sizeof(info.version));
-
- /* Calling setPkgInfo() */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "--- VehicleUtility_SetGpsVersion setPkgInfo -->");
- ret = cssVer.setPkgInfo(SS_PKG_NAVI_GPS, info);
- if (ret == eFrameworkunifiedStatusOK) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "--- VehicleUtility_SetGpsVersion setPkgInfo <-- GPSVersion = %s", info.version);
- isExistGpsVersion = TRUE; /* Update Flag */
- } else {
- /* Error log */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "Failed to set PkgInfo EpositioningStatus = %d", ret);
- }
- // LCOV_EXCL_STOP
- } else if ( UNIT_TYPE_GRADE2 == eType ) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- } else {
- /* nop */
- }
- }
- return;
-}
-
-/**
- * @brief
-* Acquisition of location and time information (dump)
- *
- * @param[out] pBuf Dump information
- * @param[in] Uc_get_method Retrieval method
- */
-void VehicleSensGetDebugPosDate(void* pBuf, u_int8 uc_get_method) { // LCOV_EXCL_START 7: uesd only in FrameworkunifiedOnDebugDump
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static uint8_t buf[DEBUG_DUMP_MAX_SIZE];
- static uint8_t bufTmp[256];
- VEHICLESENS_DATA_MASTER stSnsData;
- SENSORLOCATION_LONLATINFO_DAT *pstLonLat;
- SENSORLOCATION_ALTITUDEINFO_DAT *pstAltitude;
- SENSORMOTION_HEADINGINFO_DAT *pstHeading;
- SENSOR_MSG_GPSDATA_DAT stGpsData;
- SENSOR_MSG_GPSTIME *pstDateTimeGps;
- NAVIINFO_DIAG_GPS *pstDiagGps;
- uint8_t i;
-
- memset(&buf, 0x00, sizeof(buf));
- /* Title */
- switch ( uc_get_method ) {
- case VEHICLESENS_GETMETHOD_GPS:
- snprintf(reinterpret_cast<char *>(&buf), sizeof(buf), "GPS Info");
- break;
- case VEHICLESENS_GETMETHOD_NAVI:
- snprintf(reinterpret_cast<char *>(&buf), sizeof(buf), "Navi Info");
- break;
- default:
- /* nop */
- break;
- }
-
- /* Latitude,Longitude */
- VehicleSensGetLocationLonLat(&stSnsData, uc_get_method);
- pstLonLat = reinterpret_cast<SENSORLOCATION_LONLATINFO_DAT*>(stSnsData.uc_data);
- memset(&bufTmp[0], 0x00, sizeof(bufTmp));
- snprintf( reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp),
- "\n [LonLat] sync:%3d, Enable:%01d, Lon:%10d, Lat:%10d, PosSts:0x%02x, PosAcc:0x%04x",
- pstLonLat->SyncCnt,
- pstLonLat->isEnable,
- pstLonLat->Longitude,
- pstLonLat->Latitude,
- pstLonLat->posSts,
- pstLonLat->posAcc);
- _pb_strcat(reinterpret_cast<char *>(&buf[0]), reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp));
-
- /* Altitude */
- VehicleSensGetLocationAltitude(&stSnsData, uc_get_method);
- pstAltitude = reinterpret_cast<SENSORLOCATION_ALTITUDEINFO_DAT*>(stSnsData.uc_data);
- memset(&bufTmp[0], 0x00, sizeof(bufTmp));
- snprintf(reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp),
- "\n [Alt] sync:%3d, Enable:%01d, Alt:%10d",
- pstAltitude->SyncCnt,
- pstAltitude->isEnable,
- pstAltitude->Altitude);
- _pb_strcat(reinterpret_cast<char *>(&buf[0]), reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp));
-
- /* Orientation */
- VehicleSensGetMotionHeading(&stSnsData, uc_get_method);
- pstHeading = reinterpret_cast<SENSORMOTION_HEADINGINFO_DAT*>(stSnsData.uc_data);
- memset(&bufTmp[0], 0x00, sizeof(bufTmp));
- snprintf(reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp),
- "\n [Head] sync:%3d, Enable:%01d, Head:%5d, PosSts:0x%02x",
- pstHeading->SyncCnt,
- pstHeading->isEnable,
- pstHeading->Heading,
- pstHeading->posSts);
- _pb_strcat(reinterpret_cast<char *>(&buf[0]), reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp));
-
- switch ( uc_get_method ) {
- case VEHICLESENS_GETMETHOD_GPS:
- /* Satellite information */
- VehicleSensGetNaviinfoDiagGPSg(&stGpsData);
- pstDiagGps = reinterpret_cast<NAVIINFO_DIAG_GPS*>(stGpsData.uc_data);
- memset(&bufTmp[0], 0x00, sizeof(bufTmp));
- snprintf(reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp),
- "\n [Diag]\n FixSts:0x%02x",
- pstDiagGps->stFix.ucFixSts);
- _pb_strcat(reinterpret_cast<char *>(&buf[0]), reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp));
- for (i = 0; i < 12; i++) {
- memset(&bufTmp[0], 0x00, sizeof(bufTmp));
- snprintf(reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp),
- "\n [%02d] RcvSts:0x%02x, prn:0x%02x, elv:0x%02x, Lv:0x%02x, azm:0x%04x",
- i,
- pstDiagGps->stSat.stPrn[i].ucRcvSts,
- pstDiagGps->stSat.stPrn[i].ucPrn,
- pstDiagGps->stSat.stPrn[i].ucelv,
- pstDiagGps->stSat.stPrn[i].ucLv,
- pstDiagGps->stSat.stPrn[i].usAzm);
- _pb_strcat(reinterpret_cast<char *>(&buf[0]), reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp));
- }
-
- /* Time */
- VehicleSensGetGpsTime(&stGpsData, VEHICLESENS_GETMETHOD_GPS);
- pstDateTimeGps = reinterpret_cast<SENSOR_MSG_GPSTIME*>(stGpsData.uc_data);
- memset(&bufTmp[0], 0x00, sizeof(bufTmp));
- snprintf(reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp),
- "\n [Time] %04d/%02d/%02d %02d:%02d:%02d, sts:%d",
- pstDateTimeGps->utc.year,
- pstDateTimeGps->utc.month,
- pstDateTimeGps->utc.date,
- pstDateTimeGps->utc.hour,
- pstDateTimeGps->utc.minute,
- pstDateTimeGps->utc.second,
- pstDateTimeGps->tdsts);
- _pb_strcat(reinterpret_cast<char *>(&buf[0]), reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp));
- break;
- case VEHICLESENS_GETMETHOD_NAVI:
- /* nop */
- break;
- default:
- /* nop */
- break;
- }
- memcpy(pBuf, &buf[0], sizeof(buf));
- return;
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_DataMasterMain.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_DataMasterMain.cpp
deleted file mode 100755
index 7bf40d1..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_DataMasterMain.cpp
+++ /dev/null
@@ -1,1880 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_DataMasterMain.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master
- * Module configuration :VehicleSensInitDataMaster() Vehicle data master initialization function
- * :VehicleSensSetDataMasterCan() Vehicle sensor data master CAN data set processing
- * :VehicleSensSetDataMasterLineSens() Vehicle sensor data master LineSensor data set process
- * :VehicleSensSetDataMasterGps() Vehicle Sensor Data Master GPS Data Set Processing
- * :VehicleSensGetDataMaster() Vehicle Sensor Data Master Get Processing
- * :VehicleSensGetGpsDataMaster() Vehicle Sensor Data Master GPS Data Get Processing
- * :VehicleSensGetGps_CWORD82_NmeaSensorCnt() Vehicle sensor GPS_sensor counter GET function
- * :VehicleSensSetDataMaster_CWORD82_() Vehicle sensor data master GPS data (_CWORD82_) set processing
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "gps_hal.h"
-#include "POS_private.h"
-#include "DeadReckoning_main.h"
-#include "VehicleSens_DeliveryCtrl.h"
-#include "Vehicle_API.h"
-#include "CommonDefine.h"
-#include <vehicle_service/POS_common_API.h>
-#include "SensorMotion_API.h"
-#include "SensorLog.h"
-#include "ClockIf.h"
-#include "DiagSrvIf.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-VEHICLESENS_PKG_DELIVERY_TEMP_EXT gstPkgTempExt; // NOLINT(readability/nolint)
-#endif
-
-#define DR_DEBUG 0
-#define GPS_DEBUG 0
-
-/*************************************************/
-/* Function prototype */
-/*************************************************/
-static uint8_t VehicleSensGetSensorCnt(void);
-
-
-/*******************************************************************************
-* MODULE : VehicleSensInitDataMaster
-* ABSTRACT : Vehicle sensor data master initialization
-* FUNCTION : Initializing Vehicle Sensor Data Master
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitDataMaster(void) {
- /* Vehicle sensor data master initialization */
-
- VehicleSensInitSpeedPulsel();
- VehicleSensInitSpeedKmphl();
- VehicleSensInitGyroXl();
- VehicleSensInitGyroYl();
- VehicleSensInitGyroZl();
- VehicleSensInitGsnsXl();
- VehicleSensInitGsnsYl();
- VehicleSensInitGsnsZl();
- VehicleSensInitRevl();
- VehicleSensInitGpsAntennal();
- VehicleSensInitSnsCounterl();
- VehicleSensInitGpsCounterg();
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
- VehicleSensInitGyroRevl();
- VehicleSensInitSnsCounterExtl();
- VehicleSensInitGyroExtl();
- VehicleSensInitGyroYExtl();
- VehicleSensInitGyroZExtl();
- VehicleSensInitSpeedPulseExtl();
- VehicleSensInitRevExtl();
- VehicleSensInitGsnsXExtl();
- VehicleSensInitGsnsYExtl();
- VehicleSensInitGsnsZExtl();
- VehicleSensInitGsnsXFstl();
- VehicleSensInitGsnsYFstl();
- VehicleSensInitGsnsZFstl();
- VehicleSensInitGyroXFstl();
- VehicleSensInitGyroYFstl();
- VehicleSensInitGyroZFstl();
- VehicleSensInitSpeedPulseFstl();
- VehicleSensInitSpeedPulseFlagFstl();
- VehicleSensInitRevFstl();
-#endif
- /* ++ GPS _CWORD82_ support */
- VehicleSensInitGps_CWORD82_FullBinaryG();
- VehicleSensInitGps_CWORD82_NmeaG();
- VehicleSensInitGps_CWORD82__CWORD44_Gp4G();
- VehicleSensInitGpsNmeaG();
- /* -- GPS _CWORD82_ support */
-
- /* ++ PastModel002 support */
- VehicleSensInitNavVelnedG();
- VehicleSensInitNavTimeUtcG();
- VehicleSensInitNavTimeGpsG();
- VehicleSensInitNavSvInfoG();
- VehicleSensInitNavStatusG();
- VehicleSensInitNavPosllhG();
- VehicleSensInitNavClockG();
- VehicleSensInitNavDopG();
- VehicleSensInitMonHwG();
-
- VehicleSensInitSpeedPulseFlag();
- VehicleSensInitGpsInterruptFlag();
-
- VehicleSensInitGyroTrouble();
- VehicleSensInitMainGpsInterruptSignal();
- VehicleSensInitSysGpsInterruptSignal();
- VehicleSensInitGyroConnectStatus();
- VehicleSensInitGpsAntennaStatus();
- /* -- PastModel002 support */
-
- VehicleSensInitGyroTempFstl();
- VehicleSensInitGyroTempExtl();
- VehicleSensInitGyroTempl();
- VehicleSensInitPulseTimeExtl();
- VehicleSensInitPulseTimel();
-
- VehicleSensInitLocationLonLatG();
- VehicleSensInitLocationAltitudeG();
- VehicleSensInitMotionSpeedG();
- VehicleSensInitMotionHeadingG();
- VehicleSensInitNaviinfoDiagGPSg();
- VehicleSensInitGpsTimeG();
- VehicleSensInitGpsTimeRawG();
- VehicleSensInitWknRolloverG();
- VehicleSensInitLocationLonLatN();
- VehicleSensInitLocationAltitudeN();
- VehicleSensInitMotionSpeedN();
- VehicleSensInitMotionHeadingN();
- VehicleSensInitSettingTimeclock();
- VehicleSensInitMotionSpeedI();
- VehicleSensInitGpsClockDriftG();
- VehicleSensInitGpsClockFreqG();
-
- VehicleSens_InitLocationInfoNmea_n();
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetDataMasterLineSens
-* ABSTRACT : Vehicle sensor data master LineSensor data set process
-* FUNCTION : Set LineSensor data
-* ARGUMENT : *pst_data : LineSensor Vehicle Signal Notification Data
-* : p_data_master_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetDataMasterLineSens(const LSDRV_LSDATA *pst_data,
- PFUNC_DMASTER_SET_N p_data_master_set_n,
- BOOL b_sens_ext) {
- u_int8 uc_chg_type;
-
- /*------------------------------------------------------*/
- /* Call the data set processing associated with the DID */
- /* Call the data master set notification process */
- /*------------------------------------------------------*/
- switch (pst_data->ul_did) {
- case POSHAL_DID_SPEED_PULSE:
- {
- uc_chg_type = VehicleSensSetSpeedPulsel(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
-
- break;
- }
-// case POSHAL_DID_GYRO_X:
-// {
-// uc_chg_type = VehicleSensSetGyroXl(pst_data);
-// (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
-// break;
-// }
- case POSHAL_DID_GYRO_Y:
- {
- uc_chg_type = VehicleSensSetGyroYl(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_GYRO_Z:
- {
- uc_chg_type = VehicleSensSetGyroZl(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_REV:
- {
- uc_chg_type = VehicleSensSetRevl(pst_data);
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "VehicleSens_SetDataMaster POSHAL_DID_REV \r\n");
-#endif
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- /* -- PastModel002 support DR */
- break;
- }
- case POSHAL_DID_GPS_ANTENNA:
- {
- uc_chg_type = VehicleSensSetGpsAntennal(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_GYRO_X:
- case POSHAL_DID_GYRO_EXT: /* 3 to 14bit A/D value,0bit:REV */
- {
- uc_chg_type = VehicleSensSetGyroRevl(pst_data);
-// if (b_sens_ext == TRUE) {
-// VehicleSensSetGyroExtl(pst_data);
-// }
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- default:
- break;
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetDataMasterLineSensG
-* ABSTRACT : Vehicle sensor data master LineSensor data set process
-* FUNCTION : Set LineSensor data
-* ARGUMENT : *pst_data : LineSensor Vehicle Signal Notification Data
-* : p_data_master_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetDataMasterLineSensG(const LSDRV_LSDATA_G *pst_data,
- PFUNC_DMASTER_SET_N p_data_master_set_n,
- BOOL b_sens_ext) {
- u_int8 uc_chg_type;
- SENSORMOTION_SPEEDINFO_DAT stSpeed;
- const VEHICLESENS_DATA_MASTER* pst_master;
- u_int16 usSP_KMPH = 0; /* Vehicle speed(km/h) */
-
- /*------------------------------------------------------*/
- /* Call the data set processing associated with the DID */
- /* Call the data master set notification process */
- /*------------------------------------------------------*/
- switch (pst_data->ul_did) {
- case POSHAL_DID_SPEED_PULSE:
- {
- uc_chg_type = VehicleSensSetSpeedPulselG(pst_data);
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "VehicleSens_SetDataMaster POSHAL_DID_SPEED_PULSE \r\n");
-#endif
- if (b_sens_ext == TRUE) {
- VehicleSensSetSpeedPulseExtlG(pst_data);
- }
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- /* -- PastModel002 support DR */
- break;
- }
- case POSHAL_DID_SPEED_KMPH:
- {
- uc_chg_type = VehicleSensSetSpeedKmphlG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
-
- /* Set the data master of Motion Seepd (Internal) */
- pst_master = (const VEHICLESENS_DATA_MASTER*)pst_data;
- memset(&stSpeed, 0x00, sizeof(SENSORMOTION_SPEEDINFO_DAT));
- /* When the notified size is ""0"",The vehicle speed cannot be calculated with the line sensor. */
- if (pst_master->us_size == 0) {
- stSpeed.isEnable = FALSE;
- } else {
- stSpeed.isEnable = TRUE;
- memcpy(&usSP_KMPH, pst_master->uc_data, sizeof(u_int16));
- }
- stSpeed.getMethod = SENSOR_GET_METHOD_POS;
- /* Unit conversion [0.01km/h] -> [0.01m/s] */
- stSpeed.Speed = static_cast<uint16_t>((1000 * usSP_KMPH) / 3600);
-
- uc_chg_type = VehicleSensSetMotionSpeedI(&stSpeed);
- (*p_data_master_set_n)(VEHICLE_DID_MOTION_SPEED_INTERNAL, uc_chg_type, VEHICLESENS_GETMETHOD_INTERNAL);
- break;
- }
-// case POSHAL_DID_GYRO_X:
-// {
-// uc_chg_type = VehicleSensSetGyroXlG(pst_data);
-//#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
-// FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "VehicleSens_SetDataMaster POSHAL_DID_GYRO_X \r\n");
-//#endif
-// (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
-// /* ++ PastModel002 support DR */
-// VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
-// /* -- PastModel002 support DR */
-// break;
-// }
- case POSHAL_DID_GYRO_Y:
- {
- uc_chg_type = VehicleSensSetGyroYlG(pst_data);
- if (b_sens_ext == TRUE) {
- VehicleSensSetGyroYExtlG(pst_data);
- }
-#if (DR_DEBUG == 1)
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "VehicleSens_SetDataMaster POSHAL_DID_GYRO_Y \r\n");
-#endif
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_GYRO_Z:
- {
- uc_chg_type = VehicleSensSetGyroZlG(pst_data);
- if (b_sens_ext == TRUE) {
- VehicleSensSetGyroZExtlG(pst_data);
- }
-#if (DR_DEBUG == 1)
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "VehicleSens_SetDataMaster POSHAL_DID_GYRO_Z \r\n");
-#endif
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_SNS_COUNTER:
- {
-#if (DR_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "VehicleSens_SetDataMaster POSHAL_DID_SNS_COUNTER \r\n");
-#endif
- uc_chg_type = VehicleSensSetSnsCounterlG(pst_data);
- if (b_sens_ext == TRUE) {
- VehicleSensSetSnsCounterExtlG(pst_data);
- }
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- /* -- PastModel002 support DR */
- break;
- }
- case POSHAL_DID_GYRO_X:
- case POSHAL_DID_GYRO_EXT: /* 3 to 14bit A/D value,0bit:REV */
- {
- uc_chg_type = VehicleSensSetGyroRevlG(pst_data);
-
- if (b_sens_ext == TRUE) {
- VehicleSensSetGyroExtlG(pst_data);
- }
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
-
- break;
- }
-
- case POSHAL_DID_SPEED_PULSE_FLAG:
- {
- uc_chg_type = VehicleSensSetSpeedPulseFlag((const LSDRV_LSDATA_G *)pst_data);
-
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- /* -- PastModel002 support DR */
-
- break;
- }
- case POSHAL_DID_GPS_INTERRUPT_FLAG:
- {
- uc_chg_type = VehicleSensSetGpsInterruptFlag((const LSDRV_LSDATA_G *)pst_data);
-
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
-
- break;
- }
- case POSHAL_DID_REV:
- {
- uc_chg_type = VehicleSensSetRevlG(pst_data);
- if (b_sens_ext == TRUE) {
- VehicleSensSetRevExtlG(pst_data);
- }
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_GYRO_TEMP:
- {
- uc_chg_type = VehicleSensSetGyroTemplG(pst_data);
- if (b_sens_ext == TRUE) {
- VehicleSensSetGyroTempExtlG(pst_data);
- }
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_GSNS_X:
- {
- uc_chg_type = VehicleSensSetGsnsXlG(pst_data);
- if (b_sens_ext == TRUE) {
- VehicleSensSetGsnsXExtlG(pst_data);
- }
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_GSNS_Y:
- {
- uc_chg_type = VehicleSensSetGsnsYlG(pst_data);
- if (b_sens_ext == TRUE) {
- VehicleSensSetGsnsYExtlG(pst_data);
- }
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_GSNS_Z:
- {
- uc_chg_type = VehicleSensSetGsnsZlG(pst_data);
- if (b_sens_ext == TRUE) {
- VehicleSensSetGsnsZExtlG(pst_data);
- }
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_PULSE_TIME:
- {
- uc_chg_type = VehicleSensSetPulseTimelG(pst_data);
- if (b_sens_ext == TRUE) {
- VehicleSensSetPulseTimeExtlG(pst_data);
- }
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- default:
- break;
- }
-}
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensSetDataMasterLineSensFst
-* ABSTRACT : Vehicle sensor data master LineSensor data set process
-* FUNCTION : Set LineSensor data
-* ARGUMENT : *pst_data : LineSensor Vehicle Signal Notification Data
-* : p_data_master_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetDataMasterLineSensFst(const LSDRV_LSDATA_FST *pst_data, PFUNC_DMASTER_SET_N p_data_master_set_n) { // LCOV_EXCL_START 8: dead code // // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_chg_type;
-
- /*------------------------------------------------------*/
- /* Call the data set processing associated with the DID */
- /* Call the data master set notification process */
- /*------------------------------------------------------*/
- switch (pst_data->ul_did) {
- case POSHAL_DID_GYRO_X_FST: /* 3 to 14bit A/D value,0bit:REV */
- {
- uc_chg_type = VehicleSensSetGyroXFstl(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_GYRO_Y_FST: /* 3 to 14bit A/D value,0bit:REV */
- {
- uc_chg_type = VehicleSensSetGyroYFstl(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_GYRO_Z_FST: /* 3 to 14bit A/D value,0bit:REV */
- {
- uc_chg_type = VehicleSensSetGyroZFstl(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- case POSHAL_DID_SPEED_PULSE_FST:
- {
- uc_chg_type = VehicleSensSetSpeedPulseFstl(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- break;
- }
- default:
- break;
- }
-}
-// LCOV_EXCL_STOP
-/*******************************************************************************
-* MODULE : VehicleSensSetDataMasterLineSensFstG
-* ABSTRACT : Vehicle sensor data master LineSensor data set process
-* FUNCTION : Set LineSensor data
-* ARGUMENT : *pst_data : LineSensor Vehicle Signal Notification Data
-* : p_data_master_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetDataMasterLineSensFstG(const LSDRV_MSG_LSDATA_DAT_FST *pst_data,
- PFUNC_DMASTER_SET_N p_data_master_set_n) {
- u_int8 uc_chg_type;
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /*------------------------------------------------------*/
- /* Call the data set processing associated with the DID */
- /* Call the data master set notification process */
- /*------------------------------------------------------*/
- switch (pst_data->st_gyro_x.ul_did) {
- case POSHAL_DID_GYRO_X_FST:
- {
- uc_chg_type = VehicleSensSetGyroXFstG(&(pst_data->st_gyro_x));
- if (pst_data->st_gyro_x.uc_partition_max == pst_data->st_gyro_x.uc_partition_num)
- {
- (*p_data_master_set_n)(pst_data->st_gyro_x.ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- }
- break;
- }
- default:
- break;
- }
-
- switch (pst_data->st_gyro_y.ul_did) {
- case POSHAL_DID_GYRO_Y_FST:
- {
- uc_chg_type = VehicleSensSetGyroYFstG(&(pst_data->st_gyro_y));
- if (pst_data->st_gyro_y.uc_partition_max == pst_data->st_gyro_y.uc_partition_num) {
- (*p_data_master_set_n)(pst_data->st_gyro_y.ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- }
- break;
- }
- default:
- break;
- }
-
- switch (pst_data->st_gyro_z.ul_did) {
- case POSHAL_DID_GYRO_Z_FST:
- {
- uc_chg_type = VehicleSensSetGyroZFstG(&(pst_data->st_gyro_z));
- if (pst_data->st_gyro_z.uc_partition_max == pst_data->st_gyro_z.uc_partition_num) {
- (*p_data_master_set_n)(pst_data->st_gyro_z.ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- }
- break;
- }
- default:
- break;
- }
-
- switch (pst_data->st_speed.ul_did) {
- case POSHAL_DID_SPEED_PULSE_FST:
- {
- uc_chg_type = VehicleSensSetSpeedPulseFstG(&(pst_data->st_speed));
- if (pst_data->st_speed.uc_partition_max == pst_data->st_speed.uc_partition_num)
- {
- (*p_data_master_set_n)(pst_data->st_speed.ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- }
- break;
- }
- default:
- break;
- }
-
- switch (pst_data->st_spd_pulse_flg.ul_did) {
- case POSHAL_DID_SPEED_PULSE_FLAG_FST:
- {
- uc_chg_type = VehicleSensSetSpeedPulseFlagFstG(&(pst_data->st_spd_pulse_flg));
- if (pst_data->st_spd_pulse_flg.uc_partition_max == pst_data->st_spd_pulse_flg.uc_partition_num)
- {
- (*p_data_master_set_n)(pst_data->st_spd_pulse_flg.ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- }
- break;
- }
- default:
- break;
- }
-
- switch (pst_data->st_rev.ul_did) {
- case POSHAL_DID_REV_FST:
- {
- uc_chg_type = VehicleSensSetRevFstG(&(pst_data->st_rev));
- if (pst_data->st_rev.uc_partition_max == pst_data->st_rev.uc_partition_num)
- {
- (*p_data_master_set_n)(pst_data->st_rev.ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- }
- break;
- }
- default:
- break;
- }
-
- switch (pst_data->st_gyro_temp.ul_did) {
- case POSHAL_DID_GYRO_TEMP_FST:
- {
- uc_chg_type = VehicleSensSetGyroTempFstG(&(pst_data->st_gyro_temp));
-
- if (pst_data->st_gyro_temp.uc_partition_max == pst_data->st_gyro_temp.uc_partition_num) {
- (*p_data_master_set_n)(pst_data->st_gyro_temp.ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- }
- break;
- }
- default:
- break;
- }
-
- switch (pst_data->st_gsns_x.ul_did) {
- case POSHAL_DID_GSNS_X_FST:
- {
- uc_chg_type = VehicleSensSetGsnsXFstG(&(pst_data->st_gsns_x));
-
- if (pst_data->st_gsns_x.uc_partition_max == pst_data->st_gsns_x.uc_partition_num) {
- (*p_data_master_set_n)(pst_data->st_gsns_x.ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- }
- break;
- }
- default:
- break;
- }
-
- switch (pst_data->st_gsns_y.ul_did) {
- case POSHAL_DID_GSNS_Y_FST:
- {
- uc_chg_type = VehicleSensSetGsnsYFstG(&(pst_data->st_gsns_y));
-
- if (pst_data->st_gsns_y.uc_partition_max == pst_data->st_gsns_y.uc_partition_num) {
- (*p_data_master_set_n)(pst_data->st_gsns_y.ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- }
- break;
- }
- default:
- break;
- }
-
- switch (pst_data->st_gsns_z.ul_did) {
- case POSHAL_DID_GSNS_Z_FST:
- {
- uc_chg_type = VehicleSensSetGsnsZFstG(&(pst_data->st_gsns_z));
-
- if (pst_data->st_gsns_z.uc_partition_max == pst_data->st_gsns_z.uc_partition_num) {
- (*p_data_master_set_n)(pst_data->st_gsns_z.ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- }
- break;
- }
- default:
- break;
- }
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "-");
-}
-#endif
-
-/*******************************************************************************
-* MODULE : VehicleSensSetDataMasterGps
-* ABSTRACT : Vehicle Sensor Data Master GPS Data Set Processing
-* FUNCTION : Set GPS data
-* ARGUMENT : *pst_data : GPS received message data
-* : p_data_master_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetDataMasterGps(SENSOR_MSG_GPSDATA_DAT *pst_data,
- PFUNC_DMASTER_SET_N p_data_master_set_n) {
- u_int8 uc_chg_type;
- SENSORLOCATION_LONLATINFO_DAT lstLonLat;
- SENSORLOCATION_ALTITUDEINFO_DAT lstAltitude;
- SENSORMOTION_HEADINGINFO_DAT lstHeading;
- MDEV_GPS_CUSTOMDATA *pstCustomData;
-
- VEHICLESENS_DATA_MASTER st_data;
- u_int8 antennaState = 0;
- u_int8 sensCount = 0;
- u_int8 ucResult = SENSLOG_RES_SUCCESS;
-
- EFrameworkunifiedStatus eStatus = eFrameworkunifiedStatusFail;
- BOOL bIsAvailable;
- PNO us_pno;
-
- /* Antenna Connection Information */
- (void)memset(reinterpret_cast<void *>(&st_data), 0, sizeof(st_data));
- VehicleSensGetGpsAntennal(&st_data);
- antennaState = st_data.uc_data[0];
-
- /* Sensor Counter */
- (void)memset(reinterpret_cast<void *>(&st_data), 0, sizeof(st_data));
- VehicleSensGetSnsCounterl(&st_data);
- /** Sensor Counter Value Calculation */
- /** Subtract sensor counter according to data amount from sensor counter.(Rounded off) */
- /** Communication speed9600bps = 1200byte/s,Sensor counter is 1 count at 100ms. */
- sensCount = st_data.uc_data[0];
-
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__,
- "antennaState = %d, sensCount = %d", antennaState, sensCount);
-
- /*------------------------------------------------------*/
- /* Call the data set processing associated with the DID */
- /* Call the data master set notification process */
- /*------------------------------------------------------*/
- switch (pst_data->ul_did) { // LCOV_EXCL_BR_LINE 6:some DID is not used
- case VEHICLE_DID_GPS_UBLOX_NAV_VELNED:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-#if (GPS_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "VehicleSens_SetDataMaster VEHICLE_DID_GPS_UBLOX_NAV_VELNED \r\n");
-#endif
- uc_chg_type = VehicleSensSetNavVelnedG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* -- PastModel002 support DR */
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_TIMEUTC:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-#if (GPS_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "VehicleSens_SetDataMaster VEHICLE_DID_GPS_UBLOX_NAV_TIMEUTC \r\n");
-#endif
- uc_chg_type = VehicleSensSetNavTimeUtcG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* -- PastModel002 support DR */
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_TIMEGPS:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-#if (GPS_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "VehicleSens_SetDataMaster VEHICLE_DID_GPS_UBLOX_NAV_TIMEGPS \r\n");
-#endif
- uc_chg_type = VehicleSensSetNavTimeGpsG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_SVINFO:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-#if (GPS_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "VehicleSens_SetDataMaster VEHICLE_DID_GPS_UBLOX_NAV_SVINFO \r\n");
-#endif
- uc_chg_type = VehicleSensSetNavSvInfoG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* -- PastModel002 support DR */
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_STATUS:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-#if (GPS_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "VehicleSens_SetDataMaster VEHICLE_DID_GPS_UBLOX_NAV_STATUS \r\n");
-#endif
- uc_chg_type = VehicleSensSetNavStatusG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* -- PastModel002 support DR */
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_POSLLH:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-#if (GPS_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "VehicleSens_SetDataMaster VEHICLE_DID_GPS_UBLOX_NAV_POSLLH \r\n");
-#endif
- uc_chg_type = VehicleSensSetNavPosllhG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* -- PastModel002 support DR */
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_CLOCK:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-#if (GPS_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "VehicleSens_SetDataMaster VEHICLE_DID_GPS_UBLOX_NAV_CLOCK \r\n");
-#endif
- uc_chg_type = VehicleSensSetNavClockG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* -- PastModel002 support DR */
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_DOP:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-#if (GPS_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "VehicleSens_SetDataMaster VEHICLE_DID_GPS_UBLOX_NAV_DOP \r\n");
-#endif
- uc_chg_type = VehicleSensSetNavDopG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* ++ PastModel002 support DR */
- VehicleSensDeliveryProcDR(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- /* -- PastModel002 support DR */
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_MON_HW:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-#if (GPS_DEBUG == 1) /* PastModel002_DR_VEHICLE */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "VehicleSens_SetDataMaster VEHICLE_DID_GPS_UBLOX_MON_HW \r\n");
-#endif
- uc_chg_type = VehicleSensSetMonHwG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_COUNTER:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- uc_chg_type = VehicleSensSetGpsCounterg(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- break;
- // LCOV_EXCL_STOP
- }
- /* GPS raw data(_CWORD82_ NMEA) */
- case VEHICLE_DID_GPS__CWORD82__NMEA:
- {
- /* NMEA data */
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__,
- "VehicleSens_GpsDataDelivery VEHICLE_DID_GPS__CWORD82__NMEA -->");
-
- /* Insert Antenna Connection Status and Sensor Counter */
- pst_data->uc_data[1] = antennaState; /* Insert Antennas into 2byte Eyes */
- /* Place counters at 3byte */
- pst_data->uc_data[2] = static_cast<u_int8>(sensCount - (u_int8)(((GPS_NMEA_SZ * 10) / 1200) + 1));
-
- uc_chg_type = VehicleSensSetGps_CWORD82_NmeaG(pst_data); /* Ignore->MISRA-C++:2008 Rule 5-2-5 */
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__,
- "VehicleSens_GpsDataDelivery VEHICLE_DID_GPS__CWORD82__NMEA <--");
- break;
- }
- /* GPS raw data(FullBinary) */
- case POSHAL_DID_GPS__CWORD82__FULLBINARY:
- {
- /* FullBin data */
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__,
- "VehicleSens_GpsDataDelivery POSHAL_DID_GPS__CWORD82__FULLBINARY -->");
-
- /* Insert Antenna Connection Status and Sensor Counter */
- pst_data->uc_data[0] = antennaState; /* Insert Antennas into 1byte Eyes */
- /* Place counters at 2byte */
- pst_data->uc_data[1] = static_cast<u_int8>(sensCount - (u_int8)(((GPS_CMD_FULLBIN_SZ * 10) / 1200) + 1));
-
- uc_chg_type = VehicleSensSetGps_CWORD82_FullBinaryG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__,
- "VehicleSens_GpsDataDelivery POSHAL_DID_GPS__CWORD82__FULLBINARY <--");
- break;
- }
- /* GPS raw data(Specific information) */
- case POSHAL_DID_GPS__CWORD82___CWORD44_GP4:
- {
- /* GPS-specific information */
- uc_chg_type = VehicleSensSetGps_CWORD82__CWORD44_Gp4G(pst_data); /* Ignore->MISRA-C++:2008 Rule 5-2-5 */
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- break;
- }
- case POSHAL_DID_GPS_CUSTOMDATA:
- {
- pstCustomData = reinterpret_cast<MDEV_GPS_CUSTOMDATA*>(pst_data->uc_data);
- /* Latitude/LongitudeInformation */
- (void)memcpy(&lstLonLat, &(pstCustomData->st_lonlat), sizeof(SENSORLOCATION_LONLATINFO_DAT));
- lstLonLat.SyncCnt = VehicleSensGetSensorCnt(); /* Synchronization counter setting */
- uc_chg_type = VehicleSensSetLocationLonLatG(&lstLonLat);
- (*p_data_master_set_n)(VEHICLE_DID_LOCATION_LONLAT, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
-
- /* Altitude information */
- (void)memcpy(&lstAltitude, &(pstCustomData->st_altitude), sizeof(SENSORLOCATION_ALTITUDEINFO_DAT));
- lstAltitude.SyncCnt = VehicleSensGetSensorCnt(); /* Synchronization counter setting */
- uc_chg_type = VehicleSensSetLocationAltitudeG(&lstAltitude);
- (*p_data_master_set_n)(VEHICLE_DID_LOCATION_ALTITUDE, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
-
- /* Bearing information */
- (void)memcpy(&lstHeading, &(pstCustomData->st_heading), sizeof(SENSORMOTION_HEADINGINFO_DAT));
- lstHeading.SyncCnt = VehicleSensGetSensorCnt(); /* Synchronization counter setting */
- uc_chg_type = VehicleSensSetMotionHeadingG(&lstHeading);
- (*p_data_master_set_n)(VEHICLE_DID_MOTION_HEADING, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
-
- /* GPS time information */
- uc_chg_type = VehicleSensSetGpsTimeG(&(pstCustomData->st_gps_time));
- (*p_data_master_set_n)(POSHAL_DID_GPS_TIME, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
-
- /* Set GPS time to CLOCK */
- eStatus = ClockIfDtimeSetGpsTime(&(pstCustomData->st_gps_time), &bIsAvailable);
- if ((bIsAvailable == TRUE) && (eStatus != eFrameworkunifiedStatusOK)) {
- ucResult = SENSLOG_RES_FAIL;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ClockIfDtimeSetGpsTime ERROR!! [ret=%d, y=%d, m=%d, d=%d, h=%d, n=%d, s=%d, sts=%d]",
- eStatus, pstCustomData->st_gps_time.utc.year, pstCustomData->st_gps_time.utc.month,
- pstCustomData->st_gps_time.utc.date,
- pstCustomData->st_gps_time.utc.hour, pstCustomData->st_gps_time.utc.minute,
- pstCustomData->st_gps_time.utc.second, pstCustomData->st_gps_time.tdsts);
- }
- us_pno = _pb_CnvName2Pno(SENSLOG_PNAME_CLOCK);
- SensLogWriteOutputData(SENSLOG_DATA_O_TIME_CS, 0, us_pno,
- reinterpret_cast<uint8_t *>(&(pstCustomData->st_gps_time)),
- sizeof(pstCustomData->st_gps_time), ucResult);
-
- /* Diag Info */
- uc_chg_type = VehicleSensSetNaviinfoDiagGPSg(&(pstCustomData->st_diag_gps));
- (*p_data_master_set_n)(VEHICLE_DID_NAVIINFO_DIAG_GPS, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- break;
- }
- /* GPS raw data(NMEA except _CWORD82_) */
- case POSHAL_DID_GPS_NMEA:
- {
- /* NMEA data */
- uc_chg_type = VehicleSensSetGpsNmeaG(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- break;
- }
- /* GPS version(except _CWORD82_) */
- case POSHAL_DID_GPS_VERSION:
- {
- VehicleSensSetGpsVersion(pst_data);
- break;
- }
- /* Raw GPS time data */
- case POSHAL_DID_GPS_TIME_RAW:
- {
- (void)VehicleSensSetGpsTimeRawG(reinterpret_cast<SENSOR_GPSTIME_RAW*>(pst_data->uc_data));
- break;
- }
- case POSHAL_DID_GPS_TIME:
- {
- uc_chg_type = VehicleSensSetGpsTimeG(reinterpret_cast<SENSOR_MSG_GPSTIME*>(pst_data->uc_data));
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- break;
- }
- case POSHAL_DID_GPS_WKNROLLOVER:
- {
- (void)VehicleSensSetWknRolloverG(reinterpret_cast<SENSOR_WKNROLLOVER*>(pst_data->uc_data));
- break;
- }
- /* GPS clock drift */
- case POSHAL_DID_GPS_CLOCK_DRIFT:
- {
- uc_chg_type = VehicleSensSetGpsClockDriftG(reinterpret_cast<int32_t*>(pst_data->uc_data));
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- break;
- }
- /* GPS clock frequency */
- case POSHAL_DID_GPS_CLOCK_FREQ:
- {
- uc_chg_type = VehicleSensSetGpsClockFreqG(reinterpret_cast<uint32_t*>(pst_data->uc_data));
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
- break;
- }
-
- default:
- break;
- }
-}
-
-/*******************************************************************************
- * MODULE : VehicleSensSetDataMasterData
- * ABSTRACT : Vehicle sensor data master common data set processing
- * FUNCTION : Set vehicle data
- * ARGUMENT : *pstMsg : Received message data
- * : p_data_master_set_n : Data Master Set Notification(Callback function)
- * NOTE :
- * RETURN : void
- ******************************************************************************/
-void VehicleSensSetDataMasterData(const POS_MSGINFO *pstMsg,
- PFUNC_DMASTER_SET_N p_data_master_set_n) {
- u_int8 uc_chg_type = 0;
- const POS_POSDATA *pstPosData = NULL;
- const u_int16 *pucSpeed = 0;
- SENSORLOCATION_LONLATINFO_DAT stLonLat;
- SENSORLOCATION_ALTITUDEINFO_DAT stAltitude;
- SENSORMOTION_SPEEDINFO_DAT stSpeed;
- SENSORMOTION_HEADINGINFO_DAT stHeading;
- const SENSOR_MSG_GPSTIME *pstGpsTime;
-
-// RET_API ret;
-
-// char* pEnvPositioning_CWORD86_ = NULL;
-// BOOL sndFlg;
-
-
- EFrameworkunifiedStatus eStatus = eFrameworkunifiedStatusFail;
- BOOL bIsAvailable;
- u_int8 ucResult = SENSLOG_RES_SUCCESS;
- PNO us_pno;
-
- /*------------------------------------------------------*/
- /* Call the data set processing associated with the DID */
- /* Call the data master set notification process */
- /*------------------------------------------------------*/
- switch (pstMsg->did) {
- case POSHAL_DID_GPS_CUSTOMDATA_NAVI:
- {
- pstPosData = (const POS_POSDATA *) & (pstMsg->data);
-
- /* Latitude/LongitudeInformation */
- if (((pstPosData->status & POS_LOC_INFO_LAT) == POS_LOC_INFO_LAT) ||
- ((pstPosData->status & POS_LOC_INFO_LON) == POS_LOC_INFO_LON)) {
- memset(&stLonLat, 0x00, sizeof(stLonLat));
- stLonLat.getMethod = SENSOR_GET_METHOD_NAVI;
- stLonLat.SyncCnt = VehicleSensGetSensorCnt();
- stLonLat.isEnable = SENSORLOCATION_STATUS_ENABLE;
- stLonLat.posSts = pstPosData->posSts;
- stLonLat.posAcc = pstPosData->posAcc;
- stLonLat.Longitude = pstPosData->longitude;
- stLonLat.Latitude = pstPosData->latitude;
- uc_chg_type = VehicleSensSetLocationLonLatN((const SENSORLOCATION_LONLATINFO_DAT *)&stLonLat);
- (*p_data_master_set_n)(VEHICLE_DID_LOCATION_LONLAT_NAVI, uc_chg_type, VEHICLESENS_GETMETHOD_NAVI);
- }
-
- /* Altitude information */
- if ((pstPosData->status & POS_LOC_INFO_ALT) == POS_LOC_INFO_ALT) {
- memset(&stAltitude, 0x00, sizeof(stAltitude));
- stAltitude.getMethod = SENSOR_GET_METHOD_NAVI;
- stAltitude.SyncCnt = VehicleSensGetSensorCnt();
- stAltitude.isEnable = SENSORLOCATION_STATUS_ENABLE;
- stAltitude.Altitude = pstPosData->altitude;
- uc_chg_type = VehicleSensSetLocationAltitudeN((const SENSORLOCATION_ALTITUDEINFO_DAT *)&stAltitude);
- (*p_data_master_set_n)(VEHICLE_DID_LOCATION_ALTITUDE_NAVI, uc_chg_type, VEHICLESENS_GETMETHOD_NAVI);
- }
-
- /* Bearing information */
- if ((pstPosData->status & POS_LOC_INFO_HEAD) == POS_LOC_INFO_HEAD) {
- memset(&stHeading, 0x00, sizeof(stHeading));
- stHeading.getMethod = SENSOR_GET_METHOD_NAVI;
- stHeading.SyncCnt = VehicleSensGetSensorCnt();
- stHeading.isEnable = SENSORMOTION_STATUS_ENABLE;
- stHeading.posSts = pstPosData->posSts;
- stHeading.Heading = pstPosData->heading;
- uc_chg_type = VehicleSensSetMotionHeadingN((const SENSORMOTION_HEADINGINFO_DAT *)&stHeading);
- (*p_data_master_set_n)(VEHICLE_DID_MOTION_HEADING_NAVI, uc_chg_type, VEHICLESENS_GETMETHOD_NAVI);
- }
-
- ( *p_data_master_set_n )( POSHAL_DID_GPS_CUSTOMDATA_NAVI, VEHICLESENS_NEQ, VEHICLESENS_GETMETHOD_NAVI );
-
- break;
- }
- case VEHICLE_DID_MOTION_SPEED_NAVI:
- {
- pucSpeed = (const u_int16 *) & (pstMsg->data);
-
- /* Vehicle speed information */
- memset(&stSpeed, 0x00, sizeof(stSpeed));
- stSpeed.getMethod = SENSOR_GET_METHOD_NAVI;
- stSpeed.SyncCnt = VehicleSensGetSensorCnt();
- stSpeed.isEnable = SENSORMOTION_STATUS_ENABLE;
- stSpeed.Speed = *pucSpeed;
- uc_chg_type = VehicleSensSetMotionSpeedN((const SENSORMOTION_SPEEDINFO_DAT *)&stSpeed);
- (*p_data_master_set_n)(VEHICLE_DID_MOTION_SPEED_NAVI, uc_chg_type, VEHICLESENS_GETMETHOD_NAVI);
- break;
- }
- case POSHAL_DID_GPS_TIME:
- {
- pstGpsTime = (const SENSOR_MSG_GPSTIME*)(pstMsg->data);
- uc_chg_type = VehicleSensSetGpsTimeG((const SENSOR_MSG_GPSTIME *)pstGpsTime);
- (*p_data_master_set_n)(POSHAL_DID_GPS_TIME, uc_chg_type, VEHICLESENS_GETMETHOD_GPS);
-
- /* Set GPS time to CLOCK */
- eStatus = ClockIfDtimeSetGpsTime(pstGpsTime, &bIsAvailable);
- if ((bIsAvailable == TRUE) && (eStatus != eFrameworkunifiedStatusOK)) {
- ucResult = SENSLOG_RES_FAIL;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ClockIfDtimeSetGpsTime ERROR!! [ret=%d, y=%d, m=%d, d=%d, h=%d, n=%d, s=%d, sts=%d]",
- eStatus, pstGpsTime->utc.year, pstGpsTime->utc.month, pstGpsTime->utc.date,
- pstGpsTime->utc.hour, pstGpsTime->utc.minute, pstGpsTime->utc.second, pstGpsTime->tdsts);
- }
- us_pno = _pb_CnvName2Pno(SENSLOG_PNAME_CLOCK);
- SensLogWriteOutputData(SENSLOG_DATA_O_TIME_CS, 0, us_pno,
- (uint8_t *)(pstGpsTime), // NOLINT(readability/casting)
- sizeof(SENSOR_MSG_GPSTIME), ucResult);
- break;
- }
- case VEHICLE_DID_SETTINGTIME:
- {
- /* GPS time information */
- uc_chg_type = VehicleSensSetSettingTimeclock((const POS_DATETIME *) & (pstMsg->data));
- (*p_data_master_set_n)(VEHICLE_DID_SETTINGTIME, uc_chg_type, VEHICLESENS_GETMETHOD_OTHER);
- break;
- }
-
- case VEHICLE_DID_LOCATIONINFO_NMEA_NAVI:
- {
- uc_chg_type = VehicleSens_SetLocationInfoNmea_n((const POS_LOCATIONINFO_NMEA*)&(pstMsg->data));
- (*p_data_master_set_n)(VEHICLE_DID_LOCATIONINFO_NMEA_NAVI, uc_chg_type, VEHICLESENS_GETMETHOD_NAVI );
- break;
- }
-
- default:
- break;
- }
- return;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetDataMasterGyroTrouble
-* ABSTRACT : Vehicle Sensor Data Master Gyro Failure Status Setting Process
-* FUNCTION : Set a gyro fault condition
-* ARGUMENT : *pst_data : Gyro Failure Status Notification Data
-* : p_data_master_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetDataMasterGyroTrouble(const LSDRV_MSG_LSDATA_DAT_GYRO_TROUBLE *pst_data, PFUNC_DMASTER_SET_N p_data_master_set_n) { // LCOV_EXCL_START 8: dead code. // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_chg_type;
-
- if ((pst_data != NULL) && (p_data_master_set_n != NULL)) {
- if (pst_data->ul_did == VEHICLE_DID_GYRO_TROUBLE) {
- uc_chg_type = VehicleSensSetGyroTrouble(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "UNKNOWN DID(%x) \r\n", pst_data->ul_did);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ARGUMENT is NULL\r\n");
- }
-}
-// LCOV_EXCL_STOP
-/*******************************************************************************
-* MODULE : VehicleSensSetDataMasterSysGpsInterruptSignal
-* ABSTRACT : Vehicle Sensor Data Master SYS GPS Interrupt Signal Setting
-* FUNCTION : Setting SYS GPS Interrupt Signals
-* ARGUMENT : *pst_data : SYS GPS interrupt notification
-* : p_data_master_set_shared_memory : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetDataMasterSysGpsInterruptSignal(const LSDRV_MSG_LSDATA_DAT_GPS_INTERRUPT_SIGNAL *pst_data, PFUNC_DMASTER_SET_SHARED_MEMORY p_data_master_set_shared_memory) { // LCOV_EXCL_START 8: dead code. // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_chg_type;
- if ((pst_data != NULL) && (p_data_master_set_shared_memory != NULL)) {
- if (pst_data->ul_did == VEHICLE_DID_SYS_GPS_INTERRUPT_SIGNAL) {
- uc_chg_type = VehicleSensSetSysGpsInterruptSignal(pst_data);
- /* As SYS GPS interrupt signals are not registered for delivery, */
- /* Disposal quantity,To avoid risks,DeliveryProc shall not be called. */
- (*p_data_master_set_shared_memory)(pst_data->ul_did, uc_chg_type);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "UNKNOWN DID(%x) \r\n", pst_data->ul_did);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ARGUMENT is NULL\r\n");
- }
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetDataMasterMainGpsInterruptSignal
-* ABSTRACT : Vehicle Sensor Data Master MAIN GPS Interrupt Signal Setting
-* FUNCTION : Setting MAIN GPS Interrupt Signals
-* ARGUMENT : *pst_data : MAIN GPS interrupt notification
-* : p_data_master_set_shared_memory : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetDataMasterMainGpsInterruptSignal(const SENSOR_MSG_GPSDATA_DAT *pst_data, PFUNC_DMASTER_SET_SHARED_MEMORY p_data_master_set_shared_memory) { // LCOV_EXCL_START 8: dead code. // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_chg_type;
-
- if ((pst_data != NULL) &&
- (p_data_master_set_shared_memory != NULL)) {
- if (pst_data->ul_did == VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL) {
- uc_chg_type = VehicleSensSetMainGpsInterruptSignal(pst_data);
- /* As MAIN GPS interrupt signals are not registered for delivery, */
- /* Disposal quantity,To avoid risks,DeliveryProc shall not be called. */
- (*p_data_master_set_shared_memory)(pst_data->ul_did, uc_chg_type);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "UNKNOWN DID(%x) \r\n", pst_data->ul_did);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ARGUMENT is NULL\r\n");
- }
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetDataMasterGyroConnectStatus
-* ABSTRACT : Vehicle Sensor Data Master Gyro Connection Status Setting Processing
-* FUNCTION : Set the state of the gyro connection
-* ARGUMENT : *pst_data : Gyro Connect Status Notification Data
-* : p_data_master_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetDataMasterGyroConnectStatus(const LSDRV_MSG_LSDATA_DAT_GYRO_CONNECT_STATUS *pst_data, PFUNC_DMASTER_SET_SHARED_MEMORY p_data_master_set_shared_memory) { // LCOV_EXCL_START 8: dead code. // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_chg_type;
-
- if ((pst_data != NULL) &&
- (p_data_master_set_shared_memory != NULL)) {
- if (pst_data->ul_did == VEHICLE_DID_GYRO_CONNECT_STATUS) {
- uc_chg_type = VehicleSensSetGyroConnectStatus(pst_data);
- /* As MAIN GPS interrupt signals are not registered for delivery, */
- /* Disposal quantity,To avoid risks,DeliveryProc shall not be called. */
- (*p_data_master_set_shared_memory)(pst_data->ul_did, uc_chg_type);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "UNKNOWN DID(%x) \r\n", pst_data->ul_did);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ARGUMENT is NULL\r\n");
- }
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetDataMasterGpsAntennaStatus
-* ABSTRACT : Vehicle Sensor Data Master GPS Antenna Connection Status Setting Processing
-* FUNCTION : Setting the GPS Antenna Connection Status
-* ARGUMENT : *pst_data : GPS antenna connection status notification data
-* : p_data_master_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetDataMasterGpsAntennaStatus(const LSDRV_MSG_LSDATA_DAT_GPS_ANTENNA_STATUS *pst_data, PFUNC_DMASTER_SET_N p_data_master_set_n) { // LCOV_EXCL_START 8: dead code. // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_chg_type;
-
- if ((pst_data != NULL) && (p_data_master_set_n != NULL)) {
- if (pst_data->ul_did == POSHAL_DID_GPS_ANTENNA) {
- uc_chg_type = VehicleSensSetGpsAntennaStatus(pst_data);
- (*p_data_master_set_n)(pst_data->ul_did, uc_chg_type, VEHICLESENS_GETMETHOD_LINE);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "UNKNOWN DID(%x) \r\n", pst_data->ul_did);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ARGUMENT is NULL\r\n");
- }
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensGetDataMaster
-* ABSTRACT : Vehicle Sensor Data Master Get Processing
-* FUNCTION : Provide vehicle sensor data master
-* ARGUMENT : ul_did : Data ID corresponding to the vehicle information
-* : uc_get_method : Data collection way
-* : VEHICLESENS_GETMETHOD_CAN: CAN communication
-* : VEHICLESENS_GETMETHOD_LINE: LineSensor drivers
-* : *pst_data : Pointer to the data master provider
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetDataMaster(DID ul_did,
- u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER *pst_data) {
- /*------------------------------------------------------*/
- /* Call the data Get processing associated with the DID */
- /*------------------------------------------------------*/
- switch (ul_did) { // LCOV_EXCL_BR_LINE 6:some DID is not used
- /*------------------------------------------------------*/
- /* Vehicle sensor data group */
- /*------------------------------------------------------*/
- case POSHAL_DID_SPEED_PULSE:
- {
- VehicleSensGetSpeedPulse(pst_data, uc_get_method);
- break;
- }
-// case POSHAL_DID_GYRO_X:
-// {
-// VehicleSensGetGyroX(pst_data, uc_get_method);
-// break;
-// }
- case POSHAL_DID_GYRO_Y:
- {
- VehicleSensGetGyroY(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GYRO_Z:
- {
- VehicleSensGetGyroZ(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GYRO_X:
- case POSHAL_DID_GYRO_EXT: /* 3 to 14bit A/D value,0bit:REV */
- {
- VehicleSensGetGyroRev(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GSNS_X:
- {
- VehicleSensGetGsnsX(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GSNS_Y:
- {
- VehicleSensGetGsnsY(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GSNS_Z:
- {
- VehicleSensGetGsnsZ(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_REV:
- {
- VehicleSensGetRev(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_SPEED_PULSE_FLAG:
- {
- /* Data acquisition not selected */
- VehicleSensGetSpeedPulseFlag(pst_data);
- break;
- }
- case POSHAL_DID_GPS_ANTENNA:
- {
- VehicleSensGetGpsAntenna(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_SNS_COUNTER:
- {
- VehicleSensGetSnsCounter(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GPS_INTERRUPT_FLAG:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Data acquisition not selected */
- VehicleSensGetGpsInterruptFlag(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case POSHAL_DID_SPEED_KMPH:
- {
- VehicleSensGetSpeedKmph(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GYRO_TEMP:
- {
- VehicleSensGetGyroTemp(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_PULSE_TIME:
- {
- VehicleSensGetPulseTime(pst_data, uc_get_method);
- break;
- }
- case VEHICLE_DID_LOCATION_LONLAT:
- case VEHICLE_DID_LOCATION_LONLAT_NAVI:
- {
- VehicleSensGetLocationLonLat(pst_data, uc_get_method);
- break;
- }
- case VEHICLE_DID_LOCATION_ALTITUDE:
- case VEHICLE_DID_LOCATION_ALTITUDE_NAVI:
- {
- VehicleSensGetLocationAltitude(pst_data, uc_get_method);
- break;
- }
- case VEHICLE_DID_MOTION_SPEED_NAVI:
- case VEHICLE_DID_MOTION_SPEED_INTERNAL:
- {
- VehicleSensGetMotionSpeed(pst_data, uc_get_method);
- break;
- }
- case VEHICLE_DID_MOTION_HEADING:
- case VEHICLE_DID_MOTION_HEADING_NAVI:
- {
- VehicleSensGetMotionHeading(pst_data, uc_get_method);
- break;
- }
- case VEHICLE_DID_SETTINGTIME:
- {
- VehicleSensGetSettingTime(pst_data, uc_get_method);
- break;
- }
-
- default:
- break;
- }
-}
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetDataMasterExt
-* ABSTRACT : Vehicle Sensor Data Master Get Processing(Initial delivery)
-* FUNCTION : Provide vehicle sensor data master
-* ARGUMENT : ul_did : Data ID corresponding to the vehicle information
-* : uc_get_method : Data collection way
-* : VEHICLESENS_GETMETHOD_CAN: CAN communication
-* : VEHICLESENS_GETMETHOD_LINE: LineSensor drivers
-* : VEHICLESENS_GETMETHOD_NAVI: Navi
-* : VEHICLESENS_GETMETHOD_CLOCK:Clock
-* : *pst_data : Pointer to the data master provider
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetDataMasterExt(DID ul_did,
- u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- /*------------------------------------------------------*/
- /* Call the data Get processing associated with the DID */
- /*------------------------------------------------------*/
- switch (ul_did) {
- /*------------------------------------------------------*/
- /* Vehicle sensor data group */
- /*------------------------------------------------------*/
- case POSHAL_DID_SPEED_PULSE:
- {
- VehicleSensGetSpeedPulseExt(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GSNS_X:
- {
- VehicleSensGetGsnsXExt(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GSNS_Y:
- {
- VehicleSensGetGsnsYExt(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GSNS_Z:
- {
- VehicleSensGetGsnsZExt(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_SNS_COUNTER:
- {
- VehicleSensGetSnsCounterExt(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GYRO_X:
- case POSHAL_DID_GYRO_EXT: /* 3 to 14bit A/D value,0bit:REV */
- {
- VehicleSensGetGyroExt(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GYRO_Y:
- {
- VehicleSensGetGyroYExt(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GYRO_Z:
- {
- VehicleSensGetGyroZExt(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_REV:
- {
- VehicleSensGetRevExt(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GYRO_TEMP:
- {
- VehicleSensGetGyroTempExt(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_PULSE_TIME:
- {
- VehicleSensGetPulseTimeExt(pst_data, uc_get_method);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetDataMasterFst
-* ABSTRACT : Vehicle Sensor Data Master Get Processing(Initial transmission data)
-* FUNCTION : Provide vehicle sensor data master
-* ARGUMENT : ul_did : Data ID corresponding to the vehicle information
-* : uc_get_method : Data collection way
-* : VEHICLESENS_GETMETHOD_CAN: CAN communication
-* : VEHICLESENS_GETMETHOD_LINE: LineSensor drivers
-* : *pst_data : Pointer to the data master provider
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetDataMasterFst(DID ul_did,
- u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_FST *pst_data) {
- /*------------------------------------------------------*/
- /* Call the data Get processing associated with the DID */
- /*------------------------------------------------------*/
- switch (ul_did) {
- /*------------------------------------------------------*/
- /* Vehicle sensor data group */
- /*------------------------------------------------------*/
- case POSHAL_DID_GYRO_X_FST: /* 3 to 14bit A/D value,0bit:REV */
- {
- VehicleSensGetGyroXFst(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GYRO_Y_FST: /* 3 to 14bit A/D value,0bit:REV */
- {
- VehicleSensGetGyroYFst(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GYRO_Z_FST: /* 3 to 14bit A/D value,0bit:REV */
- {
- VehicleSensGetGyroZFst(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_SPEED_PULSE_FST:
- {
- VehicleSensGetSpeedPulseFst(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_SPEED_PULSE_FLAG_FST:
- {
- VehicleSensGetSpeedPulseFlagFst(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_REV_FST:
- {
- VehicleSensGetRevFst(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GYRO_TEMP_FST:
- {
- VehicleSensGetGyroTempFst(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GSNS_X_FST:
- {
- VehicleSensGetGsnsXFst(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GSNS_Y_FST:
- {
- VehicleSensGetGsnsYFst(pst_data, uc_get_method);
- break;
- }
- case POSHAL_DID_GSNS_Z_FST:
- {
- VehicleSensGetGsnsZFst(pst_data, uc_get_method);
- break;
- }
- default:
- break;
- }
-}
-#endif
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGpsDataMaster
-* ABSTRACT : Vehicle Sensor Data Master GPS Data Get Processing
-* FUNCTION : Provide vehicle sensor data master GPS data
-* ARGUMENT : ul_did : Data ID corresponding to the vehicle information
-* : uc_get_method : Data collection way
-* : VEHICLESENS_GETMETHOD_GPS: GPS
-* : *pst_data : Pointer to the data master provider
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGpsDataMaster(DID ul_did,
- u_int8 uc_get_method,
- SENSOR_MSG_GPSDATA_DAT *pst_data) {
- /*------------------------------------------------------*/
- /* Call the data Get processing associated with the DID */
- /*------------------------------------------------------*/
- switch (ul_did) { // LCOV_EXCL_BR_LINE 6:some DID is not used
- /*------------------------------------------------------*/
- /* GPS data group */
- /*------------------------------------------------------*/
-
- case VEHICLE_DID_GPS_UBLOX_NAV_VELNED:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensGetNavVelnedG(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_TIMEUTC:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensGetNavTimeUtcG(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_TIMEGPS:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensGetNavTimeGpsG(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_SVINFO:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensGetNavSvInfoG(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_STATUS:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensGetNavStatusG(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_POSLLH:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensGetNavPosllhG(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_CLOCK:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensGetNavClockG(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_NAV_DOP:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED();
- VehicleSensGetNavDopG(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_UBLOX_MON_HW:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED();
- VehicleSensGetMonHwG(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS_COUNTER:
- {
- // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensGetGpsCounterg(pst_data);
- break;
- // LCOV_EXCL_STOP
- }
- case VEHICLE_DID_GPS__CWORD82__NMEA:
- {
- VehicleSensGetGps_CWORD82_NmeaG(pst_data);
- break;
- }
- case POSHAL_DID_GPS__CWORD82__FULLBINARY:
- {
- VehicleSensGetGps_CWORD82_FullBinaryG(pst_data);
- break;
- }
- case POSHAL_DID_GPS__CWORD82___CWORD44_GP4:
- {
- VehicleSensGetGps_CWORD82__CWORD44_Gp4G(pst_data);
- break;
- }
- case VEHICLE_DID_NAVIINFO_DIAG_GPS:
- {
- VehicleSensGetNaviinfoDiagGPSg(pst_data);
- break;
- }
- case POSHAL_DID_GPS_TIME:
- {
- VehicleSensGetGpsTimeG(pst_data);
- break;
- }
- case POSHAL_DID_GPS_TIME_RAW:
- {
- VehicleSensGetGpsTimeRawG(pst_data);
- break;
- }
- case POSHAL_DID_GPS_NMEA:
- {
- VehicleSensGetGpsNmeaG(pst_data);
- break;
- }
- case POSHAL_DID_GPS_WKNROLLOVER:
- {
- VehicleSensGetWknRolloverG(pst_data);
- break;
- }
- case POSHAL_DID_GPS_CLOCK_DRIFT:
- {
- VehicleSensGetGpsClockDriftG(pst_data);
- break;
- }
- case POSHAL_DID_GPS_CLOCK_FREQ:
- {
- VehicleSensGetGpsClockFreqG(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetDataMasterGyroTrouble
-* ABSTRACT : Vehicle Sensor Data Master Gyro Failure Status Get Processing
-* FUNCTION : Provide a gyro fault condition
-* ARGUMENT : ul_did : Data ID
-* : uc_get_method : Data collection way(Not used)
-* : VEHICLESENS_GETMETHOD_CAN : CAN communication
-* : VEHICLESENS_GETMETHOD_LINE : LineSensor drivers
-* : VEHICLESENS_GETMETHOD_GPS : GPS
-* : *pst_data : Pointer to the data master provider
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetDataMasterGyroTrouble(DID ul_did, u_int8 uc_get_method, VEHICLESENS_DATA_MASTER_GYRO_TROUBLE *pst_data) { // LCOV_EXCL_START 8: dead code. // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- if (pst_data != NULL) {
- if (ul_did == VEHICLE_DID_GYRO_TROUBLE) {
- VehicleSensGetGyroTrouble(pst_data);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "UNKNOWN DID(%x) \r\n", ul_did);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "pst_data == NULL\r\n");
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetDataMasterSysGpsInterruptSignal
-* ABSTRACT : Vehicle Sensor Data Master SYS GPS Interrupt Signal Get Processing
-* FUNCTION : Provide SYS GPS interrupt signals
-* ARGUMENT : ul_did : Data ID
-* : uc_get_method : Data collection way(Not used)
-* : VEHICLESENS_GETMETHOD_CAN : CAN communication
-* : VEHICLESENS_GETMETHOD_LINE : LineSensor drivers
-* : VEHICLESENS_GETMETHOD_GPS : GPS
-* : *pst_data : Pointer to the data master provider
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetDataMasterSysGpsInterruptSignal(DID ul_did,
- u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- if (pst_data != NULL) {
- if (ul_did == VEHICLE_DID_SYS_GPS_INTERRUPT_SIGNAL) {
- VehicleSensGetSysGpsInterruptSignal(pst_data);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "UNKNOWN DID(%x) \r\n", ul_did);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "pst_data == NULL\r\n");
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetDataMasterMainGpsInterruptSignal
-* ABSTRACT : Vehicle Sensor Data Master MAIN GPS Interrupt Signal Get Processing
-* FUNCTION : Provide MAIN GPS interrupt signals
-* ARGUMENT : ul_did : Data ID
-* : uc_get_method : Data collection way(Not used)
-* : VEHICLESENS_GETMETHOD_CAN : CAN communication
-* : VEHICLESENS_GETMETHOD_LINE : LineSensor drivers
-* : VEHICLESENS_GETMETHOD_GPS : GPS
-* : *pst_data : Pointer to the data master provider
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetDataMasterMainGpsInterruptSignal(DID ul_did,
- u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- if (pst_data != NULL) {
- if (ul_did == VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL) {
- VehicleSensGetMainGpsInterruptSignal(pst_data);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "UNKNOWN DID(%x) \r\n", ul_did);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "pst_data == NULL\r\n");
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetDataMasterGyroConnectStatus
-* ABSTRACT : Vehicle Sensor Data Master Gyro Connection Status Get Processing
-* FUNCTION : Provide the status of the gyro connection
-* ARGUMENT : ul_did : Data ID
-* : uc_get_method : Data collection way(Not used)
-* : VEHICLESENS_GETMETHOD_CAN : CAN communication
-* : VEHICLESENS_GETMETHOD_LINE : LineSensor drivers
-* : VEHICLESENS_GETMETHOD_GPS : GPS
-* : *pst_data : Pointer to the data master provider
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetDataMasterGyroConnectStatus(DID ul_did,
- u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_GYRO_CONNECT_STATUS *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- if (pst_data != NULL) {
- if (ul_did == VEHICLE_DID_GYRO_CONNECT_STATUS) {
- VehicleSensGetGyroConnectStatus(pst_data);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "UNKNOWN DID(%x)\r\n", ul_did);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "pst_data == NULL\r\n");
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetDataMasterGpsAntennaStatus
-* ABSTRACT : Vehicle Sensor Data Master GPS Antenna Connection Status Get Processing
-* FUNCTION : Provide GPS antenna connection status
-* ARGUMENT : ul_did : Data ID
-* : uc_get_method : Data collection way(Not used)
-* : VEHICLESENS_GETMETHOD_CAN : CAN communication
-* : VEHICLESENS_GETMETHOD_LINE : LineSensor drivers
-* : VEHICLESENS_GETMETHOD_GPS : GPS
-* : *pst_data : Pointer to the data master provider
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetDataMasterGpsAntennaStatus(DID ul_did,
- u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_GPS_ANTENNA_STATUS *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- if (pst_data != NULL) {
- if (ul_did == POSHAL_DID_GPS_ANTENNA) {
- VehicleSensGetGpsAntennaStatus(pst_data);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "UNKNOWN DID(%x) \r\n", ul_did);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "pst_data == NULL\r\n");
- }
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Sensor counter acquisition
- *
- * @return Sensor Counter
- *
- */
-static uint8_t VehicleSensGetSensorCnt(void) {
- VEHICLESENS_DATA_MASTER st_data;
- uint8_t sensCnt;
-
- /* Synchronous counter acquisition */
- VehicleSensGetSnsCounterl(&st_data);
-
- sensCnt = st_data.uc_data[0];
-
- return sensCnt;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_DeliveryCtrl.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_DeliveryCtrl.cpp
deleted file mode 100755
index 15aabff..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_DeliveryCtrl.cpp
+++ /dev/null
@@ -1,2243 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_DeliveryCtrl.cpp
- * System name :GPF
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle Sensor Destination Management
- * Module configuration VehicleSensInitDeliveryCtrlTbl() Vehicle sensor delivery destination management table initialization function
- * VehicleSensInitDeliveryCtrlTblMng() Vehicle sensor delivery destination management table management area initialization function
- * VehicleSensInitPkgDeliveryTblMng() Vehicle Sensor Package Delivery Management Table Initialization Function
- * VehicleSensEntryDeliveryCtrl() Vehicle sensor delivery destination management registration function
- * VehicleSensAddDeliveryCtrlTbl() Vehicle sensor delivery destination management table addition function
- * VehicleSensUpdateDeliveryCtrlTbl() Vehicle sensor delivery destination management table update function
- * VehicleSensUpdatePkgDeliveryCtrlTbl() Vehicle Sensor Delivery Destination Management Table Package Delivery Data Update Function
- * VehicleSensAddDeliveryCtrlTblMng() Vehicle sensor delivery destination management table management addition function
- * VehicleSensUpdateDeliveryCtrlTblMng() Vehicle sensor delivery destination management table management update function
- * VehicleSensAddPkgDeliveryTblMng() Vehicle Sensor Package Delivery Management Table Additional Function
- * VehicleSensEntryPkgDeliveryCtrl() Vehicle sensor package delivery management registration function
- * VehicleSensMakeDeliveryPnoTbl() Vehicle Sensor Destination PNO Table Creation Function
- * VehicleSensAddPnoTbl() Vehicle Sensor Destination PNO Table Addition Function
- * VehicleSensDeliveryProc() Vehicle Sensor Data Delivery Process
- * VehicleSensFirstDelivery() Vehicle Sensor Initial Data Delivery Process
- * VehicleSensFirstPkgDelivery() Vehicle Sensor Initial Package Data Delivery Process
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include <vehicle_service/POS_common_API.h>
-#include <vehicle_service/POS_gps_API.h>
-#include "VehicleSens_DeliveryCtrl.h"
-#include "Dead_Reckoning_Local_Api.h"
-#include "SensorLog.h"
-#include "POS_private.h"
-
-#define VEHICLE_SENS_DELIVERY_CTRL_DEBUG 0
-#define VEHICLE_SENS_DELIVERY_CTRL_DEBUG_DIAG 0
-
-#define GYRO_NORMAL (0U)
-#define GYRO_ERROR (1U)
-#define GYRO_UNFIXED (2U)
-
-#define _pb_strcat(pdest, psrc, size) (strncat(pdest, psrc, size) , (0))
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DELIVERY_CTRL_TBL g_stdelivery_ctrl_tbl;
-static VEHICLESENS_DELIVERY_CTRL_TBL_MNG g_stdelivery_ctrl_tbl_mng;
-static VEHICLESENS_PKG_DELIVERY_TBL_MNG g_stpkgdelivery_tbl_mng;
-static VEHICLESENS_DELIVERY_PNO_TBL g_stdelivery_pno_tbl;
-
-/* ++ PastModel002 response DR */
-static VEHICLESENS_DELIVERY_CTRL_TBL g_stdelivery_ctrl_tbl_dr;
-static VEHICLESENS_DELIVERY_CTRL_TBL_MNG g_stdelivery_ctrl_tbl_mng_dr;
-static VEHICLESENS_DELIVERY_PNO_TBL g_stdelivery_pno_tbl_dr;
-
-/* -- PastModel002 response DR */
-
-#if CONFIG_HW_PORTSET_TYPE_C
-u_int16 gusSeqNum; /* Sequence number for split transmission */
-#endif
-
-/*******************************************************************************
-* MODULE : VehicleSensInitDeliveryCtrlTbl
-* ABSTRACT : Vehicle sensor delivery destination management table initialization function
-* FUNCTION : Delivery destination management table initialization processing
-* ARGUMENT : void
-* NOTE :
-******************************************************************************/
-void VehicleSensInitDeliveryCtrlTbl(void) {
- memset(&g_stdelivery_ctrl_tbl, 0x00, sizeof(VEHICLESENS_DELIVERY_CTRL_TBL));
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensInitDeliveryCtrlTblMng
-* ABSTRACT : Vehicle Sensor DR Internal Delivery Destination Management Table Management Area Initialization Function
-* FUNCTION : Delivery destination management table management area initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitDeliveryCtrlTblMng(void) {
- memset(&g_stdelivery_ctrl_tbl_mng, 0x00, sizeof(VEHICLESENS_DELIVERY_CTRL_TBL_MNG));
-}
-
-/* ++ PastModel002 response DR */
-/*******************************************************************************
-* MODULE : VehicleSensInitDeliveryCtrlTblDR
-* ABSTRACT : Vehicle sensor delivery destination management table initialization function
-* FUNCTION : DR distribution target management table initialization processing
-* ARGUMENT : void
-* NOTE :
-******************************************************************************/
-void VehicleSensInitDeliveryCtrlTblDR(void) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&g_stdelivery_ctrl_tbl_dr, 0x00, sizeof(VEHICLESENS_DELIVERY_CTRL_TBL));
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensInitDeliveryCtrlTblMngDR
-* ABSTRACT : Vehicle sensor delivery destination management table management area initialization function
-* FUNCTION : Initialization processing for the management table area of the delivery destination management table for DR
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitDeliveryCtrlTblMngDR(void) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- memset(&g_stdelivery_ctrl_tbl_mng_dr, 0x00, sizeof(VEHICLESENS_DELIVERY_CTRL_TBL_MNG));
-}
-// LCOV_EXCL_STOP
-
-/* -- PastModel002 response DR */
-
-/*******************************************************************************
-* MODULE : VehicleSensInitPkgDeliveryTblMng
-* ABSTRACT : Vehicle Sensor Package Delivery Management Table Initialization Function
-* FUNCTION : Delivery Package Management Table Initialization Processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitPkgDeliveryTblMng(void) {
- memset(&g_stpkgdelivery_tbl_mng, 0x00, sizeof(VEHICLESENS_PKG_DELIVERY_TBL_MNG));
-}
-
-#if CONFIG_HW_PORTSET_TYPE_C
-/*******************************************************************************
-* MODULE : VehicleSensInitSeqNum
-* ABSTRACT : Sequence number initialization function for split transmission
-* FUNCTION : Sequence number initialization processing for split transmission
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitSeqNum(void) {
- gusSeqNum = 0;
-}
-#endif
-
-/*******************************************************************************
-* MODULE : VehicleSensEntryDeliveryCtrl
-* ABSTRACT : Vehicle sensor delivery destination management registration function
-* FUNCTION : Shipping management table,Update the shipping management table management.
-* ARGUMENT : pst_delivery_entry : Pointer to the delivery registration information
-* NOTE :
-* RETURN : VEHICLE_RET_NORMAL :Successful registration
-******************************************************************************/
-VEHICLE_RET_API VehicleSensEntryDeliveryCtrl(const VEHICLE_MSG_DELIVERY_ENTRY *pst_delivery_entry) {
- int32 i;
- u_int8 uc_action_type = VEHICLESENS_ACTION_TYPE_ADD;
- int32 uc_did_flag;
- DID ulentry_did = pst_delivery_entry->data.did;
- VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *pst_existing_mng_data = NULL;
- VEHICLE_RET_API ret = VEHICLE_RET_NORMAL; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- BOOL bexist_flag = FALSE;
-
- /* Check if the data ID exists. */
- uc_did_flag = VehicleSensCheckDid(ulentry_did);
- if (uc_did_flag == 0) { // LCOV_EXCL_BR_LINE 6:alway be 1
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-
- ret = VEHICLE_RET_ERROR_DID; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */ // LCOV_EXCL_LINE 8: dead code // NOLINT(whitespace/line_length)
- }
-
- /* Check the number of registered shipments. */
- if ((ret == VEHICLE_RET_NORMAL) && /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- (g_stdelivery_ctrl_tbl.us_dnum >= VEHICLESENS_DELIVERY_INFO_MAX)) {
- /* Return the FULL of delivery registrations*/
- ret = VEHICLE_RET_ERROR_BUFFULL; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- }
-
- if (ret == VEHICLE_RET_NORMAL) { /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- /* Duplicate delivery registration check*/
- for (i = 0; i < g_stdelivery_ctrl_tbl.us_dnum; i++) {
- if ((g_stdelivery_ctrl_tbl.st_ctrl_data[i].ul_did == ulentry_did) &&
- (g_stdelivery_ctrl_tbl.st_ctrl_data[i].us_pno == pst_delivery_entry->data.pno) &&
- (g_stdelivery_ctrl_tbl.st_ctrl_data[i].uc_method == VEHICLESENS_DELIVERY_METHOD_NORMAL)) {
- /* When the same shipping address (PNO) and shipping DID are already registered,Update registration information and exit */
- g_stdelivery_ctrl_tbl.st_ctrl_data[i].uc_chg_type = pst_delivery_entry->data.delivery_timing;
- bexist_flag = TRUE;
- break;
- }
- }
-
- if (bexist_flag == TRUE) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "Duplicate DID=0x%x PNO=0x%x ChgType=%d",
- ulentry_did,
- pst_delivery_entry->data.pno,
- pst_delivery_entry->data.delivery_timing);
- } else {
- /* By searching for the delivery registration of the relevant DID,Hold the address. */
- for (i = 0; i < g_stdelivery_ctrl_tbl_mng.us_dnum; i++) {
- if (g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i].ul_did == ulentry_did) {
- uc_action_type = VEHICLESENS_ACTION_TYPE_UPDATE;
- pst_existing_mng_data = &g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i];
- }
- }
- /* Add to the shipping management table.*/
- VehicleSensAddDeliveryCtrlTbl(pst_delivery_entry);
-
- /* Processing when updating existing data*/
- if (uc_action_type == VEHICLESENS_ACTION_TYPE_UPDATE) {
- /* Update the shipping management table.*/
- VehicleSensUpdateDeliveryCtrlTbl(pst_existing_mng_data);
-
- /* Update the shipping destination management table management information.*/
- VehicleSensUpdateDeliveryCtrlTblMng(pst_existing_mng_data);
- } else { /* Newly added processing*/
- /* Add to the shipping management table management information.*/
- VehicleSensAddDeliveryCtrlTblMng(pst_delivery_entry);
- }
- }
- }
- return ret; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensAddDeliveryCtrlTbl
-* ABSTRACT : Vehicle sensor delivery destination management table addition function
-* FUNCTION : Add to the shipping management table.
-* ARGUMENT : *pst_delivery_entry : Pointer to the delivery registration information
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensAddDeliveryCtrlTbl(const VEHICLE_MSG_DELIVERY_ENTRY *pst_delivery_entry) {
- VEHICLESENS_DELIVERY_CTRL_TBL_DATA *pst_ctrl_data;
-
- pst_ctrl_data = &g_stdelivery_ctrl_tbl.st_ctrl_data[g_stdelivery_ctrl_tbl.us_dnum];
- pst_ctrl_data->ul_did = pst_delivery_entry->data.did;
- pst_ctrl_data->us_pno = pst_delivery_entry->data.pno;
- pst_ctrl_data->uc_chg_type = pst_delivery_entry->data.delivery_timing;
- pst_ctrl_data->uc_ctrl_flg = pst_delivery_entry->data.ctrl_flg;
- pst_ctrl_data->us_link_idx = VEHICLESENS_LINK_INDEX_END;
- pst_ctrl_data->us_pkg_start_idx = VEHICLESENS_LINK_INDEX_END;
- pst_ctrl_data->us_pkg_end_idx = VEHICLESENS_LINK_INDEX_END;
- pst_ctrl_data->uc_method = VEHICLESENS_DELIVERY_METHOD_NORMAL;
- g_stdelivery_ctrl_tbl.us_dnum = static_cast<u_int16>(g_stdelivery_ctrl_tbl.us_dnum + 1);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensUpdateDeliveryCtrlTbl
-* ABSTRACT : Vehicle sensor delivery destination management table update function
-* FUNCTION : Update the shipping management table.
-* ARGUMENT : *pstExistingMngData : Pointer to the previous data information with the same data ID
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensUpdateDeliveryCtrlTbl(VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *pst_existing_mng_data) {
- /* Ignore->MISRA-C++:2008 Rule 7-1-2 */
- /* Update Link Index Only.
- For indexes of usEndIdx values matching the data IDs in the target management table
- Making usLinkIdx an Index-Registered Index */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- g_stdelivery_ctrl_tbl.st_ctrl_data[pst_existing_mng_data->us_end_idx].us_link_idx =
- static_cast<u_int16>(g_stdelivery_ctrl_tbl.us_dnum - 1); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensUpdatePkgDeliveryCtrlTbl
-* ABSTRACT : Vehicle Sensor Delivery Destination Management Table Package Delivery Data Update Function
-* FUNCTION : Updating Package Delivery Data in the Destination Management Table.
-* ARGUMENT : us_dnum : Number of data items in the package delivery management table
-* : us_pkg_num : Number of packages to create
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensUpdatePkgDeliveryCtrlTbl(u_int16 us_dnum, u_int16 us_pkg_num) {
- VEHICLESENS_DELIVERY_CTRL_TBL_DATA *pst_ctrl_data;
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_ctrl_data = &g_stdelivery_ctrl_tbl.st_ctrl_data[g_stdelivery_ctrl_tbl.us_dnum - 1];
- pst_ctrl_data->us_pkg_start_idx = us_dnum;
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_ctrl_data->us_pkg_end_idx = static_cast<u_int16>(us_dnum + us_pkg_num - 1);
- pst_ctrl_data->uc_method = VEHICLESENS_DELIVERY_METHOD_PACKAGE;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensAddDeliveryCtrlTblMng
-* ABSTRACT : Vehicle sensor delivery destination management table management addition function
-* FUNCTION : Add to the shipping management table management.
-* ARGUMENT : *pst_delivery_entry : Pointer to the delivery registration information
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensAddDeliveryCtrlTblMng(const VEHICLE_MSG_DELIVERY_ENTRY *pst_delivery_entry) {
- VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *pst_ctrl_mng_data;
-
- pst_ctrl_mng_data = &g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[g_stdelivery_ctrl_tbl_mng.us_dnum];
- pst_ctrl_mng_data->ul_did = pst_delivery_entry->data.did;
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_ctrl_mng_data->us_start_idx = static_cast<u_int16>(g_stdelivery_ctrl_tbl.us_dnum - 1);
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_ctrl_mng_data->us_end_idx = static_cast<u_int16>(g_stdelivery_ctrl_tbl.us_dnum - 1);
- pst_ctrl_mng_data->usdlvry_entry_num++;
- g_stdelivery_ctrl_tbl_mng.us_dnum++;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensUpdateDeliveryCtrlTblMng
-* ABSTRACT : Vehicle sensor delivery destination management table management update function
-* FUNCTION : Update the shipping management table management.
-* ARGUMENT : *pst_existing_mng_data : Pointer to the previous data information with the same data ID
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensUpdateDeliveryCtrlTblMng(VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *pst_existing_mng_data) {
- /* Update only the end index and the number of registered shipping destinations. */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_existing_mng_data->us_end_idx = static_cast<u_int16>(g_stdelivery_ctrl_tbl.us_dnum - 1);
- pst_existing_mng_data->usdlvry_entry_num++;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensAddPkgDeliveryTblMng
-* ABSTRACT : Vehicle Sensor Package Delivery Management Table Additional Function
-* FUNCTION : Add to the shipping management table management.
-* ARGUMENT : *pst_pkg : Pointer to package delivery registration information
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensAddPkgDeliveryTblMng(const SENSOR_MSG_DELIVERY_ENTRY *pst_pkg) {
- int32 i; /* Generic counters */
-
- /* Data ID registration */
- /* Registration of delivery data index */
- for (i = 0; i < (pst_pkg->data.pkg_num); i++) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- g_stpkgdelivery_tbl_mng.st_pkg_data[g_stpkgdelivery_tbl_mng.us_dnum].ul_did = pst_pkg->data.did[i];
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- g_stpkgdelivery_tbl_mng.st_pkg_data[g_stpkgdelivery_tbl_mng.us_dnum].usdlvry_idx = \
- static_cast<u_int16>(g_stpkgdelivery_tbl_mng.us_dnum + 1);
- g_stpkgdelivery_tbl_mng.us_dnum++;
- }
- /* The final delivery data index overwrites the terminating code */
- g_stpkgdelivery_tbl_mng.st_pkg_data[g_stpkgdelivery_tbl_mng.us_dnum - 1].usdlvry_idx = VEHICLESENS_LINK_INDEX_END;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensEntryPkgDeliveryCtrl
-* ABSTRACT : Vehicle sensor package delivery management registration function
-* FUNCTION : Shipping management table,Destination management table management,Update the package delivery management table.
-* ARGUMENT : *pst_pkg : Pointer to package delivery registration information
-* NOTE :
-* RETURN : VEHICLE_RET_NORMAL : Successful registration
-******************************************************************************/
-VEHICLE_RET_API VehicleSensEntryPkgDeliveryCtrl(const SENSOR_MSG_DELIVERY_ENTRY *pst_pkg ,
- u_int8 uc_ext_chk) { /* Ignore->MISRA-C++:2008 Rule 6-6-5 */
- int32 i;
- u_int16 us_size = 0;
- u_int8 uc_action_type = VEHICLESENS_ACTION_TYPE_ADD;
- VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *pst_existing_mng_data = NULL;
- VEHICLE_MSG_DELIVERY_ENTRY st_delivery_entry;
- u_int16 us_boundary_adj; /* For boundary adjustment */
- u_int16 us_next_offset; /* For size calculation */
- VEHICLE_RET_API ret = VEHICLE_RET_NORMAL; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- BOOL bexist_flag = FALSE;
-
- /* Check if the data ID exists. */
- for (i = 0; i < (pst_pkg->data.pkg_num); i++) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- if (VEHICLESENS_INVALID == VehicleSensCheckDid(pst_pkg->data.did[i])) { // LCOV_EXCL_BR_LINE 200: always Valid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- ret = VEHICLE_RET_ERROR_DID; // // LCOV_EXCL_LINE 8 :dead code
- /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- }
- }
-
- /* Check the number of registered shipments. */
- if ((ret == VEHICLE_RET_NORMAL) && /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- (VEHICLESENS_DELIVERY_INFO_MAX <= g_stdelivery_ctrl_tbl.us_dnum)) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Return the FULL of delivery registrations*/
- ret = VEHICLE_RET_ERROR_BUFFULL; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- }
-
- /* Check the number of registered package shipments. */
- if ((ret == VEHICLE_RET_NORMAL) && /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- (VEHICLESENS_PKG_DELIVERY_INFO_MAX < (g_stpkgdelivery_tbl_mng.us_dnum + pst_pkg->data.pkg_num))) {
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Return the FULL of delivery registrations*/
- ret = VEHICLE_RET_ERROR_BUFFULL; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- }
-
- if (ret == VEHICLE_RET_NORMAL) { /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- /* Check that the size of the buffer to be delivered does not exceed the maximum size. */
- /* For boundary adjustment */
- us_boundary_adj = (u_int16)VEHICLESENS_BIT1 | (u_int16)VEHICLESENS_BIT0;
- for (i = 0; i < pst_pkg->data.pkg_num; i++) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- /* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
- if (uc_ext_chk == VEHICLESENS_EXT_OFF) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */ // LCOV_EXCL_BR_LINE 200: VEHICLESENS_EXT_OFF passed in function is dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- us_next_offset = VehicleSensGetDataMasterOffset(pst_pkg->data.did[i]); // LCOV_EXCL_LINE 8: dead code
- } else {
- us_next_offset = VehicleSensGetDataMasterExtOffset(pst_pkg->data.did[i]);
- }
-#else
- us_next_offset = VehicleSensGetDataMasterOffset(pst_pkg->data.did[i]);
-#endif
- /* Ignore->MISRA-C++:2008 Rule 2-7-2 */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 Ignore->MISRA-C++:2008 Rule 5-0-13, 5-0-14, 5-3-1 */
- if ((us_next_offset & us_boundary_adj) != 0) {
- /* If you need to adjust */
- /* Mask Lower Bit Ignore->MISRA-C++:2008 Rule 5-0-5 Ignore->MISRA-C++:2008 Rule 5-0-21 */
- us_next_offset = static_cast<u_int16>(us_next_offset & ~us_boundary_adj);
- us_next_offset = static_cast<u_int16>(us_next_offset + (u_int16)VEHICLESENS_BIT2); /* Add numbers */
- }
- us_size = static_cast<u_int16>(us_size + us_next_offset); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- }
- if (SENSOR_VSINFO_DSIZE < us_size) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Return the FULL of delivery registrations(Exceed the size of the buffer to be delivered due to the combination of packages)*/
- ret = VEHICLE_RET_ERROR_BUFFULL; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- }
- }
-
- if (ret == VEHICLE_RET_NORMAL) { /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- for (i = 0; i < g_stdelivery_ctrl_tbl.us_dnum; i++) {
- if ((g_stdelivery_ctrl_tbl.st_ctrl_data[i].us_pno == pst_pkg->data.pno) &&
- (g_stdelivery_ctrl_tbl.st_ctrl_data[i].uc_method == VEHICLESENS_DELIVERY_METHOD_PACKAGE)) {
- /* When the same shipping address (PNO) is already registered,Update registration information and exit */
- g_stdelivery_ctrl_tbl.st_ctrl_data[i].uc_chg_type = pst_pkg->data.delivery_timing;
- bexist_flag = TRUE;
- break;
- }
- }
-
- if (bexist_flag == TRUE) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "Duplicate PNO=0x%x ChgType=%d",
- pst_pkg->data.pno, pst_pkg->data.delivery_timing);
- } else {
- /* By searching for the delivery registration of the relevant DID,Hold the address. */
- for (i = 0; i < g_stdelivery_ctrl_tbl_mng.us_dnum; i++) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- if (g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i].ul_did == pst_pkg->data.did[0]) {
- uc_action_type = VEHICLESENS_ACTION_TYPE_UPDATE;
- pst_existing_mng_data = &g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i];
- }
- }
- /* Type conversion,And copies of the data section(Because the header is unused,Not involved) */
- memset(reinterpret_cast<void *>(&st_delivery_entry),
- static_cast<int32>(0),
- (size_t)sizeof(VEHICLE_MSG_DELIVERY_ENTRY));
- st_delivery_entry.data.did = pst_pkg->data.did[0];
- st_delivery_entry.data.pno = pst_pkg->data.pno;
- st_delivery_entry.data.delivery_timing = pst_pkg->data.delivery_timing;
- st_delivery_entry.data.ctrl_flg = pst_pkg->data.ctrl_flg;
- st_delivery_entry.data.event_id = pst_pkg->data.event_id;
- /* Add to the shipping management table.*/
- VehicleSensAddDeliveryCtrlTbl(&st_delivery_entry);
-
- /* Processing when updating existing data*/
- /* Ignore->MISRA-C++:2008 Rule 5-0-13, 5-0-14, 5-3-1 */
- if (uc_action_type == VEHICLESENS_ACTION_TYPE_UPDATE) {
- /* Update the shipping management table.*/
- VehicleSensUpdateDeliveryCtrlTbl(pst_existing_mng_data);
-
- /* Update the shipping destination management table management information.*/
- VehicleSensUpdateDeliveryCtrlTblMng(pst_existing_mng_data);
- } else { /* Newly added processing*/
- /* Add to the shipping management table management information.*/
- VehicleSensAddDeliveryCtrlTblMng(&st_delivery_entry);
- }
-
- /* Updating Package Relationship Data in the Destination Management Table.*/
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- VehicleSensUpdatePkgDeliveryCtrlTbl(g_stpkgdelivery_tbl_mng.us_dnum, pst_pkg->data.pkg_num);
- /* Add to the package delivery management table.*/
- VehicleSensAddPkgDeliveryTblMng(pst_pkg);
- }
- }
-
- return ret; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensMakeDeliveryPnoTbl
-* ABSTRACT : Vehicle sensor delivery destination PNO table creation function
-* FUNCTION : Create the shipping destination PNO table
-* ARGUMENT : ul_did Data ID
-* Change_type Delivery Trigger
-* NOTE :
-* RETURN : VEHICLESENS_DELIVERY_PNO_TBL* Pointer to the shipping PNO table
-******************************************************************************/
-VEHICLESENS_DELIVERY_PNO_TBL* VehicleSensMakeDeliveryPnoTbl(DID ul_did, u_int8 change_type) {
- int32 i;
- u_int8 uc_ctrl_tbl_mng_data_list;
- u_int16 us_index = 0;
- u_int16 us_dnum = 0;
-
- /* Get the start index and count of the corresponding data ID. */
- uc_ctrl_tbl_mng_data_list = static_cast<u_int8>(
- (sizeof(g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data)) /
- (sizeof(g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[0])));
- for (i = 0; i < uc_ctrl_tbl_mng_data_list; i++) {
- /* Stores the information of the corresponding DID.. */
- if (g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i].ul_did == ul_did) {
- us_index = g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i].us_start_idx;
- us_dnum = g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i].usdlvry_entry_num;
- break;
- }
- }
-
- /* Create a PNO list */
- g_stdelivery_pno_tbl.us_dnum = 0;
- if (change_type == VEHICLESENS_CHGTYPE_CHG) {
- /* Processing when delivery timing is changed*/
- for (i = 0; i < us_dnum; i++) {
- /* Functionalization by Increasing Structure Members */
- VehicleSensAddPnoTbl(us_index);
- us_index = g_stdelivery_ctrl_tbl.st_ctrl_data[us_index].us_link_idx;
- }
- } else {
- /* Processing when delivery timing is update */
- for (i = 0; i < us_dnum; i++) {
- if (VEHICLE_DELIVERY_TIMING_UPDATE == g_stdelivery_ctrl_tbl.st_ctrl_data[us_index].uc_chg_type) {
- /* Functionalization by Increasing Structure Members */
- VehicleSensAddPnoTbl(us_index);
- }
- us_index = g_stdelivery_ctrl_tbl.st_ctrl_data[us_index].us_link_idx;
- }
- }
- return(&g_stdelivery_pno_tbl);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensAddPnoTbl
-* ABSTRACT : Vehicle Sensor Destination PNO Table Addition Function
-* FUNCTION : Add to the shipping PNO table.
-* ARGUMENT : us_index : Index of the referenced destination management table
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensAddPnoTbl(u_int16 us_index) {
- u_int16 us_pno_tbl_idx;
-
- us_pno_tbl_idx = g_stdelivery_pno_tbl.us_dnum;
- g_stdelivery_pno_tbl.st_pno_data[us_pno_tbl_idx].us_pno = \
- g_stdelivery_ctrl_tbl.st_ctrl_data[us_index].us_pno;
- g_stdelivery_pno_tbl.st_pno_data[us_pno_tbl_idx].us_pkg_start_idx = \
- g_stdelivery_ctrl_tbl.st_ctrl_data[us_index].us_pkg_start_idx;
- g_stdelivery_pno_tbl.st_pno_data[us_pno_tbl_idx].us_pkg_end_idx = \
- g_stdelivery_ctrl_tbl.st_ctrl_data[us_index].us_pkg_end_idx;
- g_stdelivery_pno_tbl.st_pno_data[us_pno_tbl_idx].uc_method = \
- g_stdelivery_ctrl_tbl.st_ctrl_data[us_index].uc_method;
- g_stdelivery_pno_tbl.us_dnum++;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensDeliveryGPS
-* ABSTRACT : Vehicle Sensor Data Delivery Process
-* FUNCTION : Deliver data to a destination.
-* ARGUMENT : ul_did :Data ID
-* uc_chg_type :Delivery timing
-* uc_get_method :Acquisition method
-* NOTE :
-* RETURN : void
-******************************************************************************/
-u_int8 VehicleSensDeliveryGPS(DID ul_did, u_int8 uc_get_method, u_int8 uc_current_get_method, int32 pno_index,
- u_int32* cid,
- VEHICLESENS_DATA_MASTER* stmaster,
- const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl) {
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
- SENSORLOCATION_MSG_LONLATINFO *plonlat_msg;
- SENSORLOCATION_MSG_ALTITUDEINFO *paltitude_msg;
- SENSORMOTION_MSG_HEADINGINFO *pheading_msg;
-#endif
-
- SENSOR_MSG_GPSDATA_DAT gps_master;
- VEHICLESENS_DELIVERY_FORMAT delivery_data;
- u_int16 length;
- u_int16 senslog_len;
- RET_API ret = RET_NORMAL; /* API return value */
- u_int8 uc_result = SENSLOG_RES_SUCCESS; /* Send/Receive result */
-
- VehicleSensGetGpsDataMaster(ul_did, uc_current_get_method, &gps_master);
-
- if (ul_did == POSHAL_DID_GPS_TIME) {
- /* GPS time,Because there is no header in the message to be delivered,
- Padding deliveryData headers */
- (void)memcpy(reinterpret_cast<void*>(&delivery_data),
- reinterpret_cast<void*>(&gps_master.uc_data[0]), gps_master.us_size);
- length = gps_master.us_size;
- senslog_len = length;
- *cid = CID_VEHICLESENS_VEHICLE_INFO_GPS_TIME;
- } else if (ul_did == VEHICLE_DID_LOCATION_LONLAT) {
- plonlat_msg = reinterpret_cast<SENSORLOCATION_MSG_LONLATINFO*>(&delivery_data);
- /* Acquire the applicable data information from the data master..*/
- VehicleSensGetDataMaster(ul_did, uc_current_get_method, stmaster);
- (void)memcpy(reinterpret_cast<void*>(&(plonlat_msg->data)),
- reinterpret_cast<void*>(&(stmaster->uc_data[0])), stmaster->us_size);
- length = (u_int16)(stmaster->us_size);
- senslog_len = length;
- *cid = CID_POSIF_REGISTER_LISTENER_LONLAT;
- } else if (ul_did == VEHICLE_DID_LOCATION_ALTITUDE) {
- paltitude_msg = reinterpret_cast<SENSORLOCATION_MSG_ALTITUDEINFO*>(&delivery_data);
- /* Acquire the applicable data information from the data master..*/
- VehicleSensGetDataMaster(ul_did, uc_get_method, stmaster);
- (void)memcpy(reinterpret_cast<void*>(&(paltitude_msg->data)),
- reinterpret_cast<void*>(&stmaster->uc_data[0]), stmaster->us_size);
- length = (u_int16)(stmaster->us_size);
- senslog_len = length;
- *cid = CID_POSIF_REGISTER_LISTENER_ALTITUDE;
- } else if (ul_did == VEHICLE_DID_MOTION_HEADING) {
- pheading_msg = reinterpret_cast<SENSORMOTION_MSG_HEADINGINFO*>(&delivery_data);
- /* Acquire the applicable data information from the data master..*/
- VehicleSensGetDataMaster(ul_did, uc_get_method, stmaster);
- (void)memcpy(reinterpret_cast<void*>(&(pheading_msg->data)),
- reinterpret_cast<void*>(&stmaster->uc_data[0]), stmaster->us_size);
- length = (u_int16)(stmaster->us_size);
- senslog_len = length;
- *cid = CID_POSIF_REGISTER_LISTENER_HEADING;
- } else {
- delivery_data.header.did = gps_master.ul_did;
- delivery_data.header.size = gps_master.us_size;
- delivery_data.header.rcv_flag = gps_master.uc_rcv_flag;
- delivery_data.header.sensor_cnt = gps_master.uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(&delivery_data.data[0]),
- reinterpret_cast<void *>(&gps_master.uc_data[0]),
- (size_t)delivery_data.header.size);
-
- length = static_cast<u_int16>((u_int16)sizeof(delivery_data.header) + \
- delivery_data.header.size);
- senslog_len = delivery_data.header.size;
- *cid = CID_VEHICLESENS_VEHICLE_INFO;
- }
-
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- static_cast<CID>(*cid),
- length,
- (const void *)&delivery_data);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- if (*cid != CID_VEHICLESENS_VEHICLE_INFO) {
- SensLogWriteOutputData(SENSLOG_DATA_O_UNSPECIFIED, ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&delivery_data),
- senslog_len, uc_result);
- } else {
- SensLogWriteOutputData(SENSLOG_DATA_O_UNSPECIFIED, ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&(delivery_data.data[0])),
- senslog_len, uc_result);
- }
- return uc_result;
-}
-
-u_int8 VehicleSensDeliveryFst(DID ul_did, u_int8 uc_get_method, int32 pno_index,
- const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl) {
- VEHICLESENS_DATA_MASTER_FST st_master_fst; /* Master of initial sensor data */
- VEHICLESENS_DATA_MASTER_FST st_master_fst_temp; /* For temporary storage */
-
- RET_API ret = RET_NORMAL; /* API return value */
- u_int8 uc_result = SENSLOG_RES_SUCCESS; /* Send/Receive result */
- (void)memset(reinterpret_cast<void *>(&st_master_fst),
- 0,
- sizeof(VEHICLESENS_DATA_MASTER_FST));
- (void)memset(reinterpret_cast<void *>(&st_master_fst_temp),
- 0,
- sizeof(VEHICLESENS_DATA_MASTER_FST));
- VehicleSensGetDataMasterFst(ul_did, uc_get_method, &st_master_fst);
- if (st_master_fst.partition_flg == 1) {
- /* When the partitioning flag is enabled,Or exceeds the size that can be sent,Perform split transmission */
- memcpy(&st_master_fst_temp, &st_master_fst, sizeof(VEHICLESENS_DATA_MASTER_FST));
- if ((ul_did == POSHAL_DID_GYRO_X_FST) || /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- (ul_did == POSHAL_DID_GYRO_Y_FST) ||
- (ul_did == POSHAL_DID_GYRO_Z_FST) ||
- (ul_did == POSHAL_DID_GSNS_X_FST) ||
- (ul_did == POSHAL_DID_GSNS_Y_FST) ||
- (ul_did == POSHAL_DID_GSNS_Z_FST)) {
- /* 1st session */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- /* Size of data that can be transmitted in one division(Same size definition used)*/
- st_master_fst_temp.us_size = LSDRV_FSTSNS_DSIZE_GYRO_X;
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(st_master_fst_temp.us_size + 8),
- (const void *)&st_master_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS,
- ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&(st_master_fst_temp.uc_data[0])),
- st_master_fst_temp.us_size,
- uc_result);
-
- /* Second time */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- (void)memset(reinterpret_cast<void *>(&st_master_fst_temp.uc_data[0]),
- 0,
- sizeof(u_int8) * VEHICLE_DSIZE_DATA_MASTER_FST);
- /* Size of the data - Transmission size(Same size definition used)Ignore->MISRA-C++:2008 Rule 5-0-5 */
- st_master_fst_temp.us_size = static_cast<u_int16>(st_master_fst.us_size - \
- LSDRV_FSTSNS_DSIZE_GYRO_X);
- memcpy(&st_master_fst_temp.uc_data[0],
- &st_master_fst.uc_data[LSDRV_FSTSNS_DSIZE_GYRO_X],
- st_master_fst_temp.us_size);
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 #Coverity_19347 */
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(st_master_fst_temp.us_size + 8),
- (const void *)&st_master_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS,
- ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&(st_master_fst_temp.uc_data[0])),
- st_master_fst_temp.us_size,
- uc_result);
- } else if (ul_did == POSHAL_DID_REV_FST) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* 1st session */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- /* Size of data that can be transmitted in one division */
- st_master_fst_temp.us_size = LSDRV_FSTSNS_DSIZE_REV;
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(st_master_fst_temp.us_size + 8),
- (const void *)&st_master_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS,
- ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&(st_master_fst_temp.uc_data[0])),
- st_master_fst_temp.us_size,
- uc_result);
-
- /* Second time */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- (void)memset(reinterpret_cast<void *>(&st_master_fst_temp.uc_data[0]),
- 0,
- sizeof(u_int8) * VEHICLE_DSIZE_DATA_MASTER_FST);
- /* Size of the data - Transmission size Ignore->MISRA-C++:2008 Rule 5-0-5 */
- st_master_fst_temp.us_size = static_cast<u_int16>(st_master_fst.us_size - \
- LSDRV_FSTSNS_DSIZE_REV);
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 #Coverity_19347 */
- memcpy(&st_master_fst_temp.uc_data[0],
- &st_master_fst.uc_data[LSDRV_FSTSNS_DSIZE_REV],
- st_master_fst_temp.us_size);
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(st_master_fst_temp.us_size + 8),
- (const void *)&st_master_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS,
- ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&(st_master_fst_temp.uc_data[0])),
- st_master_fst_temp.us_size,
- uc_result);
- } else {
- /* 1st session */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- /* Size of data that can be transmitted in one division(Same size definition used)*/
- st_master_fst_temp.us_size = LSDRV_FSTSNS_DSIZE_GYRO_TEMP;
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(st_master_fst_temp.us_size + 8),
- (const void *)&st_master_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS,
- ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&(st_master_fst_temp.uc_data[0])),
- st_master_fst_temp.us_size,
- uc_result);
- /* Second time */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- (void)memset(reinterpret_cast<void *>(&st_master_fst_temp.uc_data[0]),
- 0,
- sizeof(u_int8) * VEHICLE_DSIZE_DATA_MASTER_FST);
- /* Size of the data - Transmission size(Same size definition used)Ignore->MISRA-C++:2008 Rule 5-0-5 */
- st_master_fst_temp.us_size = static_cast<u_int16>(st_master_fst.us_size - \
- LSDRV_FSTSNS_DSIZE_GYRO_TEMP);
- memcpy(&st_master_fst_temp.uc_data[0],
- &st_master_fst.uc_data[LSDRV_FSTSNS_DSIZE_GYRO_TEMP],
- st_master_fst_temp.us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 #Coverity_19347*/
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(st_master_fst_temp.us_size + 8),
- (const void *)&st_master_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS,
- ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&(st_master_fst_temp.uc_data[0])),
- st_master_fst_temp.us_size,
- uc_result);
- }
- } else {
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(st_master_fst.us_size + 8),
- (const void *)&st_master_fst);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS,
- ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&(st_master_fst.uc_data[0])),
- st_master_fst.us_size,
- uc_result);
- }
-
- return uc_result;
-}
-
-u_int8 VehicleSensDeliveryGyro(DID ul_did, u_int8 uc_current_get_method, int32 pno_index, const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl) { // LCOV_EXCL_START 8: dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API ret = RET_NORMAL; /* API return value */
- u_int8 uc_result = SENSLOG_RES_SUCCESS; /* Send/Receive result */
-
- VEHICLESENS_DATA_MASTER_GYRO_TROUBLE st_master_gyro_trouble;
- SENSORMOTION_MSG_GYROTROUBLEINFO_DAT st_msg_gyro_trouble_info;
-
- /* Initialization */
- st_msg_gyro_trouble_info.reserve = 0;
-
- VehicleSensGetDataMasterGyroTrouble(ul_did, uc_current_get_method, &st_master_gyro_trouble);
-
- /* Size storage(GYROTROUBLE) */
- st_msg_gyro_trouble_info.size = st_master_gyro_trouble.us_size;
-
- /* Set the GyroTrouble */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_gyro_trouble_info.gyro_trouble)),
- reinterpret_cast<void *>(&(st_master_gyro_trouble.uc_data)),
- sizeof(st_msg_gyro_trouble_info.gyro_trouble));
-
-#if VEHICLE_SENS_DELIVERY_CTRL_DEBUG_DIAG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[DIAG] ul_did = VEHICLE_DID_GYRO_TROUBLE");
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[DIAG] st_msg_gyro_trouble_info.size = %d", st_msg_gyro_trouble_info.size);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[DIAG] st_msg_gyro_trouble_info.gyro_trouble = 0x%08X \r\n",
- st_msg_gyro_trouble_info.gyro_trouble);
-#endif /* VEHICLE_SENS_DELIVERY_CTRL_DEBUG_DIAG */
- /* Since the undefined state is not a device specification,Do not deliver to the app side */
- if (st_msg_gyro_trouble_info.gyro_trouble != GYRO_UNFIXED) {
-
- /* Send GyroTrouble to API-caller */
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- CID_VEHICLE_SENSORMOTION_GYROTROUBLE,
- sizeof(SENSORMOTION_MSG_GYROTROUBLEINFO_DAT),
- (const void *)&st_msg_gyro_trouble_info);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS,
- ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&st_msg_gyro_trouble_info),
- sizeof(SENSORMOTION_MSG_GYROTROUBLEINFO_DAT),
- uc_result);
-#if VEHICLE_SENS_DELIVERY_CTRL_DEBUG_DIAG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "#[DIAG] GyroTrouble Delivery");
-#endif /* VEHICLE_SENS_DELIVERY_CTRL_DEBUG_DIAG */
- }
- return uc_result;
-}
-// LCOV_EXCL_STOP
-
-void VehicleSensDeliveryAntenna(DID ul_did, u_int8 uc_current_get_method, int32 pno_index, const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl) { // LCOV_EXCL_START 8 : dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VEHICLESENS_DATA_MASTER_GPS_ANTENNA_STATUS gps_antenna_status;
- VEHICLESENS_DELIVERY_FORMAT delivery_data;
- u_int16 length;
-
- VehicleSensGetDataMasterGpsAntennaStatus(ul_did, uc_current_get_method, &gps_antenna_status);
-
- delivery_data.header.did = gps_antenna_status.ul_did;
- delivery_data.header.size = gps_antenna_status.us_size;
- delivery_data.header.rcv_flag = gps_antenna_status.uc_rcvflag;
- delivery_data.header.sensor_cnt = gps_antenna_status.uc_sensor_cnt;
- (void)memcpy(reinterpret_cast<void *>(&delivery_data.data[0]),
- reinterpret_cast<void *>(&gps_antenna_status.uc_data),
- (size_t)delivery_data.header.size);
-
- length = static_cast<u_int16>(static_cast<u_int32>(sizeof(delivery_data.header)) + delivery_data.header.size);
-
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- (void)VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- length,
- (const void *)&delivery_data);
-}
-// LCOV_EXCL_STOP
-
-u_int8 VehicleSensDeliveryOther(DID ul_did, u_int8 uc_current_get_method, int32 pno_index,
- u_int32* cid, // NOLINT(readability/nolint)
- VEHICLESENS_DATA_MASTER* stmaster, // NOLINT(readability/nolint)
- const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl) {
- RET_API ret = RET_NORMAL; /* API return value */
- u_int8 uc_result = SENSLOG_RES_SUCCESS; /* Send/Receive result */
-/* Determine CID */
- if (ul_did == VEHICLE_DID_LOCATION_LONLAT_NAVI) {
- *cid = CID_POSIF_REGISTER_LISTENER_LONLAT;
- } else if (ul_did == VEHICLE_DID_LOCATION_ALTITUDE_NAVI) { // LCOV_EXCL_BR_LINE 6:VEHICLE_DID_LOCATION_ALTITUDE_NAVI no API to pass in // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- *cid = CID_POSIF_REGISTER_LISTENER_ALTITUDE; // LCOV_EXCL_LINE 8: dead code
- } else if ((ul_did == VEHICLE_DID_MOTION_SPEED_NAVI) ||
- (ul_did == VEHICLE_DID_MOTION_SPEED_INTERNAL)) {
- *cid = CID_VEHICLE_SENSORMOTION_SPEED;
- } else if (ul_did == VEHICLE_DID_MOTION_HEADING_NAVI) {
- *cid = CID_POSIF_REGISTER_LISTENER_HEADING;
- } else if (ul_did == VEHICLE_DID_SETTINGTIME) {
- *cid = CID_POSIF_REGISTER_LISTENER_GPS_TIME_SET_REQ;
- } else { // LCOV_EXCL_BR_LINE 6: cannot be this one
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- *cid = 0xFFFF; /* DID error */ // LCOV_EXCL_LINE 8: dead code
- }
-
- /* Send vehicle sensor information notification */
- if (*cid == 0xFFFF) { // LCOV_EXCL_BR_LINE 6: cannot be this one
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Error log */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Unknown DID [%d]", ul_did);
- } else {
- /* Acquire the applicable data information from the data master..*/
- (void)memset(reinterpret_cast<void *>(stmaster), 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- VehicleSensGetDataMaster(ul_did, uc_current_get_method, stmaster);
-
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- static_cast<CID>(*cid),
- (u_int16)(stmaster->us_size),
- (const void *)&(stmaster->uc_data[0]));
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_UNSPECIFIED,
- ul_did,
- pst_pno_tbl->st_pno_data[pno_index].us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster->uc_data[0])),
- stmaster->us_size,
- uc_result);
- }
-
- return uc_result;
-}
-
-void VehicleSensDeliveryProc(DID ul_did, u_int8 uc_chg_type, u_int8 uc_get_method) {
- VEHICLESENS_DATA_MASTER stmaster; /* Data master of normal data */
- const VEHICLESENS_DELIVERY_PNO_TBL *pst_pno_tbl; /* Vehicle Sensor Destination PNO Table Pointer */
- SENSOR_PKG_MSG_VSINFO st_pkg_master; /* Data master for package delivery */
- uint32_t cid;
- uint8_t uc_result = SENSLOG_RES_SUCCESS; /* Send/Receive result */
-
- /* Obtain the data acquisition method from the Vehicle Selection Item List */
- uint8_t uc_current_get_method = VehicleSensGetSelectionItemList(ul_did);
-
- if (uc_current_get_method == uc_get_method) {
- /* When the data acquisition methods match (= delivery target) */
-
- /* Obtain the shipping destination PNO */
- pst_pno_tbl = (const VEHICLESENS_DELIVERY_PNO_TBL *) VehicleSensMakeDeliveryPnoTbl(ul_did, uc_chg_type);
-
- if ((pst_pno_tbl->us_dnum) > 0) {
- /* When there is a shipping destination PNO registration */
- /* For boundary adjustment */
- uint16_t us_boundary_adj = (u_int16) VEHICLESENS_BIT1 | (u_int16) VEHICLESENS_BIT0; /* #012 */
- /* Vehicle sensor information notification transmission process */
- for (uint32_t i = 0; i < (pst_pno_tbl->us_dnum); i++) {
- if (VEHICLESENS_DELIVERY_METHOD_PACKAGE == pst_pno_tbl->st_pno_data[i].uc_method) {
- /* When the delivery method is the package method */
- (void) memset(reinterpret_cast<void *>(&st_pkg_master), 0, sizeof(SENSOR_PKG_MSG_VSINFO));
-
- uint16_t us_index = pst_pno_tbl->st_pno_data[i].us_pkg_start_idx;
- uint8_t uc_data_cnt = 0U;
- uint16_t us_offset = 0U;
- for (uint32_t j = 0; j < SENSOR_PKG_DELIVERY_MAX; j++) {
- DID ul_pkg_did = g_stpkgdelivery_tbl_mng.st_pkg_data[us_index].ul_did; /* Get DID */
- st_pkg_master.usOffset[uc_data_cnt] = us_offset; /* Offset setting */
- uc_current_get_method = VehicleSensGetSelectionItemList(ul_pkg_did); /* Data collection way */
- if (VEHICLESENS_GETMETHOD_GPS == uc_current_get_method) {
- VehicleSensGetGpsDataMaster(ul_pkg_did, uc_current_get_method,
- reinterpret_cast<SENSOR_MSG_GPSDATA_DAT *>(&st_pkg_master.ucData[us_offset]));
- }
- else {
- VehicleSensGetDataMaster(ul_pkg_did, uc_current_get_method,
- reinterpret_cast<VEHICLESENS_DATA_MASTER *>(&st_pkg_master.ucData[us_offset]));
- }
- uc_data_cnt++; /* Data count increment */
- if ((us_index == pst_pno_tbl->st_pno_data[i].us_pkg_end_idx)
- || (VEHICLESENS_LINK_INDEX_END == g_stpkgdelivery_tbl_mng.st_pkg_data[us_index].usdlvry_idx)) {
- st_pkg_master.ucDNum = uc_data_cnt; /* To save the number of data */
- break;
- }
- else {
- /* By creating the following processing contents,Need to obtain an offset value */
- uint16_t us_next_offset = VehicleSensGetDataMasterOffset(ul_pkg_did); /* Next offset calculation */
- /* Boundary adjustment of data size */
- if ((us_next_offset & us_boundary_adj) != 0) {
- /* If you need to adjust */
- /* Mask Lower Bit */
- us_next_offset = static_cast<u_int16>(us_next_offset & ~us_boundary_adj);
- /* Add numbers */
- us_next_offset = static_cast<u_int16>(us_next_offset + (u_int16) VEHICLESENS_BIT2);
- }
- us_offset = static_cast<u_int16>(us_offset + us_next_offset);
- /* Get next index */
- us_index = g_stpkgdelivery_tbl_mng.st_pkg_data[us_index].usdlvry_idx;
- }
- }
- RET_API ret = PosSndMsg(PNO_VEHICLE_SENSOR, pst_pno_tbl->st_pno_data[i].us_pno,
- CID_SENSOR_PKG_INFO, (u_int16) sizeof(SENSOR_PKG_MSG_VSINFO), (const void *) &st_pkg_master);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS_PKG, 0, pst_pno_tbl->st_pno_data[i].us_pno,
- reinterpret_cast<uint8_t *>(&st_pkg_master), sizeof(SENSOR_PKG_MSG_VSINFO), uc_result);
- }
- else {
- /* When the delivery system is normal */
- /* Acquire the applicable data information from the data master..*/
- if (VEHICLESENS_GETMETHOD_GPS == uc_current_get_method) {
- uc_result = VehicleSensDeliveryGPS(ul_did, uc_get_method, uc_current_get_method, i, &cid, &stmaster,
- pst_pno_tbl);
- }
- else if ((VEHICLESENS_GETMETHOD_NAVI == uc_get_method) || // NOLINT(readability/braces)
- (VEHICLESENS_GETMETHOD_OTHER == uc_get_method) || (VEHICLESENS_GETMETHOD_INTERNAL == uc_get_method)) {
- uc_result = VehicleSensDeliveryOther(ul_did, uc_current_get_method, i, &cid, &stmaster, pst_pno_tbl);
- }
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- else if ((ul_did == POSHAL_DID_GYRO_X_FST) || // NOLINT(readability/braces)
- (ul_did == POSHAL_DID_GYRO_Y_FST) || // NOLINT(readability/braces)
- (ul_did == POSHAL_DID_GYRO_Z_FST) || // NOLINT(readability/braces)
- (ul_did == POSHAL_DID_REV_FST) ||
- (ul_did == POSHAL_DID_GYRO_TEMP_FST) ||
- (ul_did == POSHAL_DID_GSNS_X_FST) ||
- (ul_did == POSHAL_DID_GSNS_Y_FST) ||
- (ul_did == POSHAL_DID_GSNS_Z_FST) ||
- (ul_did == POSHAL_DID_SPEED_PULSE_FST)) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Acquire the applicable data information from the data master for the initial sensor..*/
- uc_result = VehicleSensDeliveryFst(ul_did, uc_get_method, i, pst_pno_tbl);
- }
-#endif
- else if (ul_did == VEHICLE_DID_GYRO_TROUBLE) { // LCOV_EXCL_BR_LINE 6:DID is not used
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- uc_result = VehicleSensDeliveryGyro(ul_did, uc_current_get_method, i, pst_pno_tbl); // LCOV_EXCL_LINE 8: dead code // NOLINT(whitespace/line_length)
- }
- else { // NOLINT(readability/braces)
- (void) memset(reinterpret_cast<void *>(&stmaster), 0x00, sizeof(stmaster));
- VehicleSensGetDataMaster(ul_did, uc_current_get_method, &stmaster);
-
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- RET_API ret = VehicleSndMsg(PNO_VEHICLE_SENSOR, pst_pno_tbl->st_pno_data[i].us_pno,
- CID_VEHICLESENS_VEHICLE_INFO, (u_int16) sizeof(VEHICLESENS_DATA_MASTER), (const void *) &stmaster);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS, ul_did, pst_pno_tbl->st_pno_data[i].us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster.uc_data[0])), stmaster.us_size, uc_result);
- }
- }
- }
- }
- }
-}
-
-u_int8 VehicleSensFirstDeliverySens(PNO us_pno, DID ul_did, u_int8 uc_get_method,
- VEHICLESENS_DATA_MASTER_FST* stmaster_fst,
- VEHICLESENS_DATA_MASTER_FST* stmaster_fst_temp) {
- RET_API ret = RET_NORMAL; /* API return value */
- u_int8 uc_result = SENSLOG_RES_SUCCESS; /* Send/Receive result */
- /* Acquire the applicable data information from the data master for the initial sensor..*/
- (void)memset(reinterpret_cast<void *>(stmaster_fst), 0, sizeof(VEHICLESENS_DATA_MASTER_FST));
- (void)memset(reinterpret_cast<void *>(stmaster_fst_temp), 0, sizeof(VEHICLESENS_DATA_MASTER_FST));
- VehicleSensGetDataMasterFst(ul_did, uc_get_method, stmaster_fst);
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__,
- "[LOG:POSHAL_DID_GYRO_FST,POSHAL_DID_SPEED_PULSE_FST]");
-
- if (stmaster_fst->partition_flg == 1) {
- /* When the partitioning flag is enabled,Or exceeds the size that can be sent,Perform split transmission */
- memcpy(stmaster_fst_temp, stmaster_fst, sizeof(VEHICLESENS_DATA_MASTER_FST));
- if ((ul_did == POSHAL_DID_GYRO_X_FST) || /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- (ul_did == POSHAL_DID_GYRO_Y_FST) ||
- (ul_did == POSHAL_DID_GYRO_Z_FST) ||
- (ul_did == POSHAL_DID_GSNS_X_FST) ||
- (ul_did == POSHAL_DID_GSNS_Y_FST) ||
- (ul_did == POSHAL_DID_GSNS_Z_FST)) {
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__,
- "[CALL:VehicleSndMsg:INPOSHAL_DID_GYRO_FST Partition]");
-
- /* 1st session */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- /* Size of data that can be transmitted in one division(Same size definition used) */
- stmaster_fst_temp->us_size = LSDRV_FSTSNS_DSIZE_GYRO_X;
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(stmaster_fst_temp->us_size + 8),
- (const void *)stmaster_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS,
- ul_did,
- us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster_fst_temp->uc_data[0])),
- stmaster_fst_temp->us_size,
- uc_result);
-
- /* Second time */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- (void)memset(reinterpret_cast<void *>(&stmaster_fst_temp->uc_data[0]),
- 0,
- sizeof(u_int8) * VEHICLE_DSIZE_DATA_MASTER_FST);
- /* Size of the data - Transmission size(Same size definition used) Ignore->MISRA-C++:2008 Rule 5-0-5 */
- stmaster_fst_temp->us_size = static_cast<u_int16>(stmaster_fst->us_size - LSDRV_FSTSNS_DSIZE_GYRO_X);
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- memcpy(&stmaster_fst_temp->uc_data[0],
- &stmaster_fst->uc_data[LSDRV_FSTSNS_DSIZE_GYRO_X],
- stmaster_fst_temp->us_size);
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(stmaster_fst_temp->us_size + 8),
- (const void *)stmaster_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS, ul_did, us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster_fst_temp->uc_data[0])),
- stmaster_fst_temp->us_size, uc_result);
- } else if (ul_did == POSHAL_DID_REV_FST) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__,
- "[CALL:VehicleSndMsg:INPOSHAL_DID_REV_FST Partition]");
-
- /* 1st session */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- stmaster_fst_temp->us_size = LSDRV_FSTSNS_DSIZE_REV; /* Size of data that can be transmitted in one division */
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(stmaster_fst_temp->us_size + 8),
- (const void *)stmaster_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS, ul_did, us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster_fst_temp->uc_data[0])),
- stmaster_fst_temp->us_size, uc_result);
-
- /* Second time */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- (void)memset(reinterpret_cast<void *>(&stmaster_fst_temp->uc_data[0]),
- 0,
- sizeof(u_int8) * VEHICLE_DSIZE_DATA_MASTER_FST);
- /* Size of the data - Transmission size Ignore->MISRA-C++:2008 Rule 5-0-5 */
- stmaster_fst_temp->us_size = static_cast<u_int16>(stmaster_fst->us_size - LSDRV_FSTSNS_DSIZE_REV);
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- memcpy(&stmaster_fst_temp->uc_data[0],
- &stmaster_fst->uc_data[LSDRV_FSTSNS_DSIZE_REV],
- stmaster_fst_temp->us_size);
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(stmaster_fst_temp->us_size + 8),
- (const void *)stmaster_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS, ul_did, us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster_fst_temp->uc_data[0])),
- stmaster_fst_temp->us_size, uc_result);
- } else {
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__,
- "[CALL:Vehicle_SndMsg:POSHAL_DID_SPEED_PULSE_FST Partition]");
-
- /* 1st session */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- /* Size of data that can be transmitted in one division(Same size definition used) */
- stmaster_fst_temp->us_size = LSDRV_FSTSNS_DSIZE_GYRO_TEMP;
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(stmaster_fst_temp->us_size + 8),
- (const void *)stmaster_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS, ul_did, us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster_fst_temp->uc_data[0])),
- stmaster_fst_temp->us_size, uc_result);
-
- /* Second time */
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- (void)memset(reinterpret_cast<void *>(&stmaster_fst_temp->uc_data[0]),
- 0,
- sizeof(u_int8) * VEHICLE_DSIZE_DATA_MASTER_FST);
- /* Size of the data - Transmission size(Same size definition used) Ignore->MISRA-C++:2008 Rule 5-0-5 */
- stmaster_fst_temp->us_size = static_cast<u_int16>(stmaster_fst->us_size - LSDRV_FSTSNS_DSIZE_GYRO_TEMP);
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- memcpy(&stmaster_fst_temp->uc_data[0],
- &stmaster_fst->uc_data[LSDRV_FSTSNS_DSIZE_GYRO_TEMP],
- stmaster_fst_temp->us_size);
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(stmaster_fst_temp->us_size + 8),
- (const void *)stmaster_fst_temp);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS, ul_did, us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster_fst_temp->uc_data[0])),
- stmaster_fst_temp->us_size, uc_result);
- }
- } else {
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "[CALL:VehicleSndMsg]");
-
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- /* Data size + data information Ignore->MISRA-C++:2008 Rule 5-0-5 */
- static_cast<u_int16>(stmaster_fst->us_size + 8),
- (const void *)stmaster_fst);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS, ul_did, us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster_fst->uc_data[0])),
- stmaster_fst->us_size, uc_result);
- }
-
- return uc_result;
-}
-
-u_int8 VehicleSensFirstDeliveryOther(PNO us_pno, DID ul_did, u_int8 uc_get_method,
- u_int32* cid,
- VEHICLESENS_DATA_MASTER* stmaster) {
- RET_API ret = RET_NORMAL; /* API return value */
- u_int8 uc_result = SENSLOG_RES_SUCCESS; /* Send/Receive result */
- /* Determine CID */
- if (ul_did == VEHICLE_DID_LOCATION_LONLAT_NAVI) {
- *cid = CID_POSIF_REGISTER_LISTENER_LONLAT;
- } else if (ul_did == VEHICLE_DID_LOCATION_ALTITUDE_NAVI) { // LCOV_EXCL_BR_LINE 6:VEHICLE_DID_LOCATION_ALTITUDE_NAVI no API to pass in // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- *cid = CID_POSIF_REGISTER_LISTENER_ALTITUDE; // LCOV_EXCL_LINE 8: dead code
- } else if ((ul_did == VEHICLE_DID_MOTION_SPEED_NAVI) ||
- (ul_did == VEHICLE_DID_MOTION_SPEED_INTERNAL)) {
- *cid = CID_VEHICLE_SENSORMOTION_SPEED;
- } else if (ul_did == VEHICLE_DID_MOTION_HEADING_NAVI) {
- *cid = CID_POSIF_REGISTER_LISTENER_HEADING;
- } else if (ul_did == VEHICLE_DID_SETTINGTIME) {
- *cid = CID_POSIF_REGISTER_LISTENER_GPS_TIME_SET_REQ;
- } else { // LCOV_EXCL_BR_LINE 6: cannot be this one
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- *cid = 0xFFFF; /* DID error */ // LCOV_EXCL_LINE 8: dead code
- }
-
- /* Vehicle sensor information notification transmission */
- if (*cid == 0xFFFF) { // LCOV_EXCL_BR_LINE 6: cannot be this one
- /* Error log */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Unknown DID [%d]", ul_did); // LCOV_EXCL_LINE 8: dead code // NOLINT(whitespace/line_length)
- } else {
- /* Acquire the applicable data information from the data master..*/
- (void)memset(reinterpret_cast<void *>(stmaster), 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- VehicleSensGetDataMaster(ul_did, uc_get_method, stmaster);
-
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- static_cast<CID>(*cid),
- (u_int16)stmaster->us_size,
- (const void *)&(stmaster->uc_data[0]));
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_UNSPECIFIED,
- ul_did,
- us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster->uc_data[0])),
- stmaster->us_size,
- uc_result);
- }
-
- return uc_result;
-}
-/*******************************************************************************
-* MODULE : VehicleSensFirstDelivery
-* ABSTRACT : Vehicle Sensor Initial Data Delivery Process
-* FUNCTION : Deliver the initial data to the destination.
-* ARGUMENT : us_pno :Addresses for delivery NO
-* ul_did :Data ID
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensFirstDelivery(PNO us_pno, DID ul_did) {
- u_int8 uc_get_method;
- VEHICLESENS_DATA_MASTER stmaster;
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
- VEHICLESENS_DATA_MASTER_FST stMasterFst; /* Master of initial sensor data */
- VEHICLESENS_DATA_MASTER_FST stMasterFst_temp; /* For temporary storage */
- u_int32 cid;
- SENSORLOCATION_MSG_LONLATINFO *pLonLatMsg;
- SENSORLOCATION_MSG_ALTITUDEINFO *pAltitudeMsg;
- SENSORMOTION_MSG_HEADINGINFO *pHeadingMsg;
- RET_API ret = RET_NORMAL; /* API return value */
- u_int8 uc_result = SENSLOG_RES_SUCCESS; /* Send/Receive result */
-#endif
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+ [ul_did = 0x%x us_pno:0x%x]", ul_did, us_pno);
-
- /* Obtain the data acquisition method.*/
- uc_get_method = VehicleSensGetSelectionItemList(ul_did);
-
- if (VEHICLESENS_GETMETHOD_GPS == uc_get_method) {
- SENSOR_MSG_GPSDATA_DAT gps_master;
- VEHICLESENS_DELIVERY_FORMAT delivery_data;
- u_int16 length;
- u_int16 senslog_len;
-
- VehicleSensGetGpsDataMaster(ul_did, uc_get_method, &gps_master);
-
- if (ul_did == POSHAL_DID_GPS_TIME) {
- /* GPS time,Because there is no header in the message to be delivered,Padding deliveryData headers */
- (void)memcpy(reinterpret_cast<void*>(&delivery_data),
- reinterpret_cast<void*>(&gps_master.uc_data[0]), gps_master.us_size);
- length = gps_master.us_size;
- senslog_len = length;
- cid = CID_VEHICLESENS_VEHICLE_INFO_GPS_TIME;
- } else if (ul_did == VEHICLE_DID_LOCATION_LONLAT) {
- pLonLatMsg = reinterpret_cast<SENSORLOCATION_MSG_LONLATINFO*>(&delivery_data);
- /* Acquire the applicable data information from the data master..*/
- VehicleSensGetDataMaster(ul_did, uc_get_method, &stmaster);
- (void)memcpy(reinterpret_cast<void*>(&(pLonLatMsg->data)),
- reinterpret_cast<void*>(&(stmaster.uc_data[0])), stmaster.us_size);
- length = (u_int16)stmaster.us_size;
- senslog_len = length;
- cid = CID_POSIF_REGISTER_LISTENER_LONLAT;
- } else if (ul_did == VEHICLE_DID_LOCATION_ALTITUDE) {
- pAltitudeMsg = reinterpret_cast<SENSORLOCATION_MSG_ALTITUDEINFO*>(&delivery_data);
- /* Acquire the applicable data information from the data master..*/
- VehicleSensGetDataMaster(ul_did, uc_get_method, &stmaster);
- (void)memcpy(reinterpret_cast<void*>(&(pAltitudeMsg->data)),
- reinterpret_cast<void*>(&stmaster.uc_data[0]), stmaster.us_size);
- length = (u_int16)stmaster.us_size;
- senslog_len = length;
- cid = CID_POSIF_REGISTER_LISTENER_ALTITUDE;
- } else if (ul_did == VEHICLE_DID_MOTION_HEADING) {
- pHeadingMsg = reinterpret_cast<SENSORMOTION_MSG_HEADINGINFO*>(&delivery_data);
- /* Acquire the applicable data information from the data master..*/
- VehicleSensGetDataMaster(ul_did, uc_get_method, &stmaster);
- (void)memcpy(reinterpret_cast<void*>(&(pHeadingMsg->data)),
- reinterpret_cast<void*>(&stmaster.uc_data[0]), stmaster.us_size);
- length = (u_int16)stmaster.us_size;
- senslog_len = length;
- cid = CID_POSIF_REGISTER_LISTENER_HEADING;
- } else {
-
- delivery_data.header.did = gps_master.ul_did;
- delivery_data.header.size = gps_master.us_size;
- delivery_data.header.rcv_flag = gps_master.uc_rcv_flag;
- delivery_data.header.sensor_cnt = gps_master.uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(&delivery_data.data[0]),
- reinterpret_cast<void *>(&gps_master.uc_data[0]),
- (size_t)delivery_data.header.size);
-
- length = static_cast<u_int16>((u_int16)sizeof(delivery_data.header) + delivery_data.header.size);
- senslog_len = delivery_data.header.size;
- cid = CID_VEHICLESENS_VEHICLE_INFO;
- }
-
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- static_cast<CID>(cid),
- length,
- (const void *)&delivery_data);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- if (cid != CID_VEHICLESENS_VEHICLE_INFO) {
- SensLogWriteOutputData(SENSLOG_DATA_O_UNSPECIFIED, ul_did, us_pno,
- reinterpret_cast<uint8_t *>(&delivery_data), senslog_len, uc_result);
- } else {
- SensLogWriteOutputData(SENSLOG_DATA_O_UNSPECIFIED, ul_did, us_pno,
- reinterpret_cast<uint8_t *>(&(delivery_data.data[0])), senslog_len, uc_result);
- }
- }
- else if ((VEHICLESENS_GETMETHOD_NAVI == uc_get_method) || // NOLINT(readability/braces)
- (VEHICLESENS_GETMETHOD_OTHER == uc_get_method) ||
- (VEHICLESENS_GETMETHOD_INTERNAL == uc_get_method)) {
- uc_result = VehicleSensFirstDeliveryOther(us_pno, ul_did, uc_get_method, &cid, &stmaster);
- }
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- else if ((ul_did == POSHAL_DID_GYRO_X_FST) || // NOLINT(readability/braces)
- (ul_did == POSHAL_DID_GYRO_Y_FST) || // NOLINT(readability/braces)
- (ul_did == POSHAL_DID_GYRO_Z_FST) || // NOLINT(readability/braces)
- (ul_did == POSHAL_DID_REV_FST) ||
- (ul_did == POSHAL_DID_GYRO_TEMP_FST) ||
- (ul_did == POSHAL_DID_GSNS_X_FST) ||
- (ul_did == POSHAL_DID_GSNS_Y_FST) ||
- (ul_did == POSHAL_DID_GSNS_Z_FST) ||
- (ul_did == POSHAL_DID_SPEED_PULSE_FST)) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Acquire the applicable data information from the data master for the initial sensor..*/
- uc_result = VehicleSensFirstDeliverySens(us_pno, ul_did, uc_get_method, &stMasterFst, &stMasterFst_temp);
- }
-#endif
- else if (ul_did == VEHICLE_DID_GYRO_TROUBLE) { // LCOV_EXCL_BR_LINE 8 : DID in not used
- // LCOV_EXCL_START 8: DID is not used
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VEHICLESENS_DATA_MASTER_GYRO_TROUBLE st_master_gyro_trouble;
- SENSORMOTION_MSG_GYROTROUBLEINFO_DAT st_msg_gyro_trouble_info;
-
- /* Initialization */
- st_master_gyro_trouble.uc_reserve = 0;
- st_msg_gyro_trouble_info.reserve = 0;
-
- VehicleSensGetDataMasterGyroTrouble(ul_did, uc_get_method, &st_master_gyro_trouble);
-
- /* Size storage(GYROTROUBLE) */
- st_msg_gyro_trouble_info.size = st_master_gyro_trouble.us_size;
-
- /* Set the GyroTrouble */
- (void)memcpy(reinterpret_cast<void *>(&(st_msg_gyro_trouble_info.gyro_trouble)),
- reinterpret_cast<void *>(&(st_master_gyro_trouble.uc_data)),
- sizeof(st_msg_gyro_trouble_info.gyro_trouble));
-
-#if VEHICLE_SENS_DELIVERY_CTRL_DEBUG_DIAG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "#[DIAG] ul_did = VEHICLE_DID_GYRO_TROUBLE");
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[DIAG] st_msg_gyro_trouble_info.size = %d",
- st_msg_gyro_trouble_info.size);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[DIAG] st_msg_gyro_trouble_info.gyro_trouble = 0x%08X \r\n",
- st_msg_gyro_trouble_info.gyro_trouble);
-#endif /* VEHICLE_SENS_DELIVERY_CTRL_DEBUG_DIAG */
- /* Since the undefined state is not a device specification,Do not deliver to the app for the first time */
- if (st_msg_gyro_trouble_info.gyro_trouble != GYRO_UNFIXED) {
-
- /* Send GyroTrouble to API-caller */
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLE_SENSORMOTION_GYROTROUBLE,
- sizeof(SENSORMOTION_MSG_GYROTROUBLEINFO_DAT),
- (const void *)&st_msg_gyro_trouble_info);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS, ul_did, us_pno,
- reinterpret_cast<uint8_t *>(&st_msg_gyro_trouble_info),
- sizeof(SENSORMOTION_MSG_GYROTROUBLEINFO_DAT),
- uc_result);
-#if VEHICLE_SENS_DELIVERY_CTRL_DEBUG_DIAG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "#[DIAG] GyroTrouble FirstDelivery");
-#endif /* VEHICLE_SENS_DELIVERY_CTRL_DEBUG_DIAG */
- }
- // LCOV_EXCL_STOP
- }
- else { // NOLINT(readability/braces)
- (void)memset(reinterpret_cast<void *>(&stmaster), 0x00, sizeof(stmaster));
- /* Acquire the applicable data information from the data master..*/
- VehicleSensGetDataMaster(ul_did, uc_get_method, &stmaster);
-
- /* Call Vehicle Sensor Information Notification Transmission Process.*/
- ret = VehicleSndMsg(PNO_VEHICLE_SENSOR,
- us_pno,
- CID_VEHICLESENS_VEHICLE_INFO,
- (u_int16)sizeof(VEHICLESENS_DATA_MASTER),
- (const void *)&stmaster);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS, ul_did, us_pno,
- reinterpret_cast<uint8_t *>(&(stmaster.uc_data[0])),
- stmaster.us_size, uc_result);
- }
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "-");
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensFirstPkgDelivery
-* ABSTRACT : Vehicle Sensor Initial Package Data Delivery Process
-* FUNCTION : Deliver the initial package data to the destination.
-* ARGUMENT : *pst_data :Data portion pointer of the message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensFirstPkgDelivery(const SENSOR_MSG_DELIVERY_ENTRY_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_get_method; /* Data collection way */
- int32 i; /* Generic counters */
- SENSOR_PKG_MSG_VSINFO st_pkg_master; /* Data master for package delivery */
- DID ul_pkg_did; /* DID for package data acquisition */
- u_int16 us_offset = 0; /* For offset calculation */
- u_int16 us_next_offset; /* Next offset value */
- u_int16 us_boundary_adj; /* For boundary adjustment */
- RET_API ret = RET_NORMAL; /* API return value */
- u_int8 uc_result = 0; /* Send/Receive result */
-
- (void)memset(reinterpret_cast<void *>(&st_pkg_master), 0, sizeof(SENSOR_PKG_MSG_VSINFO));
- /* For boundary adjustment */
- us_boundary_adj = (u_int16)VEHICLESENS_BIT1 | (u_int16)VEHICLESENS_BIT0;
- for (i = 0; i < pst_data->pkg_num; i++) {
- ul_pkg_did = pst_data->did[i]; /* Get DID */
- st_pkg_master.usOffset[i] = us_offset; /* Offset setting */
- /* Data collection way */
- uc_get_method = VehicleSensGetSelectionItemList(ul_pkg_did);
- if (VEHICLESENS_GETMETHOD_GPS == uc_get_method) {
- VehicleSensGetGpsDataMaster(ul_pkg_did,
- uc_get_method,
- reinterpret_cast<SENSOR_MSG_GPSDATA_DAT *>(&st_pkg_master.ucData[us_offset]));
- } else {
- VehicleSensGetDataMaster(ul_pkg_did,
- uc_get_method,
- reinterpret_cast<VEHICLESENS_DATA_MASTER *>(&st_pkg_master.ucData[us_offset]));
- }
- /* Next offset calculation */
- /* Boundary adjustment of data size */
- us_next_offset = VehicleSensGetDataMasterOffset(ul_pkg_did);
- if ((us_next_offset & us_boundary_adj) != 0) {
- /* If you need to adjust */
- us_next_offset = static_cast<u_int16>(us_next_offset & ~us_boundary_adj); /* Mask Lower Bit */
- us_next_offset = static_cast<u_int16>(us_next_offset + (u_int16)VEHICLESENS_BIT2); /* Add numbers */
- }
- us_offset = static_cast<u_int16>(us_offset + us_next_offset);
- }
-
- st_pkg_master.ucDNum = pst_data->pkg_num; /* To save the number of data */
- ret = PosSndMsg(PNO_VEHICLE_SENSOR,
- pst_data->pno,
- CID_SENSOR_PKG_INFO,
- (u_int16)sizeof(SENSOR_PKG_MSG_VSINFO),
- (const void *)&st_pkg_master);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS_PKG, 0, pst_data->pno,
- reinterpret_cast<uint8_t *>(&st_pkg_master),
- sizeof(SENSOR_PKG_MSG_VSINFO),
- uc_result);
-}
-// LCOV_EXCL_STOP
-
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensFirstPkgDeliveryExt
-* ABSTRACT : Vehicle Sensor Initial Expansion Package Data Delivery Process
-* FUNCTION : Deliver the initial expansion package data to the destination.
-* ARGUMENT : *pst_data :Data portion pointer of the message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensFirstPkgDeliveryExt(const SENSOR_MSG_DELIVERY_ENTRY_DAT *pst_data) {
- u_int8 ucGetMethod; /* Data collection way */
- int32 i; /* Generic counters */
- static SENSOR_PKG_MSG_VSINFO stPkgMaster; /* Data master for package delivery */
- DID ulPkgDid; /* DID for package data acquisition */
- u_int16 usOffset = 0; /* For offset calculation */
- u_int16 usNextOffset; /* Next offset value */
- u_int16 usBoundaryAdj; /* For boundary adjustment */
- static VEHICLESENS_DATA_MASTER_EXT stExtDataTemp[11];/* Extended data master temporary storage area */
- u_int16 usDataCnt[11] = {0}; /* For storing the number of data items */
- u_int8 ucDivideCnt; /* Total number of partitions */
- u_int8 ucDivide100Cnt = 0; /* Total number of 100 partitions */
- u_int8 ucDivideSendCnt; /* Number of divided transmissions */
- u_int16 usDivideSendSize[11] = {0}; /* Split Send Size */
- u_int16 ucDivideSendPoint; /* Split transmission data acquisition position */
- u_int8 ucDataBreak; /* Storage area of all data undelivered flag */
- RET_API ret = RET_NORMAL; /* API return value */
- u_int8 uc_result = 0; /* Send/Receive result */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* For boundary adjustment */
- usBoundaryAdj = (u_int16)VEHICLESENS_BIT1 | (u_int16)VEHICLESENS_BIT0;
- /* #Polaris_004 START */ /* Ignore->MISRA-C++:2008 Rule 2-7-2 */
- (void)memset(reinterpret_cast<void *>(&stExtDataTemp), 0, sizeof(stExtDataTemp));
- for (i = 0; i < pst_data->pkg_num; i++) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- ulPkgDid = pst_data->did[i]; /* Get DID */
- ucGetMethod = VehicleSensGetSelectionItemList(ulPkgDid); /* Data collection way */
- if (VEHICLESENS_GETMETHOD_GPS < ucGetMethod) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "VEHICLESENS_DELIVERYCTRL: VehicleSensGetSelectionItemList error :%d\r\n", ucGetMethod);
- }
-
- if ((ulPkgDid == POSHAL_DID_GYRO_EXT) ||
- (ulPkgDid == POSHAL_DID_GYRO_X) ||
- (ulPkgDid == POSHAL_DID_GYRO_Y) ||
- (ulPkgDid == POSHAL_DID_GYRO_Z) ||
- (ulPkgDid == POSHAL_DID_GSNS_X) ||
- (ulPkgDid == POSHAL_DID_GSNS_Y) ||
- (ulPkgDid == POSHAL_DID_GSNS_Z) ||
- (ulPkgDid == POSHAL_DID_SPEED_PULSE) ||
- (ulPkgDid == POSHAL_DID_REV) ||
- (ulPkgDid == POSHAL_DID_GYRO_TEMP) ||
- (ulPkgDid == POSHAL_DID_PULSE_TIME) ||
- (ulPkgDid == POSHAL_DID_SNS_COUNTER)) {
- /* Store in the extended data master information buffer */
- VehicleSensGetDataMasterExt(ulPkgDid, ucGetMethod, &stExtDataTemp[i]);
- /* Obtain the number of data items */
- if ((ulPkgDid == POSHAL_DID_SNS_COUNTER) ||
- (ulPkgDid == POSHAL_DID_REV)) {
- usDataCnt[i] = stExtDataTemp[i].us_size; /* 1data 1byte */
- /* Store the transmission size for 10 items */
- usDivideSendSize[i] = 10;
- } else if (ulPkgDid == POSHAL_DID_GYRO_TEMP) {
- usDataCnt[i] = stExtDataTemp[i].us_size / 2; /* 1data 2byte */
- /* Store the transmission size for 10 items */
- usDivideSendSize[i] = 20;
- }
- else if (ulPkgDid == POSHAL_DID_PULSE_TIME) { // NOLINT(readability/braces)
- usDataCnt[i] = stExtDataTemp[i].us_size / 132; /* 1data 132byte */
- /* Store the transmission size for 10 items */
- usDivideSendSize[i] = 1320;
- }
- else { // NOLINT(readability/braces)
- usDataCnt[i] = stExtDataTemp[i].us_size / 2; /* 1data 2byte Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Store the transmission size for 100 items */
- usDivideSendSize[i] = 200;
-
- // divide cnt is 100
- if (((usDataCnt[i] % VEHICLESENS_PKG_EXT_SEND_MAX_10DATA) > 0) || (usDataCnt[i] == 0)) {
- ucDivide100Cnt = static_cast<u_int8>((usDataCnt[i] / VEHICLESENS_PKG_EXT_SEND_MAX_10DATA) + 1);
- } else {
- ucDivide100Cnt = static_cast<u_int8>(usDataCnt[i] / VEHICLESENS_PKG_EXT_SEND_MAX_10DATA);
- }
- }
- }
- }
- /* All-data undelivered flag holding Ignore->MISRA-C ++: 2008 Rule 5-0-5 */
- ucDataBreak = static_cast<u_int8>(gstPkgTempExt.data_break);
-
- /* From the number of data items in the acquired buffer,Calculate the number of transmissions */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- if (((usDataCnt[0] % VEHICLESENS_PKG_EXT_SEND_MAX) > 0) || (usDataCnt[0] == 0)) {
- /* If there is a remainder,,Division result + 1 */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- ucDivideCnt = static_cast<u_int8>((usDataCnt[0] / VEHICLESENS_PKG_EXT_SEND_MAX) + 1);
- } else {
- /* If there is no remainder,,The result of division is the total number of transmissions. */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- ucDivideCnt = static_cast<u_int8>(usDataCnt[0] / VEHICLESENS_PKG_EXT_SEND_MAX);
- }
-
- // if ucDivide100cnt is valid (greater than 0)
- ucDivideCnt = (ucDivide100Cnt > 0) ? ucDivide100Cnt : ucDivideCnt;
-
- ucDivideSendCnt = 0; /* Number of divided transmissions */
- while (ucDivideSendCnt < ucDivideCnt) {
- /* Clear send message buffer */
- (void)memset(reinterpret_cast<void *>(&stPkgMaster), 0, sizeof(SENSOR_PKG_MSG_VSINFO));
- usOffset = 0;
- for (i = 0; i < pst_data->pkg_num; i++) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- ulPkgDid = pst_data->did[i]; /* Get DID */
- stPkgMaster.usOffset[i] = usOffset; /* Offset setting */
- /* copy Data ID of extended data master structure,Size of the data,Receive flag,Reserved */
- memcpy(reinterpret_cast<void *>(&stPkgMaster.ucData[usOffset]),
- reinterpret_cast<void *>(&stExtDataTemp[i]), 11);
- if ((ulPkgDid == POSHAL_DID_SNS_COUNTER) ||
- (ulPkgDid == POSHAL_DID_REV) ||
- (ulPkgDid == POSHAL_DID_PULSE_TIME) ||
- (ulPkgDid == POSHAL_DID_GYRO_TEMP)) {
- if (usDataCnt[i] > VEHICLESENS_PKG_EXT_SEND_MAX) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Calculate the data acquisition position */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- ucDivideSendPoint = static_cast<u_int16>((u_int16)ucDivideSendCnt * usDivideSendSize[i]);
- /* Update the data size*/
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- stPkgMaster.ucData[usOffset + 4] = (u_int8)usDivideSendSize[i];
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- stPkgMaster.ucData[usOffset + 5] = (u_int8)(usDivideSendSize[i] >> 8);
- /* Create 10 divided transmission data of sensor counters of extended data master structure */
- memcpy(reinterpret_cast<void *>(&stPkgMaster.ucData[usOffset + 8]),
- reinterpret_cast<void *>(&stExtDataTemp[i].uc_data[ucDivideSendPoint]),
- usDivideSendSize[i]); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Subtract the number of created transmission data */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- usDataCnt[i] = static_cast<u_int16>(usDataCnt[i] - VEHICLESENS_PKG_EXT_SEND_MAX);
- } else {
- /* Calculate the data acquisition position */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- ucDivideSendPoint = static_cast<u_int16>((u_int16)ucDivideSendCnt * usDivideSendSize[i]);
- /* Update the data size*/
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- stPkgMaster.ucData[usOffset + 4] = (u_int8)(stExtDataTemp[i].us_size - (u_int16)ucDivideSendPoint);
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 Ignore->MISRA-C++:2008 Rule 5-0-21 */
- stPkgMaster.ucData[usOffset + 5] = \
- (u_int8)((stExtDataTemp[i].us_size - (u_int16)ucDivideSendPoint) >> 8);
- /* Create the remaining divided send data of sensor counter of extended data master structure */
- memcpy(reinterpret_cast<void *>(&stPkgMaster.ucData[usOffset + 8]),
- reinterpret_cast<void *>(&stExtDataTemp[i].uc_data[ucDivideSendPoint]),
- stExtDataTemp[i].us_size - ucDivideSendPoint); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Since all buffers have been created, the number of data is set to 0. */
- usDataCnt[i] = 0;
- }
- } else {
- if (usDataCnt[i] > VEHICLESENS_PKG_EXT_SEND_MAX_10DATA) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Calculate the data acquisition position */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- ucDivideSendPoint = static_cast<u_int16>((u_int16)ucDivideSendCnt * usDivideSendSize[i]);
- /* Update the data size*/
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- stPkgMaster.ucData[usOffset + 4] = (u_int8)usDivideSendSize[i];
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- stPkgMaster.ucData[usOffset + 5] = (u_int8)(usDivideSendSize[i] >> 8);
- /* Create 100 divided transmission data of vehicle sensor data of extended data master structure */
- memcpy(reinterpret_cast<void *>(&stPkgMaster.ucData[usOffset + 8]),
- reinterpret_cast<void *>(&stExtDataTemp[i].uc_data[ucDivideSendPoint]),
- usDivideSendSize[i]); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Subtract the number of created transmission data */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- usDataCnt[i] = static_cast<u_int16>(usDataCnt[i] - VEHICLESENS_PKG_EXT_SEND_MAX_10DATA);
- } else {
- /* Calculate the data acquisition position */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- ucDivideSendPoint = static_cast<u_int16>((u_int16)ucDivideSendCnt * usDivideSendSize[i]);
- /* Update the data size*/
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- stPkgMaster.ucData[usOffset + 4] = \
- (u_int8)(stExtDataTemp[i].us_size - (u_int16)ucDivideSendPoint);
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 Ignore->MISRA-C++:2008 Rule 5-0-21 */
- stPkgMaster.ucData[usOffset + 5] = \
- (u_int8)((stExtDataTemp[i].us_size - (u_int16)ucDivideSendPoint) >> 8);
- /* Create the remaining divided transmission data of the vehicle sensor data of the extended data master structure. */
- memcpy(reinterpret_cast<void *>(&stPkgMaster.ucData[usOffset + 8]),
- reinterpret_cast<void *>(&stExtDataTemp[i].uc_data[ucDivideSendPoint]),
- stExtDataTemp[i].us_size - ucDivideSendPoint); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Since all buffers have been created, the number of data is set to 0. */
- usDataCnt[i] = 0;
- }
- }
- /* Next offset calculation */
- /* Boundary adjustment of data size */
- usNextOffset = VehicleSensGetDataMasterExtOffset(ulPkgDid);
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 Ignore->MISRA-C++:2008 Rule 5-0-13, 5-0-14, 5-3-1 */
- if ((usNextOffset & usBoundaryAdj) != 0) {
- /* If you need to adjust */
- /* Mask Lower Bit Ignore->MISRA-C++:2008 Rule 5-0-5 Ignore->MISRA-C++:2008 Rule 5-0-21 */
- usNextOffset = static_cast<u_int16>(usNextOffset & ~usBoundaryAdj);
- usNextOffset = static_cast<u_int16>(usNextOffset + (u_int16)VEHICLESENS_BIT2); /* Add numbers */
- }
- usOffset = static_cast<u_int16>(usOffset + usNextOffset); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- }
- stPkgMaster.ucDNum = pst_data->pkg_num; /* To save the number of data */
- stPkgMaster.ucDataBreak = ucDataBreak; /* Set all data undelivered flag */
- stPkgMaster.ucDivideCnt = ucDivideCnt; /* Set total number of partitions */
- /* Division number setting Ignore->MISRA-C++:2008 Rule 5-0-5 */
- stPkgMaster.ucDivideSendCnt = static_cast<uint8_t>(ucDivideSendCnt + 1);
- ret = PosSndMsg(PNO_VEHICLE_SENSOR,
- pst_data->pno,
- CID_SENSOR_PKG_INFO,
- (u_int16)sizeof(SENSOR_PKG_MSG_VSINFO),
- (const void *)&stPkgMaster);
- uc_result = SENSLOG_RES_SUCCESS;
- if (ret != RET_NORMAL) {
- uc_result = SENSLOG_RES_FAIL;
- }
- SensLogWriteOutputData(SENSLOG_DATA_O_SYS_PKG, 0, pst_data->pno,
- reinterpret_cast<uint8_t *>(&stPkgMaster),
- sizeof(SENSOR_PKG_MSG_VSINFO), uc_result);
-
- ucDivideSendCnt++;
-
- /* Package delivery (split) confirmation debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__,
- "### SENS RECV # FST PKG DELIVERY : cnt[%d/7]", ucDivideSendCnt);
- if (7 <= ucDivideSendCnt) {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__,
- "### SENS RECV # FST PKG DELIVERY : last sns_cnt[%d][%d][%d][%d]",
- stPkgMaster.ucData[8], stPkgMaster.ucData[9], stPkgMaster.ucData[10], stPkgMaster.ucData[11]);
- }
- }
- /* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "-");
-}
-#endif
-
-/* ++ PastModel002 response DR */
-
-/*******************************************************************************
- * MODULE : VehicleSensEntryDeliveryCtrlDR
- * ABSTRACT : Internal delivery destination management registration function for vehicle sensor DR
- * FUNCTION : Internal distribution destination management table for DR,Update the shipping management table management.
- * ARGUMENT : pst_delivery_entry : Pointer to the delivery registration information
- * NOTE :
- * RETURN : VEHICLE_RET_NORMAL :Successful registration
- ******************************************************************************/
-VEHICLE_RET_API VehicleSensEntryDeliveryCtrlDR(const DEADRECKONING_MSG_DELIVERY_ENTRY *pst_delivery_entry) { // LCOV_EXCL_START 8 : dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- int32 i;
- u_int8 uc_action_type = VEHICLESENS_ACTION_TYPE_ADD;
- int32 uc_did_flag;
- DID ulentry_did = pst_delivery_entry->data.did;
- VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *pst_existing_mng_data = NULL;
- VEHICLE_RET_API ret = VEHICLE_RET_NORMAL; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
-
- /* Check if the data ID exists. */
- uc_did_flag = VehicleSensCheckDid(ulentry_did);
- if (uc_did_flag == 0) {
- ret = VEHICLE_RET_ERROR_DID; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- }
-
- /* Check the number of registered shipments. */
- if ((ret == VEHICLE_RET_NORMAL) &&/* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- (g_stdelivery_ctrl_tbl_dr.us_dnum >= VEHICLESENS_DELIVERY_INFO_MAX)) {
- /* Return the FULL of delivery registrations*/
- ret = VEHICLE_RET_ERROR_BUFFULL; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- }
-
- if (ret == VEHICLE_RET_NORMAL) { /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
- /* By searching for the delivery registration of the relevant DID,Hold the address. */
- for (i = 0; i < g_stdelivery_ctrl_tbl_mng_dr.us_dnum; i++) {
- if (g_stdelivery_ctrl_tbl_mng_dr.st_ctrl_tbl_mng_data[i].ul_did == ulentry_did) {
- uc_action_type = VEHICLESENS_ACTION_TYPE_UPDATE;
- pst_existing_mng_data = &g_stdelivery_ctrl_tbl_mng_dr.st_ctrl_tbl_mng_data[i];
- }
- }
-
- /* Add to the shipping management table.*/
- VehicleSensAddDeliveryCtrlTblDR(pst_delivery_entry);
- /* Processing when updating existing data*/
- if (uc_action_type == VEHICLESENS_ACTION_TYPE_UPDATE) {
- /* Update the shipping management table.*/
- VehicleSensUpdateDeliveryCtrlTblDR(pst_existing_mng_data);
-
- /* Update the shipping destination management table management information.*/
- VehicleSensUpdateDeliveryCtrlTblMngDR(pst_existing_mng_data);
- } else { /* Newly added processing*/
- /* Add to the shipping management table management information.*/
- VehicleSensAddDeliveryCtrlTblMngDR(pst_delivery_entry);
- }
- }
- return ret; /* _CWORD71_:QAC++4020:Multiple exit points found. MISRA-C++ Rule 6-6-5 */
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensMakeDeliveryPnoTblDR
-* ABSTRACT : Vehicle sensor internal delivery destination PNO table creation function for DR
-* FUNCTION : Create an internal delivery destination PNO table for DR
-* ARGUMENT : ul_did Data ID
-* Change_type Delivery Trigger
-* NOTE :
-* RETURN : VEHICLESENS_DELIVERY_PNO_TBL* Pointer to the shipping PNO table
-******************************************************************************/
-VEHICLESENS_DELIVERY_PNO_TBL* VehicleSensMakeDeliveryPnoTblDR(DID ul_did, u_int8 change_type) { // LCOV_EXCL_START 8 : dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- int32 i;
- u_int8 uc_ctrl_tbl_mng_data_list;
- u_int16 us_index = 0;
- u_int16 us_dnum = 0;
-
- /* Get the start index and count of the corresponding data ID. */
- uc_ctrl_tbl_mng_data_list = static_cast<u_int8>(
- (sizeof(g_stdelivery_ctrl_tbl_mng_dr.st_ctrl_tbl_mng_data)) /
- (sizeof(g_stdelivery_ctrl_tbl_mng_dr.st_ctrl_tbl_mng_data[0])));
-
- for (i = 0; i < uc_ctrl_tbl_mng_data_list; i++) {
- /* Stores the information of the corresponding DID.. */
- if (g_stdelivery_ctrl_tbl_mng_dr.st_ctrl_tbl_mng_data[i].ul_did == ul_did) {
- us_index = g_stdelivery_ctrl_tbl_mng_dr.st_ctrl_tbl_mng_data[i].us_start_idx;
- us_dnum = g_stdelivery_ctrl_tbl_mng_dr.st_ctrl_tbl_mng_data[i].usdlvry_entry_num;
- break;
- }
- }
-
- /* Create a PNO list */
- (void)memset(reinterpret_cast<void *>(&g_stdelivery_pno_tbl_dr),
- static_cast<int32>(0),
- (size_t)sizeof(g_stdelivery_pno_tbl_dr));
- if (change_type == VEHICLESENS_CHGTYPE_CHG) {
- /* Processing when delivery timing is changed*/
- for (i = 0; i < us_dnum; i++) {
- /* Functionalization by Increasing Structure Members */
- VehicleSensAddPnoTblDR(us_index);
- us_index = g_stdelivery_ctrl_tbl_dr.st_ctrl_data[us_index].us_link_idx;
- }
- } else {
- /* Processing when delivery timing is update */
- for (i = 0; i < us_dnum; i++) {
- if (VEHICLE_DELIVERY_TIMING_UPDATE == g_stdelivery_ctrl_tbl_dr.st_ctrl_data[us_index].uc_chg_type) {
- /* Functionalization by Increasing Structure Members */
- VehicleSensAddPnoTblDR(us_index);
- }
- us_index = g_stdelivery_ctrl_tbl_dr.st_ctrl_data[us_index].us_link_idx;
- }
- }
-
- return(&g_stdelivery_pno_tbl_dr);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensAddPnoTblDR
-* ABSTRACT : Vehicle sensor DR internal delivery destination PNO table addition function
-* FUNCTION : Add to the internal DR shipping destination PNO table.
-* ARGUMENT : us_index : Index of the referenced destination management table
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensAddPnoTblDR(u_int16 us_index) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int16 us_pno_tbl_idx;
-
- us_pno_tbl_idx = g_stdelivery_pno_tbl_dr.us_dnum;
- g_stdelivery_pno_tbl_dr.st_pno_data[us_pno_tbl_idx].us_pno = \
- g_stdelivery_ctrl_tbl_dr.st_ctrl_data[us_index].us_pno;
- g_stdelivery_pno_tbl_dr.st_pno_data[us_pno_tbl_idx].us_pkg_start_idx = \
- g_stdelivery_ctrl_tbl_dr.st_ctrl_data[us_index].us_pkg_start_idx;
- g_stdelivery_pno_tbl_dr.st_pno_data[us_pno_tbl_idx].us_pkg_end_idx = \
- g_stdelivery_ctrl_tbl_dr.st_ctrl_data[us_index].us_pkg_end_idx;
- g_stdelivery_pno_tbl_dr.st_pno_data[us_pno_tbl_idx].uc_method = \
- g_stdelivery_ctrl_tbl_dr.st_ctrl_data[us_index].uc_method;
- g_stdelivery_pno_tbl_dr.us_dnum++;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensAddDeliveryCtrlTblDR
-* ABSTRACT : Vehicle sensor DR internal delivery destination management table addition function
-* FUNCTION : Add to the DR internal shipping management table.
-* ARGUMENT : *pst_delivery_entry : Pointer to the delivery registration information
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensAddDeliveryCtrlTblDR(const DEADRECKONING_MSG_DELIVERY_ENTRY *pst_delivery_entry) { // LCOV_EXCL_START 8: dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VEHICLESENS_DELIVERY_CTRL_TBL_DATA *pst_ctrl_data;
-
- pst_ctrl_data = &g_stdelivery_ctrl_tbl_dr.st_ctrl_data[g_stdelivery_ctrl_tbl_dr.us_dnum];
- pst_ctrl_data->ul_did = pst_delivery_entry->data.did;
- pst_ctrl_data->us_pno = pst_delivery_entry->data.pno;
- pst_ctrl_data->uc_chg_type = pst_delivery_entry->data.delivery_timing;
- pst_ctrl_data->uc_ctrl_flg = pst_delivery_entry->data.ctrl_flg;
- pst_ctrl_data->us_link_idx = VEHICLESENS_LINK_INDEX_END;
- pst_ctrl_data->us_pkg_start_idx = VEHICLESENS_LINK_INDEX_END;
- pst_ctrl_data->us_pkg_end_idx = VEHICLESENS_LINK_INDEX_END;
- pst_ctrl_data->uc_method = VEHICLESENS_DELIVERY_METHOD_NORMAL;
- g_stdelivery_ctrl_tbl_dr.us_dnum = static_cast<u_int16>(g_stdelivery_ctrl_tbl_dr.us_dnum + 1);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensAddDeliveryCtrlTblMngDR
-* ABSTRACT : Internal delivery destination management table management addition function for vehicle sensor DR
-* FUNCTION : Add to the DR internal shipping management table management.
-* ARGUMENT : *pst_delivery_entry : Pointer to the delivery registration information
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensAddDeliveryCtrlTblMngDR(const DEADRECKONING_MSG_DELIVERY_ENTRY *pst_delivery_entry) { // LCOV_EXCL_START 8: dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *pst_ctrl_mng_data;
-
- pst_ctrl_mng_data = &g_stdelivery_ctrl_tbl_mng_dr.st_ctrl_tbl_mng_data[g_stdelivery_ctrl_tbl_mng_dr.us_dnum];
- pst_ctrl_mng_data->ul_did = pst_delivery_entry->data.did;
- pst_ctrl_mng_data->us_start_idx = static_cast<u_int16>(g_stdelivery_ctrl_tbl_dr.us_dnum - 1);
- pst_ctrl_mng_data->us_end_idx = static_cast<u_int16>(g_stdelivery_ctrl_tbl_dr.us_dnum - 1);
- pst_ctrl_mng_data->usdlvry_entry_num++;
- g_stdelivery_ctrl_tbl_mng_dr.us_dnum++;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
- * MODULE : VehicleSensUpdateDeliveryCtrlTblMngDR
- * ABSTRACT : Internal delivery destination management table management update function for vehicle sensor DR
- * FUNCTION : Update the internal delivery destination management table management for DR.
- * ARGUMENT : *pst_existing_mng_data : Pointer to the previous data information with the same data ID
- * NOTE :
- * RETURN : void
- ******************************************************************************/
-void VehicleSensUpdateDeliveryCtrlTblMngDR(VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *pst_existing_mng_data) { // LCOV_EXCL_START 8: dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Update only the end index and the number of registered shipping destinations. */
- pst_existing_mng_data->us_end_idx = static_cast<u_int16>(g_stdelivery_ctrl_tbl_dr.us_dnum - 1);
- pst_existing_mng_data->usdlvry_entry_num++;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensUpdateDeliveryCtrlTblDR
-* ABSTRACT : Vehicle sensor DR internal delivery destination management table update function
-* FUNCTION : Update the internal distribution destination management table for DR.
-* ARGUMENT : *pst_existing_mng_data : Pointer to the previous data information with the same data ID
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensUpdateDeliveryCtrlTblDR(VEHICLESENS_DELIVERY_CTRL_TBL_MNG_DATA *pst_existing_mng_data) { // LCOV_EXCL_START 8: dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Update Link Index Only.
- For indexes of usEndIdx values matching the data IDs in the target management table
- Making usLinkIdx an Index-Registered Index */
- g_stdelivery_ctrl_tbl_dr.st_ctrl_data[pst_existing_mng_data->us_end_idx].us_link_idx =
- static_cast<u_int16>(g_stdelivery_ctrl_tbl_dr.us_dnum - 1);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
- * MODULE : VehicleSensDeliveryProcDR
- * ABSTRACT : Internal Data Delivery Process for Vehicle Sensor DR
- * FUNCTION : Deliver data to internal DR destinations.
- * ARGUMENT : ul_did :Data ID
- * uc_chg_type :Delivery timing
- * uc_get_method :Acquisition method
- * NOTE :
- * RETURN : void
- ******************************************************************************/
-void VehicleSensDeliveryProcDR(DID ul_did, u_int8 uc_chg_type, u_int8 uc_get_method) {
- return;
-}
-
-/**
- * @brief
- * Obtain dump info(g_stdelivery_ctrl_tbl)
- *
- * @param[out] pbuf Dump information
- */
-void VehicleSensGetDebugDeliveryCtrlTbl(void* pbuf) { // LCOV_EXCL_START 7: uesd only in FrameworkunifiedOnDebugDump
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static uint8_t buf[DEBUG_DUMP_MAX_SIZE];
- static uint8_t bufTmp[256];
- u_int16 i;
-
- memset(&buf, 0x00, sizeof(buf));
- snprintf(reinterpret_cast<char *>(&(buf)),
- 32,
- "Delivery-Tbl\n DNum:%d", g_stdelivery_ctrl_tbl.us_dnum);
- for (i = 0; i < g_stdelivery_ctrl_tbl.us_dnum; i++) {
- if (i >= 30) {
- break;
- }
- memset(&bufTmp[0], 0x00, sizeof(bufTmp));
- snprintf(reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp),
- "\n [%02d] did:0x%08x, pno:0x%04x, chgT:0x%02x, ctrlFg:0x%02x, "\
- "lnkidx:0x%04x, pkgSidx:0x%04x, pkgEidx:0x%04x, Mth:0x%02x",
- i,
- g_stdelivery_ctrl_tbl.st_ctrl_data[i].ul_did,
- g_stdelivery_ctrl_tbl.st_ctrl_data[i].us_pno,
- g_stdelivery_ctrl_tbl.st_ctrl_data[i].uc_chg_type,
- g_stdelivery_ctrl_tbl.st_ctrl_data[i].uc_ctrl_flg,
- g_stdelivery_ctrl_tbl.st_ctrl_data[i].us_link_idx,
- g_stdelivery_ctrl_tbl.st_ctrl_data[i].us_pkg_start_idx,
- g_stdelivery_ctrl_tbl.st_ctrl_data[i].us_pkg_end_idx,
- g_stdelivery_ctrl_tbl.st_ctrl_data[i].uc_method);
- _pb_strcat(reinterpret_cast<char *>(&buf[0]), reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp));
- }
- memcpy(pbuf, &buf[0], sizeof(buf));
- return;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Obtain dump info(g_stdelivery_ctrl_tbl_mng)
- *
- * @param[out] pbuf Dump information
- */
-void VehicleSensGetDebugDeliveryCtrlTblMng(void* pbuf) { // LCOV_EXCL_START 7: uesd only in FrameworkunifiedOnDebugDump
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static uint8_t buf[DEBUG_DUMP_MAX_SIZE];
- static uint8_t bufTmp[256];
- u_int16 i;
-
- memset(&buf, 0x00, sizeof(buf));
- snprintf(reinterpret_cast<char *>(&(buf)),
- 32,
- "Delivery-TblMng\n DNum:%d",
- g_stdelivery_ctrl_tbl_mng.us_dnum);
- for (i = 0; i < g_stdelivery_ctrl_tbl_mng.us_dnum; i++) {
- if (i >= 60) {
- break;
- }
- memset(&bufTmp[0], 0x00, sizeof(bufTmp));
- snprintf(reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp),
- "\n [%02d] did:0x%08x, Sidx:0x%04x, Eidx:0x%04x, EntNum:0x%04x",
- i,
- g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i].ul_did,
- g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i].us_start_idx,
- g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i].us_end_idx,
- g_stdelivery_ctrl_tbl_mng.st_ctrl_tbl_mng_data[i].usdlvry_entry_num);
- _pb_strcat(reinterpret_cast<char *>(&buf[0]), reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp));
- }
- memcpy(pbuf, &buf[0], sizeof(buf));
- return;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Obtain dump info(g_stpkgdelivery_tbl_mng)
- *
- * @param[out] pbuf Dump information
- */
-void VehicleSensGetDebugPkgDeliveryTblMng(void* pbuf) { // LCOV_EXCL_START 7: uesd only in FrameworkunifiedOnDebugDump
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static uint8_t buf[DEBUG_DUMP_MAX_SIZE];
- static uint8_t bufTmp[256];
- u_int16 i;
-
- memset(&buf, 0x00, sizeof(buf));
- snprintf(reinterpret_cast<char *>(&(buf)),
- 32,
- "Delivery-PkgTblMng\n DNum:%d",
- g_stpkgdelivery_tbl_mng.us_dnum);
- for (i = 0; i < g_stpkgdelivery_tbl_mng.us_dnum; i++) {
- if (i >= 100) {
- break;
- }
- memset(&bufTmp[0], 0x00, sizeof(bufTmp));
- snprintf(reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp),
- "\n [%02d] did:0x%08x, Didx:0x%04x",
- i,
- g_stpkgdelivery_tbl_mng.st_pkg_data[i].ul_did,
- g_stpkgdelivery_tbl_mng.st_pkg_data[i].usdlvry_idx);
- _pb_strcat(reinterpret_cast<char *>(&buf[0]), reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp));
- }
- memcpy(pbuf, &buf[0], sizeof(buf));
- return;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Obtain dump info(g_stdelivery_pno_tbl)
- *
- * @param[out] pbuf Dump information
- */
-void VehicleSensGetDebugDeliveryPnoTbl(void* pbuf) { // LCOV_EXCL_START 7: uesd only in FrameworkunifiedOnDebugDump
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static uint8_t buf[DEBUG_DUMP_MAX_SIZE];
- static uint8_t bufTmp[256];
- u_int16 i;
-
- memset(&buf, 0x00, sizeof(buf));
- snprintf(reinterpret_cast<char *>(&(buf)),
- 32,
- "Delivery-PnoTbl\n DNum:%d",
- g_stdelivery_pno_tbl.us_dnum);
- for (i = 0; i < g_stdelivery_pno_tbl.us_dnum; i++) {
- if (i >= 60) {
- break;
- }
- memset(&bufTmp[0], 0x00, sizeof(bufTmp));
- snprintf(reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp),
- "\n [%02d] pno:0x%04x, pkgSidx:0x%04x, pkgEidx:0x%04x, Mth:0x%02x",
- i,
- g_stdelivery_pno_tbl.st_pno_data[i].us_pno,
- g_stdelivery_pno_tbl.st_pno_data[i].us_pkg_start_idx,
- g_stdelivery_pno_tbl.st_pno_data[i].us_pkg_end_idx,
- g_stdelivery_pno_tbl.st_pno_data[i].uc_method);
- _pb_strcat(reinterpret_cast<char *>(&buf[0]), reinterpret_cast<char *>(&bufTmp[0]), sizeof(bufTmp));
- }
- memcpy(pbuf, &buf[0], sizeof(buf));
- return;
-}
-// LCOV_EXCL_STOP
-/* -- PastModel002 support DR */
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GPSInterruptFlag.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GPSInterruptFlag.cpp
deleted file mode 100755
index eefbc51..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GPSInterruptFlag.cpp
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_GPSInterruptFlag.cpp
-@detail Master vehicle sensor data(VEHICLE_DID_GPS_INTERRUPT_FLAG)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstGpsInterruptFlag; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief VehicleSensInitGpsInterruptFlag<BR>
- Vehicle sensor SPEED_PULSE initialization function
-@outline SPEED_PULSE_FLAG initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitGpsInterruptFlag(void) {
- memset(&gstGpsInterruptFlag, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstGpsInterruptFlag.ul_did = POSHAL_DID_GPS_INTERRUPT_FLAG;
- gstGpsInterruptFlag.us_size = VEHICLE_DSIZE_GPS_INTERRUPT_FLAG;
-
- gstGpsInterruptFlag.uc_data[0] = VEHICLE_DINIT_GPS_INTERRUPT_FLAG;
-}
-
-/***************************************************************************
-@brief NAV-CLOCK SET vehicle sensor function
-@outline To update the master data NAV-CLOCK.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetGpsInterruptFlag(const LSDRV_LSDATA_G *pst_data) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGpsInterruptFlag;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function NAV-CLOCK GET
-@outline Master Data provides the NAV-CLOCK
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetGpsInterruptFlag(VEHICLESENS_DATA_MASTER *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER *pst_masterdata;
-
- pst_masterdata = &gstGpsInterruptFlag;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_masterdata->ul_did;
- pst_data->us_size = pst_masterdata->us_size;
- pst_data->uc_rcvflag = pst_masterdata->uc_rcvflag;
- pst_data->uc_snscnt = pst_masterdata->uc_snscnt;
- (void)memcpy(reinterpret_cast<void *>(pst_data->uc_data),
- (const void *)(pst_masterdata->uc_data), (size_t)(pst_masterdata->us_size));
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntenna.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntenna.cpp
deleted file mode 100755
index bbf4965..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntenna.cpp
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GpsAntenna.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GPS_ANTENNA)
- * Module configuration :VehicleSensGetGpsAntenna() Vehicle Sensor GPS_ANTENNA GET Function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGpsAntenna
-* ABSTRACT : Vehicle sensor GPS_ANTENNA GET function
-* FUNCTION : Provide the GPS_ANTENNA data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGpsAntenna(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGpsAntennal(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntennaStatus.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntennaStatus.cpp
deleted file mode 100755
index dc950cc..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntennaStatus.cpp
+++ /dev/null
@@ -1,112 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GpsAntennaStatus.cpp
- * System name :PastModel002
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GPS_ANTENNA)
- * Module configuration :VehicleSensInitGpsAntennaStatus() Vehicle sensor GPS_ANTENNA_STATUS initialization function
- * :VehicleSensSetGpsAntennaStatus() Vehicle sensor GPS_ANTENNA_STATUS SET function
- * :VehicleSensGetGpsAntennaStatus() Vehicle sensor GPS_ANTENNA_STATUS GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_ANTENNA_STATUS gstGpsAntennaStatus; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGpsAntennaStatus
-* ABSTRACT : Vehicle sensor GPS_ANTENNA_STATUS initialization function
-* FUNCTION : GPS_ANTENNA_STATUS data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGpsAntennaStatus(void) {
- (void)memset(reinterpret_cast<void *>(&gstGpsAntennaStatus), 0, sizeof(gstGpsAntennaStatus));
- gstGpsAntennaStatus.ul_did = POSHAL_DID_GPS_ANTENNA;
- gstGpsAntennaStatus.us_size = VEHICLE_DSIZE_GPS_ANTENNA;
- gstGpsAntennaStatus.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
- gstGpsAntennaStatus.uc_sensor_cnt = 0U;
- gstGpsAntennaStatus.uc_data = VEHICLE_DINIT_GPS_ANTENNA;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGpsAntennaStatus
-* ABSTRACT : Vehicle sensor GPS_ANTENNA_STATUS SET function
-* FUNCTION : Update the GPS_ANTENNA_STATUS data master
-* ARGUMENT : *pst_data : Pointer to received message data
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* : VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGpsAntennaStatus(const LSDRV_MSG_LSDATA_DAT_GPS_ANTENNA_STATUS *pst_data) { // LCOV_EXCL_START 8: dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_GPS_ANTENNA_STATUS *pst_master;
-
- if (pst_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "pst_data == NULL\r\n");
- } else {
- pst_master = &gstGpsAntennaStatus;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(reinterpret_cast<void *>(&(pst_master->uc_data)),
- (const void *)(&(pst_data->uc_data)), (size_t)(pst_data->uc_size));
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = (u_int16)pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_sensor_cnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(&(pst_master->uc_data)),
- (const void *)(&(pst_data->uc_data)), sizeof(pst_master->uc_data));
- }
- return(uc_ret);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGpsAntennaStatus
-* ABSTRACT : Vehicle sensor GPS_ANTENNA_STATUS GET function
-* FUNCTION : Provide the GPS_ANTENNA_STATUS data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGpsAntennaStatus(VEHICLESENS_DATA_MASTER_GPS_ANTENNA_STATUS *pst_data) { // LCOV_EXCL_START 8: dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_ANTENNA_STATUS *pst_master;
- if (pst_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "pst_data == NULL\r\n");
- } else {
- pst_master = &gstGpsAntennaStatus;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->uc_sensor_cnt = pst_master->uc_sensor_cnt;
- (void)memcpy(reinterpret_cast<void *>(&(pst_data->uc_data)),
- (const void *)(&(pst_master->uc_data)), sizeof(pst_data->uc_data));
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntenna_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntenna_l.cpp
deleted file mode 100755
index 00db159..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsAntenna_l.cpp
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GpsAntenna_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GPS_ANTENNA)
- * Module configuration :VehicleSensInitGpsAntennal() Vehicle sensor GPS_ANTENNA initialization function
- * :VehicleSensSetGpsAntennal() Vehicle Sensor GPS_ANTENNA SET Function
- * :VehicleSensGetGpsAntennal() Vehicle Sensor GPS_ANTENNA GET Function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstGpsAntenna_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGpsAntennal
-* ABSTRACT : Vehicle sensor GPS_ANTENNA initialization function
-* FUNCTION : GPS_ANTENNA data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGpsAntennal(void) {
- memset(&gstGpsAntenna_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstGpsAntenna_l.ul_did = POSHAL_DID_GPS_ANTENNA;
- gstGpsAntenna_l.us_size = VEHICLE_DSIZE_GPS_ANTENNA;
- gstGpsAntenna_l.uc_data[0] = VEHICLE_DINIT_GPS_ANTENNA;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGpsAntennal
-* ABSTRACT : Vehicle Sensor GPS_ANTENNA SET Function
-* FUNCTION : Update the GPS_ANTENNA data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGpsAntennal(const LSDRV_LSDATA *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGpsAntenna_l;
-
- /* Compare data master and received data */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size; /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGpsAntennal
-* ABSTRACT : Vehicle Sensor GPS_ANTENNA GET Function
-* FUNCTION : Provide the GPS_ANTENNA data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGpsAntennal(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGpsAntenna_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockDrift.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockDrift.cpp
deleted file mode 100755
index 955e161..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockDrift.cpp
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GpsClockDrift.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * GPS clock drift data master GET processing
- *
- * @param[out] SENSOR_MSG_GPSDATA_DAT*
- * @param[in] u_int8
- */
-void VehicleSensGetGpsClockDrift(SENSOR_MSG_GPSDATA_DAT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) {
- case VEHICLESENS_GETMETHOD_GPS:
- {
- /** To acquire from GPS */
- VehicleSensGetGpsClockDriftG(pst_data);
- break;
- }
-
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockDrift_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockDrift_g.cpp
deleted file mode 100755
index ecfbb4f..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockDrift_g.cpp
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GpsClockDrift_g.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gGpsClockDrift_g; // NOLINT(readability/nolint)
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * GPS clock drift data master initialization process
- */
-void VehicleSensInitGpsClockDriftG(void) {
- int32_t l_gps_clock_drift;
-
- memset(&gGpsClockDrift_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gGpsClockDrift_g.ul_did = POSHAL_DID_GPS_CLOCK_DRIFT;
- /** Data size setting */
- gGpsClockDrift_g.us_size = sizeof(int32_t);
- /** Data content setting */
- l_gps_clock_drift = 0xFFFFFFFF;
- memcpy(&gGpsClockDrift_g.uc_data[0], &l_gps_clock_drift, sizeof(l_gps_clock_drift));
-
- return;
-}
-
-/**
- * @brief
- * GPS clock drift data master SET process
- *
- * @param[in] int32_t*
- *
- * @return u_int8
- */
-u_int8 VehicleSensSetGpsClockDriftG(const int32_t *p_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gGpsClockDrift_g;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, p_data, sizeof(int32_t));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = POSHAL_DID_GPS_CLOCK_DRIFT;
- pst_master->us_size = sizeof(int32_t);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, p_data, sizeof(int32_t));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * GPS clock drift data master GET processing
- *
- * @param[out] SENSOR_MSG_GPSDATA_DAT*
- */
-void VehicleSensGetGpsClockDriftG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gGpsClockDrift_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockFreq.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockFreq.cpp
deleted file mode 100755
index 39fac42..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockFreq.cpp
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GpsClockFreq.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * GPS clock frequency data master GET processing
- *
- * @param[out] SENSOR_MSG_GPSDATA_DAT*
- * @param[in] u_int8
- */
-void VehicleSensGetGpsClockFreq(SENSOR_MSG_GPSDATA_DAT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) {
- case VEHICLESENS_GETMETHOD_GPS:
- {
- /** To acquire from GPS */
- VehicleSensGetGpsClockFreqG(pst_data);
- break;
- }
-
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockFreq_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockFreq_g.cpp
deleted file mode 100755
index 85cbdd6..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsClockFreq_g.cpp
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GpsClockFreq_g.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gGpsClockFreq_g; // NOLINT(readability/nolint)
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Initialization of GPS clock frequency data master
- */
-void VehicleSensInitGpsClockFreqG(void) {
- uint32_t ul_gps_clock_freq;
-
- memset(&gGpsClockFreq_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gGpsClockFreq_g.ul_did = POSHAL_DID_GPS_CLOCK_FREQ;
- /** Data size setting */
- gGpsClockFreq_g.us_size = sizeof(uint32_t);
- /** Data content setting */
- ul_gps_clock_freq = 0xFFFFFFFF;
- memcpy(&gGpsClockFreq_g.uc_data[0], &ul_gps_clock_freq, sizeof(ul_gps_clock_freq));
-
- return;
-}
-
-/**
- * @brief
- * GPS clock frequency data master SET process
- *
- * @param[in] uint32_t*
- *
- * @return u_int8
- */
-u_int8 VehicleSensSetGpsClockFreqG(const uint32_t *p_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gGpsClockFreq_g;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, p_data, sizeof(uint32_t));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = POSHAL_DID_GPS_CLOCK_FREQ;
- pst_master->us_size = sizeof(uint32_t);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, p_data, sizeof(uint32_t));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * GPS clock frequency data master GET processing
- *
- * @param[out] SENSOR_MSG_GPSDATA_DAT*
- */
-void VehicleSensGetGpsClockFreqG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gGpsClockFreq_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsCounter_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsCounter_g.cpp
deleted file mode 100755
index d4aba14..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsCounter_g.cpp
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GpsCounter_g.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GPS_COUNTER)
- * Module configuration :VehicleSensInitGpsCounterg() Vehicle sensor GPS_COUNTER initialization function
- * :VehicleSensSetGpsCounterg() Vehicle Sensor GPS_COUNTER SET Function
- * :VehicleSensGetGpsCounterg() Vehicle Sensor GPS_COUNTER GET Function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstGpsCounter_g; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGpsCounterg
-* ABSTRACT : Vehicle sensor GPS_COUNTER initialization function
-* FUNCTION : GPS_COUNTER data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGpsCounterg(void) {
- memset(&gstGpsCounter_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstGpsCounter_g.ul_did = VEHICLE_DID_GPS_COUNTER;
- gstGpsCounter_g.us_size = VEHICLE_DSIZE_GPS_COUNTER;
- gstGpsCounter_g.uc_data[0] = VEHICLE_DINIT_GPS_COUNTER;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGpsCounterg
-* ABSTRACT : Vehicle Sensor GPS_COUNTER SET Function
-* FUNCTION : Update the GPS_COUNTER data master
-* ARGUMENT : *pst_data : Pointer to CAN received message data
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGpsCounterg(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGpsCounter_g;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = (u_int8)pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGpsCounterg
-* ABSTRACT : Vehicle Sensor GPS_COUNTER GET Function
-* FUNCTION : Provide the GPS_COUNTER data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGpsCounterg(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGpsCounter_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsNmea_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsNmea_g.cpp
deleted file mode 100755
index a7b733e..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsNmea_g.cpp
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GpsNmea_g.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files
- *---------------------------------------------------------------------------------*/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "gps_hal.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER_GPS_FORMAT gstGpsNmea_g; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Vehicle sensor GPS_NMEA initialization processing
- */
-void VehicleSensInitGpsNmeaG(void) {
- memset(&gstGpsNmea_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_FORMAT));
- gstGpsNmea_g.ul_did = POSHAL_DID_GPS_NMEA;
- gstGpsNmea_g.us_size = VEHICLE_DSIZE_GPS_FORMAT;
-}
-
-/**
- * @brief
- * Vehicle sensor GPS_NMEA SET processing
- *
- * @param[in] Pointer to received message data
- *
- * @return VEHICLESENS_EQ No data change<BR>
- * VEHICLESENS_NEQ Data change
- */
-u_int8 VehicleSensSetGpsNmeaG(const SENSOR_MSG_GPSDATA_DAT *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_FORMAT *pst_master;
-
- pst_master = &gstGpsNmea_g;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Vehicle sensor GPS_NMEA GET processing
- *
- * @param[out] pst_data Pointer to the data master acquisition destination
- */
-void VehicleSensGetGpsNmeaG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- const VEHICLESENS_DATA_MASTER_GPS_FORMAT *pst_master;
-
- pst_master = &gstGpsNmea_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTime.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTime.cpp
deleted file mode 100755
index 8c23e3e..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTime.cpp
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GpsTime.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * GPS time information data master GET processing
- *
- * @param[out] VEHICLESENS_DATA_MASTER*
- * @param[in] u_int8
- */
-void VehicleSensGetGpsTime(SENSOR_MSG_GPSDATA_DAT *pst_data, u_int8 uc_get_method) { // LCOV_EXCL_START 7: uesd only in FrameworkunifiedOnDebugDump // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- switch (uc_get_method) {
- case VEHICLESENS_GETMETHOD_GPS:
- {
- /** To acquire from GPSorNAVI */
- VehicleSensGetGpsTimeG(pst_data);
- break;
- }
-
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTimeRaw.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTimeRaw.cpp
deleted file mode 100755
index 9637b72..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTimeRaw.cpp
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GpsTimeRaw.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Raw GPS time information data master GET processing
- *
- * @param[out] VEHICLESENS_DATA_MASTER*
- * @param[in] u_int8
- */
-void VehicleSensGetGpsTimeRaw(SENSOR_MSG_GPSDATA_DAT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) {
- case VEHICLESENS_GETMETHOD_GPS:
- {
- /** To acquire from GPS */
- VehicleSensGetGpsTimeRawG(pst_data);
- break;
- }
-
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTimeRaw_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTimeRaw_g.cpp
deleted file mode 100755
index 52cda83..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTimeRaw_g.cpp
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GpsTimeRaw_g.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gstGpsTimeRaw_g; // NOLINT(readability/nolint)
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * GPS time information data master initialization processing
- */
-void VehicleSensInitGpsTimeRawG(void) {
- SENSOR_GPSTIME_RAW st_gps_time_raw;
-
- memset(&gstGpsTimeRaw_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstGpsTimeRaw_g.ul_did = POSHAL_DID_GPS_TIME_RAW;
- /** Data size setting */
- gstGpsTimeRaw_g.us_size = sizeof(SENSOR_GPSTIME_RAW);
- /** Data content setting */
- memset(&st_gps_time_raw, 0x00, sizeof(st_gps_time_raw));
- memcpy(&gstGpsTimeRaw_g.uc_data[0], &st_gps_time_raw, sizeof(st_gps_time_raw));
-
- return;
-}
-
-/**
- * @brief
- * Raw GPS Time Data Master SET Processing
- *
- * @param[in] SENSOR_GPSTIME_RAW*
- *
- * @return u_int8
- */
-u_int8 VehicleSensSetGpsTimeRawG(const SENSOR_GPSTIME_RAW *pst_gps_time_raw) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGpsTimeRaw_g;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_gps_time_raw, sizeof(SENSOR_GPSTIME_RAW));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = POSHAL_DID_GPS_TIME_RAW;
- pst_master->us_size = sizeof(SENSOR_GPSTIME_RAW);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_gps_time_raw, sizeof(SENSOR_GPSTIME_RAW));
-
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__,
- "year=%04d, month=%02d, date=%02d, hour=%02d, minute=%02d, second=%02d, tdsts=%d",
- pst_gps_time_raw->utc.year, pst_gps_time_raw->utc.month, pst_gps_time_raw->utc.date,
- pst_gps_time_raw->utc.hour, pst_gps_time_raw->utc.minute,
- pst_gps_time_raw->utc.second, pst_gps_time_raw->tdsts);
- return(uc_ret);
-}
-
-/**
- * @brief
- * Raw GPS time information data master GET processing
- *
- * @param[out] SENSOR_MSG_GPSDATA_DAT*
- */
-void VehicleSensGetGpsTimeRawG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGpsTimeRaw_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTime_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTime_g.cpp
deleted file mode 100755
index 404e60e..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GpsTime_g.cpp
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GpsTime_g.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gstGpsTime_g; // NOLINT(readability/nolint)
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * GPS time information data master initialization processing
- */
-void VehicleSensInitGpsTimeG(void) {
- SENSOR_MSG_GPSTIME st_gps_time;
-
- memset(&gstGpsTime_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstGpsTime_g.ul_did = POSHAL_DID_GPS_TIME;
- /** Data size setting */
- gstGpsTime_g.us_size = sizeof(SENSOR_MSG_GPSTIME);
- /** Data content setting */
- memset(&st_gps_time, 0x00, sizeof(st_gps_time));
- memcpy(&gstGpsTime_g.uc_data[0], &st_gps_time, sizeof(st_gps_time));
-
- return;
-}
-
-/**
- * @brief
- * GPS time information data master SET process
- *
- * @param[in] SENSOR_MSG_GPS*
- *
- * @return u_int8
- */
-u_int8 VehicleSensSetGpsTimeG(const SENSOR_MSG_GPSTIME *pst_gps_time) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGpsTime_g;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_gps_time, sizeof(SENSOR_MSG_GPSTIME));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = POSHAL_DID_GPS_TIME;
- pst_master->us_size = sizeof(SENSOR_MSG_GPSTIME);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_gps_time, sizeof(SENSOR_MSG_GPSTIME));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * GPS time information data master GET processing
- *
- * @param[out] SENSOR_MSG_GPS*
- */
-void VehicleSensGetGpsTimeG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGpsTime_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82_FullBinary_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82_FullBinary_g.cpp
deleted file mode 100755
index 8f84200..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82_FullBinary_g.cpp
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_Gps_CWORD82_FullBinary_g.cpp
- * System name :_CWORD72_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GPS__CWORD82__FULLBINARY)
- * Module configuration :VehicleSensInitGps_CWORD82_FullBinaryG() Vehicle sensor GPS__CWORD82__FULLBINARY initialization function
- * :VehicleSensSetGps_CWORD82_FullBinaryG() Vehicle sensor GPS__CWORD82__FULLBINARY SET function
- * :VehicleSensGetGps_CWORD82_FullBinaryG() Vehicle sensor GPS__CWORD82__FULLBINARY GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "VehicleSens_Common.h"
-#include "gps_hal.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_FORMAT gstGps_CWORD82_FullBinary_g; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGps_CWORD82_FullBinaryG
-* ABSTRACT : Vehicle sensor GPS_VERSION initialization function
-* FUNCTION : GPS__CWORD82__FULLBINARY data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGps_CWORD82_FullBinaryG(void) {
- memset(&gstGps_CWORD82_FullBinary_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_FORMAT));
- gstGps_CWORD82_FullBinary_g.ul_did = POSHAL_DID_GPS__CWORD82__FULLBINARY;
- /* _CWORD82_-only format with a fixed magic number */
- /* GPS antenna connection information(1byte) + Sensor Counter(1byte) + 191 */
- gstGps_CWORD82_FullBinary_g.us_size = (VEHICLE_DSIZE_GPS_ANTENNA + VEHICLE_DSIZE_SNS_COUNTER + GPS_CMD_FULLBIN_SZ);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGps_CWORD82_FullBinaryG
-* ABSTRACT : Vehicle sensor GPS_VERSION SET function
-* FUNCTION : Update the GPS__CWORD82__FULLBINARY data master
-* ARGUMENT : *pst_data : Pointer to CAN received message data
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGps_CWORD82_FullBinaryG(const SENSOR_MSG_GPSDATA_DAT *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_FORMAT *pst_master;
- VehicleSensSetGpsVersion(pst_data); /* Pass the _CWORD82_ binary */
-
- pst_master = &gstGps_CWORD82_FullBinary_g;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGps_CWORD82_FullBinaryG
-* ABSTRACT : Vehicle sensor GPS_VERSION GET function
-* FUNCTION : Provide the GPS__CWORD82__FULLBINARY data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGps_CWORD82_FullBinaryG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- const VEHICLESENS_DATA_MASTER_GPS_FORMAT *pst_master;
-
- pst_master = &gstGps_CWORD82_FullBinary_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82_Nmea_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82_Nmea_g.cpp
deleted file mode 100755
index 9f69054..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82_Nmea_g.cpp
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_Gps_CWORD82_Nmea_g.cpp
- * System name :_CWORD72_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GPS__CWORD82__FULLBINARY)
- * Module configuration :VehicleSensInitGps_CWORD82_FullBinaryG() Vehicle sensor GPS__CWORD82__FULLBINARY initialization function
- * :VehicleSensSetGps_CWORD82_FullBinaryG() Vehicle sensor GPS__CWORD82__FULLBINARY SET function
- * :VehicleSensGetGps_CWORD82_FullBinaryG() Vehicle sensor GPS__CWORD82__FULLBINARY GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "gps_hal.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_FORMAT gstGps_CWORD82_Nmea_g; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGps_CWORD82_NmeaG
-* ABSTRACT : Vehicle sensor GPS__CWORD82__NMEA initialization function
-* FUNCTION : GPS__CWORD82__NMEA data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGps_CWORD82_NmeaG(void) {
- memset(&gstGps_CWORD82_Nmea_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_FORMAT));
- gstGps_CWORD82_Nmea_g.ul_did = VEHICLE_DID_GPS__CWORD82__NMEA;
- /* _CWORD82_-only format with a fixed magic number */
- gstGps_CWORD82_Nmea_g.us_size = 3 /* NMEA reception flag + GPS antenna connection information + sensor counter */
- + VEHICLE_DSIZE_GPS_NMEA_DRMC
- + VEHICLE_DSIZE_GPS_NMEA_GSA
- + VEHICLE_DSIZE_GPS_NMEA_GSV_1
- + VEHICLE_DSIZE_GPS_NMEA_GSV_2
- + VEHICLE_DSIZE_GPS_NMEA_GSV_3
- + VEHICLE_DSIZE_GPS_NMEA_PJRDC_GP_3;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGps_CWORD82_NmeaG
-* ABSTRACT : Vehicle sensor GPS_NMEA SET function
-* FUNCTION : Update the GPS__CWORD82___CWORD44__GP4 data master
-* ARGUMENT : *pst_data : Pointer to CAN received message data
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-*******************************************************************************/
-u_int8 VehicleSensSetGps_CWORD82_NmeaG(const SENSOR_MSG_GPSDATA_DAT *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_FORMAT *pst_master;
-
- pst_master = &gstGps_CWORD82_Nmea_g;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGps_CWORD82_NmeaG
-* ABSTRACT : Vehicle sensor GPS__CWORD82__NMEA GET function
-* FUNCTION : GPS__CWORD82__NMEA Provides a data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGps_CWORD82_NmeaG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- const VEHICLESENS_DATA_MASTER_GPS_FORMAT *pst_master;
-
- pst_master = &gstGps_CWORD82_Nmea_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82__CWORD44_Gp4_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82__CWORD44_Gp4_g.cpp
deleted file mode 100755
index 4ce8678..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Gps_CWORD82__CWORD44_Gp4_g.cpp
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_Gps_CWORD82_Nmea_g.cpp
- * System name :_CWORD72_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GPS__CWORD82__FULLBINARY)
- * Module configuration :VehicleSensInitGps_CWORD82_FullBinaryG() Vehicle sensor GPS__CWORD82__FULLBINARY initialization function
- * :VehicleSensSetGps_CWORD82_FullBinaryG() Vehicle sensor GPS__CWORD82__FULLBINARY SET function
- * :VehicleSensGetGps_CWORD82_FullBinaryG() Vehicle sensor GPS__CWORD82__FULLBINARY GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "gps_hal.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_FORMAT gstGps_CWORD82__CWORD44_Gp4_g; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGps_CWORD82__CWORD44_Gp4G
-* ABSTRACT : Vehicle sensor GPS__CWORD44__GP4 initialization function
-* FUNCTION : GPS__CWORD82___CWORD44__GP4 data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGps_CWORD82__CWORD44_Gp4G(void) {
- memset(&gstGps_CWORD82__CWORD44_Gp4_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_FORMAT));
- gstGps_CWORD82__CWORD44_Gp4_g.ul_did = POSHAL_DID_GPS__CWORD82___CWORD44_GP4;
- /* Initialize with _CWORD82_ only and size fixed VEHICLE_DSIZE_GPS_NMEA_PJRDC_GP_4 */
- /* GPS antenna connection information(1byte) + Sensor Counter(1byte) + VEHICLE_DSIZE_GPS_NMEA_PJRDC_GP_4 */
- gstGps_CWORD82__CWORD44_Gp4_g.us_size = (VEHICLE_DSIZE_GPS_ANTENNA + VEHICLE_DSIZE_SNS_COUNTER) \
- + (VEHICLE_DSIZE_GPS_NMEA_PJRDC_GP_4);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGps_CWORD82__CWORD44_Gp4G
-* ABSTRACT : Vehicle sensor GPS_NMEA SET function
-* FUNCTION : Update the GPS__CWORD82___CWORD44__GP4 data master
-* ARGUMENT : *pst_data : Pointer to CAN received message data
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-*******************************************************************************/
-u_int8 VehicleSensSetGps_CWORD82__CWORD44_Gp4G(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_FORMAT *pst_master;
-
- pst_master = &gstGps_CWORD82__CWORD44_Gp4_g;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = (u_int8)pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGps_CWORD82__CWORD44_Gp4G
-* ABSTRACT : Vehicle sensor GPS__CWORD44__GP4 GET function
-* FUNCTION : Provide the GPS__CWORD82___CWORD44__GP4 data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGps_CWORD82__CWORD44_Gp4G(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_FORMAT *pst_master;
-
- pst_master = &gstGps_CWORD82__CWORD44_Gp4_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsX.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsX.cpp
deleted file mode 100755
index e68edc6..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsX.cpp
+++ /dev/null
@@ -1,119 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GsnsX.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GSNS_X)
- * Module configuration :VehicleSensGetGsnsX() Vehicle sensor GSNS_X GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsX
-* ABSTRACT : Vehicle sensor GSNS_X GET function
-* FUNCTION : Provide the GSNS_X data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsX(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGsnsXl(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
-
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsXExt
-* ABSTRACT : Vehicle sensor GSNS_X GET function
-* FUNCTION : Provide the GSNS_X data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsXExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGsnsXExtl(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
-#endif
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-
-/**
- * @brief
- * Vehicle sensor GSNS_X GET function
- *
- * Provide the GSNS_X data master
- *
- * @param[in] *pst_data: Pointer to the data master acquisition destination
- * @param[in] uc_get_method: Acquisition method(Direct Line or CAN)
- */
-void VehicleSensGetGsnsXFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGsnsXFstl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsXExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsXExt_l.cpp
deleted file mode 100755
index 4a481bb..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsXExt_l.cpp
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GsnsXExt_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GSNS_X)
- * Module configuration :VehicleSensInitGsnsXExtl() Vehicle sensor GSNS_X initialization function
- * :VehicleSensSetGsnsXExtlG() Vehicle sensor GSNS_X SET function
- * :VehicleSensGetGsnsXExtl() Vehicle sensor GSNS_X GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_EXT gstGsnsXExt_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGsnsXExtl
-* ABSTRACT : Vehicle sensor GSNS_X initialization function
-* FUNCTION : GSNS_X data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGsnsXExtl(void) {
- memset(&gstGsnsXExt_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- gstGsnsXExt_l.ul_did = POSHAL_DID_GSNS_X;
- gstGsnsXExt_l.us_size = VEHICLE_DSIZE_GSNS_X_EXT_INIT;
- gstGsnsXExt_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_X SET function
- *
- * Update the GSNS_X data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- */
-void VehicleSensSetGsnsXExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_start = 0;
- u_int16 us_size = 0;
- u_int16 us_cnt = 0;
-
- pst_master = &gstGsnsXExt_l;
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Store the latest one in the internal data structure */
- us_start = gstPkgTempExt.start_point[GsnsX]; /* Location to store one received message */
- /* Stored in data master(Order of reception)*/
- if (us_start >= VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = pst_data->ul_did;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- for (us_cnt = 0; us_cnt < us_size; us_cnt++) {
- pst_master->uc_data[us_start * us_size + us_cnt] = (u_int8)(pst_data->uc_data[us_cnt]);
- }
-
- /* Update next storage start position and latest data storage position */
- us_start++;
- gstPkgTempExt.start_point[GsnsX] = us_start;
-
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_GSNS_X_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + us_size);
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsXExtl
-* ABSTRACT : Vehicle sensor GSNS_X GET function
-* FUNCTION : Provide the GSNS_X data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsXExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- uint16_t us_size = 0;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &gstGsnsXExt_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[GsnsX];
- }
-
- /* Acquire data from the oldest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[GsnsX] + us_cnt < VEHICLE_DKEEP_MAX) {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[(gstPkgTempExt.start_point[GsnsX] + us_cnt) * us_size], us_size);
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_loop_cnt * us_size], us_size);
- us_loop_cnt++;
- }
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_cnt * us_size], us_size);
- }
- }
-}
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsXFst_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsXFst_l.cpp
deleted file mode 100755
index 61ee990..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsXFst_l.cpp
+++ /dev/null
@@ -1,127 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GsnsXFst_l.cpp
- * @brief
- * Vehicle sensor data master(POSHAL_DID_GSNS_X_FST)
- */
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_FST g_st_gsnsx_fst_l; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Vehicle sensor GSNS_X initialization function
- *
- * GSNS_X data master initialization processing
- */
-void VehicleSensInitGsnsXFstl(void) {
- memset(&g_st_gsnsx_fst_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_FST));
- g_st_gsnsx_fst_l.ul_did = POSHAL_DID_GSNS_X_FST;
- g_st_gsnsx_fst_l.us_size = VEHICLE_DSIZE_GSNS_X_EXT_INIT;
- g_st_gsnsx_fst_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
- g_st_gsnsx_fst_l.partition_flg = 0;
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_X SET function
- *
- * Update the GSNS_X data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- */
-u_int8 VehicleSensSetGsnsXFstG(const LSDRV_LSDATA_FST_GSENSOR_X *pst_data) {
- static u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- u_int8 partition_max; /* Total number of partitions */
- u_int8 partition_num; /* Data number */
-
- pst_master = &g_st_gsnsx_fst_l;
-
- partition_max = pst_data->uc_partition_max;
- partition_num = pst_data->uc_partition_num;
-
- if (partition_max == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 0;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_max == 2) {
- if (partition_num == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->partition_flg = 1;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_num == 2) {
- /* Compare data master and received data */
- if (uc_ret == VEHICLESENS_EQ) {
- uc_ret = VehicleSensmemcmp(&pst_master->uc_data[VEHICLE_DSIZE_GSNSX_FST],
- pst_data->uc_data, pst_data->uc_size);
- }
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 1;
- memcpy(&pst_master->uc_data[VEHICLE_DSIZE_GSNSX_FST], pst_data->uc_data, pst_data->uc_size);
- } else { }
- } else { }
- return(uc_ret);
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_X GET function
- *
- * Provide the GSNS_X data master
- *
- * @param[in] Pointer to the data master acquisition destination
- */
-void VehicleSensGetGsnsXFstl(VEHICLESENS_DATA_MASTER_FST *pst_data) {
- const VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &g_st_gsnsx_fst_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->partition_flg = pst_master->partition_flg;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsX_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsX_l.cpp
deleted file mode 100755
index 90d16ce..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsX_l.cpp
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GsnsX_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GSNS_X)
- * Module configuration :VehicleSensInitGsnsXl() Vehicle sensor GSNS_X initialization function
- * :VehicleSensSetGsnsXlG() Vehicle sensor GSNS_X SET function
- * :VehicleSensGetGsnsXl() Vehicle sensor GSNS_X GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstGsnsX_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGsnsXl
-* ABSTRACT : Vehicle sensor GSNS_X initialization function
-* FUNCTION : GSNS_X data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGsnsXl(void) {
- memset(&gstGsnsX_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstGsnsX_l.ul_did = POSHAL_DID_GSNS_X;
- gstGsnsX_l.us_size = VEHICLE_DSIZE_GSNS_X;
- gstGsnsX_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_X SET function
- *
- * Update the GSNS_X data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- */
-u_int8 VehicleSensSetGsnsXlG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGsnsX_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsXl
-* ABSTRACT : Vehicle sensor GSNS_X GET function
-* FUNCTION : Provide the GSNS_X data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsXl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGsnsX_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsY.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsY.cpp
deleted file mode 100755
index 0ab4b67..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsY.cpp
+++ /dev/null
@@ -1,121 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GsnsY.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GSNS_Y)
- * Module configuration :VehicleSensGetGsnsY() Vehicle sensor GSNS_Y GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsY
-* ABSTRACT : Vehicle sensor GSNS_Y GET function
-* FUNCTION : Provide the GSNS_Y data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsY(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGsnsYl(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
-
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsYExt
-* ABSTRACT : Vehicle sensor GSNS_Y GET function
-* FUNCTION : Provide the GSNS_Y data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsYExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGsnsYExtl(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
-#endif
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-
-/**
- * @brief
- * Vehicle sensor GSNS_Y GET function
- *
- * Provide the GSNS_Y data master
- *
- * @param[in] *pst_data: Pointer to the data master acquisition destination
- * @param[in] uc_get_method: Acquisition method(Direct Line or CAN)
- */
-void VehicleSensGetGsnsYFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
-
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGsnsYFstl(pst_data);
- break;
- }
-
- default:
- break;
- }
-}
-
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsYExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsYExt_l.cpp
deleted file mode 100755
index 947da7f..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsYExt_l.cpp
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GsnsYExt_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GSNS_Y)
- * Module configuration :VehicleSensInitGsnsYExtl() Vehicle sensor GSNS_Y initialization function
- * :VehicleSensSetGsnsYExtlG() Vehicle sensor GSNS_Y SET function
- * :VehicleSensGetGsnsYExtl() Vehicle sensor GSNS_Y GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_EXT gstGsnsYExt_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGsnsYExtl
-* ABSTRACT : Vehicle sensor GSNS_Y initialization function
-* FUNCTION : GSNS_Y data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGsnsYExtl(void) {
- memset(&gstGsnsYExt_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- gstGsnsYExt_l.ul_did = POSHAL_DID_GSNS_Y;
- gstGsnsYExt_l.us_size = VEHICLE_DSIZE_GSNS_Y_EXT_INIT;
- gstGsnsYExt_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_Y SET function
- *
- * Update the GSNS_Y data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- */
-void VehicleSensSetGsnsYExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_start = 0;
- u_int16 us_size = 0;
- u_int16 us_cnt = 0;
-
- pst_master = &gstGsnsYExt_l;
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Store the latest one in the internal data structure */
- us_start = gstPkgTempExt.start_point[GsnsY]; /* Location to store one received message */
- /* Stored in data master(Order of reception)*/
- if (us_start >= VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = pst_data->ul_did;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- for (us_cnt = 0; us_cnt < us_size; us_cnt++) {
- pst_master->uc_data[us_start * us_size + us_cnt] = (u_int8)(pst_data->uc_data[us_cnt]);
- }
-
- /* Update next storage start position and latest data storage position */
- us_start++;
- gstPkgTempExt.start_point[GsnsY] = us_start;
-
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_GSNS_Y_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + us_size);
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsYExtl
-* ABSTRACT : Vehicle sensor GSNS_Y GET function
-* FUNCTION : Provide the GSNS_Y data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsYExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- uint16_t us_size = 0;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &gstGsnsYExt_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[GsnsY];
- }
-
- /* Acquire data from the oldest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[GsnsY] + us_cnt < VEHICLE_DKEEP_MAX) {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[(gstPkgTempExt.start_point[GsnsY] + us_cnt) * us_size], us_size);
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_loop_cnt * us_size], us_size);
- us_loop_cnt++;
- }
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_cnt * us_size], us_size);
- }
- }
-}
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsYFst_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsYFst_l.cpp
deleted file mode 100755
index 1fc1b92..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsYFst_l.cpp
+++ /dev/null
@@ -1,128 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GsnsYFst_l.cpp
- * @brief
- * Vehicle sensor data master(POSHAL_DID_GSNS_Y_FST)
- */
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_FST g_st_gsnsy_fst_l; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Vehicle sensor GSNS_Y initialization function
- *
- * GSNS_Y data master initialization processing
- */
-void VehicleSensInitGsnsYFstl(void) {
- memset(&g_st_gsnsy_fst_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_FST));
- g_st_gsnsy_fst_l.ul_did = POSHAL_DID_GSNS_Y_FST;
- g_st_gsnsy_fst_l.us_size = VEHICLE_DSIZE_GSNS_Y_EXT_INIT;
- g_st_gsnsy_fst_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
- g_st_gsnsy_fst_l.partition_flg = 0;
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_Y SET function
- *
- * Update the GSNS_Y data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- */
-u_int8 VehicleSensSetGsnsYFstG(const LSDRV_LSDATA_FST_GSENSOR_Y *pst_data) {
- static u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- u_int8 partition_max; /* Total number of partitions */
- u_int8 partition_num; /* Data number */
-
- pst_master = &g_st_gsnsy_fst_l;
-
- partition_max = pst_data->uc_partition_max;
- partition_num = pst_data->uc_partition_num;
-
- if (partition_max == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 0;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_max == 2) {
- if (partition_num == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->partition_flg = 1;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_num == 2) {
- /* Compare data master and received data */
- if (uc_ret == VEHICLESENS_EQ) {
- uc_ret = VehicleSensmemcmp(&pst_master->uc_data[VEHICLE_DSIZE_GSNSY_FST],
- pst_data->uc_data, pst_data->uc_size);
- }
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 1;
- memcpy(&pst_master->uc_data[VEHICLE_DSIZE_GSNSY_FST], pst_data->uc_data, pst_data->uc_size);
- } else {}
- } else {}
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_Y GET function
- *
- * Provide the GSNS_Y data master
- *
- * @param[in] Pointer to the data master acquisition destination
- */
-void VehicleSensGetGsnsYFstl(VEHICLESENS_DATA_MASTER_FST *pst_data) {
- const VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &g_st_gsnsy_fst_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->partition_flg = pst_master->partition_flg;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsY_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsY_l.cpp
deleted file mode 100755
index 1bf2e30..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsY_l.cpp
+++ /dev/null
@@ -1,99 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GsnsY_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GSNS_Y)
- * Module configuration :VehicleSensInitGsnsYl() Vehicle sensor GSNS_Y initialization function
- * :VehicleSensSetGsnsYlG() Vehicle sensor GSNS_Y SET function
- * :VehicleSensGetGsnsYl() Vehicle sensor GSNS_Y GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstGsnsY_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGsnsYl
-* ABSTRACT : Vehicle sensor GSNS_Y initialization function
-* FUNCTION : GSNS_Y data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGsnsYl(void) {
- memset(&gstGsnsY_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstGsnsY_l.ul_did = POSHAL_DID_GSNS_Y;
- gstGsnsY_l.us_size = VEHICLE_DSIZE_GSNS_Y;
- gstGsnsY_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_Y SET function
- *
- * Update the GSNS_Y data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- *
- */
-u_int8 VehicleSensSetGsnsYlG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGsnsY_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsYl
-* ABSTRACT : Vehicle sensor GSNS_Y GET function
-* FUNCTION : Provide the GSNS_Y data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsYl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGsnsY_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZ.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZ.cpp
deleted file mode 100755
index ec865c3..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZ.cpp
+++ /dev/null
@@ -1,116 +0,0 @@
-/*
- * @copyright Copyright (c) 2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GsnsY.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GSNS_Z)
- * Module configuration :VehicleSensGetGsnsZ() Vehicle sensor GSNS_Z GET function
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsZ
-* ABSTRACT : Vehicle sensor GSNS_Z GET function
-* FUNCTION : Provide the GSNS_Z data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsZ(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGsnsZl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsZExt
-* ABSTRACT : Vehicle sensor GSNS_Z GET function
-* FUNCTION : Provide the GSNS_Z data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsZExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGsnsZExtl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-#endif
-
-/**
- * @brief
- * Vehicle sensor GSNS_Z GET function
- *
- * Provide the GSNS_Z data master
- *
- * @param[in] *pst_data: Pointer to the data master acquisition destination
- * @param[in] uc_get_method: Acquisition method(Direct Line or CAN)
- */
-void VehicleSensGetGsnsZFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
-
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGsnsZFstl(pst_data);
- break;
- }
-
- default:
- break;
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZExt_l.cpp
deleted file mode 100755
index 9dc1e39..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZExt_l.cpp
+++ /dev/null
@@ -1,142 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GsnsZExt_l.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GSNS_Z)
- * Module configuration :VehicleSensInitGsnsZExtl() Vehicle sensor GSNS_Z initialization function
- * :VehicleSensSetGsnsZExtlG() Vehicle sensor GSNS_Z SET function
- * :VehicleSensGetGsnsZExtl() Vehicle sensor GSNS_Z GET function
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_EXT gstGsnsZExt_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGsnsZExtl
-* ABSTRACT : Vehicle sensor GSNS_Z initialization function
-* FUNCTION : GSNS_Z data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGsnsZExtl(void) {
- memset(&gstGsnsZExt_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- gstGsnsZExt_l.ul_did = POSHAL_DID_GSNS_Z;
- gstGsnsZExt_l.us_size = VEHICLE_DSIZE_GSNS_Z_EXT_INIT;
- gstGsnsZExt_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_Z SET function
- *
- * Update the GSNS_Z data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- */
-void VehicleSensSetGsnsZExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_start = 0;
- u_int16 us_size = 0;
- u_int16 us_cnt = 0;
-
- pst_master = &gstGsnsZExt_l;
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Store the latest one in the internal data structure */
- us_start = gstPkgTempExt.start_point[GsnsZ]; /* Location to store one received message */
- /* Stored in data master(Order of reception)*/
- if (us_start >= VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = pst_data->ul_did;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- for (us_cnt = 0; us_cnt < us_size; us_cnt++) {
- pst_master->uc_data[us_start * us_size + us_cnt] = (u_int8)(pst_data->uc_data[us_cnt]);
- }
-
- /* Update next storage start position and latest data storage position */
- us_start++;
- gstPkgTempExt.start_point[GsnsZ] = us_start;
-
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_GSNS_Z_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + us_size);
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsZExtl
-* ABSTRACT : Vehicle sensor GSNS_Z GET function
-* FUNCTION : Provide the GSNS_Z data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsZExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- uint16_t us_size = 0;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &gstGsnsZExt_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[GsnsZ];
- }
-
- /* Acquire data from the oldest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[GsnsZ] + us_cnt < VEHICLE_DKEEP_MAX) {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[(gstPkgTempExt.start_point[GsnsZ] + us_cnt) * us_size], us_size);
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_loop_cnt * us_size], us_size);
- us_loop_cnt++;
- }
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_cnt * us_size], us_size);
- }
- }
-}
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZFst_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZFst_l.cpp
deleted file mode 100755
index a69bb87..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZFst_l.cpp
+++ /dev/null
@@ -1,127 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GsnsZFst_l.cpp
- * @brief
- * Vehicle sensor data master(POSHAL_DID_GSNS_Z_FST)
- */
-
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_FST g_st_gsnsz_fst_l; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Vehicle sensor GSNS_Z initialization function
- *
- * GSNS_Z data master initialization processing
- */
-void VehicleSensInitGsnsZFstl(void) {
- memset(&g_st_gsnsz_fst_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_FST));
- g_st_gsnsz_fst_l.ul_did = POSHAL_DID_GSNS_Z_FST;
- g_st_gsnsz_fst_l.us_size = VEHICLE_DSIZE_GSNS_Z_EXT_INIT;
- g_st_gsnsz_fst_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
- g_st_gsnsz_fst_l.partition_flg = 0;
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_Z SET function
- *
- * Update the GSNS_Z data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- */
-u_int8 VehicleSensSetGsnsZFstG(const LSDRV_LSDATA_FST_GSENSOR_Z *pst_data) {
- static u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- u_int8 partition_max; /* Total number of partitions */
- u_int8 partition_num; /* Data number */
-
- pst_master = &g_st_gsnsz_fst_l;
-
- partition_max = pst_data->uc_partition_max;
- partition_num = pst_data->uc_partition_num;
-
- if (partition_max == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 0;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_max == 2) {
- if (partition_num == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->partition_flg = 1;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_num == 2) {
- /* Compare data master and received data */
- if (uc_ret == VEHICLESENS_EQ) {
- uc_ret = VehicleSensmemcmp(&pst_master->uc_data[VEHICLE_DSIZE_GSNSZ_FST],
- pst_data->uc_data, pst_data->uc_size);
- }
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 1;
- memcpy(&pst_master->uc_data[VEHICLE_DSIZE_GSNSZ_FST], pst_data->uc_data, pst_data->uc_size);
- } else {}
- } else {}
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_Z GET function
- *
- * Provide the GSNS_Z data master
- *
- * @param[in] Pointer to the data master acquisition destination
- */
-void VehicleSensGetGsnsZFstl(VEHICLESENS_DATA_MASTER_FST *pst_data) {
- const VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &g_st_gsnsz_fst_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->partition_flg = pst_master->partition_flg;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZ_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZ_l.cpp
deleted file mode 100755
index 8614535..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GsnsZ_l.cpp
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GsnsZ_l.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GSNS_Z)
- * Module configuration :VehicleSensInitGsnsZl() Vehicle sensor GSNS_Z initialization function
- * :VehicleSensSetGsnsZlG() Vehicle sensor GSNS_Z SET function
- * :VehicleSensGetGsnsZl() Vehicle sensor GSNS_Z GET function
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstGsnsZ_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGsnsZl
-* ABSTRACT : Vehicle sensor GSNS_Z initialization function
-* FUNCTION : GSNS_Z data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGsnsZl(void) {
- memset(&gstGsnsZ_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstGsnsZ_l.ul_did = POSHAL_DID_GSNS_Z;
- gstGsnsZ_l.us_size = VEHICLE_DSIZE_GSNS_Z;
- gstGsnsZ_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/**
- * @brief
- * Vehicle sensor GSNS_Z SET function
- *
- * Update the GSNS_Z data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- *
- */
-u_int8 VehicleSensSetGsnsZlG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGsnsZ_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGsnsZl
-* ABSTRACT : Vehicle sensor GSNS_Z GET function
-* FUNCTION : Provide the GSNS_Z data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGsnsZl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGsnsZ_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroConnectStatus.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroConnectStatus.cpp
deleted file mode 100755
index d6fee30..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroConnectStatus.cpp
+++ /dev/null
@@ -1,110 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroConnectStatus.cpp
- * System name :PastModel002
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GYRO_CONNECT_STATUS)
- * Module configuration :VehicleSensInitGyroConnectStatus() Vehicle Sensor GYRO CONNECT STATUS Initialization Functions
- * :VehicleSensSetGyroConnectStatus() Vehicle Sensor GYRO CONNECT STATUS SET Functions
- * :VehicleSensGetGyroConnectStatus() Vehicle Sensor GYRO CONNECT STATUS GET Functions
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GYRO_CONNECT_STATUS gstGyroConnectStatus; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroConnectStatus
-* ABSTRACT : Vehicle sensor GYRO_CONNECT_STATUS initialization function
-* FUNCTION : GYRO_CONNECT_STATUS data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroConnectStatus(void) {
- (void)memset(reinterpret_cast<void *>(&(gstGyroConnectStatus)), static_cast<int>(0x00),
- sizeof(VEHICLESENS_DATA_MASTER_GYRO_CONNECT_STATUS));
- gstGyroConnectStatus.ul_did = VEHICLE_DID_GYRO_CONNECT_STATUS;
- gstGyroConnectStatus.us_size = VEHICLE_DSIZE_GYRO_CONNECT_STATUS;
- gstGyroConnectStatus.uc_data = VEHICLE_DINIT_GYRO_CONNECT_STATUS;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroConnectStatus
-* ABSTRACT : Vehicle sensor GYRO_CONNECT_STATUS SET function
-* FUNCTION : Update the GYRO_CONNECT_STATUS data master
-* ARGUMENT : *pst_data : Pointer to received message data
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroConnectStatus(const LSDRV_MSG_LSDATA_DAT_GYRO_CONNECT_STATUS *pst_data) { // LCOV_EXCL_START 8: dead code. // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_GYRO_CONNECT_STATUS *pst_master;
-
- if (pst_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "pst_data == NULL\r\n");
- } else {
- pst_master = &gstGyroConnectStatus;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(reinterpret_cast<void *>(&(pst_master->uc_data)),
- (const void *)(&(pst_data->uc_data)), (size_t)(pst_data->uc_size));
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = (u_int16)pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- (void)memcpy(reinterpret_cast<void *>(&(pst_master->uc_data)),
- (const void *)(&(pst_data->uc_data)), sizeof(pst_master->uc_data));
- }
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroConnectStatus
-* ABSTRACT : Vehicle Sensor GYRO TROUBLE GET Functions
-* FUNCTION : Provide a GYRO TROUBLE data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroConnectStatus(VEHICLESENS_DATA_MASTER_GYRO_CONNECT_STATUS *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GYRO_CONNECT_STATUS *pst_master;
-
- if (pst_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "pst_data == NULL\r\n");
- } else {
- pst_master = &gstGyroConnectStatus;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- (void)memcpy(reinterpret_cast<void *>(&(pst_data->uc_data)),
- (const void *)(&(pst_master->uc_data)), sizeof(pst_data->uc_data));
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroExt_l.cpp
deleted file mode 100755
index 0470c9f..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroExt_l.cpp
+++ /dev/null
@@ -1,257 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroExt_l.cpp
- * System name :Polaris
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GYRO_EXT)
- * Module configuration :VehicleSensInitGyroExtl() Vehicle Sensor GYRO (Initial Delivery) Initialization Functions
- * :VehicleSensSetGyroExtlG() Vehicle Sensor GYRO (Initial Delivery) Set Functions
- * :VehicleSensGetGyroExtl() Vehicle Sensor GYRO (Initial Delivery) Get Functions
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_EXT gstGyroExt_l; // NOLINT(readability/nolint)
-static VEHICLESENS_DATA_MASTER gstGyroRev_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroRevl
-* ABSTRACT : Vehicle Sensor GYRO Initialization Functions(Extensions data)
-* FUNCTION : GYRO data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroRevl(void) {
- u_int16 *pus;
-
- memset(&gstGyroRev_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- /* POSHAL_DID_GYRO initialized by POSHAL_DID_GYRO_X because POSHAL_DID_GYRO is internally replaced by POSHAL_DID_GYRO_EXT */
- gstGyroRev_l.ul_did = POSHAL_DID_GYRO_X;
- gstGyroRev_l.us_size = VEHICLE_DSIZE_GYRO;
-
- pus = reinterpret_cast<u_int16 *>(gstGyroRev_l.uc_data);
- pus[0] = VEHICLE_DINIT_GYRO; /* Ignore->MISRA-C++:2008 Rule 5-0-15 */
- pus[1] = VEHICLE_DINIT_GYRO; /* Ignore->MISRA-C++:2008 Rule 5-0-15 */
- pus[2] = VEHICLE_DINIT_GYRO; /* Ignore->MISRA-C++:2008 Rule 5-0-15 */
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroExtl
-* ABSTRACT : Vehicle Sensor GYRO Initialization Functions(Initial delivery)
-* FUNCTION : GYRO data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroExtl(void) {
- u_int16 *pus;
-
- memset(&gstGyroExt_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- /* POSHAL_DID_GYRO initialized by POSHAL_DID_GYRO_X because POSHAL_DID_GYRO is internally replaced by POSHAL_DID_GYRO_EXT */
- gstGyroExt_l.ul_did = POSHAL_DID_GYRO_X;
- gstGyroExt_l.us_size = VEHICLE_DSIZE_GYRO_EXT_INIT;
-
- pus = reinterpret_cast<u_int16 *>(gstGyroExt_l.uc_data);
- memset(reinterpret_cast<void*>(pus), VEHICLE_DINIT_GYRO, VEHICLE_DSIZE_GYRO_EXT);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroRevl
-* ABSTRACT : Vehicle Sensor GYRO SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroRevl(const LSDRV_LSDATA *pst_data) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroRev_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data,
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- /* Received data is set in the data master. */
- pst_master->ul_did = POSHAL_DID_GYRO_X;
- pst_master->us_size = pst_data->uc_size; /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- return(uc_ret);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroRevlG
-* ABSTRACT : Vehicle Sensor GYRO SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroRevlG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroRev_l;
-
- /* Compare data master and received data */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = POSHAL_DID_GYRO_X;
- pst_master->us_size = pst_data->uc_size; /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroExtlG
-* ABSTRACT : Vehicle Sensor GYRO SET Functions(Initial delivery)
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-void VehicleSensSetGyroExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_start = 0;
- u_int16 us_size = 0;
- u_int16 us_cnt = 0;
-
- pst_master = &gstGyroExt_l;
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Retrieve the location where the received one is stored */
- us_start = gstPkgTempExt.start_point[GyroExt];
-
- /* Stored in data master(Order of reception)*/
- if (us_start >= VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = POSHAL_DID_GYRO_X;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- for (us_cnt = 0; us_cnt < us_size; us_cnt++) {
- pst_master->uc_data[us_start * us_size + us_cnt] = (u_int8)(pst_data->uc_data[us_cnt]);
- }
-
- /* Update next storage start position and latest data storage position */
- us_start++;
- gstPkgTempExt.start_point[GyroExt] = us_start;
-
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_GYRO_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + us_size);
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroExtl
-* ABSTRACT : Vehicle Sensor GYRO GET Functions(Initial delivery)
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- uint16_t us_size = 0;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &gstGyroExt_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[GyroExt];
- }
-
- /* Acquire data from the oldest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[GyroExt] + us_cnt < VEHICLE_DKEEP_MAX) {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[(gstPkgTempExt.start_point[GyroExt] + us_cnt) * us_size], us_size);
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_loop_cnt * us_size], us_size);
- us_loop_cnt++;
- }
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_cnt * us_size], us_size);
- }
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroRevl
-* ABSTRACT : Vehicle Sensor GYRO GET Functions(Initial delivery)
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroRevl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroRev_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->uc_snscnt = pst_master->uc_snscnt;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTemp.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTemp.cpp
deleted file mode 100755
index d6debe6..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTemp.cpp
+++ /dev/null
@@ -1,114 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GyroTemp.cpp
- * @brief
- * Vehicle sensor data master(VEHICLE_DID_GYRO_TEMP_)
- */
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/**
- * @brief
- * Vehicle Sensor Gyro Temperature GET Function
- *
- * Provide a gyro temperature data master
- *
- * @param[in] *pst_data: Pointer to the data master acquisition destination
- * @param[in] uc_get_method: Acquisition method(Direct Line or CAN)
- */
-void VehicleSensGetGyroTemp(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroTempl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-/**
- * @brief
- * Vehicle Sensor Gyro Temperature (Initial Delivery) GET Function
- *
- * Provide a gyro temperature data master
- *
- * @param[in] *pst_data: Pointer to the data master acquisition destination
- * @param[in] uc_get_method: Acquisition method(Direct Line or CAN)
- */
-void VehicleSensGetGyroTempExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroTempExtl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-/**
- * @brief
- * Vehicle sensor gyro temperature (initial sensor) GET function
- *
- * Provide a gyro temperature data master
- *
- * @param[in] *pst_data: Pointer to the data master acquisition destination
- * @param[in] uc_get_method: Acquisition method(Direct Line or CAN)
- */
-void VehicleSensGetGyroTempFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroTempFstl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTempExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTempExt_l.cpp
deleted file mode 100755
index aee750d..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTempExt_l.cpp
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GyroTempExt_l.cpp
- * @brief
- * Vehicle sensor data master(POSHAL_DID_GYRO_TEMP)
- */
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_EXT g_stgyro_temp_ext_l; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Vehicle sensor gyro temperature initialization function
- *
- * Gyro Temperature Data Master Initialization Processing
- */
-void VehicleSensInitGyroTempExtl(void) {
- (void)memset(reinterpret_cast<void *>(&g_stgyro_temp_ext_l), 0, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- g_stgyro_temp_ext_l.ul_did = POSHAL_DID_GYRO_TEMP;
- g_stgyro_temp_ext_l.us_size = VEHICLE_DSIZE_GYRO_TEMP_EXT_INIT;
- g_stgyro_temp_ext_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/**
- * @brief
- * Vehicle Sensor Gyro Temperature SET Function
- *
- * Update the gyro temperature data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- */
-void VehicleSensSetGyroTempExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_start = 0;
- u_int16 us_size = 0;
- u_int16 us_cnt = 0;
-
- pst_master = &g_stgyro_temp_ext_l;
- us_size = sizeof(u_int16); /* Size of one data item: 2byte */
-
- /* Store the latest one in the internal data structure */
- us_start = gstPkgTempExt.start_point[GyroTemp]; /* Location to store one received message */
- /* Stored in data master(Order of reception)*/
- if (us_start == VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = pst_data->ul_did;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- for (us_cnt = 0; us_cnt < us_size; us_cnt++) {
- pst_master->uc_data[us_start * us_size + us_cnt] = (u_int8)(pst_data->uc_data[us_cnt]);
- }
-
- /* Update next storage start position and latest data storage position. */
- us_start++;
- gstPkgTempExt.start_point[GyroTemp] = us_start;
-
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_GYRO_TEMP_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + us_size);
- }
-}
-
-/**
- * @brief
- * Vehicle Sensor Gyro Temperature GET Function
- *
- * Provide a gyro temperature data master
- *
- * @param[in] Pointer to the data master acquisition destination
- */
-void VehicleSensGetGyroTempExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- uint16_t us_size = 0;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &g_stgyro_temp_ext_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- us_size = sizeof(u_int16); /* Size of one data item: 2byte */
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[GyroTemp];
- }
-
- /* Acquire data from the oldest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[GyroTemp] + us_cnt < VEHICLE_DKEEP_MAX) {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[(gstPkgTempExt.start_point[GyroTemp] + us_cnt) * us_size], us_size);
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_loop_cnt * us_size], us_size);
- us_loop_cnt++;
- }
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_cnt * us_size], us_size);
- }
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTempFst_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTempFst_l.cpp
deleted file mode 100755
index 3c2906d..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTempFst_l.cpp
+++ /dev/null
@@ -1,128 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GyroTempFst_l.cpp
- * @brief
- * Vehicle sensor data master(POSHAL_DID_GYRO_TEMP_FST)
- */
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_FST g_st_gyro_tempfst_l; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Vehicle sensor gyro temperature initialization function
- *
- * Gyro Temperature Data Master Initialization Processing
- */
-void VehicleSensInitGyroTempFstl(void) {
- memset(&g_st_gyro_tempfst_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_FST));
- g_st_gyro_tempfst_l.ul_did = POSHAL_DID_GYRO_TEMP_FST;
- g_st_gyro_tempfst_l.us_size = VEHICLE_DSIZE_GYRO_TEMP_EXT_INIT;
- g_st_gyro_tempfst_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
- g_st_gyro_tempfst_l.partition_flg = 0;
-}
-
-/**
- * @brief
- * Vehicle Sensor Gyro Temperature SET Function
- *
- * Update the gyro temperature data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- */
-u_int8 VehicleSensSetGyroTempFstG(const LSDRV_LSDATA_FST_GYRO_TEMP *pst_data) {
- static u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- u_int8 partition_max; /* Total number of partitions */
- u_int8 partition_num; /* Data number */
-
- pst_master = &g_st_gyro_tempfst_l;
-
- partition_max = pst_data->uc_partition_max;
- partition_num = pst_data->uc_partition_num;
-
- if (partition_max == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 0;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_max == 2) {
- if (partition_num == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->partition_flg = 1;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_num == 2) {
- /* Compare data master and received data */
- if (uc_ret == VEHICLESENS_EQ) {
- uc_ret = VehicleSensmemcmp(&pst_master->uc_data[VEHICLE_DSIZE_GYROTEMP_FST],
- pst_data->uc_data, pst_data->uc_size);
- }
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 1;
- memcpy(&pst_master->uc_data[VEHICLE_DSIZE_GYROTEMP_FST], pst_data->uc_data, pst_data->uc_size);
- } else {}
- } else {}
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Vehicle Sensor Gyro Temperature GET Function
- *
- * Provide a gyro temperature data master
- *
- * @param[in] Pointer to the data master acquisition destination
- */
-void VehicleSensGetGyroTempFstl(VEHICLESENS_DATA_MASTER_FST *pst_data) {
- const VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &g_st_gyro_tempfst_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->partition_flg = pst_master->partition_flg;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTemp_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTemp_l.cpp
deleted file mode 100755
index 002cf02..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTemp_l.cpp
+++ /dev/null
@@ -1,95 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_GyroTemp_l.cpp
- * @brief
- * Vehicle sensor data master(POSHAL_DID_GYRO_TEMP)
- */
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstGyroTemp_l; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Vehicle sensor gyro temperature initialization function
- *
- * Gyro Temperature Data Master Initialization Processing
- */
-void VehicleSensInitGyroTempl(void) {
- (void)memset(reinterpret_cast<void *>(&gstGyroTemp_l), 0, sizeof(VEHICLESENS_DATA_MASTER));
- gstGyroTemp_l.ul_did = POSHAL_DID_GYRO_TEMP;
- gstGyroTemp_l.us_size = VEHICLE_DSIZE_GYRO_TEMP;
- gstGyroTemp_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/**
- * @brief
- * Vehicle Sensor Gyro Temperature SET Function
- *
- * Update the gyro temperature data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- */
-u_int8 VehicleSensSetGyroTemplG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroTemp_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Vehicle Sensor Gyro Temperature GET Function
- *
- * Provide a gyro temperature data master
- *
- * @param[in] Pointer to the data master acquisition destination
- */
-void VehicleSensGetGyroTempl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroTemp_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->uc_snscnt = pst_master->uc_snscnt;
- (void)memcpy(reinterpret_cast<void *>(pst_data->uc_data),
- (const void *)(pst_master->uc_data), (size_t)(pst_master->us_size));
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTrouble.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTrouble.cpp
deleted file mode 100755
index e588c39..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroTrouble.cpp
+++ /dev/null
@@ -1,121 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroTrouble.cpp
- * System name :PastModel002
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GYRO_TROUBLE)
- * Module configuration :VehicleSensInitGyroTrouble() Vehicle Sensor GYRO TROUBLE Initialization Functions
- * :VehicleSensSetGyroTrouble() Vehicle Sensor GYRO TROUBLE SET Functions
- * :VehicleSensGetGyroTrouble() Vehicle Sensor GYRO TROUBLE GET Functions
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-#define VEHICLE_SENS_DID_GYRO_TROUBLE_DEBUG_FACTORY 0
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GYRO_TROUBLE gstGyroTrouble; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroTrouble
-* ABSTRACT : Vehicle sensor GYRO_TROUBLE initialization function
-* FUNCTION : GYRO_TROUBLE data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroTrouble(void) {
- (void)memset(reinterpret_cast<void *>(&(gstGyroTrouble)),
- static_cast<int>(0x00), sizeof(VEHICLESENS_DATA_MASTER_GYRO_TROUBLE));
- gstGyroTrouble.ul_did = VEHICLE_DID_GYRO_TROUBLE;
- gstGyroTrouble.us_size = VEHICLE_DSIZE_GYRO_TROUBLE;
- gstGyroTrouble.uc_data = VEHICLE_DINIT_GYRO_TROUBLE;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroTrouble
-* ABSTRACT : Vehicle Sensor GYRO_TROUBLE SET Function
-* FUNCTION : Update the GYRO_TROUBLE data master
-* ARGUMENT : *pst_data : Pointer to received message data
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroTrouble(const LSDRV_MSG_LSDATA_DAT_GYRO_TROUBLE *pst_data) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_GYRO_TROUBLE *pst_master;
-
- if (pst_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "pst_data == NULL\r\n");
- } else {
- pst_master = &gstGyroTrouble;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(&(pst_master->uc_data), &(pst_data->uc_data), pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = (u_int16)pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_data = pst_data->uc_data;
- (void)memcpy(reinterpret_cast<void *>(&(pst_master->uc_data)),
- (const void *)(&(pst_data->uc_data)), sizeof(pst_master->uc_data));
- }
-
-#if VEHICLE_SENS_DID_GYRO_TROUBLE_DEBUG_FACTORY
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "#[DIAG] pst_data->ul_did == 0x%x", pst_data->ul_did);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "#[DIAG] gstGyroTrouble.ul_did == 0x%x\r\n", gstGyroTrouble.ul_did);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "#[DIAG] (u_int8)pst_data->ucSize == 0x%x", (u_int8)pst_data->uc_size);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "#[DIAG] gstGyroTrouble.us_size == 0x%x\r\n", gstGyroTrouble.us_size);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "#[DIAG] pst_data->uc_data == 0x%x", pst_data->uc_data);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "#[DIAG] gstGyroTrouble.uc_data == 0x%x\r\n", gstGyroTrouble.uc_data);
-#endif
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroTrouble
-* ABSTRACT : Vehicle Sensor GYRO TROUBLE GET Functions
-* FUNCTION : Provide a GYRO TROUBLE data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroTrouble(VEHICLESENS_DATA_MASTER_GYRO_TROUBLE *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GYRO_TROUBLE *pst_master;
-
- if (pst_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "pst_data == NULL\r\n");
- } else {
- pst_master = &gstGyroTrouble;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- (void)memcpy(reinterpret_cast<void *>(&(pst_data->uc_data)),
- (const void *)(&(pst_master->uc_data)), sizeof(pst_data->uc_data));
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroX.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroX.cpp
deleted file mode 100755
index 3cda53a..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroX.cpp
+++ /dev/null
@@ -1,145 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroX.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GYRO_X)
- * Module configuration :VehicleSensGetGyroX() Vehicle Sensor GYRO GET Functions
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroX
-* ABSTRACT : Vehicle Sensor GYRO_X GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroX(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroXl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroRev
-* ABSTRACT : Vehicle Sensor GYRO GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroRev(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroRevl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroExt
-* ABSTRACT : Vehicle Sensor GYRO GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroExtl(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroXFst
-* ABSTRACT : Vehicle Sensor GYRO_X GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroXFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroXFstl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-#endif
-
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroXFst_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroXFst_l.cpp
deleted file mode 100755
index e9997ac..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroXFst_l.cpp
+++ /dev/null
@@ -1,176 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroXFst_l.cpp
- * System name :Polaris
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GYRO_X_FST)
- * Module configuration :VehicleSensInitGyroXFstl() Vehicle sensor GYRO (initial sensor) initialization functions
- * :VehicleSensSetGyroXFstl() Vehicle sensor GYRO (initial sensor) SET-function
- * :VehicleSensSetGyroXFstG() Vehicle sensor GYRO (initial sensor) SET-function
- * :VehicleSensGetGyroXFstl() Vehicle sensor GYRO (initial sensor) GET-function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_FST gstGyroXFst_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroXFstl
-* ABSTRACT : Vehicle Sensor GYRO_X Initialization Functions
-* FUNCTION : GYRO data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroXFstl(void) {
- u_int16 *pus;
-
- memset(&gstGyroXFst_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_FST));
- gstGyroXFst_l.ul_did = POSHAL_DID_GYRO_X_FST;
- gstGyroXFst_l.us_size = 0;
- gstGyroXFst_l.partition_flg = 0;
-
- pus = reinterpret_cast<u_int16 *>(gstGyroXFst_l.uc_data);
- memset(reinterpret_cast<void*>(pus), VEHICLE_DINIT_GYRO_X, VEHICLE_DSIZE_GYRO_X_FST);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroXFstl
-* ABSTRACT : Vehicle Sensor GYRO_X SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroXFstl(const LSDRV_LSDATA_FST *pst_data) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstGyroXFst_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data,
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->partition_flg = 0;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- return(uc_ret);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroXFstG
-* ABSTRACT : Vehicle Sensor GYRO SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroXFstG(const LSDRV_LSDATA_FST_GYRO_X *pst_data) {
- static u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- u_int8 partition_max; /* Total number of partitions */
- u_int8 partition_num; /* Data number */
-
- partition_max = pst_data->uc_partition_max;
- partition_num = pst_data->uc_partition_num;
-
- pst_master = &gstGyroXFst_l;
-
- if (partition_max == 1) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data,
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 0;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- } else if (partition_max == 2) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- if (partition_num == 1) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Compare data master and received data */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->partition_flg = 1;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- } else if (partition_num == 2) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Compare data master and received data */
- if (uc_ret == VEHICLESENS_EQ) {
- uc_ret = VehicleSensmemcmp(&pst_master->uc_data[VEHICLE_DSIZE_GYRO_X_FST],
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- }
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 1;
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- memcpy(&pst_master->uc_data[VEHICLE_DSIZE_GYRO_X_FST], pst_data->uc_data, pst_data->uc_size);
- } else {}
- } else {}
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroXFstl
-* ABSTRACT : Vehicle Sensor GYRO GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroXFstl(VEHICLESENS_DATA_MASTER_FST *pst_data) {
- const VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstGyroXFst_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->partition_flg = pst_master->partition_flg;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
-
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroX_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroX_l.cpp
deleted file mode 100755
index af90e25..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroX_l.cpp
+++ /dev/null
@@ -1,128 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroX_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GYRO_X)
- * Module configuration :VehicleSensInitGyroXl() Vehicle Sensor GYRO Initialization Functions
- * :VehicleSensSetGyroXl() Vehicle Sensor GYRO SET Functions
- * :VehicleSensGetGyroXl() Vehicle Sensor GYRO GET Functions
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstGyroX_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroXl
-* ABSTRACT : Vehicle Sensor GYRO_X Initialization Functions
-* FUNCTION : GYRO data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroXl(void) {
- memset(&gstGyroX_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstGyroX_l.ul_did = POSHAL_DID_GYRO_X;
- gstGyroX_l.us_size = VEHICLE_DSIZE_GYRO_X;
- gstGyroX_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroXl
-* ABSTRACT : Vehicle Sensor GYRO_X SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroXl(const LSDRV_LSDATA *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroX_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)pst_data->uc_size);
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroXlG
-* ABSTRACT : Vehicle Sensor GYRO_X SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroXlG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroX_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroXl
-* ABSTRACT : Vehicle Sensor GYRO_X GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroXl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroX_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->uc_snscnt = pst_master->uc_snscnt;
- (void)memcpy(reinterpret_cast<void *>(pst_data->uc_data),
- (const void *)(pst_master->uc_data), (size_t)(pst_master->us_size));
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroY.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroY.cpp
deleted file mode 100755
index b7d0e5a..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroY.cpp
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroY.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GYRO_Y)
- * Module configuration :VehicleSensGetGyroY() Vehicle Sensor GYRO GET Functions
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroY
-* ABSTRACT : Vehicle Sensor GYRO_Y GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroY(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroYl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroYExt
-* ABSTRACT : Vehicle Sensor GYRO_Y GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroYExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) {
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- break;
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroYExtl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroYFst
-* ABSTRACT : Vehicle Sensor GYRO_Y GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroYFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroYFstl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroYExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroYExt_l.cpp
deleted file mode 100755
index 898dafb..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroYExt_l.cpp
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroYExt_l.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GYRO_EXT)
- * Module configuration :VehicleSensInitGyroYExtl() Vehicle Sensor GYRO (Initial Delivery) Initialization Functions
- * :VehicleSensSetGyroYExtlG() Vehicle Sensor GYRO (Initial Delivery) Set Functions
- * :VehicleSensGetGyroYExtl() Vehicle Sensor GYRO (Initial Delivery) Get Functions
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_EXT gstGyroYExt_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroYExtl
-* ABSTRACT : Vehicle Sensor GYRO_Y Initialization Functions(Initial delivery)
-* FUNCTION : GYRO data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroYExtl(void) {
- u_int16 *pus;
-
- memset(&gstGyroYExt_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- gstGyroYExt_l.ul_did = POSHAL_DID_GYRO_Y;
- gstGyroYExt_l.us_size = VEHICLE_DSIZE_GYRO_EXT_INIT;
-
- pus = reinterpret_cast<u_int16 *>(gstGyroYExt_l.uc_data);
- memset(reinterpret_cast<void*>(pus), VEHICLE_DINIT_GYRO, VEHICLE_DSIZE_GYRO_EXT);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroYExtlG
-* ABSTRACT : Vehicle Sensor GYRO_Y SET Functions(Initial delivery)
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-void VehicleSensSetGyroYExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_start = 0;
- u_int16 us_size = 0;
- u_int16 us_cnt = 0;
-
- pst_master = &gstGyroYExt_l;
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Retrieve the location where the received one is stored */
- us_start = gstPkgTempExt.start_point[GyroY];
-
- /* Stored in data master(Order of reception)*/
- if (us_start >= VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = pst_data->ul_did;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- for (us_cnt = 0; us_cnt < us_size; us_cnt++) {
- pst_master->uc_data[us_start * us_size + us_cnt] = (u_int8)(pst_data->uc_data[us_cnt]);
- }
-
- /* Update next storage start position and latest data storage position */
- us_start++;
- gstPkgTempExt.start_point[GyroY] = us_start;
-
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_GYRO_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + us_size);
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroYExtl
-* ABSTRACT : Vehicle Sensor GYRO_Y GET Functions(Initial delivery)
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroYExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- uint16_t us_size = 0;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &gstGyroYExt_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[GyroY];
- }
-
- /* Acquire data from the oldest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[GyroY] + us_cnt < VEHICLE_DKEEP_MAX) {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[(gstPkgTempExt.start_point[GyroY] + us_cnt) * us_size], us_size);
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_loop_cnt * us_size], us_size);
- us_loop_cnt++;
- }
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_cnt * us_size], us_size);
- }
- }
-}
-#endif // CONFIG_SENSOR_EXT_VALID
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroYFst_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroYFst_l.cpp
deleted file mode 100755
index 164cf4d..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroYFst_l.cpp
+++ /dev/null
@@ -1,169 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroYFst_l.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GYRO_Y_FST)
- * Module configuration :VehicleSensInitGyroYFstl() Vehicle sensor GYRO (initial sensor) initialization functions
- * :VehicleSensSetGyroYFstl() Vehicle sensor GYRO (initial sensor) SET-function
- * :VehicleSensSetGyroYFstG() Vehicle sensor GYRO (initial sensor) SET-function
- * :VehicleSensGetGyroYFstl() Vehicle sensor GYRO (initial sensor) GET-function
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_FST gstGyroYFst_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroYFstl
-* ABSTRACT : Vehicle Sensor GYRO_Y Initialization Functions
-* FUNCTION : GYRO data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroYFstl(void) {
- u_int16 *pus;
-
- memset(&gstGyroYFst_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_FST));
- gstGyroYFst_l.ul_did = POSHAL_DID_GYRO_Y_FST;
- gstGyroYFst_l.us_size = 0;
- gstGyroYFst_l.partition_flg = 0;
-
- pus = reinterpret_cast<u_int16 *>(gstGyroYFst_l.uc_data);
- memset(reinterpret_cast<void*>(pus), VEHICLE_DINIT_GYRO_Y, VEHICLE_DSIZE_GYRO_Y_FST);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroYFstl
-* ABSTRACT : Vehicle Sensor GYRO_Y SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroYFstl(const LSDRV_LSDATA_FST *pst_data) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstGyroYFst_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data,
- pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->partition_flg = 0;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- return(uc_ret);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroYFstG
-* ABSTRACT : Vehicle Sensor GYRO_Y SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroYFstG(const LSDRV_LSDATA_FST_GYRO_Y *pst_data) {
- static u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- u_int8 partition_max; /* Total number of partitions */
- u_int8 partition_num; /* Data number */
-
- partition_max = pst_data->uc_partition_max;
- partition_num = pst_data->uc_partition_num;
-
- pst_master = &gstGyroYFst_l;
-
- if (partition_max == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data,
- pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 0;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_max == 2) {
- if (partition_num == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->partition_flg = 1;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_num == 2) {
- /* Compare data master and received data */
- if (uc_ret == VEHICLESENS_EQ) {
- uc_ret = VehicleSensmemcmp(&pst_master->uc_data[VEHICLE_DSIZE_GYRO_Y_FST],
- pst_data->uc_data, pst_data->uc_size);
- }
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 1;
- memcpy(&pst_master->uc_data[VEHICLE_DSIZE_GYRO_Y_FST], pst_data->uc_data, pst_data->uc_size);
- } else {}
- } else {}
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroYFstl
-* ABSTRACT : Vehicle Sensor GYRO_Y GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroYFstl(VEHICLESENS_DATA_MASTER_FST *pst_data) {
- const VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstGyroYFst_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->partition_flg = pst_master->partition_flg;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroY_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroY_l.cpp
deleted file mode 100755
index 9799b29..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroY_l.cpp
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroY_l.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GYRO_Y)
- * Module configuration :VehicleSensInitGyroYl() Vehicle Sensor GYRO Initialization Functions
- * :VehicleSensSetGyroYl() Vehicle Sensor GYRO SET Functions
- * :VehicleSensGetGyroYl() Vehicle Sensor GYRO GET Functions
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstGyroY_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroYl
-* ABSTRACT : Vehicle Sensor GYRO_Y Initialization Functions
-* FUNCTION : GYRO data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroYl(void) {
- memset(&gstGyroY_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstGyroY_l.ul_did = POSHAL_DID_GYRO_Y;
- gstGyroY_l.us_size = VEHICLE_DSIZE_GYRO_Y;
- gstGyroY_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroYl
-* ABSTRACT : Vehicle Sensor GYRO_Y SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroYl(const LSDRV_LSDATA *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroY_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)pst_data->uc_size);
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroYlG
-* ABSTRACT : Vehicle Sensor GYRO_Y SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroYlG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroY_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroYl
-* ABSTRACT : Vehicle Sensor GYRO_Y GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroYl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroY_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->uc_snscnt = pst_master->uc_snscnt;
- (void)memcpy(reinterpret_cast<void *>(pst_data->uc_data),
- (const void *)(pst_master->uc_data), (size_t)(pst_master->us_size));
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZ.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZ.cpp
deleted file mode 100755
index 1b84af7..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZ.cpp
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroZ.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_GYRO_Z)
- * Module configuration :VehicleSensGetGyroZ() Vehicle Sensor GYRO GET Functions
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroZ
-* ABSTRACT : Vehicle Sensor GYRO_Z GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroZ(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroZl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroZExt
-* ABSTRACT : Vehicle Sensor GYRO_Z GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroZExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) {
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- break;
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroZExtl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroZFst
-* ABSTRACT : Vehicle Sensor GYRO_Z GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroZFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetGyroZFstl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZExt_l.cpp
deleted file mode 100755
index 9ef9996..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZExt_l.cpp
+++ /dev/null
@@ -1,148 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroZExt_l.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GYRO_EXT)
- * Module configuration :VehicleSensInitGyroxiZYExtl() Vehicle Sensor GYRO (Initial Delivery) Initialization Functions
- * :VehicleSensSetGyroZExtlG() Vehicle Sensor GYRO (Initial Delivery) Set Functions
- * :VehicleSensGetGyroZExtl() Vehicle Sensor GYRO (Initial Delivery) Get Functions
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_EXT gstGyroZExt_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroZExtl
-* ABSTRACT : Vehicle Sensor GYRO_Z Initialization Functions(Initial delivery)
-* FUNCTION : GYRO data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroZExtl(void) {
- u_int16 *pus;
-
- memset(&gstGyroZExt_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- gstGyroZExt_l.ul_did = POSHAL_DID_GYRO_Z;
- gstGyroZExt_l.us_size = VEHICLE_DSIZE_GYRO_EXT_INIT;
-
- pus = reinterpret_cast<u_int16 *>(gstGyroZExt_l.uc_data);
- memset(reinterpret_cast<void*>(pus), VEHICLE_DINIT_GYRO, VEHICLE_DSIZE_GYRO_EXT);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroZExtlG
-* ABSTRACT : Vehicle Sensor GYRO_Z SET Functions(Initial delivery)
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-void VehicleSensSetGyroZExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_start = 0;
- u_int16 us_size = 0;
- u_int16 us_cnt = 0;
-
- pst_master = &gstGyroZExt_l;
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Retrieve the location where the received one is stored */
- us_start = gstPkgTempExt.start_point[GyroZ];
-
- /* Stored in data master(Order of reception)*/
- if (us_start >= VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = pst_data->ul_did;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- for (us_cnt = 0; us_cnt < us_size; us_cnt++) {
- pst_master->uc_data[us_start * us_size + us_cnt] = (u_int8)(pst_data->uc_data[us_cnt]);
- }
-
- /* Update next storage start position and latest data storage position */
- us_start++;
- gstPkgTempExt.start_point[GyroZ] = us_start;
-
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_GYRO_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + us_size);
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroZExtl
-* ABSTRACT : Vehicle Sensor GYRO_Z GET Functions(Initial delivery)
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroZExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- uint16_t us_size = 0;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &gstGyroZExt_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[GyroZ];
- }
-
- /* Acquire data from the oldest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[GyroZ] + us_cnt < VEHICLE_DKEEP_MAX) {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[(gstPkgTempExt.start_point[GyroZ] + us_cnt) * us_size], us_size);
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_loop_cnt * us_size], us_size);
- us_loop_cnt++;
- }
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_cnt * us_size], us_size);
- }
- }
-}
-#endif // CONFIG_SENSOR_EXT_VALID
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZFst_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZFst_l.cpp
deleted file mode 100755
index 587f565..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZFst_l.cpp
+++ /dev/null
@@ -1,169 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroZFst_l.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GYRO_Z_FST)
- * Module configuration :VehicleSensInitGyroZFstl() Vehicle sensor GYRO (initial sensor) initialization functions
- * :VehicleSensSetGyroZFstl() Vehicle sensor GYRO (initial sensor) SET-function
- * :VehicleSensSetGyroZFstG() Vehicle sensor GYRO (initial sensor) SET-function
- * :VehicleSensGetGyroZFstl() Vehicle sensor GYRO (initial sensor) GET-function
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_FST gstGyroZFst_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroZFstl
-* ABSTRACT : Vehicle Sensor GYRO_Z Initialization Functions
-* FUNCTION : GYRO data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroZFstl(void) {
- u_int16 *pus;
-
- memset(&gstGyroZFst_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_FST));
- gstGyroZFst_l.ul_did = POSHAL_DID_GYRO_Z_FST;
- gstGyroZFst_l.us_size = 0;
- gstGyroZFst_l.partition_flg = 0;
-
- pus = reinterpret_cast<u_int16 *>(gstGyroZFst_l.uc_data);
- memset(reinterpret_cast<void*>(pus), VEHICLE_DINIT_GYRO_Z, VEHICLE_DSIZE_GYRO_Z_FST);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroZFstl
-* ABSTRACT : Vehicle Sensor GYRO_Z SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroZFstl(const LSDRV_LSDATA_FST *pst_data) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstGyroZFst_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data,
- pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->partition_flg = 0;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- return(uc_ret);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroZFstG
-* ABSTRACT : Vehicle Sensor GYRO_Z SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroZFstG(const LSDRV_LSDATA_FST_GYRO_Z *pst_data) {
- static u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- u_int8 partition_max; /* Total number of partitions */
- u_int8 partition_num; /* Data number */
-
- partition_max = pst_data->uc_partition_max;
- partition_num = pst_data->uc_partition_num;
-
- pst_master = &gstGyroZFst_l;
-
- if (partition_max == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data,
- pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 0;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_max == 2) {
- if (partition_num == 1) {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->partition_flg = 1;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
- } else if (partition_num == 2) {
- /* Compare data master and received data */
- if (uc_ret == VEHICLESENS_EQ) {
- uc_ret = VehicleSensmemcmp(&pst_master->uc_data[VEHICLE_DSIZE_GYRO_Z_FST],
- pst_data->uc_data, pst_data->uc_size);
- }
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 1;
- memcpy(&pst_master->uc_data[VEHICLE_DSIZE_GYRO_Z_FST], pst_data->uc_data, pst_data->uc_size);
- } else {}
- } else {}
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroZFstl
-* ABSTRACT : Vehicle Sensor GYRO_Z GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroZFstl(VEHICLESENS_DATA_MASTER_FST *pst_data) {
- const VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstGyroZFst_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->partition_flg = pst_master->partition_flg;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZ_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZ_l.cpp
deleted file mode 100755
index 8296dab..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_GyroZ_l.cpp
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * @copyright Copyright (c) 2019-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_GyroZ_l.cpp
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_GYRO_Z)
- * Module configuration :VehicleSensInitGyroZl() Vehicle Sensor GYRO Initialization Functions
- * :VehicleSensSetGyroZl() Vehicle Sensor GYRO SET Functions
- * :VehicleSensGetGyroZl() Vehicle Sensor GYRO GET Functions
- ******************************************************************************/
-
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstGyroZ_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitGyroZl
-* ABSTRACT : Vehicle Sensor GYRO_Z Initialization Functions
-* FUNCTION : GYRO data master initialization process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitGyroZl(void) {
- memset(&gstGyroZ_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstGyroZ_l.ul_did = POSHAL_DID_GYRO_Z;
- gstGyroZ_l.us_size = VEHICLE_DSIZE_GYRO_Z;
- gstGyroZ_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroZl
-* ABSTRACT : Vehicle Sensor GYRO_Z SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroZl(const LSDRV_LSDATA *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroZ_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)pst_data->uc_size);
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetGyroZlG
-* ABSTRACT : Vehicle Sensor GYRO_Z SET Functions
-* FUNCTION : Update the GYRO data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetGyroZlG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroZ_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetGyroZl
-* ABSTRACT : Vehicle Sensor GYRO_Z GET Functions
-* FUNCTION : Provide a GYRO data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetGyroZl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstGyroZ_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->uc_snscnt = pst_master->uc_snscnt;
- (void)memcpy(reinterpret_cast<void *>(pst_data->uc_data),
- (const void *)(pst_master->uc_data), (size_t)(pst_master->us_size));
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude.cpp
deleted file mode 100755
index 167fa0a..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude.cpp
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/****************************************************************************
-@file VehicleSens_Did_LocationAltitude.cpp
-@detail Altitude information data master management
-******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************
- * Global variable *
- *************************************************/
-
-/****************************************************************************
-@brief VehicleSensGetLocationAltitude<BR>
- Altitude Information Data Master GET Processing
-@outline Provide an altitude information data master
-@param[in] u_int8 uc_get_method : Acquisition method(GPS or Navi)
-@param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensGetLocationAltitude(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:no other parameter pass in
- case VEHICLESENS_GETMETHOD_GPS:
- {
- /** To acquire from GPS */
- VehicleSensGetLocationAltitudeG(pst_data);
- break;
- }
- case VEHICLESENS_GETMETHOD_NAVI:
- {
- /** To acquire from NAVI */
- VehicleSensGetLocationAltitudeN(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude_g.cpp
deleted file mode 100755
index cae429c..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude_g.cpp
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/****************************************************************************
-@file VehicleSens_Did_LocationAltitude_g.cpp
-@detail Altitude information data master management(NMEA information)
-******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "CommonDefine.h"
-
-/*************************************************
- * Global variable *
- *************************************************/
-static VEHICLESENS_DATA_MASTER gstLocationAltitude_g; // NOLINT(readability/nolint)
-
-/****************************************************************************
-@brief VehicleSensInitLocationAltitudeG<BR>
- Altitude information data master initialization processing(NMEA information)
-@outline Initialize the altitude information data master
-@param[in] none
-@param[out] none
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensInitLocationAltitudeG(void) {
- SENSORLOCATION_ALTITUDEINFO_DAT st_altitude;
-
- memset(&gstLocationAltitude_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstLocationAltitude_g.ul_did = VEHICLE_DID_LOCATION_ALTITUDE;
- /** Data size setting */
- gstLocationAltitude_g.us_size = sizeof(SENSORLOCATION_ALTITUDEINFO_DAT);
- /** Data content setting */
- memset(&st_altitude, 0x00, sizeof(st_altitude));
- st_altitude.getMethod = SENSOR_GET_METHOD_GPS;
- st_altitude.SyncCnt = 0x00;
- st_altitude.isEnable = SENSORLOCATION_STATUS_DISABLE;
- memcpy(&gstLocationAltitude_g.uc_data[0], &st_altitude, sizeof(st_altitude));
-}
-
-/****************************************************************************
-@brief VehicleSensSetLocationAltitudeG<BR>
- Altitude information data master SET processing(NMEA information)
-@outline Update the altitude information data master
-@param[in] u_int8 ucSensCnt : Sensor counter value
-@param[in] u_int8* pucDGGA : Double precision GGAInformation(_CWORD82_ NMEA)
-@param[out] none
-@return u_int8
-@retval VEHICLESENS_EQ : No data change
-@retval VEHICLESENS_NEQ : Data change
-*******************************************************************************/
-u_int8 VehicleSensSetLocationAltitudeG(const SENSORLOCATION_ALTITUDEINFO_DAT *pst_altitude) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstLocationAltitude_g;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_altitude, sizeof(SENSORLOCATION_ALTITUDEINFO_DAT));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_LOCATION_ALTITUDE;
- pst_master->us_size = sizeof(SENSORLOCATION_ALTITUDEINFO_DAT);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_altitude, sizeof(SENSORLOCATION_ALTITUDEINFO_DAT));
-
- return(uc_ret);
-}
-
-/****************************************************************************
-@brief VehicleSensGetLocationAltitudeG<BR>
- Altitude Information Data Master GET Processing(NMEA information)
-@outline Provide an altitude information data master
-@param[in] none
-@param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensGetLocationAltitudeG(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstLocationAltitude_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude_n.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude_n.cpp
deleted file mode 100755
index 1d6064f..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationAltitude_n.cpp
+++ /dev/null
@@ -1,121 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_LocationAltitude_n.cpp
- * @brief
- */
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "SensorLocation_API.h"
-#include "CommonDefine.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gstLocationAltitude_n; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Altitude information data master initialization processing(NAVI information)
- *
- * Initialize the altitude information data master
- *
- * @param[in] none
- * @param[out] none
- * @return none
- * @retval none
- */
-void VehicleSensInitLocationAltitudeN(void) {
- SENSORLOCATION_ALTITUDEINFO_DAT st_altitude;
-
- memset(&gstLocationAltitude_n, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstLocationAltitude_n.ul_did = VEHICLE_DID_LOCATION_ALTITUDE_NAVI;
-
- /** Data size setting */
- gstLocationAltitude_n.us_size = sizeof(SENSORLOCATION_ALTITUDEINFO_DAT);
-
- /** Data content setting */
- memset(&st_altitude, 0x00, sizeof(st_altitude));
- st_altitude.getMethod = SENSOR_GET_METHOD_NAVI;
- st_altitude.SyncCnt = 0x00;
- st_altitude.isEnable = SENSORLOCATION_STATUS_DISABLE;
- st_altitude.Altitude = 0x00;
- memcpy(&gstLocationAltitude_n.uc_data[0], &st_altitude, sizeof(st_altitude));
-
- return;
-}
-
-/**
- * @brief
- * Altitude information data master SET processing(NAVI information)
- *
- * Update the altitude information data master
- *
- * @param[in] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
- * @param[out] none
- * @return u_int8
- * @retval VEHICLESENS_EQ : No data change
- * @retval VEHICLESENS_NEQ : Data change
- */
-u_int8 VehicleSensSetLocationAltitudeN(const SENSORLOCATION_ALTITUDEINFO_DAT *pst_altitude) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstLocationAltitude_n;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_altitude, sizeof(SENSORLOCATION_ALTITUDEINFO_DAT));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_LOCATION_ALTITUDE_NAVI;
- pst_master->us_size = sizeof(SENSORLOCATION_ALTITUDEINFO_DAT);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_altitude, sizeof(SENSORLOCATION_ALTITUDEINFO_DAT));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Altitude Information Data Master GET Processing(NAVI information)
- *
- * Provide an altitude information data master
- *
- * @param[in] none
- * @param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
- * @return none
- * @retval none
- */
-void VehicleSensGetLocationAltitudeN(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstLocationAltitude_n;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationInfoNmea.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationInfoNmea.cpp
deleted file mode 100755
index 496e5ac..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationInfoNmea.cpp
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * @copyright Copyright (c) 2018-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**************************************************************************//**
-@file VehicleSens_Did_LocationInfoNmea.cpp
-@detail Location Information (NMEA) Management of information data master
-******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************
- * Global variable *
- *************************************************/
-
-/**************************************************************************//**
-@brief VehicleSens_GetLocationInfoNmea<BR>
- Location Information (NMEA) Information Data Master GET Processing
-@outline Location Information (NMEA) Provide an information data master
-@param[in] u_int8 ucGetMethod : Acquisition method(GPS or Navi)
-@param[out] VEHICLESENS_DATA_MASTER_GPS_FORMAT *pstData : Pointer to the data master acquisition destination
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSens_GetLocationInfoNmea(VEHICLESENS_DATA_MASTER_GPS_FORMAT *pstData, u_int8 ucGetMethod)
-{
- switch(ucGetMethod)
- {
- case VEHICLESENS_GETMETHOD_NAVI:
- {
- VehicleSens_GetLocationInfoNmea_n(pstData);
- break;
- }
-
- default:
- break;
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationInfoNmea_n.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationInfoNmea_n.cpp
deleted file mode 100755
index 048e522..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationInfoNmea_n.cpp
+++ /dev/null
@@ -1,118 +0,0 @@
-/*
- * @copyright Copyright (c) 2018-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_LocationInfoNmea_n.cpp
- * @brief
- */
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "SensorLocation_API.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER_GPS_FORMAT gstLocationInfoNmea_n;
-
-/**
- * @brief
- * Location Information (NMEA) Initialization of information data master(NAVI information)
- *
- * Location Information (NMEA) Initialize the information data master
- *
- * @param[in] none
- * @param[out] none
- * @return none
- */
-void VehicleSens_InitLocationInfoNmea_n(void)
-{
- POS_LOCATIONINFO_NMEA stLocInfoNmea;
-
- _pb_memset(&gstLocationInfoNmea_n, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_FORMAT));
-
- /* Set Data ID */
- gstLocationInfoNmea_n.ul_did = VEHICLE_DID_LOCATIONINFO_NMEA_NAVI;
-
- /* Set Data Size */
- gstLocationInfoNmea_n.us_size = sizeof(POS_LOCATIONINFO_NMEA);
-
- /** Set Data itself */
- _pb_memset(&stLocInfoNmea, 0x00, sizeof(stLocInfoNmea));
- _pb_memcpy(&gstLocationInfoNmea_n.uc_data[0], &stLocInfoNmea, sizeof(stLocInfoNmea));
-
- return;
-}
-
-/**
- * @brief
- * Location Information (NMEA) Information data master SET process(NAVI information)
- *
- * Location Information (NMEA) Update the information data master
- *
- * @param[in] VEHICLESENS_DATA_MASTER_GPS_FORMAT *pstData : Pointer to the data master acquisition destination
- * @param[out] none
- * @return u_int8
- * @retval VEHICLESENS_EQ : No data change
- * @retval VEHICLESENS_NEQ : Data change
- */
-u_int8 VehicleSens_SetLocationInfoNmea_n( const POS_LOCATIONINFO_NMEA *pstLocInfoNmea )
-{
- u_int8 ucRet;
- VEHICLESENS_DATA_MASTER_GPS_FORMAT *pstMaster;
-
- pstMaster = &gstLocationInfoNmea_n;
-
- /* Compare Received Data with Master Data */
- ucRet = VehicleSensmemcmp( pstMaster->uc_data, pstLocInfoNmea, sizeof(POS_LOCATIONINFO_NMEA) );
-
- /* Set Received Data as Master Data */
- pstMaster->ul_did = VEHICLE_DID_LOCATIONINFO_NMEA_NAVI;
- pstMaster->us_size = sizeof(POS_LOCATIONINFO_NMEA);
- pstMaster->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- _pb_memcpy(pstMaster->uc_data, pstLocInfoNmea, sizeof(POS_LOCATIONINFO_NMEA));
-
- return ucRet;
-}
-
-/**
- * @brief
- * Location Information (NMEA) Information Data Master GET Processing(NAVI information)
- *
- * Location Information (NMEA) Provide an information data master
- *
- * @param[in] none
- * @param[out] VEHICLESENS_DATA_MASTER_GPS_FORMAT *pstData : Pointer to the data master acquisition destination
- * @return none
- * @retval none
- */
-void VehicleSens_GetLocationInfoNmea_n(VEHICLESENS_DATA_MASTER_GPS_FORMAT *pstData)
-{
- const VEHICLESENS_DATA_MASTER_GPS_FORMAT *pstMaster;
-
- pstMaster = &gstLocationInfoNmea_n;
-
- /* Set Master Data to Indicated Region */
- pstData->ul_did = pstMaster->ul_did;
- pstData->us_size = pstMaster->us_size;
- pstData->uc_rcvflag = pstMaster->uc_rcvflag;
- _pb_memcpy(pstData->uc_data, pstMaster->uc_data, pstMaster->us_size);
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat.cpp
deleted file mode 100755
index 1ae1b59..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat.cpp
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/****************************************************************************
-@file VehicleSens_Did_LocationLonLat.cpp
-@detail Latitude and longitudeManagement of information data master
-******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************
- * Global variable *
- *************************************************/
-
-/****************************************************************************
-@brief VehicleSensGetLocationLonLat<BR>
- Latitude and longitudeInformation Data Master GET Processing
-@outline Latitude and longitudeProvide an information data master
-@param[in] u_int8 uc_get_method : Acquisition method(GPS or Navi)
-@param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensGetLocationLonLat(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:other parameters cannot pass in
- case VEHICLESENS_GETMETHOD_GPS:
- {
- /** To acquire from GPS */
- VehicleSensGetLocationLonLatG(pst_data);
- break;
- }
- case VEHICLESENS_GETMETHOD_NAVI:
- {
- /** To acquire from NAVI */
- VehicleSensGetLocationLonLatnUnitCnv(pst_data);
- break;
- }
-
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat_g.cpp
deleted file mode 100755
index 07075c0..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat_g.cpp
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/****************************************************************************
-@file VehicleSens_Did_LocationLonLat_g.cpp
-@detail Latitude and longitudeManagement of information data master(NMEA information)
-******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "CommonDefine.h"
-
-/*************************************************
- * Global variable *
- *************************************************/
-static VEHICLESENS_DATA_MASTER gstLocationLonLat_g; // NOLINT(readability/nolint)
-
-/****************************************************************************
-@brief VehicleSensInitLocationLonLatG<BR>
- Latitude and longitudeInitialization of information data master(NMEA information)
-@outline Latitude and longitudeInitialize the information data master
-@param[in] none
-@param[out] none
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensInitLocationLonLatG(void) {
- SENSORLOCATION_LONLATINFO_DAT st_lonlat;
-
- memset(&gstLocationLonLat_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstLocationLonLat_g.ul_did = VEHICLE_DID_LOCATION_LONLAT;
- /** Data size setting */
- gstLocationLonLat_g.us_size = sizeof(SENSORLOCATION_LONLATINFO_DAT);
- /** Data content setting */
- memset(&st_lonlat, 0x00, sizeof(st_lonlat));
- st_lonlat.getMethod = SENSOR_GET_METHOD_GPS;
- st_lonlat.SyncCnt = 0x00;
- st_lonlat.isEnable = SENSORLOCATION_STATUS_DISABLE;
- memcpy(&gstLocationLonLat_g.uc_data[0], &st_lonlat, sizeof(st_lonlat));
-}
-
-/****************************************************************************
-@brief VehicleSensSetLocationLonLatG<BR>
- Latitude and longitudeInformation data master SET process(NMEA information)
-@outline Latitude and longitudeUpdate the information data master
-@param[in] SENSORLOCATION_LONLATINFO_DAT * pst_lonlat : Latitude and longitude information
-@param[out] none
-@return u_int8
-@retval VEHICLESENS_EQ : No data change
-@retval VEHICLESENS_NEQ : Data change
-*******************************************************************************/
-u_int8 VehicleSensSetLocationLonLatG(const SENSORLOCATION_LONLATINFO_DAT *pst_lonlat) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstLocationLonLat_g;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_lonlat, sizeof(SENSORLOCATION_LONLATINFO_DAT));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_LOCATION_LONLAT;
- pst_master->us_size = sizeof(SENSORLOCATION_LONLATINFO_DAT);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_lonlat, sizeof(SENSORLOCATION_LONLATINFO_DAT));
-
- return(uc_ret);
-}
-
-/****************************************************************************
-@brief VehicleSensGetLocationLonLatG<BR>
- Latitude and longitudeInformation Data Master GET Processing(NMEA information)
-@outline Latitude and longitudeProvide an information data master
-@param[in] none
-@param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensGetLocationLonLatG(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstLocationLonLat_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat_n.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat_n.cpp
deleted file mode 100755
index dcaecff..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_LocationLonLat_n.cpp
+++ /dev/null
@@ -1,163 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_LocationLonLat_n.cpp
- * @brief
- */
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "SensorLocation_API.h"
-#include "CommonDefine.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gstLocationLonLat_n; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Latitude and longitudeInitialization of information data master(NAVI information)
- *
- * Latitude and longitudeInitialize the information data master
- *
- * @param[in] none
- * @param[out] none
- * @return none
- * @retval none
- */
-void VehicleSensInitLocationLonLatN(void) {
- SENSORLOCATION_LONLATINFO_DAT st_lonlat;
-
- memset(&gstLocationLonLat_n, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstLocationLonLat_n.ul_did = VEHICLE_DID_LOCATION_LONLAT_NAVI;
-
- /** Data size setting */
- gstLocationLonLat_n.us_size = sizeof(SENSORLOCATION_LONLATINFO_DAT);
-
- /** Data content setting */
- memset(&st_lonlat, 0x00, sizeof(st_lonlat));
- st_lonlat.getMethod = SENSOR_GET_METHOD_NAVI;
- st_lonlat.SyncCnt = 0x00;
- st_lonlat.isEnable = SENSORLOCATION_STATUS_DISABLE;
- st_lonlat.posSts = 0x00;
- st_lonlat.posAcc = 0x00;
- st_lonlat.Longitude = 0x00;
- st_lonlat.Latitude = 0x00;
- memcpy(&gstLocationLonLat_n.uc_data[0], &st_lonlat, sizeof(st_lonlat));
-
- return;
-}
-
-/**
- * @brief
- * Latitude and longitudeInformation data master SET process(NAVI information)
- *
- * Latitude and longitudeUpdate the information data master
- *
- * @param[in] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
- * @param[out] none
- * @return u_int8
- * @retval VEHICLESENS_EQ : No data change
- * @retval VEHICLESENS_NEQ : Data change
- */
-u_int8 VehicleSensSetLocationLonLatN(const SENSORLOCATION_LONLATINFO_DAT *pst_lonlat) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstLocationLonLat_n;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_lonlat, sizeof(SENSORLOCATION_LONLATINFO_DAT));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_LOCATION_LONLAT_NAVI;
- pst_master->us_size = sizeof(SENSORLOCATION_LONLATINFO_DAT);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_lonlat, sizeof(SENSORLOCATION_LONLATINFO_DAT));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Latitude and longitudeInformation Data Master GET Processing(NAVI information)
- *
- * Latitude and longitudeProvide an information data master
- *
- * @param[in] none
- * @param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
- * @return none
- * @retval none
- */
-void VehicleSensGetLocationLonLatN(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstLocationLonLat_n;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-
- return;
-}
-
-/**
- * @brief
- * Latitude and longitudeInformation Data Master GET Processing(NAVI information)
- *
- * Latitude and longitudeProvide an information data master(Unit:10^-7th degree)
- *
- * @param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
- */
-void VehicleSensGetLocationLonLatnUnitCnv(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
- SENSORLOCATION_LONLATINFO_DAT st_lonlat;
- int32_t l_lon;
- int32_t l_lat;
- int64_t ll_tmp;
-
- pst_master = &gstLocationLonLat_n;
-
- /* Perform unit conversion[1/128Second] -> [10^-7 degree] */
- memcpy(&st_lonlat, pst_master->uc_data, sizeof(st_lonlat));
-
- /* Longitude */
- l_lon = st_lonlat.Longitude;
- ll_tmp = (int64_t)l_lon * 10000000;
- st_lonlat.Longitude = (int32_t)(ll_tmp / (128 * 60 * 60));
-
- /* Latitude */
- l_lat = st_lonlat.Latitude;
- ll_tmp = (int64_t)l_lat * 10000000;
- st_lonlat.Latitude = (int32_t)(ll_tmp / (128 * 60 * 60));
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, &st_lonlat, sizeof(st_lonlat));
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MainGpsInterruptSignal.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MainGpsInterruptSignal.cpp
deleted file mode 100755
index 7066324..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MainGpsInterruptSignal.cpp
+++ /dev/null
@@ -1,132 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_MainGpsInterruptSignal.cpp
- * System name :PastModel002
- * Subsystem name :GPS process
- * Program name :MAIN GPS interrupt data master(VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL)
- * Module configuration :VehicleSensInitMainGpsInterruptSignal() Vehicle sensor MAIN_GPS_INTERRUPT_SIGNAL initialization function
- * :VehicleSensSetMainGpsInterruptSignal() Vehicle sensor MAIN_GPS_INTERRUPT_SIGNAL SET function
- * :VehicleSensGetMainGpsInterruptSignal() Vehicle sensor MAIN_GPS_INTERRUPT_SIGNAL GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-#define VEHICLE_SENS_DID_MAIN_GPS_INTERRUPT_SIGNAL_DEBUG_FACTORY 0
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL gstMainGpsInterruptSignal; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitMainGpsInterruptSignal
-* ABSTRACT : Vehicle sensor MAIN_GPS_INTERRUPT_SIGNAL initialization function
-* FUNCTION : MAIN_GPS_INTERRUPT_SIGNAL data master initialization processing
-* ARGUMENT : None
-* NOTE :
-* RETURN : None
-******************************************************************************/
-void VehicleSensInitMainGpsInterruptSignal(void) {
- (void)memset(reinterpret_cast<void *>(&(gstMainGpsInterruptSignal)),
- static_cast<int>(0x00), sizeof(VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL));
- gstMainGpsInterruptSignal.ul_did = VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL;
- gstMainGpsInterruptSignal.us_size = VEHICLE_DSIZE_MAIN_GPS_INTERRUPT_SIGNAL;
- gstMainGpsInterruptSignal.uc_data = VEHICLE_DINIT_MAIN_GPS_INTERRUPT_SIGNAL;
-
-#if VEHICLE_SENS_DID_MAIN_GPS_INTERRUPT_SIGNAL_DEBUG_FACTORY
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] gstMainGpsInterruptSignal.uc_data.uc_data == 0x%x\r\n", gstMainGpsInterruptSignal.uc_data);
-#endif
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetMainGpsInterruptSignal
-* ABSTRACT : Vehicle sensor MAIN_GPS_INTERRUPT_SIGNALE SET function
-* FUNCTION : Update the Main_GPS_INTERRUPT_SIGNAL data master
-* ARGUMENT : *pst_data : Pointer to received message data
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetMainGpsInterruptSignal(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_master;
-
- if (pst_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "pst_data == NULL\r\n");
- } else {
- pst_master = &gstMainGpsInterruptSignal;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(reinterpret_cast<void *>(&(pst_master->uc_data)),
- (const void *)(&(pst_data->uc_data)), (size_t)(pst_data->us_size));
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- (void)memcpy(reinterpret_cast<void *>(&(pst_master->uc_data)),
- (const void *)(&(pst_data->uc_data)), sizeof(pst_master->uc_data));
-
-#if VEHICLE_SENS_DID_MAIN_GPS_INTERRUPT_SIGNAL_DEBUG_FACTORY
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] pst_data->ul_did == 0x%x", pst_data->ul_did);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] gstMainGpsInterruptSignal.ul_did == 0x%x\r\n", gstMainGpsInterruptSignal.ul_did);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] (u_int8)pst_data->us_size == 0x%x", (u_int8)pst_data->us_size);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] gstMainGpsInterruptSignal.us_size == 0x%x\r\n", gstMainGpsInterruptSignal.us_size);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] pst_data->uc_data == 0x%x", pst_data->uc_data[0]);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] gstMainGpsInterruptSignal.uc_data == 0x%x\r\n", gstMainGpsInterruptSignal.uc_data);
-#endif
- }
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetMainGpsInterruptSignal
-* ABSTRACT : Vehicle sensor MAIN_GPS_INTERRUPT_SIGNAL GET function
-* FUNCTION : Provide the MAIN_GPS_INTERRUPT_SIGNAL data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : None
-******************************************************************************/
-void VehicleSensGetMainGpsInterruptSignal(VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_master;
-
- if (pst_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "pst_data == NULL\r\n");
- } else {
- pst_master = &gstMainGpsInterruptSignal;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- (void)memcpy(reinterpret_cast<void *>(&(pst_data->uc_data)),
- (const void *)(&(pst_master->uc_data)), sizeof(pst_data->uc_data));
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Mon_Hw_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Mon_Hw_g.cpp
deleted file mode 100755
index 1859f76..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Mon_Hw_g.cpp
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_Mon_Hw_g.cpp
-@detail Master vehicle sensor data(VEHICLE_DID_GPS_UBLOX_MON_HW)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT gstMonHw_g; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief MON-HW vehicle sensor initialization function
-@outline MON-HW initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitMonHwG(void) {
- memset(&gstMonHw_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT));
- gstMonHw_g.ul_did = VEHICLE_DID_GPS_UBLOX_MON_HW;
- gstMonHw_g.us_size = VEHICLE_DSIZE_GPS_UBLOX_MON_HW + VEHICLE_DSIZE_GPS_UBLOX_HEADER_SIZE;
- gstMonHw_g.uc_data[0] = VEHICLE_DINIT_GPS_UBLOX_MON_HW;
-}
-
-/***************************************************************************
-@brief MON-HW SET vehicle sensor function
-@outline To update the master data MON-HW.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetMonHwG(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstMonHw_g;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_sensor_cnt = pst_data->uc_sns_cnt;
- pst_master->uc_gpscnt_flag = pst_data->uc_gps_cnt_flag;
-
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function MON-HW GET
-@outline Master Data provides the MON-HW
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetMonHwG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstMonHw_g;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- pst_data->uc_sns_cnt = pst_master->uc_sensor_cnt;
- pst_data->uc_gps_cnt_flag = pst_master->uc_gpscnt_flag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading.cpp
deleted file mode 100755
index 67a218e..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading.cpp
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/****************************************************************************
-@file VehicleSens_Did_MotionHeading.cpp
-@detail Orientation Information Data Master Management
-******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************
- * Global variable *
- *************************************************/
-
-/****************************************************************************
-@brief VehicleSensGetMotionHeading<BR>
- Compass Data Master GET Processing
-@outline Provide an orientation information data master
-@param[in] u_int8 uc_get_method : Acquisition method(GPS or Navi)
-@param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensGetMotionHeading(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:other parameters cannot pass in
- case VEHICLESENS_GETMETHOD_GPS:
- {
- /** To acquire from GPS */
- VehicleSensGetMotionHeadingG(pst_data);
- break;
- }
- case VEHICLESENS_GETMETHOD_NAVI:
- {
- /** To acquire from NAVI */
- VehicleSensGetMotionHeadingnCnvData(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading_g.cpp
deleted file mode 100755
index 751b199..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading_g.cpp
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/****************************************************************************
-@file VehicleSens_Did_MotionHeading_g.cpp
-@detail Orientation Information Data Master Management(NMEA information)
-******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "CommonDefine.h"
-
-/*************************************************
- * Global variable *
- *************************************************/
-static VEHICLESENS_DATA_MASTER gstMotionHeading_g; // NOLINT(readability/nolint)
-
-/****************************************************************************
-@brief VehicleSensInitMotionHeadingG<BR>
- Orientation information data master initialization process(NMEA information)
-@outline Initialize the orientation information data master
-@param[in] none
-@param[out] none
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensInitMotionHeadingG(void) {
- SENSORMOTION_HEADINGINFO_DAT st_heading;
-
- memset(&gstMotionHeading_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstMotionHeading_g.ul_did = VEHICLE_DID_MOTION_HEADING;
- /** Data size setting */
- gstMotionHeading_g.us_size = sizeof(SENSORMOTION_HEADINGINFO_DAT);
- /** Data content setting */
- memset(&st_heading, 0x00, sizeof(st_heading));
- st_heading.getMethod = SENSOR_GET_METHOD_GPS;
- st_heading.SyncCnt = 0x00;
- st_heading.isEnable = SENSORMOTION_STATUS_DISABLE;
- memcpy(&gstMotionHeading_g.uc_data[0], &st_heading, sizeof(st_heading));
-}
-
-/****************************************************************************
-@brief VehicleSensSetMotionHeadingG<BR>
- Compass Data Master SET Processing(NMEA information)
-@outline Update the orientation information data master
-@param[in] SENSORMOTION_HEADINGINFO_DAT* pst_heading : Bearing information
-@param[out] none
-@return u_int8
-@retval VEHICLESENS_EQ : No data change
-@retval VEHICLESENS_NEQ : Data change
-*******************************************************************************/
-u_int8 VehicleSensSetMotionHeadingG(const SENSORMOTION_HEADINGINFO_DAT *pst_heading) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstMotionHeading_g;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_heading,
- sizeof(SENSORMOTION_HEADINGINFO_DAT));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_MOTION_HEADING;
- pst_master->us_size = sizeof(SENSORMOTION_HEADINGINFO_DAT);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_heading, sizeof(SENSORMOTION_HEADINGINFO_DAT));
-
- return(uc_ret);
-}
-
-/****************************************************************************
-@brief VehicleSensGetMotionHeadingG<BR>
- Compass Data Master GET Processing(NMEA information)
-@outline Provide an orientation information data master
-@param[in] none
-@param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensGetMotionHeadingG(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstMotionHeading_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading_n.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading_n.cpp
deleted file mode 100755
index 4475b24..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionHeading_n.cpp
+++ /dev/null
@@ -1,162 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_MotionHeading_n.cpp
- * @brief
- */
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "SensorMotion_API.h"
-#include "CommonDefine.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gstMotionHeading_n; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Orientation information data master initialization process(NAVI information)
- *
- * Initialize the orientation information data master
- *
- * @param[in] none
- * @param[out] none
- * @return none
- * @retval none
- */
-void VehicleSensInitMotionHeadingN(void) {
- SENSORMOTION_HEADINGINFO_DAT st_heading;
-
- memset(&gstMotionHeading_n, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstMotionHeading_n.ul_did = VEHICLE_DID_MOTION_HEADING_NAVI;
-
- /** Data size setting */
- gstMotionHeading_n.us_size = sizeof(SENSORMOTION_HEADINGINFO_DAT);
-
- /** Data content setting */
- memset(&st_heading, 0x00, sizeof(st_heading));
- st_heading.getMethod = SENSOR_GET_METHOD_NAVI;
- st_heading.SyncCnt = 0x00;
- st_heading.isEnable = SENSORMOTION_STATUS_DISABLE;
- st_heading.posSts = 0x00;
- st_heading.Heading = 0x00;
- memcpy(&gstMotionHeading_n.uc_data[0], &st_heading, sizeof(st_heading));
-
- return;
-}
-
-/**
- * @brief
- * Compass Data Master SET Processing(NAVI information)
- *
- * Update the orientation information data master
- *
- * @param[in] VEHICLESENS_DATA_MASTER *pst_heading : Pointer to the data master acquisition destination
- * @param[out] none
- * @return u_int8
- * @retval VEHICLESENS_EQ : No data change
- * @retval VEHICLESENS_NEQ : Data change
- */
-u_int8 VehicleSensSetMotionHeadingN(const SENSORMOTION_HEADINGINFO_DAT *pst_heading) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstMotionHeading_n;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_heading, sizeof(SENSORMOTION_HEADINGINFO_DAT));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_MOTION_HEADING_NAVI;
- pst_master->us_size = sizeof(SENSORMOTION_HEADINGINFO_DAT);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_heading, sizeof(SENSORMOTION_HEADINGINFO_DAT));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Compass Data Master GET Processing(NAVI information)
- *
- * Provide an orientation information data master
- *
- * @param[in] none
- * @param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
- * @return none
- * @retval none
- */
-void VehicleSensGetMotionHeadingN(VEHICLESENS_DATA_MASTER *pst_data) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstMotionHeading_n;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-
- return;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Compass Data Master GET Processing(NAVI information)
- *
- * Providing orientation information data master with orientation and unit conversion
- *
- * @param[in] none
- * @param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
- * @return none
- * @retval none
- */
-void VehicleSensGetMotionHeadingnCnvData(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
- SENSORMOTION_HEADINGINFO_DAT st_heading;
- int16 i_heading;
-
- pst_master = &gstMotionHeading_n;
-
- /* Perform the orientation conversion[-179 to +180] -> [0 to 359] */
- memcpy(&st_heading, pst_master->uc_data, sizeof(st_heading));
- i_heading = static_cast<int16>(st_heading.Heading);
- if (i_heading > 0) {
- i_heading = static_cast<int16>(360 - i_heading);
- } else {
- i_heading = static_cast<int16>(i_heading * -1);
- }
- /* Perform unit conversion[Once] -> [0.01 degree] */
- st_heading.Heading = (u_int16)(i_heading * 100);
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, &st_heading, sizeof(st_heading));
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed.cpp
deleted file mode 100755
index 0f7abe3..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed.cpp
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_MotionSpeed.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Speed information data master GET processing
- *
- * @param[out] *pst_data - VEHICLESENS_DATA_MASTER Pointer to the data master acquisition destination
- * @param[in] uc_get_method - u_int8 acquisition method
- */
-void VehicleSensGetMotionSpeed(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:other parameters cannot pass in
- case VEHICLESENS_GETMETHOD_INTERNAL:
- {
- /** When acquiring internal calculation data */
- VehicleSensGetMotionSpeedI(pst_data);
- }
- break;
- case VEHICLESENS_GETMETHOD_NAVI:
- {
- /** To acquire NAVI data */
- VehicleSensGetMotionSpeedN(pst_data);
- break;
- }
- default:
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_g.cpp
deleted file mode 100755
index 9b8ae6c..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_g.cpp
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_MotionSpeed_g.cpp
- * @brief
- * Vehicle Speed Information Data Master Management(NMEA information)
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "CommonDefine.h"
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gstMotionSpeed_g; // NOLINT(readability/nolint)
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Speed information data master initialization process(NMEA information)
- */
-void VehicleSensInitMotionSpeedG(void) {
- SENSORMOTION_SPEEDINFO_DAT st_speed;
-
- memset(&gstMotionSpeed_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstMotionSpeed_g.ul_did = VEHICLE_DID_MOTION_SPEED;
- /** Data size setting */
- gstMotionSpeed_g.us_size = sizeof(SENSORMOTION_SPEEDINFO_DAT);
- /** Data content setting */
- memset(&st_speed, 0x00, sizeof(st_speed));
- st_speed.getMethod = SENSOR_GET_METHOD_GPS;
- st_speed.SyncCnt = 0x00;
- st_speed.isEnable = SENSORMOTION_STATUS_DISABLE;
- memcpy(&gstMotionSpeed_g.uc_data[0], &st_speed, sizeof(st_speed));
-}
-
-/**
- * @brief
- * Rate information data master SET process(NMEA information)
- *
- * @param[in] *pst_speed - SENSORMOTION_SPEEDINFO_DAT Pointer to vehicle speed information
- *
- * @return VEHICLESENS_EQ : No data change<br>
- * VEHICLESENS_NEQ : Data change
- */
-u_int8 VehicleSensSetMotionSpeedG(const SENSORMOTION_SPEEDINFO_DAT *pst_speed) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstMotionSpeed_g;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_speed, sizeof(SENSORMOTION_SPEEDINFO_DAT));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_MOTION_SPEED;
- pst_master->us_size = sizeof(SENSORMOTION_SPEEDINFO_DAT);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_speed, sizeof(SENSORMOTION_SPEEDINFO_DAT));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Speed information data master GET processing(NMEA information)
- *
- * @param[out] *pst_speed - VEHICLESENS_DATA_MASTER Pointer to the data master acquisition destination
- */
-void VehicleSensGetMotionSpeedG(VEHICLESENS_DATA_MASTER *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstMotionSpeed_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_i.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_i.cpp
deleted file mode 100755
index 7f01e2f..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_i.cpp
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_MotionSpeed_i.cpp
- * @brief
- * Vehicle Speed Information Data Master Management(Internal calculation information)
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "CommonDefine.h"
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gstMotionSpeed_i; // NOLINT(readability/nolint)
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Speed information data master initialization process(Internal calculation information)
- */
-void VehicleSensInitMotionSpeedI(void) {
- SENSORMOTION_SPEEDINFO_DAT st_speed;
-
- memset(&gstMotionSpeed_i, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstMotionSpeed_i.ul_did = VEHICLE_DID_MOTION_SPEED_INTERNAL;
- /** Data size setting */
- gstMotionSpeed_i.us_size = sizeof(SENSORMOTION_SPEEDINFO_DAT);
- /** Data content setting */
- memset(&st_speed, 0x00, sizeof(st_speed));
- st_speed.getMethod = SENSOR_GET_METHOD_POS;
- st_speed.SyncCnt = 0x00;
- st_speed.isEnable = SENSORMOTION_STATUS_DISABLE;
- memcpy(&gstMotionSpeed_i.uc_data[0], &st_speed, sizeof(st_speed));
-}
-
-/**
- * @brief
- * Rate information data master SET process(Internal calculation information)
- *
- * @param[in] *pst_speed - SENSORMOTION_SPEEDINFO_DAT Pointer to vehicle speed information
- *
- * @return VEHICLESENS_EQ : No data change<br>
- * VEHICLESENS_NEQ : Data change
- */
-u_int8 VehicleSensSetMotionSpeedI(const SENSORMOTION_SPEEDINFO_DAT *pst_speed) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstMotionSpeed_i;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_speed, sizeof(SENSORMOTION_SPEEDINFO_DAT));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_MOTION_SPEED_INTERNAL;
- pst_master->us_size = sizeof(SENSORMOTION_SPEEDINFO_DAT);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_speed, sizeof(SENSORMOTION_SPEEDINFO_DAT));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Speed information data master GET processing(Internal calculation information)
- *
- * @param[out] *pst_speed - VEHICLESENS_DATA_MASTER Pointer to the data master acquisition destination
- */
-void VehicleSensGetMotionSpeedI(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstMotionSpeed_i;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_n.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_n.cpp
deleted file mode 100755
index 9c8f5bc..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_MotionSpeed_n.cpp
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_MotionSpeed_n.cpp
- * @brief
- * Vehicle Speed Information Data Master Management(Navi information)
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-#include "CommonDefine.h"
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gstMotionSpeed_n; // NOLINT(readability/nolint)
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Speed information data master initialization process(Navi information)
- */
-void VehicleSensInitMotionSpeedN(void) {
- SENSORMOTION_SPEEDINFO_DAT st_speed;
-
- memset(&gstMotionSpeed_n, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstMotionSpeed_n.ul_did = VEHICLE_DID_MOTION_SPEED_NAVI;
- /** Data size setting */
- gstMotionSpeed_n.us_size = sizeof(SENSORMOTION_SPEEDINFO_DAT);
- /** Data content setting */
- memset(&st_speed, 0x00, sizeof(st_speed));
- st_speed.getMethod = SENSOR_GET_METHOD_NAVI;
- st_speed.SyncCnt = 0x00;
- st_speed.isEnable = SENSORMOTION_STATUS_DISABLE;
- memcpy(&gstMotionSpeed_n.uc_data[0], &st_speed, sizeof(st_speed));
-}
-
-/**
- * @brief
- * Rate information data master SET process(Navi information)
- *
- * @param[in] *pst_speed - SENSORMOTION_SPEEDINFO_DAT Pointer to vehicle speed information
- *
- * @return VEHICLESENS_EQ : No data change<br>
- * VEHICLESENS_NEQ : Data change
- */
-u_int8 VehicleSensSetMotionSpeedN(const SENSORMOTION_SPEEDINFO_DAT *pst_speed) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstMotionSpeed_n;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_speed, sizeof(SENSORMOTION_SPEEDINFO_DAT));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_MOTION_SPEED_NAVI;
- pst_master->us_size = sizeof(SENSORMOTION_SPEEDINFO_DAT);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_speed, sizeof(SENSORMOTION_SPEEDINFO_DAT));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Speed information data master GET processing(Navi information)
- *
- * @param[out] *pst_speed - VEHICLESENS_DATA_MASTER Pointer to the data master acquisition destination
- */
-void VehicleSensGetMotionSpeedN(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstMotionSpeed_n;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Clock_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Clock_g.cpp
deleted file mode 100755
index a9bc0c9..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Clock_g.cpp
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_Nav_Clock_g.cpp
-@detail Master vehicle sensor data(VEHICLE_DID_GPS_UBLOX_NAV_CLOCK)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT gstNavClock_g; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief NAV-CLOCK vehicle sensor initialization function
-@outline NAV-CLOCK initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitNavClockG(void) {
- memset(&gstNavClock_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT));
- gstNavClock_g.ul_did = VEHICLE_DID_GPS_UBLOX_NAV_CLOCK;
- gstNavClock_g.us_size = VEHICLE_DSIZE_GPS_UBLOX_NAV_CLOCK + VEHICLE_DSIZE_GPS_UBLOX_HEADER_SIZE;
- gstNavClock_g.uc_data[0] = VEHICLE_DINIT_GPS_UBLOX_NAV_CLOCK;
-}
-
-/***************************************************************************
-@brief NAV-CLOCK SET vehicle sensor function
-@outline To update the master data NAV-CLOCK.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetNavClockG(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavClock_g;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_sensor_cnt = pst_data->uc_sns_cnt;
- pst_master->uc_gpscnt_flag = pst_data->uc_gps_cnt_flag;
-
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function NAV-CLOCK GET
-@outline Master Data provides the NAV-CLOCK
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetNavClockG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavClock_g;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- pst_data->uc_sns_cnt = pst_master->uc_sensor_cnt;
- pst_data->uc_gps_cnt_flag = pst_master->uc_gpscnt_flag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Dop_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Dop_g.cpp
deleted file mode 100755
index 211e940..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Dop_g.cpp
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_Nav_Dop_g.cpp
-@detail Master vehicle sensor data(VEHICLE_DID_GPS_UBLOX_NAV_DOP)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT gstNavDop_g; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief NAV-DOP vehicle sensor initialization function
-@outline NAV-DOP initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitNavDopG(void) {
- memset(&gstNavDop_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT));
- gstNavDop_g.ul_did = VEHICLE_DID_GPS_UBLOX_NAV_DOP;
- gstNavDop_g.us_size = VEHICLE_DSIZE_GPS_UBLOX_NAV_DOP + VEHICLE_DSIZE_GPS_UBLOX_HEADER_SIZE;
- gstNavDop_g.uc_data[0] = VEHICLE_DINIT_GPS_UBLOX_NAV_DOP;
-}
-
-/***************************************************************************
-@brief NAV-DOP SET vehicle sensor function
-@outline To update the master data NAV-DOP.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetNavDopG(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavDop_g;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_sensor_cnt = pst_data->uc_sns_cnt;
- pst_master->uc_gpscnt_flag = pst_data->uc_gps_cnt_flag;
-
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function NAV-DOP GET
-@outline Master Data provides the NAV-DOP
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetNavDopG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavDop_g;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- pst_data->uc_sns_cnt = pst_master->uc_sensor_cnt;
- pst_data->uc_gps_cnt_flag = pst_master->uc_gpscnt_flag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Posllh_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Posllh_g.cpp
deleted file mode 100755
index 17ebc04..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Posllh_g.cpp
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_Nav_Posllh_g.cpp
-@detail Master vehicle sensor data(VEHICLE_DID_GPS_UBLOX_NAV_POSLLH)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT gstNavPosllh_g; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief NAV-POSLLH vehicle sensor initialization function
-@outline NAV-POSLLH initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitNavPosllhG(void) {
- memset(&gstNavPosllh_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT));
- gstNavPosllh_g.ul_did = VEHICLE_DID_GPS_UBLOX_NAV_POSLLH;
- gstNavPosllh_g.us_size = VEHICLE_DSIZE_GPS_UBLOX_NAV_POSLLH + VEHICLE_DSIZE_GPS_UBLOX_HEADER_SIZE;
- gstNavPosllh_g.uc_data[0] = VEHICLE_DINIT_GPS_UBLOX_NAV_POSLLH;
-}
-
-/***************************************************************************
-@brief NAV-POSLLH SET vehicle sensor function
-@outline To update the master data NAV-POSLLH.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetNavPosllhG(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavPosllh_g;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_sensor_cnt = pst_data->uc_sns_cnt;
- pst_master->uc_gpscnt_flag = pst_data->uc_gps_cnt_flag;
-
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function NAV-POSLLH GET
-@outline Master Data provides the NAV-POSLLH
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetNavPosllhG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavPosllh_g;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- pst_data->uc_sns_cnt = pst_master->uc_sensor_cnt;
- pst_data->uc_gps_cnt_flag = pst_master->uc_gpscnt_flag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Status_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Status_g.cpp
deleted file mode 100755
index f03d48f..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Status_g.cpp
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_Nav_Status_g.cpp
-@detail Master vehicle sensor data(VEHICLE_DID_GPS_UBLOX_NAV_STATUS)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT gstNavStatus_g; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief NAV-STATUS vehicle sensor initialization function
-@outline NAV-STATUS initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitNavStatusG(void) {
- memset(&gstNavStatus_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT));
- gstNavStatus_g.ul_did = VEHICLE_DID_GPS_UBLOX_NAV_STATUS;
- gstNavStatus_g.us_size = VEHICLE_DSIZE_GPS_UBLOX_NAV_STATUS + VEHICLE_DSIZE_GPS_UBLOX_HEADER_SIZE;
- gstNavStatus_g.uc_data[0] = VEHICLE_DINIT_GPS_UBLOX_NAV_STATUS;
-}
-
-/***************************************************************************
-@brief NAV-STATUS SET vehicle sensor function
-@outline To update the master data NAV-STATUS.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetNavStatusG(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavStatus_g;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_sensor_cnt = pst_data->uc_sns_cnt;
- pst_master->uc_gpscnt_flag = pst_data->uc_gps_cnt_flag;
-
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function NAV-STATUS GET
-@outline Master Data provides the NAV-STATUS
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetNavStatusG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavStatus_g;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- pst_data->uc_sns_cnt = pst_master->uc_sensor_cnt;
- pst_data->uc_gps_cnt_flag = pst_master->uc_gpscnt_flag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_SvInfo_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_SvInfo_g.cpp
deleted file mode 100755
index 7211ce8..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_SvInfo_g.cpp
+++ /dev/null
@@ -1,108 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_Nav_SvInfo_g.cpp
-@detail Master vehicle sensor data(VEHICLE_DID_GPS_UBLOX_NAV_SVINFO)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT gstNavSvInfo_g; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief NAV-SVINFO vehicle sensor initialization function
-@outline NAV-SVINFO initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitNavSvInfoG(void) {
- memset(&gstNavSvInfo_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT));
- gstNavSvInfo_g.ul_did = VEHICLE_DID_GPS_UBLOX_NAV_SVINFO;
- /* Initially, the maximum storage size is set.(Common header size(8) + NAV-SVINFO fixed-data-size(8) +
- *(Maximum number of channels(16) + Size of single channel data(12))) */
- gstNavSvInfo_g.us_size = (VEHICLE_DSIZE_GPS_UBLOX_HEADER_SIZE + VEHICLE_DSIZE_GPS_UBLOX_NAV_SVINFO) +
- (VEHICLE_DSIZE_GPS_UBLOX_NAV_SVINFO_CH_MAX * \
- VEHICLE_DSIZE_GPS_UBLOX_NAV_SVINFO_ALONE_MAX);
- gstNavSvInfo_g.uc_data[0] = VEHICLE_DINIT_GPS_UBLOX_NAV_SVINFO;
-}
-
-/***************************************************************************
-@brief NAV-SVINFO SET vehicle sensor function
-@outline To update the master data NAV-SVINFO.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetNavSvInfoG(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavSvInfo_g;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_sensor_cnt = pst_data->uc_sns_cnt;
- pst_master->uc_gpscnt_flag = pst_data->uc_gps_cnt_flag;
-
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function NAV-SVINFO GET
-@outline Master Data provides the NAV-SVINFO
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetNavSvInfoG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavSvInfo_g;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- pst_data->uc_sns_cnt = pst_master->uc_sensor_cnt;
- pst_data->uc_gps_cnt_flag = pst_master->uc_gpscnt_flag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_TimeGps_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_TimeGps_g.cpp
deleted file mode 100755
index 1d959cd..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_TimeGps_g.cpp
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_Nav_TimeGps_g.cpp
-@detail Master vehicle sensor data(VEHICLE_DID_GPS_UBLOX_NAV_TIMEGPS)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT gstNavTimeGps_g; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief NAV-TIMEGPS vehicle sensor initialization function
-@outline NAV-TIMEGPS initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitNavTimeGpsG(void) {
- memset(&gstNavTimeGps_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT));
- gstNavTimeGps_g.ul_did = VEHICLE_DID_GPS_UBLOX_NAV_TIMEGPS;
- gstNavTimeGps_g.us_size = VEHICLE_DSIZE_GPS_UBLOX_NAV_TIMEGPS + VEHICLE_DSIZE_GPS_UBLOX_HEADER_SIZE;
- gstNavTimeGps_g.uc_data[0] = VEHICLE_DINIT_GPS_UBLOX_NAV_TIMEGPS;
-}
-
-/***************************************************************************
-@brief NAV-TIMEGPS SET vehicle sensor function
-@outline To update the master data NAV-TIMEGPS.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetNavTimeGpsG(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavTimeGps_g;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_sensor_cnt = pst_data->uc_sns_cnt;
- pst_master->uc_gpscnt_flag = pst_data->uc_gps_cnt_flag;
-
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function NAV-TIMEGPS GET
-@outline Master Data provides the NAV-TIMEGPS
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetNavTimeGpsG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavTimeGps_g;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- pst_data->uc_sns_cnt = pst_master->uc_sensor_cnt;
- pst_data->uc_gps_cnt_flag = pst_master->uc_gpscnt_flag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_TimeUtc_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_TimeUtc_g.cpp
deleted file mode 100755
index 8368257..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_TimeUtc_g.cpp
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_Nav_TimeUtc_g.cpp
-@detail Master vehicle sensor data(VEHICLE_DID_GPS_UBLOX_NAV_TIMEUTC)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT gstNavTimeUtc_g; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief NAV-TIMEUTC vehicle sensor initialization function
-@outline NAV-TIMEUTC initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitNavTimeUtcG(void) {
- memset(&gstNavTimeUtc_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT));
- gstNavTimeUtc_g.ul_did = VEHICLE_DID_GPS_UBLOX_NAV_TIMEUTC;
- gstNavTimeUtc_g.us_size = VEHICLE_DSIZE_GPS_UBLOX_NAV_TIMEUTC + VEHICLE_DSIZE_GPS_UBLOX_HEADER_SIZE;
- gstNavTimeUtc_g.uc_data[0] = VEHICLE_DINIT_GPS_UBLOX_NAV_TIMEUTC;
-}
-
-/***************************************************************************
-@brief NAV-TIMEUTC SET vehicle sensor function
-@outline To update the master data NAV-TIMEUTC.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetNavTimeUtcG(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavTimeUtc_g;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_sensor_cnt = pst_data->uc_sns_cnt;
- pst_master->uc_gpscnt_flag = pst_data->uc_gps_cnt_flag;
-
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function NAV-TIMEUTC GET
-@outline Master Data provides the NAV-TIMEUTC
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetNavTimeUtcG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavTimeUtc_g;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- pst_data->uc_sns_cnt = pst_master->uc_sensor_cnt;
- pst_data->uc_gps_cnt_flag = pst_master->uc_gpscnt_flag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Velned_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Velned_g.cpp
deleted file mode 100755
index ad757aa..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Nav_Velned_g.cpp
+++ /dev/null
@@ -1,104 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_Nav_Velned_g.cpp
-@detail Master vehicle sensor data(VEHICLE_DID_GPS_UBLOX_NAV_VELNED)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT gstNavVelned_g; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief NAV-VELNED vehicle sensor initialization function
-@outline NAV-VELNED initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitNavVelnedG(void) {
- memset(&gstNavVelned_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT));
- gstNavVelned_g.ul_did = VEHICLE_DID_GPS_UBLOX_NAV_VELNED;
- gstNavVelned_g.us_size = VEHICLE_DSIZE_GPS_UBLOX_NAV_VELNED + VEHICLE_DSIZE_GPS_UBLOX_HEADER_SIZE;
- gstNavVelned_g.uc_data[0] = VEHICLE_DINIT_GPS_UBLOX_NAV_VELNED;
-}
-
-/***************************************************************************
-@brief NAV-VELNED SET vehicle sensor function
-@outline To update the master data NAV-VELNED.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : A pointer to the received data message or the direct line
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetNavVelnedG(const SENSOR_MSG_GPSDATA_DAT *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavVelned_g;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->us_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_sensor_cnt = pst_data->uc_sns_cnt;
- pst_master->uc_gpscnt_flag = pst_data->uc_gps_cnt_flag;
-
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->us_size);
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function NAV-VELNED GET
-@outline Master Data provides the NAV-VELNED
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetNavVelnedG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_UBLOX_FORMAT *pst_master;
-
- pst_master = &gstNavVelned_g;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- pst_data->uc_sns_cnt = pst_master->uc_sensor_cnt;
- pst_data->uc_gps_cnt_flag = pst_master->uc_gpscnt_flag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_NaviinfoDiagGPS_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_NaviinfoDiagGPS_g.cpp
deleted file mode 100755
index 7335ce1..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_NaviinfoDiagGPS_g.cpp
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/****************************************************************************
-@file VehicleSens_Did_NaviinfoDiagGPS_g.cpp
-@detail Management of GPS Information Master for Diag
-******************************************************************************/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************
- * Global variable *
- *************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_FORMAT gstNaviinfoDiagGPS_g; // NOLINT(readability/nolint)
-
-/****************************************************************************
-@brief VehicleSensInitNaviinfoDiagGPSg<BR>
- Initialization of GPS Data Master for Diag
-@outline Initializing GPS Data Master for Diag
-@param[in] none
-@param[out] none
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensInitNaviinfoDiagGPSg(void) {
- memset(&gstNaviinfoDiagGPS_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER_GPS_FORMAT));
-
- /** Data ID setting */
- gstNaviinfoDiagGPS_g.ul_did = VEHICLE_DID_NAVIINFO_DIAG_GPS;
- /** Data size setting */
- gstNaviinfoDiagGPS_g.us_size = sizeof(NAVIINFO_DIAG_GPS);
-}
-
-/****************************************************************************
-@brief VehicleSensSetNaviinfoDiagGPSg<BR>
- GPS Information Master SET Processing for Diag
-@outline Update the GPS Data Master for Diag
-@param[in] NAVIINFO_DIAG_GPS* pst_diag_data : GPS information for Diag
-@param[out] none
-@return u_int8
-@retval VEHICLESENS_EQ : No data change
-@retval VEHICLESENS_NEQ : Data change
-*******************************************************************************/
-u_int8 VehicleSensSetNaviinfoDiagGPSg(const NAVIINFO_DIAG_GPS *pst_diag_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_GPS_FORMAT *pst_master;
-
- pst_master = &gstNaviinfoDiagGPS_g;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_diag_data, sizeof(NAVIINFO_DIAG_GPS));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_NAVIINFO_DIAG_GPS;
- pst_master->us_size = sizeof(NAVIINFO_DIAG_GPS);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_diag_data, sizeof(NAVIINFO_DIAG_GPS));
-
- return(uc_ret);
-}
-
-/****************************************************************************
-@brief VehicleSensGetNaviinfoDiagGPSg<BR>
- GPS Information Master GET Processing for Diag
-@outline Provide a master GPS information for Diag
-@param[in] none
-@param[out] SENSOR_MSG_GPSDATA_DAT *pst_data : Pointer to the data master acquisition destination
-@return none
-@retval none
-*******************************************************************************/
-void VehicleSensGetNaviinfoDiagGPSg(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- const VEHICLESENS_DATA_MASTER_GPS_FORMAT *pst_master;
-
- pst_master = reinterpret_cast<VEHICLESENS_DATA_MASTER_GPS_FORMAT*>(&gstNaviinfoDiagGPS_g);
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTime.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTime.cpp
deleted file mode 100755
index cb80e6f..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTime.cpp
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_PulseTime.cpp
- * @brief
- * Vehicle sensor data master(VEHICLE_DID_PULSE_TIME)
- */
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/**
- * @brief
- * Vehicle sensor pulse time GET function
- *
- * Provide interpulse time data master
- *
- * @param[in] *pst_data: Pointer to the data master acquisition destination
- * @param[in] uc_get_method: Acquisition method(Direct Line or CAN)
- */
-void VehicleSensGetPulseTime(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetPulseTimel(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-/**
- * @brief
- * Vehicle sensor inter-pulse time (initial delivery) GET function
- *
- * Provide interpulse time data master
- *
- * @param[in] *pst_data: Pointer to the data master acquisition destination
- * @param[in] uc_get_method: Acquisition method(Direct Line or CAN)
- */
-void VehicleSensGetPulseTimeExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
-
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetPulseTimeExtl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-/**
- * @brief
- * Vehicle sensor pulse time (initial sensor) GET function
- *
- * Provide interpulse time data master
- *
- * @param[in] *pst_data: Pointer to the data master acquisition destination
- * @param[in] uc_get_method: Acquisition method(Direct Line or CAN)
- */
-
-void VehicleSensGetPulseTimeFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) { // LCOV_EXCL_START 8: dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- switch (uc_get_method) {
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- break;
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- break;
- }
- default:
- break;
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTimeExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTimeExt_l.cpp
deleted file mode 100755
index 04e66b5..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTimeExt_l.cpp
+++ /dev/null
@@ -1,143 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_PulseTimeExt_l.cpp
- * @brief
- * Vehicle sensor data master(POSHAL_DID_PULSE_TIME)
- */
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER_EXT g_st_pulsetime_ext_l; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Vehicle sensor inter-pulse time initialization function
- *
- * Inter-pulse time data master initialization processing
- */
-void VehicleSensInitPulseTimeExtl(void) {
- (void)memset(reinterpret_cast<void *>(&g_st_pulsetime_ext_l), 0, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- g_st_pulsetime_ext_l.ul_did = POSHAL_DID_PULSE_TIME;
- g_st_pulsetime_ext_l.us_size = VEHICLE_DSIZE_PULSE_TIME_EXT_INIT;
- g_st_pulsetime_ext_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/**
- * @brief
- * Vehicle sensor pulse time SET function
- *
- * Update the interpulse time data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- */
-void VehicleSensSetPulseTimeExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_size = 0;
- u_int16 us_start = 0;
- u_int16 us_cnt = 0;
-
- pst_master = &g_st_pulsetime_ext_l;
- /* 4byte * (Number of data items + 32 data items) */
- us_size = static_cast<u_int16>(sizeof(u_int32) * (1 + VEHICLE_SNS_INFO_PULSE_NUM));
-
- /* Retrieve the location where the received one is stored */
- us_start = gstPkgTempExt.start_point[PulseTime];
-
- /* Stored in data master(Order of reception)*/
- if (us_start >= VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = pst_data->ul_did;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- for (us_cnt = 0; us_cnt < us_size; us_cnt++) {
- pst_master->uc_data[us_start * us_size + us_cnt] = (u_int8)(pst_data->uc_data[us_cnt]);
- }
-
- /* Update next storage start position and latest data storage position */
- us_start++;
- gstPkgTempExt.start_point[PulseTime] = us_start;
-
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_PULSE_TIME_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + us_size);
- }
-}
-
-/**
- * @brief
- * Vehicle sensor pulse time GET function
- *
- * Provide interpulse time data master
- *
- * @param[in] Pointer to the data master acquisition destination
- */
-void VehicleSensGetPulseTimeExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_size = 0;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &g_st_pulsetime_ext_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- /* Size of one data item: 4byte * (Number of data items + 32 data items) */
- us_size = static_cast<u_int16>(sizeof(u_int32) * (1 + VEHICLE_SNS_INFO_PULSE_NUM));
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[PulseTime];
- }
-
- /* Acquire data from the oldest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[PulseTime] + us_cnt < VEHICLE_DKEEP_MAX) {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[(gstPkgTempExt.start_point[PulseTime] + us_cnt) * us_size], us_size);
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_loop_cnt * us_size], us_size);
- us_loop_cnt++;
- }
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_cnt * us_size], us_size);
- }
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTime_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTime_l.cpp
deleted file mode 100755
index 527bb72..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_PulseTime_l.cpp
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_PulseTime_l.cpp
- * @brief
- * Vehicle sensor data master(POSHAL_DID_PULSE_TIME)
- */
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstPulseTime_l; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Vehicle sensor inter-pulse time initialization function
- *
- * Inter-pulse time data master initialization processing
- */
-void VehicleSensInitPulseTimel(void) {
- memset(&gstPulseTime_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstPulseTime_l.ul_did = POSHAL_DID_PULSE_TIME;
- gstPulseTime_l.us_size = VEHICLE_DSIZE_PULSE_TIME;
- gstPulseTime_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/**
- * @brief
- * Vehicle sensor inter-pulse time initialization function
- *
- * Update the interpulse time data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ No data change<br>
- * VEHICLESENS_NEQ Data change
- */
-u_int8 VehicleSensSetPulseTimelG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstPulseTime_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Vehicle sensor pulse time GET function
- *
- * Provide interpulse time data master
- *
- * @param[in] Pointer to the data master acquisition destination
- */
-void VehicleSensGetPulseTimel(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstPulseTime_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Rev.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Rev.cpp
deleted file mode 100755
index 08c5ec7..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Rev.cpp
+++ /dev/null
@@ -1,118 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_Rev.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_REV)
- * Module configuration :VehicleSensGetRev() Vehicle Sensor REV GET Functions
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetRev
-* ABSTRACT : Vehicle Sensor REV GET Functions
-* FUNCTION : Provide a REV data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetRev(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetRevl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetRevFst
-* ABSTRACT : Vehicle sensor GET function
-* FUNCTION : Provide a data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetRevFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetRevFstl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-#endif
-
-/**
- * @brief
- * Vehicle Sensor REV GET Functions
- *
- * Provide a REV data master
- *
- * @param[in] *pst_data: Pointer to the data master acquisition destination
- * @param[in] uc_get_method: Acquisition method(Direct Line or CAN)
- *
- * @return none
- */
-void VehicleSensGetRevExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetRevExtl(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_RevExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_RevExt_l.cpp
deleted file mode 100755
index 0f4e5e6..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_RevExt_l.cpp
+++ /dev/null
@@ -1,134 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_RevExt_l.cpp
- * @brief
- * Vehicle sensor data master(POSHAL_DID_REV)
- */
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_EXT g_st_revext_l; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * Vehicle Sensor REV Initialization Functions
- *
- * REV data master initialization processing
- *
- * @param[in] none
- */
-void VehicleSensInitRevExtl(void) {
- u_int16 *pus;
-
- memset(&g_st_revext_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- g_st_revext_l.ul_did = POSHAL_DID_REV;
- g_st_revext_l.us_size = VEHICLE_DSIZE_REV_EXT_INIT;
- g_st_revext_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
- pus = reinterpret_cast<u_int16 *>(g_st_revext_l.uc_data);
- memset(reinterpret_cast<void*>(pus), VEHICLE_DINIT_SNS_COUNTER, VEHICLE_DSIZE_REV_EXT);
-}
-
-/**
- * @brief
- * Vehicle Sensor REV SET Functions
- *
- * Update the REV data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- */
-void VehicleSensSetRevExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_start = 0;
-
- pst_master = &g_st_revext_l;
-
- /* Retrieve the location where the received one is stored */
- us_start = gstPkgTempExt.start_point[Rev];
-
- /* Stored in data master(Order of reception)*/
- if (us_start >= VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = pst_data->ul_did;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_data[us_start] = pst_data->uc_data[0];
-
- /* Update next storage start position and latest data storage position */
- us_start++;
- gstPkgTempExt.start_point[Rev] = us_start;
-
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_REV_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + sizeof(u_int8));
- }
-}
-
-/**
- * @brief
- * Vehicle Sensor REV GET Functions
- *
- * Provide a REV data master
- *
- * @param[in] *pst_data : Pointer to the data master acquisition destination
- */
-void VehicleSensGetRevExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &g_st_revext_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[Rev];
- }
-
- /* Acquire data from the newest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[Rev] + us_cnt < VEHICLE_DKEEP_MAX) {
- pst_data->uc_data[us_cnt] = pst_master->uc_data[(gstPkgTempExt.start_point[Rev] + us_cnt)];
- } else {
- pst_data->uc_data[us_cnt] = pst_master->uc_data[us_loop_cnt];
- us_loop_cnt++;
- }
- } else {
- pst_data->uc_data[us_cnt] = pst_master->uc_data[us_cnt];
- }
- }
-}
-
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_RevFst_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_RevFst_l.cpp
deleted file mode 100755
index 49d4654..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_RevFst_l.cpp
+++ /dev/null
@@ -1,171 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_RevFst_l.cpp
- * System name :PastModel002
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_REV_FST)
- * Module configuration :VehicleSensInitRevFstl() Vehicle Sensor REV Initialization Functions
- * :VehicleSensSetRevFstl() Vehicle Sensor REV SET Functions
- * :VehicleSensSetRevFstG() Vehicle Sensor REV SET Functions
- * :VehicleSensGetRevFstl() Vehicle Sensor REV GET Functions
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_FST gstRevFst_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitRevFstl
-* ABSTRACT : Vehicle Sensor REV Initialization Functions
-* FUNCTION : REV data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitRevFstl(void) {
- (void)memset(reinterpret_cast<void *>(&gstRevFst_l), 0, sizeof (VEHICLESENS_DATA_MASTER_FST));
- gstRevFst_l.ul_did = POSHAL_DID_REV_FST;
- gstRevFst_l.us_size = 0U;
- gstRevFst_l.uc_rcvflag = 0U;
- gstRevFst_l.partition_flg = 0;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetRevFstl
-* ABSTRACT : Vehicle Sensor REV SET Functions
-* FUNCTION : Update the REV data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetRevFstl(const LSDRV_LSDATA_FST *pst_data) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstRevFst_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetRevFstG
-* ABSTRACT : Vehicle Sensor REV SET Functions
-* FUNCTION : Update the REV data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetRevFstG(const LSDRV_LSDATA_FST_REV *pst_data) {
- static u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstRevFst_l;
-
- u_int8 partition_max; /* Total number of partitions */
- u_int8 partition_num; /* Data number */
-
- partition_max = pst_data->uc_partition_max;
- partition_num = pst_data->uc_partition_num;
-
- if (partition_max == 1) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data,
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 0;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- } else if (partition_max == 2) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- if (partition_num == 1) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Compare data master and received data */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->partition_flg = 1;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- } else if (partition_num == 2) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Compare data master and received data */
- if (uc_ret == VEHICLESENS_EQ) {
- uc_ret = VehicleSensmemcmp(&pst_master->uc_data[VEHICLE_DSIZE_REV_FST],
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- }
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 1;
- memcpy(&pst_master->uc_data[VEHICLE_DSIZE_REV_FST],
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- } else {}
- } else {}
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetRevFstl
-* ABSTRACT : Vehicle Sensor REV GET Functions
-* FUNCTION : Provide a REV data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetRevFstl(VEHICLESENS_DATA_MASTER_FST *pst_data) {
- const VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstRevFst_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->partition_flg = pst_master->partition_flg;
- (void)memcpy(reinterpret_cast<void *>(pst_data->uc_data),
- (const void *)(pst_master->uc_data), (size_t)(pst_master->us_size));
-}
-
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Rev_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Rev_l.cpp
deleted file mode 100755
index 8a8178a..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_Rev_l.cpp
+++ /dev/null
@@ -1,157 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_Rev_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_REV)
- * Module configuration :VehicleSensInitRevl() Vehicle Sensor REV Initialization Functions
- * :VehicleSensSetRevl() Vehicle Sensor REV SET Functions
- * :VehicleSensGetRevl() Vehicle Sensor REV GET Functions
- * :VehicleSensGetRevline() Vehicle Sensor REV GET Functions(_LINE)
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstRev_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitRevl
-* ABSTRACT : Vehicle Sensor REV Initialization Functions
-* FUNCTION : REV data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitRevl(void) {
- memset(&gstRev_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstRev_l.ul_did = VEHICLE_DID_REV;
- gstRev_l.us_size = VEHICLE_DSIZE_REV;
- gstRev_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetRevl
-* ABSTRACT : Vehicle Sensor REV SET Functions
-* FUNCTION : Update the REV data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetRevl(const LSDRV_LSDATA *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstRev_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * Vehicle Sensor REV SET Functions
- *
- * Update the REV data master
- *
- * @param[in] *pst_data : Pointer to the message data received by the direct line
- *
- * @return VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
- */
-u_int8 VehicleSensSetRevlG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstRev_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetRevl
-* ABSTRACT : Vehicle Sensor REV GET Functions
-* FUNCTION : Provide a REV data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetRevl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstRev_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->uc_snscnt = pst_master->uc_snscnt;
- (void)memcpy(reinterpret_cast<void *>(pst_data->uc_data),
- (const void *)(pst_master->uc_data), (size_t)(pst_master->us_size));
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetRevline
-* ABSTRACT : Vehicle Sensor REV GET Functions(For direct lines)
-* FUNCTION : Provide a REV data master(For direct lines)
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetRevline(VEHICLESENS_DATA_MASTER *pst_data) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstRev_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = VEHICLE_DID_REV_LINE;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->uc_snscnt = pst_master->uc_snscnt;
- (void)memcpy(reinterpret_cast<void *>(pst_data->uc_data),
- (const void *)(pst_master->uc_data), (size_t)(pst_master->us_size));
-}
-// LCOV_EXCL_STOP
-
-
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SettingTime.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SettingTime.cpp
deleted file mode 100755
index b8db26c..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SettingTime.cpp
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_SettingTime.cpp
- * @brief
- */
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-
-/**
- * @brief
- * GPS setting time information data master GET process
- *
- * Provide the GPS setting time information data master
- *
- * @param[in] u_int8 uc_get_method : Acquisition method(NAVI)
- * @param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
- *
- * @return none
- * @retval none
- */
-void VehicleSensGetSettingTime(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:other parameters cannot pass in
- case VEHICLESENS_GETMETHOD_OTHER:
- {
- /** Acquiring from Clock */
- VehicleSensGetSettingTimeclock(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SettingTime_clock.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SettingTime_clock.cpp
deleted file mode 100755
index a415a84..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SettingTime_clock.cpp
+++ /dev/null
@@ -1,116 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_SettingTime_clock.cpp
- * @brief
- */
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gstSettingTime_clock; // NOLINT(readability/nolint)
-
-/**
- * @brief
- * GPS setting time information data master initialization process(NAVI information)
- *
- * Initialize the GPS setting time information data master
- *
- * @param[in] none
- * @param[out] none
- * @return none
- * @retval none
- */
-void VehicleSensInitSettingTimeclock(void) {
- POS_DATETIME st_time;
-
- memset(&gstSettingTime_clock, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstSettingTime_clock.ul_did = VEHICLE_DID_SETTINGTIME;
-
- /** Data size setting */
- gstSettingTime_clock.us_size = sizeof(POS_DATETIME);
-
- /** Data content setting */
- memset(&st_time, 0x00, sizeof(st_time));
- memcpy(&gstSettingTime_clock.uc_data[0], &st_time, sizeof(st_time));
-
- return;
-}
-
-/**
- * @brief
- * GPS setting time information data master SET process(NAVI information)
- *
- * Update the GPS setting time information data master
- *
- * @param[in] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
- * @param[out] none
- * @return u_int8
- * @retval VEHICLESENS_EQ : No data change
- * @retval VEHICLESENS_NEQ : Data change
- */
-u_int8 VehicleSensSetSettingTimeclock(const POS_DATETIME *pst_rcv_time) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSettingTime_clock;
-
- /** Compare the data master and generated data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_rcv_time, sizeof(POS_DATETIME));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = VEHICLE_DID_SETTINGTIME;
- pst_master->us_size = sizeof(POS_DATETIME);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_rcv_time, sizeof(POS_DATETIME));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * GPS setting time information data master GET process(NAVI information)
- *
- * Provide the GPS setting time information data master
- *
- * @param[in] none
- * @param[out] VEHICLESENS_DATA_MASTER *pst_data : Pointer to the data master acquisition destination
- * @return none
- * @retval none
- */
-void VehicleSensGetSettingTimeclock(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSettingTime_clock;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- return;
-}
-
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounter.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounter.cpp
deleted file mode 100755
index 6456125..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounter.cpp
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SnsCounter.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_SNS_COUNTER)
- * Module configuration :VehicleSensGetSnsCounter() Vehicle sensor SNS_COUNTER GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSnsCounter
-* ABSTRACT : Vehicle sensor SNS_COUNTER GET function
-* FUNCTION : Provide the SNS_COUNTER data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSnsCounter(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetSnsCounterl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetSnsCounterExt
-* ABSTRACT : Vehicle sensor SNS_COUNTER GET function
-* FUNCTION : Provide the SNS_COUNTER data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSnsCounterExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetSnsCounterExtl(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
-#endif
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounterExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounterExt_l.cpp
deleted file mode 100755
index 61b7a42..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounterExt_l.cpp
+++ /dev/null
@@ -1,155 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SnsCounterExt_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_SNS_COUNTER)
- * Module configuration :VehicleSensInitSnsCounterl() Vehicle sensor SNS_COUNTER initialization function
- * :VehicleSensSetSnsCounterl() Vehicle sensor SNS_COUNTER SET function
- * :VehicleSensGetSnsCounterl() Vehicle sensor SNS_COUNTER GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Response */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_EXT gstSnsCounterExt_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitSnsCounterExtl
-* ABSTRACT : Vehicle sensor SNS_COUNTER initialization function
-* FUNCTION : SNS_COUNTER data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitSnsCounterExtl(void) {
- u_int16 *pus;
-
- memset(&gstSnsCounterExt_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- gstSnsCounterExt_l.ul_did = POSHAL_DID_SNS_COUNTER;
- gstSnsCounterExt_l.us_size = VEHICLE_DSIZE_SNS_COUNTER_EXT_INIT;
- pus = reinterpret_cast<u_int16 *>(gstSnsCounterExt_l.uc_data);
- memset(reinterpret_cast<void*>(pus), VEHICLE_DINIT_SNS_COUNTER, VEHICLE_DSIZE_SNS_COUNTER_EXT);
-
- /* Initializing Initial Delivery Internal Information */
- memset(&gstPkgTempExt, 0x00, sizeof(VEHICLESENS_PKG_DELIVERY_TEMP_EXT));
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSnsCounterExtl
-* ABSTRACT : Vehicle sensor SNS_COUNTER SET function
-* FUNCTION : Update the SNS_COUNTER data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetSnsCounterExtl(const LSDRV_LSDATA *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- return;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSnsCounterExtlG
-* ABSTRACT : Vehicle sensor SNS_COUNTER SET function
-* FUNCTION : Update the SNS_COUNTER data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetSnsCounterExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_start = 0;
-
- pst_master = &gstSnsCounterExt_l;
-
- /* Retrieve the location where the received one is stored */
- us_start = gstPkgTempExt.start_point[SNSCounter];
-
- /* Stored in data master(Order of reception)*/
- if (us_start >= VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = pst_data->ul_did;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_data[us_start] = pst_data->uc_data[0];
-
- /* Update next storage start position and latest data storage position */
- us_start++;
- gstPkgTempExt.start_point[SNSCounter] = us_start;
-
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_SNS_COUNTER_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + sizeof(u_int8));
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSnsCounterExtl
-* ABSTRACT : Vehicle sensor SNS_COUNTER GET function
-* FUNCTION : Provide the SNS_COUNTER data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSnsCounterExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &gstSnsCounterExt_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[SNSCounter];
- }
-
- /* Acquire data from the newest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[SNSCounter] + us_cnt < VEHICLE_DKEEP_MAX) {
- pst_data->uc_data[us_cnt] = pst_master->uc_data[(gstPkgTempExt.start_point[SNSCounter] + us_cnt)];
- } else {
- pst_data->uc_data[us_cnt] = pst_master->uc_data[us_loop_cnt];
- us_loop_cnt++;
- }
- } else {
- pst_data->uc_data[us_cnt] = pst_master->uc_data[us_cnt];
- }
- }
-}
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounter_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounter_l.cpp
deleted file mode 100755
index b81b4b3..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SnsCounter_l.cpp
+++ /dev/null
@@ -1,124 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SnsCounter_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_SNS_COUNTER)
- * Module configuration :VehicleSensInitSnsCounterl() Vehicle sensor SNS_COUNTER initialization function
- * :VehicleSensSetSnsCounterl() Vehicle sensor SNS_COUNTER SET function
- * :VehicleSensGetSnsCounterl() Vehicle sensor SNS_COUNTER GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstSnsCounter_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitSnsCounterl
-* ABSTRACT : Vehicle sensor SNS_COUNTER initialization function
-* FUNCTION : SNS_COUNTER data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitSnsCounterl(void) {
- memset(&gstSnsCounter_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstSnsCounter_l.ul_did = POSHAL_DID_SNS_COUNTER;
- gstSnsCounter_l.us_size = VEHICLE_DSIZE_SNS_COUNTER;
- gstSnsCounter_l.uc_data[0] = VEHICLE_DINIT_SNS_COUNTER;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSnsCounterl
-* ABSTRACT : Vehicle sensor SNS_COUNTER SET function
-* FUNCTION : Update the SNS_COUNTER data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSnsCounterl(const LSDRV_LSDATA *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSnsCounter_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- return(uc_ret);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSnsCounterlG
-* ABSTRACT : Vehicle sensor SNS_COUNTER SET function
-* FUNCTION : Update the SNS_COUNTER data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSnsCounterlG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSnsCounter_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSnsCounterl
-* ABSTRACT : Vehicle sensor SNS_COUNTER GET function
-* FUNCTION : Provide the SNS_COUNTER data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSnsCounterl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSnsCounter_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedKmph.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedKmph.cpp
deleted file mode 100755
index 4705774..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedKmph.cpp
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SpeedKmph.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_SPEED_KMPH)
- * Module configuration :VehicleSensGetSpeedKmph() Vehicle Sensor SPEED_KMPH GET Function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSpeedKmph
-* ABSTRACT : Vehicle Sensor SPEED_KMPH GET Function
-* FUNCTION : Provide the SPEED_KMPH data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(DIRECT or CAN or NAVI)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSpeedKmph(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) {
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- break;
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetSpeedKmphl(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedKmph_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedKmph_l.cpp
deleted file mode 100755
index abbb27a..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedKmph_l.cpp
+++ /dev/null
@@ -1,156 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SpeedKmph_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_SPEED_KMPH)
- * Module configuration :VehicleSensInitSpeedKmphl() Vehicle sensor SPEED_KMPH initialization function
- * :VehicleSensSetSpeedKmphl() Vehicle sensor SPEED_KMPH SET function
- * :VehicleSensGetSpeedKmphl() Vehicle Sensor SPEED_KMPH GET Function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstSpeedKmph_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitSpeedKmphl
-* ABSTRACT : Vehicle sensor SPEED_KMPH initialization function
-* FUNCTION : SPEED_KMPH data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitSpeedKmphl(void) {
- u_int16 *pus;
-
- memset(&gstSpeedKmph_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
- gstSpeedKmph_l.ul_did = POSHAL_DID_SPEED_KMPH;
- gstSpeedKmph_l.us_size = VEHICLE_DSIZE_SPEED_KMPH;
-
- pus = reinterpret_cast<u_int16 *>(gstSpeedKmph_l.uc_data);
- *pus = VEHICLE_DINIT_SPEED_KMPH;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSpeedKmphl
-* ABSTRACT : Vehicle sensor SPEED_KMPH SET function
-* FUNCTION : Update the SPEED_KMPH data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSpeedKmphl(const LSDRV_LSDATA *pst_data) { // LCOV_EXCL_START 8: dead code.
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSpeedKmph_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data,
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size; /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- return(uc_ret);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSpeedKmphlG
-* ABSTRACT : Vehicle sensor SPEED_KMPH SET function
-* FUNCTION : Update the SPEED_KMPH data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSpeedKmphlG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- static u_int16 pre_speed[2] = {0, 0};
- u_int16 cur_speed = 0;
- memcpy(&cur_speed, &pst_data->uc_data[0], sizeof(u_int16));
-
- BOOL under2 = TRUE;
- BOOL eq_speed = TRUE;
-
- pst_master = &gstSpeedKmph_l;
-
- /* Transition of 0->1km/h and 1->0km/h requires 3 consecutive matches. Compliance with driving regulations */
- under2 = ((pre_speed[1] < 2) && (pre_speed[0] < 2) && (cur_speed < 2));
- eq_speed = ((pre_speed[1] == pre_speed[0]) && (pre_speed[0] == cur_speed));
-
- if ((under2 == TRUE) && (eq_speed != TRUE) && (pst_master->uc_rcvflag == VEHICLE_RCVFLAG_ON)) {
- uc_ret = VEHICLESENS_EQ; /* Return without data change */
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size; /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
-
- } else {
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data,
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size; /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- }
-
- /* For the next comparison,Update Speed */
- pre_speed[1] = pre_speed[0];
- pre_speed[0] = cur_speed;
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSpeedKmphl
-* ABSTRACT : Vehicle Sensor SPEED_KMPH GET Function
-* FUNCTION : Provide the SPEED_KMPH data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSpeedKmphl(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSpeedKmph_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulse.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulse.cpp
deleted file mode 100755
index 3f4ec8a..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulse.cpp
+++ /dev/null
@@ -1,117 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SpeedPulse.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_)
- * Module configuration :VehicleSensGetSpeedPulse() Vehicle sensor GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSpeedPulse
-* ABSTRACT : Vehicle sensor GET function
-* FUNCTION : Provide a data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSpeedPulse(VEHICLESENS_DATA_MASTER *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetSpeedPulsel(pst_data);
- break;
- }
- default:
- break;
- }
-}
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetSpeedPulseExt
-* ABSTRACT : Vehicle sensor GET function
-* FUNCTION : Provide a data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSpeedPulseExt(VEHICLESENS_DATA_MASTER_EXT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetSpeedPulseExtl(pst_data);
- break;
- }
- default: /* Ignore->MISRA-C++:2008 Rule 6-3-1, 6-4-1 */
- break;
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSpeedPulseFst
-* ABSTRACT : Vehicle sensor GET function
-* FUNCTION : Provide a data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSpeedPulseFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) { // LCOV_EXCL_BR_LINE 6:VEHICLESENS_GETMETHOD_CAN cannot to pass in
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- break; // LCOV_EXCL_LINE 8: dead code
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetSpeedPulseFstl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-#endif
-
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseExt_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseExt_l.cpp
deleted file mode 100755
index 86c8f49..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseExt_l.cpp
+++ /dev/null
@@ -1,150 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SpeedPulseExt_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_SPEED_PULSE)
- * Module configuration :VehicleSensInitSpeedPulseExtl() Vehicle sensor SPEED_PULSE initialization function
- * :VehicleSensSetSpeedPulseExtlG() Vehicle Sensor SPEED_PULSE SET Function
- * :VehicleSensGetSpeedPulseExtl() Vehicle Sensor SPEED_PULSE GET Function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/* Ignore->MISRA-C++:2008 Rule 2-7-2 */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_EXT gstSpeedPulseExt_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitSpeedPulseExtl
-* ABSTRACT : Vehicle sensor SPEED_PULSE initialization function
-* FUNCTION : SPEED_PULSE data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitSpeedPulseExtl(void) {
- u_int16 *pus;
-
- memset(&gstSpeedPulseExt_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_EXT));
- gstSpeedPulseExt_l.ul_did = POSHAL_DID_SPEED_PULSE;
- gstSpeedPulseExt_l.us_size = VEHICLE_DSIZE_SPEED_PULSE_EXT_INIT;
-
- pus = reinterpret_cast<u_int16 *>(gstSpeedPulseExt_l.uc_data);
- memset(reinterpret_cast<void*>(pus), VEHICLE_DINIT_SPEED_PULSE, VEHICLE_DSIZE_SPEED_PULSE_EXT);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSpeedPulseExtlG
-* ABSTRACT : Vehicle Sensor SPEED_PULSE SET Function
-* FUNCTION : Update the SPEED_PULSE data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-void VehicleSensSetSpeedPulseExtlG(const LSDRV_LSDATA_G *pst_data) {
- VEHICLESENS_DATA_MASTER_EXT *pst_master;
- u_int16 us_start = 0;
- u_int16 us_size = 0;
- u_int16 us_cnt = 0;
-
- pst_master = &gstSpeedPulseExt_l;
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Retrieve the location where the received one is stored */
- us_start = gstPkgTempExt.start_point[SpeedPulse];
-
- /* Stored in data master(Order of reception)*/
- if (us_start >= VEHICLE_DKEEP_MAX) {
- /* Store the latest one at position 0 */
- us_start = VEHICLE_DATA_POS_00;
- /* If you are discarding old data,,Set a flag */
- gstPkgTempExt.data_break = VEHICLE_SNS_BREAK;
- }
- pst_master->ul_did = pst_data->ul_did;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- for (us_cnt = 0; us_cnt < us_size; us_cnt++) {
- pst_master->uc_data[us_start * us_size + us_cnt] = (u_int8)(pst_data->uc_data[us_cnt]);
- }
-
- /* Update next storage start position and latest data storage position */
- us_start++;
- gstPkgTempExt.start_point[SpeedPulse] = us_start;
- /* Update data master size */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Make the size of all extended data masters */
- pst_master->us_size = VEHICLE_DSIZE_SPEED_PULSE_EXT;
- } else {
- /* Add the size of one received data item */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + us_size);
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSpeedPulseExtl
-* ABSTRACT : Vehicle Sensor SPEED_PULSE GET Function
-* FUNCTION : Provide the SPEED_PULSE data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSpeedPulseExtl(VEHICLESENS_DATA_MASTER_EXT *pst_data) {
- const VEHICLESENS_DATA_MASTER_EXT *pst_master;
- uint16_t us_size = 0;
- uint16_t us_data_cnt = 0; // Number of data contained
- uint16_t us_loop_cnt = 0; // 64 over index
-
- /* Store the data master in the specified destination. */
- pst_master = &gstSpeedPulseExt_l;
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
-
- us_size = static_cast<u_int16>(sizeof(u_int16) * 10); /* Size of one data item: 2byte * 10 data items */
-
- /* Checking whether the number of stored entries is looped */
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- us_data_cnt = VEHICLE_DKEEP_MAX;
- } else {
- us_data_cnt = gstPkgTempExt.start_point[SpeedPulse];
- }
-
- /* Acquire data from the newest data master */
- for (uint16_t us_cnt = 0; us_cnt < us_data_cnt; us_cnt++) {
- if (gstPkgTempExt.data_break == VEHICLE_SNS_BREAK) {
- /* Get information before loop */
- if (gstPkgTempExt.start_point[SpeedPulse] + us_cnt < VEHICLE_DKEEP_MAX) {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[(gstPkgTempExt.start_point[SpeedPulse] + us_cnt) * us_size], us_size);
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_loop_cnt * us_size], us_size);
- us_loop_cnt++;
- }
- } else {
- memcpy(&pst_data->uc_data[us_cnt * us_size],
- &pst_master->uc_data[us_cnt * us_size], us_size);
- }
- }
-}
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFlag.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFlag.cpp
deleted file mode 100755
index f6ab8df..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFlag.cpp
+++ /dev/null
@@ -1,133 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleSens_Did_Nav_Clock_g.cpp
-@detail Master vehicle sensor data(POSHAL_DID_SPEED_PULSE_FLAG)
-*****************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstSpeedPulseFlag; // NOLINT(readability/nolint)
-
-/***************************************************************************
-@brief VehicleSensInitSpeedPulseFlag
-@outline SPEED_PULSE_FLAG initialization process data master
-@type Completion return type
-@param[in] none
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensInitSpeedPulseFlag(void) {
- (void)memset(reinterpret_cast<void *>(&gstSpeedPulseFlag), 0, sizeof(VEHICLESENS_DATA_MASTER));
- gstSpeedPulseFlag.ul_did = POSHAL_DID_SPEED_PULSE_FLAG;
- gstSpeedPulseFlag.us_size = VEHICLE_DSIZE_SPEED_PULSE_FLAG;
- gstSpeedPulseFlag.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/***************************************************************************
-@brief NAV-CLOCK SET vehicle sensor function
-@outline To update the master data NAV-CLOCK.
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : The pointer to GPS incoming message data
-@threshold none
-@return u_int8
-@retval VEHICLESENS_EQ : No data changes
-@retval VEHICLESENS_NEQ : With data changes
-@trace
-*****************************************************************************/
-u_int8 VehicleSensSetSpeedPulseFlag(const LSDRV_LSDATA_G *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSpeedPulseFlag;
-
- /** Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /** Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/***************************************************************************
-@brief Vehicle sensor function NAV-CLOCK GET
-@outline Master Data provides the NAV-CLOCK
-@type Completion return type
-@param[in] SENSOR_MSG_GPSDATA_DAT *pst_data : Where to get a pointer to the data master
-@threshold none
-@return void
-@retval none
-@trace
-*****************************************************************************/
-void VehicleSensGetSpeedPulseFlag(VEHICLESENS_DATA_MASTER *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSpeedPulseFlag;
-
- /** Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->uc_snscnt = pst_master->uc_snscnt;
- (void)memcpy(reinterpret_cast<void *>(pst_data->uc_data),
- (const void *)(pst_master->uc_data), (size_t)(pst_master->us_size));
-}
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensGetSpeedPulseFlagFst
-* ABSTRACT : Vehicle sensor GET function
-* FUNCTION : Provide a data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* uc_get_method : Acquisition method(Direct Line or CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSpeedPulseFlagFst(VEHICLESENS_DATA_MASTER_FST *pst_data, u_int8 uc_get_method) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- switch (uc_get_method) {
- case VEHICLESENS_GETMETHOD_CAN:
- {
- /* When acquiring from CAN data */
- break;
- }
- case VEHICLESENS_GETMETHOD_LINE:
- {
- /* To acquire from LineSensor */
- VehicleSensGetSpeedPulseFlagFstl(pst_data);
- break;
- }
- default:
- break;
- }
-}
-#endif
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFlagFst_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFlagFst_l.cpp
deleted file mode 100755
index 051c6bb..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFlagFst_l.cpp
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SpeedPulseFlagFst_l.cpp
- * System name :PastModel002
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_SPEED_PULSE_FLAG_FST)
- * Module configuration :VehicleSensInitSpeedPulseFlagFstl() Vehicle sensor SPEED_PULSE_FLAG initialization function
- * :VehicleSensSetSpeedPulseFlagFstl() Vehicle Sensor SPEED_PULSE_FLAG SET Function
- * :VehicleSensSetSpeedPulseFlagFstG() Vehicle Sensor SPEED_PULSE_FLAG SET Function
- * :VehicleSensGetSpeedPulseFlagFstl() Vehicle Sensor SPEED_PULSE_FLAG GET Function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/* #Polaris_003 START */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Response */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensInitSpeedPulseFlagFstl
-* ABSTRACT : Vehicle sensor SPEED_PULSE_FLAG initialization function
-* FUNCTION : SPEED_PULSE_FLAG data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitSpeedPulseFlagFstl(void) {
- return;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSpeedPulseFlagFstl
-* ABSTRACT : Vehicle Sensor SPEED_PULSE_FLAG SET Function
-* FUNCTION : Update the SPEED_PULSE_FLAG data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSpeedPulseFlagFstl(const LSDRV_LSDATA_FST *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- return(VEHICLESENS_EQ);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSpeedPulseFlagFstG
-* ABSTRACT : Vehicle Sensor SPEED_PULSE_FLAG SET Function
-* FUNCTION : Update the SPEED_PULSE_FLAG data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSpeedPulseFlagFstG(const LSDRV_LSDATA_FST_SPEED_PULSE_FLAG *pst_data) {
- return VEHICLESENS_EQ;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSpeedPulseFlagFstl
-* ABSTRACT : Vehicle Sensor SPEED_PULSE_FLAG GET Function
-* FUNCTION : Provide the SPEED_PULSE_FLAG data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSpeedPulseFlagFstl(VEHICLESENS_DATA_MASTER_FST *pst_data) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- return;
-}
-
-#endif
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFst_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFst_l.cpp
deleted file mode 100755
index 26952b3..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulseFst_l.cpp
+++ /dev/null
@@ -1,172 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SpeedPulseFst_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_SPEED_PULSE_FST)
- * Module configuration :VehicleSensInitSpeedPulseFstl() Vehicle sensor SPEED_PULSE initialization function
- * :VehicleSensSetSpeedPulseFstl() Vehicle Sensor SPEED_PULSE SET Function
- * :VehicleSensSetSpeedPulseFstG() Vehicle Sensor SPEED_PULSE SET Function
- * :VehicleSensGetSpeedPulseFstl() Vehicle Sensor SPEED_PULSE GET Function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_FST gstSpeedPulseFst_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitSpeedPulseFstl
-* ABSTRACT : Vehicle sensor SPEED_PULSE initialization function
-* FUNCTION : SPEED_PULSE data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitSpeedPulseFstl(void) {
- u_int16 *pus;
-
- memset(&gstSpeedPulseFst_l, 0x00, sizeof(VEHICLESENS_DATA_MASTER_FST));
- gstSpeedPulseFst_l.ul_did = POSHAL_DID_SPEED_PULSE_FST;
- gstSpeedPulseFst_l.us_size = 0;
- gstSpeedPulseFst_l.partition_flg = 0;
- pus = reinterpret_cast<u_int16 *>(gstSpeedPulseFst_l.uc_data);
- memset(reinterpret_cast<void*>(pus), VEHICLE_DINIT_SPEED_PULSE, VEHICLE_DSIZE_SPEED_PULSE_FST);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSpeedPulseFstl
-* ABSTRACT : Vehicle Sensor SPEED_PULSE SET Function
-* FUNCTION : Update the SPEED_PULSE data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSpeedPulseFstl(const LSDRV_LSDATA_FST *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstSpeedPulseFst_l;
-
- /* Compare data master and received data */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSpeedPulseFstG
-* ABSTRACT : Vehicle Sensor SPEED_PULSE SET Function
-* FUNCTION : Update the SPEED_PULSE data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSpeedPulseFstG(const LSDRV_LSDATA_FST_SPEED *pst_data) {
- static u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- u_int8 partition_max; /* Total number of partitions */
- u_int8 partition_num; /* Data number */
-
- pst_master = &gstSpeedPulseFst_l;
-
- partition_max = pst_data->uc_partition_max;
- partition_num = pst_data->uc_partition_num;
-
- if (partition_max == 1) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Compare data master and received data */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 0;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- } else if (partition_max == 2) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- if (partition_num == 1) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Compare data master and received data */
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->partition_flg = 1;
- memcpy(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- } else if (partition_num == 2) { /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- /* Compare data master and received data */
- if (uc_ret == VEHICLESENS_EQ) {
- uc_ret = VehicleSensmemcmp(&pst_master->uc_data[VEHICLE_DSIZE_SPEED_PULSE_FST],
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- }
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- pst_master->us_size = static_cast<u_int16>(pst_master->us_size + pst_data->uc_size);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->partition_flg = 1;
- memcpy(&pst_master->uc_data[VEHICLE_DSIZE_SPEED_PULSE_FST],
- pst_data->uc_data, pst_data->uc_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
- } else {}
- } else {}
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSpeedPulseFstl
-* ABSTRACT : Vehicle Sensor SPEED_PULSE GET Function
-* FUNCTION : Provide the SPEED_PULSE data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSpeedPulseFstl(VEHICLESENS_DATA_MASTER_FST *pst_data) {
- const VEHICLESENS_DATA_MASTER_FST *pst_master;
-
- pst_master = &gstSpeedPulseFst_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->partition_flg = pst_master->partition_flg;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size); /* Ignore->MISRA-C++:2008 Rule 5-0-5 */
-}
-
-#endif
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulse_l.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulse_l.cpp
deleted file mode 100755
index a3ebc01..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SpeedPulse_l.cpp
+++ /dev/null
@@ -1,128 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SpeedPulse_l.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(POSHAL_DID_SPEED_PULSE)
- * Module configuration :VehicleSensInitSpeedPulsel() Vehicle sensor SPEED_PULSE initialization function
- * :VehicleSensSetSpeedPulsel() Vehicle Sensor SPEED_PULSE SET Function
- * :VehicleSensGetSpeedPulsel() Vehicle Sensor SPEED_PULSE GET Function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER gstSpeedPulse_l; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitSpeedPulsel
-* ABSTRACT : Vehicle sensor SPEED_PULSE initialization function
-* FUNCTION : SPEED_PULSE data master initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitSpeedPulsel(void) {
- (void)memset(reinterpret_cast<void *>(&gstSpeedPulse_l), 0, sizeof(VEHICLESENS_DATA_MASTER));
- gstSpeedPulse_l.ul_did = POSHAL_DID_SPEED_PULSE;
- gstSpeedPulse_l.us_size = VEHICLE_DSIZE_SPEED_PULSE;
- gstSpeedPulse_l.uc_rcvflag = VEHICLE_RCVFLAG_OFF;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSpeedPulsel
-* ABSTRACT : Vehicle Sensor SPEED_PULSE SET Function
-* FUNCTION : Update the SPEED_PULSE data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSpeedPulsel(const LSDRV_LSDATA *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSpeedPulse_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSpeedPulselG
-* ABSTRACT : Vehicle Sensor SPEED_PULSE SET Function
-* FUNCTION : Update the SPEED_PULSE data master
-* ARGUMENT : *pst_data : Pointer to the message data received by the direct line
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSpeedPulselG(const LSDRV_LSDATA_G *pst_data) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSpeedPulse_l;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_data->uc_data, pst_data->uc_size);
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- pst_master->uc_snscnt = pst_data->uc_sns_cnt;
- (void)memcpy(reinterpret_cast<void *>(pst_master->uc_data),
- (const void *)(pst_data->uc_data), (size_t)(pst_data->uc_size));
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSpeedPulsel
-* ABSTRACT : Vehicle Sensor SPEED_PULSE GET Function
-* FUNCTION : Provide the SPEED_PULSE data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetSpeedPulsel(VEHICLESENS_DATA_MASTER *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstSpeedPulse_l;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- pst_data->uc_snscnt = pst_master->uc_snscnt;
- (void)memcpy(reinterpret_cast<void *>(pst_data->uc_data),
- (const void *)(pst_master->uc_data), (size_t)(pst_master->us_size));
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SysGpsInterruptSignal.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SysGpsInterruptSignal.cpp
deleted file mode 100755
index e1400f2..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_SysGpsInterruptSignal.cpp
+++ /dev/null
@@ -1,132 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Did_SysGpsInterruptSignal.cpp
- * System name :PastModel002
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor data master(VEHICLE_DID_SYS_GPS_INTERRUPT_SIGNAL)
- * Module configuration :VehicleSensInitSysGpsInterruptSignal() Vehicle sensor Sys_GPS_INTERRUPT_SIGNAL initialization function
- * :VehicleSensSetSysGpsInterruptSignal() Vehicle Sensor Sys_GPS_INTERRUPT_SIGNAL SET Function
- * :VehicleSensGetSysGpsInterruptSignal() Vehicle sensor Sys_GPS_INTERRUPT_SIGNAL GET function
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-#define VEHICLE_SENS_DID_SYS_GPS_INTERRUPT_SIGNAL_DEBUG_FACTORY 0
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL gstSysGpsInterruptSignal; // NOLINT(readability/nolint)
-
-/*******************************************************************************
-* MODULE : VehicleSensInitSysGpsInterruptSignal
-* ABSTRACT : Vehicle sensor Sys_GPS_INTERRUPT_SIGNAL initialization function
-* FUNCTION : Sys_GPS_INTERRUPT_SIGNAL data master initialization processing
-* ARGUMENT : None
-* NOTE :
-* RETURN : None
-******************************************************************************/
-void VehicleSensInitSysGpsInterruptSignal(void) {
- (void)memset(reinterpret_cast<void *>(&(gstSysGpsInterruptSignal)), static_cast<int>(0x00),
- sizeof(VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL));
- gstSysGpsInterruptSignal.ul_did = VEHICLE_DID_SYS_GPS_INTERRUPT_SIGNAL;
- gstSysGpsInterruptSignal.us_size = VEHICLE_DSIZE_SYS_GPS_INTERRUPT_SIGNAL;
- gstSysGpsInterruptSignal.uc_data = VEHICLE_DINIT_SYS_GPS_INTERRUPT_SIGNAL;
-
-#if VEHICLE_SENS_DID_SYS_GPS_INTERRUPT_SIGNAL_DEBUG_FACTORY
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] gstSysGpsInterruptSignal.uc_data == 0x%x\r\n", gstSysGpsInterruptSignal.uc_data);
-#endif
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSysGpsInterruptSignal
-* ABSTRACT : Vehicle sensor SYS_GPS_INTERRUPT_SIGNAL SET function
-* FUNCTION : Update the Sys_GPS_INTERRUPT_SIGNAL data master
-* ARGUMENT : *pst_data : Pointer to received message data
-* NOTE :
-* RETURN : VEHICLESENS_EQ : No data change
-* VEHICLESENS_NEQ : Data change
-******************************************************************************/
-u_int8 VehicleSensSetSysGpsInterruptSignal(const LSDRV_MSG_LSDATA_DAT_GPS_INTERRUPT_SIGNAL *pst_data) { // LCOV_EXCL_START 8: dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- u_int8 uc_ret = VEHICLESENS_EQ;
- VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_master;
-
- if (pst_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "pst_data == NULL\r\n");
- } else {
- pst_master = &gstSysGpsInterruptSignal;
-
- /* Compare data master and received data */
- uc_ret = VehicleSensmemcmp(reinterpret_cast<void *>(&(pst_master->uc_data)),
- (const void *)(&(pst_data->uc_data)), (size_t)(pst_data->uc_size));
-
- /* Received data is set in the data master. */
- pst_master->ul_did = pst_data->ul_did;
- pst_master->us_size = (u_int16)pst_data->uc_size;
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- (void)memcpy(reinterpret_cast<void *>(&(pst_master->uc_data)),
- (const void *)(&(pst_data->uc_data)), sizeof(pst_master->uc_data));
-
-#if VEHICLE_SENS_DID_SYS_GPS_INTERRUPT_SIGNAL_DEBUG_FACTORY
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] pst_data->ul_did == 0x%x", pst_data->ul_did);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] gstSysGpsInterruptSignal.ul_did == 0x%x\r\n", gstSysGpsInterruptSignal.ul_did);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] (u_int8)pst_data->ucSize == 0x%x", (u_int8)pst_data->uc_size);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] gstSysGpsInterruptSignal.us_size == 0x%x\r\n", gstSysGpsInterruptSignal.us_size);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] pst_data->uc_data == 0x%x", pst_data->uc_data);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "#[FACTORY] gstSysGpsInterruptSignal.uc_data == 0x%x\r\n", gstSysGpsInterruptSignal.uc_data);
-#endif
- }
-
- return(uc_ret);
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSysGpsInterruptSignal
-* ABSTRACT : Vehicle sensor SYS_GPS_INTERRUPT_SIGNAL GET function
-* FUNCTION : Provide the SYS_GPS_INTERRUPT_SIGNAL data master
-* ARGUMENT : *pst_data : Pointer to the data master acquisition destination
-* NOTE :
-* RETURN : None
-******************************************************************************/
-void VehicleSensGetSysGpsInterruptSignal(VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_data) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- const VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL *pst_master;
-
- if (pst_data == NULL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "pst_data == NULL\r\n");
- } else {
- pst_master = &gstSysGpsInterruptSignal;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcvflag = pst_master->uc_rcvflag;
- (void)memcpy(reinterpret_cast<void *>(&(pst_data->uc_data)),
- (const void *)(&(pst_master->uc_data)), sizeof(pst_data->uc_data));
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_WknRollover.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_WknRollover.cpp
deleted file mode 100755
index e98d364..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_WknRollover.cpp
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_WknRollover.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * GPS Rollover Standard Week Number Data Master GET Processing
- *
- * @param[out] VEHICLESENS_DATA_MASTER*
- * @param[in] u_int8
- */
-void VehicleSensGetWknRollover(SENSOR_MSG_GPSDATA_DAT *pst_data, u_int8 uc_get_method) {
- switch (uc_get_method) {
- case VEHICLESENS_GETMETHOD_GPS:
- {
- /** To acquire from GPS */
- VehicleSensGetWknRolloverG(pst_data);
- break;
- }
-
- default:
- break;
- }
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_WknRollover_g.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_WknRollover_g.cpp
deleted file mode 100755
index 4a5defe..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Did_WknRollover_g.cpp
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehicleSens_Did_WknRollover_g.cpp
- * @brief
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_DataMaster.h"
-
-/*---------------------------------------------------------------------------------*
- * Global Value *
- *---------------------------------------------------------------------------------*/
-static VEHICLESENS_DATA_MASTER gstWknRollover_g; // NOLINT(readability/nolint)
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * GPS rollover standard week number data master initialization processing
- */
-void VehicleSensInitWknRolloverG(void) {
- SENSOR_WKNROLLOVER st_wkn_rollover;
-
- memset(&gstWknRollover_g, 0x00, sizeof(VEHICLESENS_DATA_MASTER));
-
- /** Data ID setting */
- gstWknRollover_g.ul_did = POSHAL_DID_GPS_WKNROLLOVER;
- /** Data size setting */
- gstWknRollover_g.us_size = sizeof(SENSOR_WKNROLLOVER);
- /** Data content setting */
- memset(&st_wkn_rollover, 0x00, sizeof(st_wkn_rollover));
- memcpy(&gstWknRollover_g.uc_data[0], &st_wkn_rollover, sizeof(st_wkn_rollover));
-
- return;
-}
-
-/**
- * @brief
- * GPS Rollover Standard Week Number Data Master SET Process
- *
- * @param[in] SENSOR_WKNROLLOVER*
- *
- * @return u_int8
- */
-u_int8 VehicleSensSetWknRolloverG(const SENSOR_WKNROLLOVER *pst_wkn_rollover) {
- u_int8 uc_ret;
- VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstWknRollover_g;
-
- /** With the contents of the current data master,Compare received data */
- uc_ret = VehicleSensmemcmp(pst_master->uc_data, pst_wkn_rollover, sizeof(SENSOR_WKNROLLOVER));
-
- /** Received data is set in the data master. */
- pst_master->ul_did = POSHAL_DID_GPS_WKNROLLOVER;
- pst_master->us_size = sizeof(SENSOR_WKNROLLOVER);
- pst_master->uc_rcvflag = VEHICLE_RCVFLAG_ON;
- memset(pst_master->uc_data, 0x00, sizeof(pst_master->uc_data));
- memcpy(pst_master->uc_data, pst_wkn_rollover, sizeof(SENSOR_WKNROLLOVER));
-
- return(uc_ret);
-}
-
-/**
- * @brief
- * GPS Rollover Standard Week Number Data Master GET Processing
- *
- * @param[out] SENSOR_MSG_GPSDATA_DAT*
- */
-void VehicleSensGetWknRolloverG(SENSOR_MSG_GPSDATA_DAT *pst_data) {
- const VEHICLESENS_DATA_MASTER *pst_master;
-
- pst_master = &gstWknRollover_g;
-
- /* Store the data master in the specified destination. */
- pst_data->ul_did = pst_master->ul_did;
- pst_data->us_size = pst_master->us_size;
- pst_data->uc_rcv_flag = pst_master->uc_rcvflag;
- memcpy(pst_data->uc_data, pst_master->uc_data, pst_master->us_size);
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_FromAccess.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_FromAccess.cpp
deleted file mode 100755
index 99f2dc3..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_FromAccess.cpp
+++ /dev/null
@@ -1,319 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_FromAccess.cpp
- * System name :PastModel002
- * Subsystem name :Vehicle sensor process
- * Program name :Functions for accessing vehicle sensor FROM
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_FromAccess.h"
-#include "ClockDataMng.h"
-
-/********************************************************************************
- * Global variable *
- ********************************************************************************/
-
-/********************************************************************************
- * prototype declalation *
- ********************************************************************************/
-static RET_API VehicleSensReadNV(NV_DATA_VEHICLESENS *p_nv_data);
-
-/********************************************************************************
- * Definition *
- ********************************************************************************/
-#define VEHICLESENS_FROM_ACCESS_DEBUG 0
-
-/*******************************************************************************
-* MODULE : VehicleSensFromAccessInitialize
-* ABSTRACT : Initializing process
-* FUNCTION :
-* ARGUMENT : None
-* NOTE :
-* RETURN : None
-******************************************************************************/
-void VehicleSensFromAccessInitialize(void) {
- /* The result of tag registration for non-volatile memory access is stored in g_nv_access_available, so no confirmation is required. */
- (void)VehicleSensRegistNvTag();
-
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensRegistNvTag
-* ABSTRACT : Tag registration process
-* FUNCTION : Registering Tag Name to Identify Data Storage Destination
-* ARGUMENT : None
-* NOTE :
-* RETURN : RET_NORMAL :Successful registration
-* : RET_ERROR :Registration failure
-******************************************************************************/
-RET_API VehicleSensRegistNvTag(void) {
- RET_API lret = RET_NORMAL;
- return lret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensReadNV
-* ABSTRACT : Get local time Lonlat
-* FUNCTION : Reading local time Lonlat from non-volatile memory
-* ARGUMENT : NV_DATA_VEHICLESENS * p_nv_data : Pointer to data acquired from non-volatile memory
-* NOTE : None
-* RETURN : RET_NORMAL :Read success
-* : RET_ERROR :Failed to read
-******************************************************************************/
-static RET_API VehicleSensReadNV(NV_DATA_VEHICLESENS * p_nv_data) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API lret = RET_NORMAL;
- FILE *fp;
- NV_DATA_VEHICLESENS nv_data_tmp;
- BOOL ret_read = FALSE;
- BOOL ret_read2 = FALSE;
-
- u_int32 loop;
- u_int8 CK_A = 0;
- u_int8 CK_B = 0;
- u_int8 *ptr;
-
- fp = fopen(NV_FILE_VEHICLESENS_TEMP, "rb");
-
- /* Read File1 */
- if (fp != NULL) {
- if ((fread(reinterpret_cast<void *>(p_nv_data), sizeof(u_int8), sizeof(NV_DATA_VEHICLESENS), fp)) == \
- sizeof(NV_DATA_VEHICLESENS)) {
- /* Checksum processing */
- ptr = reinterpret_cast<u_int8 *>(p_nv_data); /* #QAC confirmation Rule11.4 1Byte accesses for checksums */
- CK_A = 0;
- CK_B = 0;
-
- /* The 2Byte portion from the end of the checksum data is excluded because the checksum storage area. */
- for (loop = 0; loop < (sizeof(NV_DATA_VEHICLESENS) - 2); loop++) {
- CK_A = static_cast<u_int8>(CK_A + ptr[loop]);
- CK_B = static_cast<u_int8>(CK_B + CK_A);
- }
-
-
- if ((p_nv_data->cka == CK_A) && (p_nv_data->ckb == CK_B)) {
- ret_read = TRUE;
-
-#if VEHICLESENS_FROM_ACCESS_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "NV read, status, year, month, day, hour, min, sec, lat, lon, "\
- "timediff, update_counter, cka, ckb ");
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "NV read, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d ",
- p_nv_data->localtime.status,
- p_nv_data->localtime.year,
- p_nv_data->localtime.month,
- p_nv_data->localtime.day,
- p_nv_data->localtime.hour,
- p_nv_data->localtime.min,
- p_nv_data->localtime.sec,
- p_nv_data->lonlat.latitude,
- p_nv_data->lonlat.longitude,
- p_nv_data->timediff,
- p_nv_data->update_counter,
- p_nv_data->cka,
- p_nv_data->ckb);
-#endif /* VEHICLESENS_FROM_ACCESS_DEBUG */
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Checksum1 failed.");
- ret_read = FALSE;
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "fread1 failed.");
- }
- fclose(fp);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "fopen1 failed.");
- }
-
- /* Read File2 */
- fp = fopen(NV_FILE_VEHICLESENS2_TEMP, "rb");
-
- if (fp != NULL) {
- if ((fread(reinterpret_cast<void *>(&nv_data_tmp), sizeof(u_int8), sizeof(NV_DATA_VEHICLESENS), fp)) == \
- sizeof(NV_DATA_VEHICLESENS)) {
- /* Checksum processing */
- ptr = reinterpret_cast<u_int8 *>(&nv_data_tmp); /* #QAC confirmation Rule11.4 1Byte accesses for checksums */
- CK_A = 0;
- CK_B = 0;
-
- /* The 2Byte portion from the end of the checksum data is excluded because the checksum storage area. */
- for (loop = 0; loop < (sizeof(NV_DATA_VEHICLESENS) - 2); loop++) {
- CK_A = static_cast<u_int8>(CK_A + ptr[loop]);
- CK_B = static_cast<u_int8>(CK_B + CK_A);
- }
-
-
- if ((nv_data_tmp.cka == CK_A) && (nv_data_tmp.ckb == CK_B)) {
- ret_read2 = TRUE;
-
-#if VEHICLESENS_FROM_ACCESS_DEBUG
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "NV read2, status, year, month, day, hour, min, sec, lat, lon, "\
- "timediff, update_counter, cka, ckb ");
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "NV read2, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d ",
- nv_data_tmp.localtime.status,
- nv_data_tmp.localtime.year,
- nv_data_tmp.localtime.month,
- nv_data_tmp.localtime.day,
- nv_data_tmp.localtime.hour,
- nv_data_tmp.localtime.min,
- nv_data_tmp.localtime.sec,
- nv_data_tmp.lonlat.latitude,
- nv_data_tmp.lonlat.longitude,
- nv_data_tmp.timediff,
- nv_data_tmp.update_counter,
- nv_data_tmp.cka,
- nv_data_tmp.ckb);
-#endif /* VEHICLESENS_FROM_ACCESS_DEBUG */
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Checksum2 failed.");
- ret_read2 = FALSE;
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "fread2 failed.");
- }
- fclose(fp);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "fopen2 failed.");
- }
-
-
- /* Check the read results of File 1 and File 2. */
- if ((ret_read == TRUE) && (ret_read2 == TRUE)) {
- /* Whether File 1 or File 2 is the most recent file,Check with the update count counter */
- if (p_nv_data->update_counter < nv_data_tmp.update_counter) {
- (void)memcpy(reinterpret_cast<void *>(p_nv_data), reinterpret_cast<void *>(&nv_data_tmp), \
- sizeof(NV_DATA_VEHICLESENS));
- }
- lret = RET_NORMAL;
- } else if (ret_read == TRUE) {
- /* Use file 1 */
- lret = RET_NORMAL;
- } else if (ret_read2 == TRUE) {
- /* Use file 2 */
- (void)memcpy(reinterpret_cast<void *>(p_nv_data), reinterpret_cast<void *>(&nv_data_tmp), \
- sizeof(NV_DATA_VEHICLESENS));
- lret = RET_NORMAL;
- } else {
- /* Read failed for both file 1 and file 2 */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "fread failed.");
- lret = RET_ERROR;
- }
-
- return lret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensReadNVLocalTime
-* ABSTRACT : Local time acquisition at shutdown
-* FUNCTION : Read local time at shutdown from non-volatile memory
-* ARGUMENT : LOCALTIME * local_time : Local time at shutdown
-* NOTE : None
-* RETURN : RET_NORMAL :Successful acquisition
-* : RET_ERROR :Failed to acquire
-******************************************************************************/
-RET_API VehicleSensReadNVLocalTime(LOCALTIME * local_time) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API lret;
- NV_DATA_VEHICLESENS nv_data;
-
- lret = VehicleSensReadNV(&nv_data);
-
- if (lret == RET_NORMAL) {
- (void)memcpy(reinterpret_cast<void *>(local_time), (const void *)(&nv_data.localtime), sizeof(LOCALTIME));
- }
-
- return lret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensReadNVLonLat
-* ABSTRACT : Obtain position at shutdown
-* FUNCTION : Read the shutdown position from the non-volatile memory
-* ARGUMENT : LONLAT * lonlat : Shutdown position
-* NOTE : None
-* RETURN : RET_NORMAL :Successful acquisition
-* : RET_ERROR :Failed to acquire
-******************************************************************************/
-RET_API VehicleSensReadNVLonLat(LONLAT * lonlat) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API lret;
- NV_DATA_VEHICLESENS nv_data;
-
- lret = VehicleSensReadNV(&nv_data);
-
- if (lret == RET_NORMAL) {
- (void)memcpy(reinterpret_cast<void *>(lonlat), (const void *)(&nv_data.lonlat), sizeof(LONLAT));
- }
-
- return lret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensReadNVTimeDiff
-* ABSTRACT : Shutdown time difference acquisition
-* FUNCTION : Reading the shutdown time difference from the non-volatile memory
-* ARGUMENT : int32 * time_diff : Shutdown position
-* NOTE : None
-* RETURN : RET_NORMAL :Successful acquisition
-* : RET_ERROR :Failed to acquire
-******************************************************************************/
-RET_API VehicleSensReadNVTimeDiff(int32 * time_diff) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API lret;
- NV_DATA_VEHICLESENS nv_data;
-
- lret = VehicleSensReadNV(&nv_data);
-
- if (lret == RET_NORMAL) {
- *time_diff = nv_data.timediff;
- }
-
- return lret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensStoreLonlat
-* ABSTRACT : Store location data in non-volatile memory
-* FUNCTION :
-* ARGUMENT : LONLAT * plonlat : Position data
-* NOTE :
-* RETURN : None
-******************************************************************************/
-void VehicleSensStoreLonlat(LONLAT * plonlat) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-
- return;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensWriteNVLocaltime
-* ABSTRACT : Local Time Write
-* FUNCTION : Write local time
-* ARGUMENT : LOCALTIME * local_time : Local time
-* NOTE :
-* RETURN : RET_NORMAL :Successful write
-* : RET_ERROR :Writing failure
-******************************************************************************/
-RET_API VehicleSensWriteNVLocaltime(LOCALTIME * local_time, int32 * time_diff) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API lret = RET_NORMAL;
-
- return lret;
-}
-
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_SelectionItemList.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_SelectionItemList.cpp
deleted file mode 100755
index 4172b1e..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_SelectionItemList.cpp
+++ /dev/null
@@ -1,466 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_SelectionItemList.cpp
- * System name :_CWORD107_
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle Sensor Selection Item List
- * Module configuration :VehicleSensInitSelectionItemList() Vehicle sensor selection item list initialization function
- * :VehicleSensGetSelectionItemList() Vehicle sensor selection item list acquisition method GET function
- * :VehicleSensGetSelectionItemListCanId() Vehicle Sensor Selection Items List CANID GET Functions
- * :VehicleSensSetSelectionItemListCanId() Vehicle Sensor Selection Items List CANID SET Functions
- * :VehicleSensCommWatchTblInit() Disruption monitoring data management table initialization function
- * :VehicleSensCommWatchTblSave() Disruption monitoring data management table storage function
- * :VehicleSensCommWatchTblRun() Disruption monitoring data management table execution function
- ******************************************************************************/
-
-#include <positioning_hal.h>
-#include <vehicle_service/positioning_base_library.h>
-
-#include "VehicleSens_SelectionItemList.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLESENS_SELECTION_ITEM_LIST g_st_selection_itemlist[VEHICLESENS_SELECTION_ITEM_LIST_LEN];
-static VEHICLE_COMM_WATCH_TBL g_st_comm_watchtbl[VEHICLE_COMM_WATCHTBL_DID_NUM];
-
-/*******************************************************************************
-* MODULE : VehicleSensInitSelectionItemList
-* ABSTRACT : Vehicle sensor selection item list initialization function
-* FUNCTION : Vehicle Sensor Selection Item List Initialization Process
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensInitSelectionItemList(void) {
- u_int8 uc_get_method;
-
- VehicleSensCommWatchTblInit();
-
- /* Setting Acquisition Method (CAN/ Direct Line) for DataID in Vehicle Sensor Selection Item List.
- BackDoor, Adim, Rev sets the CAN/ direct line obtained from the FROM
- */
- memset(&g_st_selection_itemlist, 0x00, sizeof(g_st_selection_itemlist));
-
- g_st_selection_itemlist[0].ul_did = VEHICLE_DID_HV;
- g_st_selection_itemlist[0].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[0].uc_get_method = VEHICLESENS_GETMETHOD_CAN;
- g_st_selection_itemlist[1].ul_did = VEHICLE_DID_VB;
- g_st_selection_itemlist[1].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[2].ul_did = VEHICLE_DID_IG;
- g_st_selection_itemlist[2].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[3].ul_did = VEHICLE_DID_MIC;
- g_st_selection_itemlist[3].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[4].ul_did = VEHICLE_DID_ILL;
- g_st_selection_itemlist[4].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[5].ul_did = VEHICLE_DID_RHEOSTAT;
- g_st_selection_itemlist[5].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[6].ul_did = VEHICLE_DID_SYSTEMP;
- g_st_selection_itemlist[6].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[7].ul_did = POSHAL_DID_SPEED_PULSE;
- g_st_selection_itemlist[7].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[8].ul_did = POSHAL_DID_SPEED_KMPH;
- g_st_selection_itemlist[8].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[9].ul_did = POSHAL_DID_GYRO_X;
- g_st_selection_itemlist[9].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[10].ul_did = POSHAL_DID_GYRO_Y;
- g_st_selection_itemlist[10].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[11].ul_did = POSHAL_DID_GYRO_Z;
- g_st_selection_itemlist[11].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[12].ul_did = POSHAL_DID_GSNS_X;
- g_st_selection_itemlist[12].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[13].ul_did = POSHAL_DID_GSNS_Y;
- g_st_selection_itemlist[13].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[14].ul_did = POSHAL_DID_GSNS_Z;
- g_st_selection_itemlist[14].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[15].ul_did = VEHICLE_DID_REV;
- g_st_selection_itemlist[15].ul_canid = VEHICLESENS_INVALID;
- uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[15].uc_get_method = uc_get_method;
- g_st_selection_itemlist[16].ul_did = POSHAL_DID_GPS_ANTENNA;
- g_st_selection_itemlist[16].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[17].ul_did = POSHAL_DID_SNS_COUNTER;
- g_st_selection_itemlist[17].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[18].ul_did = VEHICLE_DID_GPS_COUNTER;
- g_st_selection_itemlist[18].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[19].ul_did = POSHAL_DID_GPS_VERSION;
- g_st_selection_itemlist[19].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[20].ul_did = VEHICLE_DID_LOCATION;
- g_st_selection_itemlist[20].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[21].ul_did = VEHICLE_DID_REV_LINE;
- g_st_selection_itemlist[21].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[22].ul_did = VEHICLE_DID_REV_CAN;
- g_st_selection_itemlist[22].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[22].uc_get_method = VEHICLESENS_GETMETHOD_CAN;
- /* ++ GPS _CWORD82_ support */
- g_st_selection_itemlist[23].ul_did = POSHAL_DID_GPS__CWORD82___CWORD44_GP4;
- g_st_selection_itemlist[23].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[24].ul_did = VEHICLE_DID_GPS__CWORD82__NMEA;
- g_st_selection_itemlist[24].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[25].ul_did = POSHAL_DID_GPS__CWORD82__FULLBINARY;
- g_st_selection_itemlist[25].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- /* -- GPS _CWORD82_ support */
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Response */
- g_st_selection_itemlist[26].ul_did = POSHAL_DID_GYRO_EXT;
- g_st_selection_itemlist[26].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[27].ul_did = POSHAL_DID_SPEED_PULSE_FST;
- g_st_selection_itemlist[27].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[28].ul_did = POSHAL_DID_GYRO_X_FST;
- g_st_selection_itemlist[28].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[29].ul_did = POSHAL_DID_GYRO_Y_FST;
- g_st_selection_itemlist[29].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[30].ul_did = POSHAL_DID_GYRO_Z_FST;
- g_st_selection_itemlist[30].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[31].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_POSLLH;
- g_st_selection_itemlist[31].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[32].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_STATUS;
- g_st_selection_itemlist[32].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[33].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_TIMEUTC;
- g_st_selection_itemlist[33].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[34].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_VELNED;
- g_st_selection_itemlist[34].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[35].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_DOP;
- g_st_selection_itemlist[35].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[36].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_TIMEGPS;
- g_st_selection_itemlist[36].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[37].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_SVINFO;
- g_st_selection_itemlist[37].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[38].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_CLOCK;
- g_st_selection_itemlist[38].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[39].ul_did = VEHICLE_DID_GPS_UBLOX_MON_HW;
- g_st_selection_itemlist[39].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[40].ul_did = POSHAL_DID_SPEED_PULSE_FLAG;
- g_st_selection_itemlist[40].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[41].ul_did = VEHICLE_DID_GYRO_TROUBLE;
- g_st_selection_itemlist[41].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[41].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[42].ul_did = VEHICLE_DID_SYS_GPS_INTERRUPT_SIGNAL;
- g_st_selection_itemlist[42].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[42].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[43].ul_did = VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL;
- g_st_selection_itemlist[43].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[43].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[44].ul_did = VEHICLE_DID_GYRO_CONNECT_STATUS;
- g_st_selection_itemlist[44].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[44].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[45].ul_did = POSHAL_DID_SPEED_PULSE_FLAG_FST;
- g_st_selection_itemlist[45].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[46].ul_did = POSHAL_DID_REV_FST;
- g_st_selection_itemlist[46].ul_canid = VEHICLESENS_INVALID;
- uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[46].uc_get_method = uc_get_method;
- g_st_selection_itemlist[47].ul_did = POSHAL_DID_GPS_NMEA;
- g_st_selection_itemlist[47].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[48].ul_did = POSHAL_DID_GPS_TIME;
- g_st_selection_itemlist[48].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[48].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[49].ul_did = VEHICLE_DID_NAVIINFO_DIAG_GPS;
- g_st_selection_itemlist[49].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[49].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[50].ul_did = POSHAL_DID_GYRO_TEMP;
- g_st_selection_itemlist[50].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[50].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[51].ul_did = POSHAL_DID_GYRO_TEMP_FST;
- g_st_selection_itemlist[51].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[51].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[52].ul_did = POSHAL_DID_GSNS_X_FST;
- g_st_selection_itemlist[52].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[52].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[53].ul_did = POSHAL_DID_GSNS_Y_FST;
- g_st_selection_itemlist[53].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[53].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[54].ul_did = POSHAL_DID_GSNS_Z_FST;
- g_st_selection_itemlist[54].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[54].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[55].ul_did = VEHICLE_DID_LOCATION_LONLAT;
- g_st_selection_itemlist[55].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[55].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[56].ul_did = VEHICLE_DID_LOCATION_ALTITUDE;
- g_st_selection_itemlist[56].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[56].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[57].ul_did = VEHICLE_DID_MOTION_HEADING;
- g_st_selection_itemlist[57].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[57].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[58].ul_did = VEHICLE_DID_LOCATION_LONLAT_NAVI;
- g_st_selection_itemlist[58].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[58].uc_get_method = VEHICLESENS_GETMETHOD_NAVI;
- g_st_selection_itemlist[59].ul_did = VEHICLE_DID_LOCATION_ALTITUDE_NAVI;
- g_st_selection_itemlist[59].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[59].uc_get_method = VEHICLESENS_GETMETHOD_NAVI;
- g_st_selection_itemlist[60].ul_did = VEHICLE_DID_MOTION_HEADING_NAVI;
- g_st_selection_itemlist[60].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[60].uc_get_method = VEHICLESENS_GETMETHOD_NAVI;
- g_st_selection_itemlist[61].ul_did = VEHICLE_DID_SETTINGTIME;
- g_st_selection_itemlist[61].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[61].uc_get_method = VEHICLESENS_GETMETHOD_OTHER;
- g_st_selection_itemlist[62].ul_did = VEHICLE_DID_MOTION_SPEED;
- g_st_selection_itemlist[62].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[62].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[63].ul_did = VEHICLE_DID_MOTION_SPEED_NAVI;
- g_st_selection_itemlist[63].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[63].uc_get_method = VEHICLESENS_GETMETHOD_NAVI;
- g_st_selection_itemlist[64].ul_did = VEHICLE_DID_MOTION_SPEED_INTERNAL;
- g_st_selection_itemlist[64].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[64].uc_get_method = VEHICLESENS_GETMETHOD_INTERNAL;
- g_st_selection_itemlist[65].ul_did = POSHAL_DID_PULSE_TIME;
- g_st_selection_itemlist[65].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[65].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[66].ul_did = POSHAL_DID_GPS_TIME_RAW;
- g_st_selection_itemlist[66].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[66].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[67].ul_did = POSHAL_DID_GPS_WKNROLLOVER;
- g_st_selection_itemlist[67].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[67].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[68].ul_did = POSHAL_DID_GPS_CLOCK_DRIFT;
- g_st_selection_itemlist[68].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[68].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[69].ul_did = POSHAL_DID_GPS_CLOCK_FREQ;
- g_st_selection_itemlist[69].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[69].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
-#else
- g_st_selection_itemlist[26].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_POSLLH;
- g_st_selection_itemlist[26].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[27].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_STATUS;
- g_st_selection_itemlist[27].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[28].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_TIMEUTC;
- g_st_selection_itemlist[28].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[29].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_VELNED;
- g_st_selection_itemlist[29].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[30].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_DOP;
- g_st_selection_itemlist[30].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[31].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_TIMEGPS;
- g_st_selection_itemlist[31].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[32].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_SVINFO;
- g_st_selection_itemlist[32].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[33].ul_did = VEHICLE_DID_GPS_UBLOX_NAV_CLOCK;
- g_st_selection_itemlist[33].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[34].ul_did = VEHICLE_DID_GPS_UBLOX_MON_HW;
- g_st_selection_itemlist[34].uc_get_method = VEHICLESENS_GETMETHOD_GPS;
- g_st_selection_itemlist[35].ul_did = POSHAL_DID_SPEED_PULSE_FLAG;
- g_st_selection_itemlist[35].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[36].ul_did = VEHICLE_DID_GYRO_TROUBLE;
- g_st_selection_itemlist[36].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[36].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[37].ul_did = VEHICLE_DID__CWORD56__GPS_INTERRUPT_SIGNAL;
- g_st_selection_itemlist[37].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[37].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[38].ul_did = VEHICLE_DID__CWORD102__GPS_INTERRUPT_SIGNAL;
- g_st_selection_itemlist[38].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[38].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
- g_st_selection_itemlist[39].ul_did = VEHICLE_DID_GYRO_CONNECT_STATUS;
- g_st_selection_itemlist[39].ul_canid = VEHICLESENS_INVALID;
- g_st_selection_itemlist[39].uc_get_method = VEHICLESENS_GETMETHOD_LINE;
-#endif
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSelectionItemList
-* ABSTRACT : Vehicle sensor_data acquisition method GET function
-* FUNCTION : Provide data acquisition methods
-* ARGUMENT : ul_did Data ID
-* NOTE :
-* RETURN : VEHICLESENS_GETMETHOD_CAN :CAN line
-* VEHICLESENS_GETMETHOD_LINE :Direct Line
-* VEHICLESENS_GETMETHOD_NO_DETECTION :Not downloaded
-* VEHICLESENS_GETMETHOD_GPS :GPS
-* VEHICLESENS_GETMETHOD_NAVI :Navi
-* VEHICLESENS_GETMETHOD_CLOCK :Clock
-* VEHICLESENS_GETMETHOD_OTHER :Others
-******************************************************************************/
-u_int8 VehicleSensGetSelectionItemList(DID ul_did) {
- int32 i;
- u_int8 uc_get_method = VEHICLESENS_GETMETHOD_NO_DETECTION;
- /* Ignore->MISRA-C++:2008 Rule 2-13-3 */ /* Ignore->MISRA-C++:2008 Rule 5-0-13, 5-0-14, 5-3-1 */
- if ( (ul_did & VEHICLESENS_BIT31_29) != 0 ) {
- /* For other than CAN frame data */
- for (i = 0; i < VEHICLESENS_SELECTION_ITEM_LIST_LEN; i++) {
- if (g_st_selection_itemlist[i].ul_did == ul_did) {
- uc_get_method = g_st_selection_itemlist[i].uc_get_method;
- break;
- }
- }
- } else {
- /* CAN frame data */
- uc_get_method = VEHICLESENS_GETMETHOD_CAN;
- }
- return uc_get_method;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetSelectionItemListCanId
-* ABSTRACT : Vehicle Sensor Selection Item List_CANID GET Function
-* FUNCTION : Provide CANID
-* ARGUMENT :
-* NOTE :
-* RETURN : ul_canid CANID
-******************************************************************************/
-u_int32 VehicleSensGetSelectionItemListCanId(DID ul_did) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- int32 i;
- u_int32 ul_canid = VEHICLESENS_INVALID;
-
- for (i = 0; i < VEHICLESENS_SELECTION_ITEM_LIST_LEN; i++) {
- if (g_st_selection_itemlist[i].ul_did == ul_did) {
- if (VEHICLESENS_GETMETHOD_CAN == g_st_selection_itemlist[i].uc_get_method) {
- /* When the data source type is CAN communication */
- ul_canid = g_st_selection_itemlist[i].ul_canid;
- }
- break;
- }
- }
- return ul_canid;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetSelectionItemListCanId
-* ABSTRACT : Vehicle Sensor Selection Item List_CANID SET Function
-* FUNCTION : Sets when the CANID associated with the specified DID is unconfirmed.
-* ARGUMENT : ul_canid u-int32(CANID)
-* NOTE :
-* RETURN : TRUE :Successful registration(Including when the CANID is fixed)
-* : FALSE :Registration failure
-******************************************************************************/
-BOOL VehicleSensSetSelectionItemListCanId(DID ul_did, u_int32 ul_canid) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- BOOL b_ret = TRUE;
- u_int8 uc_cnt = 0;
- int32 uc_last_cnt = 0;
-
- u_int8 uc_effective_flg = VEHICLESENS_EFFECTIVE;
-
- for (uc_cnt = 0; uc_cnt < VEHICLE_COMM_WATCHTBL_DID_NUM; uc_cnt++) {
- if (g_st_comm_watchtbl[uc_cnt].ul_did == ul_did) {
- /* Obtain CANID determination flg */
- uc_effective_flg = g_st_comm_watchtbl[uc_cnt].uc_effective_flg;
- break;
- }
- }
-
- if (uc_cnt >= VEHICLE_COMM_WATCHTBL_DID_NUM) {
- return FALSE;
- }
-
- if (VEHICLESENS_EFFECTIVE != uc_effective_flg) {
- /* When the CANID is undetermined */
- b_ret = FALSE;
- for (uc_last_cnt = 0; uc_last_cnt < VEHICLESENS_SELECTION_ITEM_LIST_LEN; uc_last_cnt++) {
- if (g_st_selection_itemlist[uc_last_cnt].ul_did == ul_did) {
- /* Updating the CANID of the Vehicle Sensor Selection Items List */
- g_st_selection_itemlist[uc_last_cnt].ul_canid = ul_canid;
- /* To fix the CANID */
- g_st_comm_watchtbl[uc_cnt].uc_effective_flg = VEHICLESENS_EFFECTIVE;
-
- /* During CANID indoubt,When Vehicle API ""Vehicle Sensor Information Disruption Monitoring"" is called */
- /* Register for disruption monitoring of pending CAN threads */
- if (0x00 < g_st_comm_watchtbl[uc_cnt].uc_vehicle_comm_watch_cnt) {
- VehicleSensCommWatchTblRun(ul_did);
- }
- b_ret = TRUE;
- break;
- }
- }
- }
- return b_ret;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensCommWatchTblInit
-* ABSTRACT : Disruption monitoring data management table initialization function
-* FUNCTION : Disruption monitoring data management table initialization processing
-* ARGUMENT : void
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensCommWatchTblInit(void) {
- memset(&g_st_comm_watchtbl, 0x00, sizeof(g_st_comm_watchtbl));
-
- /* DID initialization */
- g_st_comm_watchtbl[0].ul_did = VEHICLE_DID_REV;
- g_st_comm_watchtbl[1].ul_did = VEHICLE_DID_REV_CAN;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensCommWatchTblSave
-* ABSTRACT : Disruption monitoring data management table storage function
-* FUNCTION : When the target CANID is undetermined, save the discontinuation monitoring data...
-* ARGUMENT :
-* NOTE :
-* RETURN : TRUE : To fix the CANID
-* : FALSE : CANID undetermined
-******************************************************************************/
-BOOL VehicleSensCommWatchTblSave(const VEHICLE_MSG_WATCH_STOPPAGE *pst_msg) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- BOOL b_ret = TRUE; /* Function return value */
- u_int8 uc_cnt = 0; /* Generic counters */
- u_int8 uc_last_cnt = 0; /* Vehicle Sensor Information Disruption Monitoring Request Count */
- u_int8 uc_get_method = VEHICLESENS_GETMETHOD_CAN; /* Acquisition method */
- u_int8 uc_effective_flg = VEHICLESENS_EFFECTIVE; /* CANID determination flg */
-
-
- uc_get_method = VehicleSensGetSelectionItemList(pst_msg->st_data.ul_did);
-
- /* If the retrieval method is CAN: Check if the CANID is fixed */
- if (VEHICLESENS_GETMETHOD_CAN == uc_get_method) {
- for ( uc_cnt = 0; uc_cnt < VEHICLE_COMM_WATCHTBL_DID_NUM; uc_cnt++ ) {
- if ( g_st_comm_watchtbl[uc_cnt].ul_did == pst_msg->st_data.ul_did ) {
- /* Obtain CANID determination flg */
- uc_effective_flg = g_st_comm_watchtbl[uc_cnt].uc_effective_flg;
- break;
- }
- }
- }
-
- if ( VEHICLESENS_EFFECTIVE != uc_effective_flg ) {
- /* Due to being asked for disruption monitoring of CANID indoubt data,Keep parameters required for disruption monitoring */
- /* Returns success to the API user,No Disruption Monitoring Registration at this time */
- /* Ask the CAN thread to monitor for disruption when the CANID is fixed. */
-
- uc_last_cnt = g_st_comm_watchtbl[uc_cnt].uc_vehicle_comm_watch_cnt;
- if ( VEHICLE_COMM_WATCHTBL_DAT_NUM > uc_last_cnt ) {
- /* Destination PNO,Keep Disrupted Monitoring Time */
- g_st_comm_watchtbl[uc_cnt].st_comm_watch_dat[uc_last_cnt].us_pno = pst_msg->st_data.us_pno;
- g_st_comm_watchtbl[uc_cnt].st_comm_watch_dat[uc_last_cnt].us_watch_time = pst_msg->st_data.us_watch_time;
-
- /* Vehicle sensor information disruption monitoring request count is incremented. */
- uc_last_cnt++;
- g_st_comm_watchtbl[uc_cnt].uc_vehicle_comm_watch_cnt = uc_last_cnt;
- }
- b_ret = FALSE;
- }
- return b_ret;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensCommWatchTblRun
-* ABSTRACT : Disruption monitoring data management table execution function
-* FUNCTION : Execute requested disruption monitoring when CANID is unconfirmed
-* ARGUMENT : ul_did DID
-* NOTE :
-* RETURN : TRUE : Normal completion
-* : FALSE : ABENDs
-******************************************************************************/
-BOOL VehicleSensCommWatchTblRun(DID ul_did) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- BOOL b_ret = TRUE;
-
- return b_ret;
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_SharedMemory.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_SharedMemory.cpp
deleted file mode 100755
index 1fc9954..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_SharedMemory.cpp
+++ /dev/null
@@ -1,521 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_SharedMemory.cpp
- * System name :PastModel002
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor shared memory management
- ******************************************************************************/
-
-#include <vehicle_service/positioning_base_library.h>
-#include "VehicleSens_SharedMemory.h"
-#include "Sensor_API.h"
-#include "VehicleSens_DataMaster.h"
-#include "Sensor_API_private.h"
-#include "SensorLocation_API.h"
-#include "SensorLocation_API_private.h"
-
-/********************************************************************************
- * prototype declalation *
- ********************************************************************************/
-static void VehicleSensLinkSharedMemory(char *shared_memory_name, void **p_share_addr);
-static RET_API VehicleSensWriteDataGpsInterruptSignal(DID ul_did);
-static RET_API VehicleSensWriteDataGyroConnectStatus(DID ul_did);
-static RET_API VehicleSensWriteDataLocalTime(void);
-static RET_API VehicleSensWriteDataLonLat(void);
-
-/********************************************************************************
- * Definition *
- ********************************************************************************/
-
-/*******************************************************************************
-* MODULE : VehicleSensInitSharedMemory
-* ABSTRACT : Shared Memory Initialization
-* FUNCTION : Initialize shared memory
-* ARGUMENT : None
-* NOTE :
-* RETURN : RET_NORMAL :Normal
-* : RET_ERROR :Abnormality
-******************************************************************************/
-RET_API VehicleSensInitSharedMemory(void) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API l_ret; /* Return of the functions */
-
- /* All shared memory initialization */
- l_ret = VehicleSensWriteDataGpsInterruptSignal(VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL);
- if (l_ret == RET_NORMAL) {
- l_ret = VehicleSensWriteDataGpsInterruptSignal(VEHICLE_DID_SYS_GPS_INTERRUPT_SIGNAL);
- }
- if (l_ret == RET_NORMAL) {
- l_ret = VehicleSensWriteDataGyroConnectStatus(VEHICLE_DID_GYRO_CONNECT_STATUS);
- }
-
- /* Initializes the effective ephemeris count when the shared memory is shut down. */
- if (l_ret == RET_NORMAL) {
- l_ret = VehicleSensWriteDataValidEphemerisNum(0); /* Initialized with effective ephemeris number 0 */
- }
-
- /* Writes the value read from the non-volatile memory to the shared memory. */
- /* This process is executed only at startup.,After that, the shared memory will not be overwritten. */
- if (l_ret == RET_NORMAL) {
- l_ret = VehicleSensWriteDataLocalTime();
- }
-
- if (l_ret == RET_NORMAL) {
- l_ret = VehicleSensWriteDataLonLat();
- }
-
- return l_ret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensLinkSharedMemory
-* ABSTRACT : Shared memory link
-* FUNCTION : Link to shared memory
-* ARGUMENT :
-* NOTE :
-* RETURN : None
-******************************************************************************/
-static void VehicleSensLinkSharedMemory(char *shared_memory_name, void **p_share_addr) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API ret_api;
- void *pv_share_mem; /* Store Shared Memory Address */
- u_int32 ul_share_mem_size; /* Size of the linked shared memory */
-
- /* Link to the handle storage area */
- ret_api = _pb_LinkShareData(shared_memory_name, &pv_share_mem, &ul_share_mem_size);
-
- if (ret_api == RET_NORMAL) {
- /* If the link is successful */
- *p_share_addr = pv_share_mem; /* Set the address */
- } else {
- /* If the link fails */
- *p_share_addr = NULL;
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensWriteDataGpsInterruptSignal
-* ABSTRACT : Writing of data
-* FUNCTION : Writing Data to Shared Memory
-* ARGUMENT : DID : Data ID
-* NOTE :
-* RETURN : RET_NORMAL :Normal
-* : RET_ERROR :Abnormality
-******************************************************************************/
-static RET_API VehicleSensWriteDataGpsInterruptSignal(DID ul_did) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static GPS_INTERRUPT *gpsInterruptSharedAddr = NULL; /* Store Shared Memory Address */
- static SemID sem_id = 0; /* ID of shared memory exclusive semaphore */
-
- VEHICLESENS_DATA_MASTER_GPS_INTERRUPT_SIGNAL pst_data;
-
- RET_API l_ret = RET_NORMAL; /* Return of the functions */
- RET_API l_ret_api; /* Return of the functions */
-
-
- /* Get Semaphore ID */
- if (sem_id == 0) {
- sem_id = _pb_CreateSemaphore(const_cast<char *>(GPS_INTERRUPT_SIGNAL_SEMAPHO_NAME));
- }
-
- if (sem_id != 0) {
- /* Semaphore ID successfully acquired */
- l_ret_api = _pb_SemLock(sem_id); /* Semaphore Lock */
-
- if (l_ret_api == RET_NORMAL) {
- /* Semaphore lock successful */
-
- /* When the shared memory is not linked */
- if (gpsInterruptSharedAddr == NULL) {
- /* Link to shared memory */
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
- VehicleSensLinkSharedMemory(const_cast<char *>(GPS_INTERRUPT_SIGNAL_SHARE_NAME),
- reinterpret_cast<void **>(&gpsInterruptSharedAddr));
- }
-
- if (gpsInterruptSharedAddr != NULL) {
- /* The link to shared memory is successful. */
- switch (ul_did) {
- case VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL:
- {
- /* Get data from data master */
- VehicleSensGetDataMasterMainGpsInterruptSignal(ul_did, 0, &pst_data);
-
- /* Writing Data to Shared Memory */
- gpsInterruptSharedAddr->_CWORD102__interrupt = pst_data.uc_data;
- break;
- }
- case VEHICLE_DID_SYS_GPS_INTERRUPT_SIGNAL:
- {
- /* Get data from data master */
- VehicleSensGetDataMasterSysGpsInterruptSignal(ul_did, 0, &pst_data);
-
- /* Writing Data to Shared Memory */
- gpsInterruptSharedAddr->_CWORD56__interrupt = pst_data.uc_data;
- break;
- }
- default:
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "DID is unknown. \r\n");
- break;
- }
-
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "gpsInterruptSharedAddr == NULL \r\n");
- }
-
- /* Semaphore unlock */
- (void)_pb_SemUnlock(sem_id);
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SemLock failed");
- }
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "sem_id == 0");
- }
-
- return l_ret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensWriteDataGyroConnectStatus
-* ABSTRACT : Writing of data
-* FUNCTION : Writing Data to Shared Memory
-* ARGUMENT : DID : Data ID
-* NOTE :
-* RETURN : RET_NORMAL :Normal
-* : RET_ERROR :Abnormality
-******************************************************************************/
-static RET_API VehicleSensWriteDataGyroConnectStatus(DID ul_did) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static u_int8 *gyroConnectSharedAddr = NULL; /* Store Shared Memory Address */
- static SemID sem_id = 0; /* ID of shared memory exclusive semaphore */
-
- VEHICLESENS_DATA_MASTER_GYRO_CONNECT_STATUS pst_data;
-
- RET_API l_ret = RET_NORMAL; /* Return of the functions */
- RET_API l_ret_api; /* Return of the functions */
-
- /* Get Semaphore ID */
- if (sem_id == 0) {
- sem_id = _pb_CreateSemaphore(const_cast<char *>(GYRO_CONNECT_STATUS_SEMAPHO_NAME));
- }
-
- if (sem_id != 0) {
- /* Semaphore ID successfully acquired */
- l_ret_api = _pb_SemLock(sem_id); /* Semaphore Lock */
-
- if (l_ret_api == RET_NORMAL) {
- /* Semaphore lock successful */
-
- /* When the shared memory is not linked */
- if (gyroConnectSharedAddr == NULL) {
- /* Link to shared memory */
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
- VehicleSensLinkSharedMemory(const_cast<char *>(GYRO_CONNECT_STATUS_SHARE_NAME),
- reinterpret_cast<void **>(&gyroConnectSharedAddr));
- }
-
- if (gyroConnectSharedAddr != NULL) {
- /* The link to shared memory is successful. */
-
- /* Get data from data master */
- VehicleSensGetDataMasterGyroConnectStatus(ul_did, 0, &pst_data);
-
- /* Writing Data to Shared Memory */
- *gyroConnectSharedAddr = pst_data.uc_data;
-
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "gyroConnectSharedAddr == NULL \r\n");
- }
-
- /* Semaphore unlock */
- (void)_pb_SemUnlock(sem_id);
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SemLock failed");
- }
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "sem_id == 0");
- }
-
- return l_ret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensWriteDataValidEphemerisNum
-* ABSTRACT : Write effective ephemeris number at shutdown
-* FUNCTION : Write effective ephemeris number at shutdown to shared memory
-* ARGUMENT : u_int8 valid_ephemer_isnum : Number of effective ephemeris written to shared memory during shutdown
-* NOTE :
-* RETURN : RET_NORMAL :Normal
-* : RET_ERROR :Abnormality
-******************************************************************************/
-RET_API VehicleSensWriteDataValidEphemerisNum(u_int8 valid_ephemer_isnum) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static u_int8 *shared_addr = NULL; /* Store Shared Memory Address */
- static SemID sem_id = 0; /* ID of shared memory exclusive semaphore */
-
- RET_API l_ret; /* Return of the functions */
- RET_API l_ret_api; /* Return of the functions */
-
- /* Get Semaphore ID */
- if (sem_id == 0) {
- sem_id = _pb_CreateSemaphore(const_cast<char *>(EPHEMERIS_NUM_SEMAPHO_NAME));
- }
-
- if (sem_id != 0) {
- /* Semaphore ID successfully acquired */
- l_ret_api = _pb_SemLock(sem_id); /* Semaphore Lock */
-
- if (l_ret_api == RET_NORMAL) {
- /* Semaphore lock successful */
-
- /* When the shared memory is not linked */
- if (shared_addr == NULL) {
- /* Link to shared memory */
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
- VehicleSensLinkSharedMemory(const_cast<char *>(EPHEMERIS_NUM_SHARE_NAME),
- reinterpret_cast<void **>(&shared_addr));
- }
-
- if (shared_addr != NULL) {
- *shared_addr = valid_ephemer_isnum;
- l_ret = RET_NORMAL;
-
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "shared_addr == NULL \r\n");
- }
-
- /* Semaphore unlock */
- l_ret_api = _pb_SemUnlock(sem_id);
- if (l_ret_api != RET_NORMAL) {
- /* Semaphore unlock failure */
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SemUnlock failed");
- }
- } else {
- /* Semaphore ID acquisition failure */
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SemLock failed");
- }
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "sem_id == 0");
- }
-
- return l_ret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensWriteDataLocalTime
-* ABSTRACT : Writing Local Time at Shutdown
-* FUNCTION : Write local time on shutdown to shared memory
-* ARGUMENT : None
-* NOTE :
-* RETURN : RET_NORMAL :Acquisition normal
-* : RET_ERROR :Acquisition anomaly
-******************************************************************************/
-static RET_API VehicleSensWriteDataLocalTime(void) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static LOCALTIME *shared_addr = NULL; /* Store Shared Memory Address */
- static SemID sem_id = 0; /* ID of shared memory exclusive semaphore */
-
- RET_API l_ret; /* Return of the functions */
- RET_API l_ret_api; /* Return of the functions */
-
- LOCALTIME LocalTime;
-
- /* Get Semaphore ID */
- if (sem_id == 0) {
- sem_id = _pb_CreateSemaphore(const_cast<char *>(LOCALTIME_SEMAPHO_NAME));
- }
-
- if (sem_id != 0) {
- /* Semaphore ID successfully acquired */
- l_ret_api = _pb_SemLock(sem_id); /* Semaphore Lock */
-
- if (l_ret_api == RET_NORMAL) {
- /* Semaphore lock successful */
-
- /* When the shared memory is not linked */
- if (shared_addr == NULL) {
- /* Link to shared memory */
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
- VehicleSensLinkSharedMemory(const_cast<char *>(LOCALTIME_SHARE_NAME),
- reinterpret_cast<void **>(&shared_addr));
- }
-
- if (shared_addr != NULL) {
- /* The link to shared memory is successful. */
-
- /* Acquires data from the non-volatile memory and writes it to the shared memory. */
- l_ret_api = VehicleSensReadNVLocalTime(&LocalTime);
- if (l_ret_api == RET_NORMAL) {
- *shared_addr = LocalTime;
- l_ret = RET_NORMAL;
- } else {
- /* When data acquisition from non-volatile memory fails,Set an invalid value */
- (*shared_addr).status = CLOCK_INVALID;
- (*shared_addr).year = 0xFFFFU; /* invalid */
- (*shared_addr).month = 255U; /* invalid */
- (*shared_addr).day = 255U; /* invalid */
- (*shared_addr).hour = 255U; /* invalid */
- (*shared_addr).min = 255U; /* invalid */
- (*shared_addr).sec = 255U; /* invalid */
- l_ret = RET_NORMAL;
- }
-
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "shared_addr == NULL \r\n");
- }
-
- /* Semaphore unlock */
- l_ret_api = _pb_SemUnlock(sem_id);
- if (l_ret_api != RET_NORMAL) {
- /* Semaphore unlock failure */
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SemUnlock failed");
- }
- } else {
- /* Semaphore ID acquisition failure */
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SemLock failed");
- }
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "sem_id == 0");
- }
-
- return l_ret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensWriteDataLonLat
-* ABSTRACT : Write position at shutdown
-* FUNCTION : Write shutdown position to shared memory
-* ARGUMENT : None
-* NOTE :
-* RETURN : RET_NORMAL :Successful acquisition
-* : RET_ERROR :Failed to acquire
-******************************************************************************/
-static RET_API VehicleSensWriteDataLonLat(void) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static LONLAT *shared_addr = NULL; /* Store Shared Memory Address */
- static SemID sem_id = 0; /* ID of shared memory exclusive semaphore */
-
- RET_API l_ret; /* Return of the functions */
- RET_API l_ret_api; /* Return of the functions */
-
- LONLAT lonlat; /* Position */
-
- /* Get Semaphore ID */
- if (sem_id == 0) {
- sem_id = _pb_CreateSemaphore(const_cast<char *>(LONLAT_SEMAPHO_NAME));
- }
-
- if (sem_id != 0) {
- /* Semaphore ID successfully acquired */
- l_ret_api = _pb_SemLock(sem_id); /* Semaphore Lock */
-
- if (l_ret_api == RET_NORMAL) {
- /* Semaphore lock successful */
-
- /* When the shared memory is not linked */
- if (shared_addr == NULL) {
- /* Link to shared memory */
- /* #QAC confirmation Rule11.4 Use structure for member reference(Cast according to shared memory link IF) */
- VehicleSensLinkSharedMemory(const_cast<char *>(LONLAT_SHARE_NAME),
- reinterpret_cast<void **>(&shared_addr));
- }
-
- if (shared_addr != NULL) {
- /* The link to shared memory is successful. */
-
- /* Acquires data from the non-volatile memory and writes it to the shared memory. */
- l_ret_api = VehicleSensReadNVLonLat(&lonlat);
- if (l_ret_api == RET_NORMAL) {
- *shared_addr = lonlat;
- l_ret = RET_NORMAL;
- } else {
- /* When data acquisition from non-volatile memory fails */
- (*shared_addr).latitude = SENSORLOCATION_LATITUDE_INIT_VALUE;
- (*shared_addr).longitude = SENSORLOCATION_LONGITUDE_INIT_VALUE;
- l_ret = RET_NORMAL;
- }
-
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "shared_addr == NULL \r\n");
- }
-
- /* Semaphore unlock */
- l_ret_api = _pb_SemUnlock(sem_id);
- if (l_ret_api != RET_NORMAL) {
- /* Semaphore unlock failure */
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SemUnlock failed");
- }
- } else {
- /* Semaphore ID acquisition failure */
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SemLock failed");
- }
- } else {
- l_ret = RET_ERROR;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "sem_id == 0");
- }
-
- return l_ret;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensWriteSharedMemory
-* ABSTRACT : Write Shared Memory
-* FUNCTION : Write Shared Memory
-* ARGUMENT : DID : Data ID
-* RETURN : None
-* NOTE :
-******************************************************************************/
-void VehicleSensWriteSharedMemory(DID ul_did) {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- switch (ul_did) {
- case VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL:
- case VEHICLE_DID_SYS_GPS_INTERRUPT_SIGNAL:
- {
- (void)VehicleSensWriteDataGpsInterruptSignal(ul_did);
- break;
- }
- case VEHICLE_DID_GYRO_CONNECT_STATUS:
- {
- (void)VehicleSensWriteDataGyroConnectStatus(ul_did);
- break;
- }
- default:
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "DID is unknown. \r\n");
- break;
- }
-}
-// LCOV_EXCL_STOP
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Thread.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleSens_Thread.cpp
deleted file mode 100755
index 8dc3922..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleSens_Thread.cpp
+++ /dev/null
@@ -1,2144 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/*******************************************************************************
- * File name :VehicleSens_Thread.cpp
- * System name :GPF
- * Subsystem name :Vehicle sensor process
- * Program name :Vehicle sensor thread
- * Module configuration :VehicleSensThread() Vehicle Sensor Thread Domain Functions
- * :VehicleSensThreadInit() Vehicle sensor thread initials
- * :VehicleSensDeliveryEntry() Vehicle sensor information delivery registration
- * :VehicleSensGetVehicleData() Vehicle sensor information acquisition
- * :VehicleSensWatchStopPage() Vehicle sensor interruption monitoring
- * :VehicleSensPkgDeliveryEntry() Vehicle sensor information package delivery registration
- * :VehicleSensGetVehiclePkgData() Vehicle sensor information package data acquisition
- * :VehicleSensLineSensDataDelivery() LineSensor Vehicle Signal Notification
- * :VehicleSensGpsDataDelivery() GPS data notification
- * :VehicleSens_CanDataDelivery() CAN data delivery notice
- * :VehicleSensDataMasterSetN() Data master set notification process(Callback function)
- * :VehicleSensSetVehicleData() GPS command request processing
- ******************************************************************************/
-#include "VehicleSens_Thread.h"
-#include <vehicle_service/positioning_base_library.h>
-#include <other_service/VP_GetEnv.h>
-#include "POS_private.h"
-#include "positioning_common.h"
-#include "SensorLog.h"
-#include "VehicleUtility.h"
-#include "VehicleSensor_Thread.h"
-
-#include "VehicleIf.h"
-
-/*************************************************/
-/* Global variable */
-/*************************************************/
-static VEHICLE_MSG_BUF g_wait_for_resp_msg; /* Message waiting to receive a response */
-static PFUNC_DMASTER_SET_N g_wait_for_resp_set_n; /* Response waiting data master set */
-static BOOL g_sent_fst_pkg_delivery_ext; /* Initial expansion package data delivery status */
-
-static VEHICLESENS_VEHICLE_SPEED_INFO g_vehicle_speed_info;
-
-uint32_t gPseudoSecClockCounter = 0u;
-
-/*************************************************/
-/* Function prototype */
-/*************************************************/
-static void VehicleSensInitDataDisrptMonitor(void);
-static void VehicleSensDataDisrptMonitorProc(DID did);
-static void VehicleSensRcvMsgTout(TimerToutMsg* rcv_msg);
-
-static void VehilceSens_InitVehicleSpeed(void);
-static void VehicleSens_StoreVehicleSpeed(VEHICLESENS_VEHICLE_SPEED_DAT* pVehicleSpeed);
-static void VehicleSens_LoadVehicleSpeed(VEHICLESENS_VEHICLE_SPEED_INFO* pVehicleSpeedInfo);
-static RET_API VehicleSens_CatNmeaSentenceFieldWithDelimiter(char* str1, const size_t size, const char* str2, const size_t n);
-static RET_API VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(char* str1, const size_t size, const char* str2, const size_t n);
-static inline RET_API VehicleSens_GeneratePASCDFieldId(char* pascd, size_t size);
-static inline RET_API VehicleSens_GeneratePASCDFieldTimestamp(char* pascd, size_t size);
-static inline RET_API VehicleSens_GeneratePASCDFieldSensorType(char* pascd, size_t size);
-static inline RET_API VehicleSens_GeneratePASCDFieldTransmissionState(char* pascd, size_t size);
-static inline RET_API VehicleSens_GeneratePASCDFieldSlipDetect(char* pascd, size_t size);
-static inline RET_API VehicleSens_GeneratePASCDFieldSampleCount(char* pascd, size_t size);
-static inline RET_API VehicleSens_GeneratePASCDFieldTimeOffsetNSpeed(char* pascd, size_t size);
-static inline RET_API VehicleSens_GeneratePASCDFieldChecksum(char* pascd, size_t size);
-static inline RET_API VehicleSens_GeneratePASCDFieldCRLF(char* pascd, size_t size);
-static RET_API VehicleSens_DeriveTransmissionStateFor_CWORD27_(VEHICLESENS_TRANSMISSION_PKG* pPkg);
-
-
-/*******************************************************************************
-* MODULE : VehicleSensThread
-* ABSTRACT : Vehicle Sensor Thread Domain Functions
-* FUNCTION : Main processing
-* ARGUMENT : lpv_para :
-* NOTE :
-* RETURN :
-******************************************************************************/
-EFrameworkunifiedStatus VehicleSensThread(HANDLE h_app) {
- RET_API ret_api = RET_NORMAL; /* Return Values of System API Functions */
- T_APIMSG_MSGBUF_HEADER *p; /* Message header */
- RET_API ret_val; /* Return value of initialization processing */
- VEHICLE_MSG_DELIVERY_ENTRY delivery_entry;
-
- static u_int8 msg_buf[MAX_MSG_BUF_SIZE]; /* message buffer */
-
- void* p_msg_buf = &msg_buf;
- LSDRV_MSG_LSDATA_G** p_lsdrv_msg;
- VEHICLE_MSG_BUF** p_vehicle_msg;
- POS_MSGINFO *p_pos_msg;
-
-
-
- p_lsdrv_msg = reinterpret_cast<LSDRV_MSG_LSDATA_G**>(&p_msg_buf);
- p_vehicle_msg = reinterpret_cast<VEHICLE_MSG_BUF**>(&p_msg_buf);
-
- VehicleUtilityInitTimer();
- (void)PosSetupThread(h_app, ETID_POS_MAIN);
-
- memset(&(delivery_entry), 0, sizeof(VEHICLE_MSG_DELIVERY_ENTRY));
-
- /* Thread initialization process */
- ret_val = VehicleSensThreadInit();
-
- gPseudoSecClockCounter = 0u;
-
- if (RET_NORMAL == ret_val) { // LCOV_EXCL_BR_LINE 6: always be RET_NORMAL
- while (1) {
- /* Message reception processing */
- p_msg_buf = &msg_buf;
- ret_api = _pb_RcvMsg(PNO_VEHICLE_SENSOR, sizeof(msg_buf), &p_msg_buf, RM_WAIT);
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__,
- "[ret_api = 0x%x]",
- ret_api);
-
- /* When the message is received successfully */
- if (ret_api == RET_RCVMSG) {
- p = reinterpret_cast<T_APIMSG_MSGBUF_HEADER *>(p_msg_buf);
-
- switch (p->hdr.cid) { // LCOV_EXCL_BR_LINE 200: some DID is not used
- case CID_VEHICLEIF_DELIVERY_ENTRY:
- {
- memcpy(&(delivery_entry), &(p_msg_buf), sizeof(VEHICLE_MSG_DELIVERY_ENTRY));
-
- /* Sort by received DID */
- switch (delivery_entry.data.did) { // LCOV_EXCL_BR_LINE 200: DR DID is not used
- case VEHICLE_DID_DR_ALTITUDE :
- case VEHICLE_DID_DR_LATITUDE :
- case VEHICLE_DID_DR_SPEED :
- case VEHICLE_DID_DR_HEADING :
- case VEHICLE_DID_DR_GYRO_SCALE_FACTOR_LEVEL :
- case VEHICLE_DID_DR_SPEED_PULSE_SCALE_FACTOR_LEVEL :
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensDrDeliveryEntry((const VEHICLE_MSG_DELIVERY_ENTRY *)p_msg_buf);
- // LCOV_EXCL_STOP
- }
- break;
- default:
- /* Vehicle sensor information delivery registration */
- VehicleSensDeliveryEntry((const VEHICLE_MSG_DELIVERY_ENTRY *)p_msg_buf);
- break;
- }
- break;
- }
- case CID_VEHICLEIF_GET_VEHICLE_DATA:
- {
- /* Vehicle sensor information acquisition */
- VehicleSensGetVehicleData((const VEHICLE_MSG_GET_VEHICLE_DATA *)p_msg_buf);
- break;
- }
- case CID_LINESENS_VEHICLE_DATA:
- {
- /* LineSensor Vehicle Signal Notification */
- VehicleSensLineSensDataDelivery((const LSDRV_MSG_LSDATA *)p_msg_buf,
- (PFUNC_DMASTER_SET_N)VehicleSensDataMasterSetN);
- break;
- }
- case CID_LINESENS_VEHICLE_DATA_G:
- {
- /* Data disruption monitoring process */
- VehicleSensDataDisrptMonitorProc(
- (reinterpret_cast<LSDRV_MSG_LSDATA_G*>(*p_lsdrv_msg))->st_para.st_data[0].ul_did);
- VehicleSensLineSensDataDeliveryG((const LSDRV_MSG_LSDATA_G *)p_msg_buf,
- (PFUNC_DMASTER_SET_N)VehicleSensDataMasterSetN);
- break;
- }
- case CID_LINESENS_VEHICLE_DATA_GYRO_TROUBLE:
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Gyro Failure Status Notification */
- VehicleSensLineSensDataDeliveryGyroTrouble((const LSDRV_MSG_LSDATA_GYRO_TROUBLE *)p_msg_buf,
- (PFUNC_DMASTER_SET_N)VehicleSensDataMasterSetN);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_LINESENS_VEHICLE_DATA_SYS_GPS_INTERRUPT_SIGNAL:
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* SYS GPS interrupt notification */
- VehicleSensLineSensDataDeliverySysGpsInterruptSignal(
- (const LSDRV_MSG_LSDATA_GPS_INTERRUPT_SIGNAL *)p_msg_buf,
- (PFUNC_DMASTER_SET_SHARED_MEMORY)VehicleSensDataMasterSetSharedMemory);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_LINESENS_VEHICLE_DATA_GYRO_CONNECT_STATUS:
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Gyro Failure Status Notification */
- VehicleSensLineSensDataDeliveryGyroConnectStatus(
- (const LSDRV_MSG_LSDATA_GYRO_CONNECT_STATUS *)p_msg_buf,
- (PFUNC_DMASTER_SET_SHARED_MEMORY)VehicleSensDataMasterSetSharedMemory);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_LINESENS_VEHICLE_DATA_GPS_ANTENNA_STATUS:
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* GPS antenna failure status notification */
- VehicleSensLineSensDataDeliveryGpsAntennaStatus(
- (const LSDRV_MSG_LSDATA_GPS_ANTENNA_STATUS *)p_msg_buf,
- (PFUNC_DMASTER_SET_N)VehicleSensDataMasterSetN);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_SENSORIF_PKG_DELIVERY_ENTRY_EXT:
- {
- /* Vehicle Sensor Information Extended Package Delivery Registration */
- VehicleSensPkgDeliveryEntryExt((const SENSOR_MSG_DELIVERY_ENTRY *)p_msg_buf);
- break;
- }
- case CID_LINESENS_VEHICLE_DATA_FST:
- {
- /* LineSensor Vehicle Initial Sensor Signal Notification */
- VehicleSensLineSensDataDeliveryFstG((const LSDRV_MSG_LSDATA_FST *)p_msg_buf,
- (PFUNC_DMASTER_SET_N)VehicleSensDataMasterSetN);
- break;
- }
- case CID_GPS_DATA:
- {
- /* GPS information notification */
- VehicleSensGpsDataDelivery(reinterpret_cast<SENSOR_MSG_GPSDATA *>(p_msg_buf),
- (PFUNC_DMASTER_SET_N)VehicleSensDataMasterSetN,
- (PFUNC_DMASTER_SET_SHARED_MEMORY)VehicleSensDataMasterSetSharedMemory);
- break;
- }
- case CID_POSIF_SET_DATA:
- {
- p_pos_msg =
- reinterpret_cast<POS_MSGINFO*>((reinterpret_cast<VEHICLE_MSG_BUF*>(*p_vehicle_msg))->data);
- /* Data disruption monitoring process */
- VehicleSensDataDisrptMonitorProc(p_pos_msg->did);
-
- /* Data Setting Notification */
- VehicleSensCommonDataDelivery((const VEHICLE_MSG_BUF *)p_msg_buf,
- (PFUNC_DMASTER_SET_N)VehicleSensDataMasterSetN);
- break;
- }
- case CID_GPS_RETTIMESETTING:
- {
- /* GPS time setting result notification */
- VehicleSensGpsTimeDelivery((const VEHICLE_MSG_BUF *)p_msg_buf);
- break;
- }
- case CID_DEAD_RECKONING_GPS_DATA : /* GPS data distribution for DR */
- case CID_DEAD_RECKONING_SENS_DATA : /* Sensor Data Delivery for DR */
- case CID_DEAD_RECKONING_SENS_FST_DATA : /* Initial Sensor Data Delivery for DR */
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensDrRcvMsg((const DEAD_RECKONING_RCVDATA *)p_msg_buf);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_VEHICLEIF_GET_DR_DATA :
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Vehicle sensor information acquisition */
- DeadReckoningGetDRData((const DEADRECKONING_MSG_GET_DR_DATA *)p_msg_buf);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_DR_MAP_MATCHING_DATA : /* Map matching information */
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- DeadReckoningSetMapMatchingData((const DR_MSG_MAP_MATCHING_DATA *)p_msg_buf);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_DR_CLEAR_BACKUP_DATA : /* Clear backup data */
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- DeadReckoningClearBackupData((const DR_MSG_CLEAR_BACKUP_DATA*)p_msg_buf);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_VEHICLEDEBUG_LOG_GET : /* Log acquisition request */
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensGetLog((const VEHICLEDEBUG_MSG_BUF *)p_msg_buf);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_VEHICLEDEBUG_LOG_SET : /* Log Setting Request */
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensSetLog((const VEHICLEDEBUG_MSG_BUF *)p_msg_buf);
- break;
- // LCOV_EXCL_STOP
- }
- case CANINPUT_CID_LOCALTIME_NOTIFICATION : /* CAN information acquisition */
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensWriteLocalTime((const CANINPUT_MSG_INFO*)p_msg_buf);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_EPH_NUM_NOTIFICATION : /* Set effective ephemeris count at shutdown */
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VehicleSensSetEphNumSharedMemory((const SENSOR_MSG_GPSDATA *)p_msg_buf);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_SENSORIF__CWORD82__REQUEST:
- {
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Requests to send GPS _CWORD82_ commands */
- VehicleSensSetVehicleData((const VEHICLE_MSG_SEND *)p_msg_buf);
- break;
- // LCOV_EXCL_STOP
- }
- case CID_THREAD_STOP_REQ:
- {
- /* Thread stop processing */
- VehicleSensThreadStopProcess();
- break;
- }
- case CID_TIMER_TOUT:
- {
- /* Timeout notification reception processing */
- VehicleSensRcvMsgTout(reinterpret_cast<TimerToutMsg*>(p_msg_buf));
- break;
- }
- default:
- break;
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "ret_api != RET_RCVMSG\r\n");
- }
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "VehicleSens: VehicleSens_MainThread Initial Error!! :%d", ret_val);
- _pb_Exit();
- }
-
- return eFrameworkunifiedStatusOK;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensThreadInit
-* ABSTRACT : Vehicle sensor thread initials
-* FUNCTION : Initial process
-* ARGUMENT : void
-* NOTE :
-* RETURN : CAN data delivery registration result
-******************************************************************************/
-RET_API VehicleSensThreadInit(void) {
- RET_API ret_val = RET_NORMAL;
-
- /* Initialization of Vehicle Selection Item List Table */
- VehicleSensInitSelectionItemList();
-
- /* Vehicle sensor data master initialization */
- VehicleSensInitDataMaster();
-
- /* Initialization of shipping destination management table */
- VehicleSensInitDeliveryCtrlTbl();
-
- /* Initialization of shipping destination management table management information */
- VehicleSensInitDeliveryCtrlTblMng();
-
- /* Initialization of package delivery management table */
- VehicleSensInitPkgDeliveryTblMng();
-
- /* Initialization of non-volatile access function block */
- VehicleSensFromAccessInitialize();
-
- /* Clear message information waiting to receive a response */
- (void)memset(&g_wait_for_resp_msg, 0x00, sizeof(VEHICLE_MSG_BUF));
- g_wait_for_resp_set_n = NULL;
- g_sent_fst_pkg_delivery_ext = FALSE; /* Initial expansion package data undelivered */
-
- VehilceSens_InitVehicleSpeed(); /* for PASCD */
-
- /* Start of data interruption monitoring */
- VehicleSensInitDataDisrptMonitor();
- return ret_val;
-}
-
-/*******************************************************************************
- * MODULE : VehicleSensDeliveryEntry
- * ABSTRACT : Vehicle sensor information delivery registration
- * FUNCTION :
- * ARGUMENT : *msg : message buffer
- * NOTE :
- * RETURN : void
- ******************************************************************************/
-void VehicleSensDeliveryEntry(const VEHICLE_MSG_DELIVERY_ENTRY *msg) {
- int32 event_val;
- EventID event_id;
-
- /* Call the process of creating the delivery destination management table */
- event_val = static_cast<int32>(VehicleSensEntryDeliveryCtrl(msg));
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* Event Generation */
- event_id = VehicleCreateEvent(msg->data.pno);
-
- /* Publish Events */
- (void)_pb_SetEvent(event_id, SAPI_EVSET_ABSOLUTE, event_val);
-
- if (VEHICLE_RET_NORMAL == event_val) {
- /* Successful delivery registration */
- /* Deliver data for the first time */
- VehicleSensFirstDelivery((PNO)(msg->data.pno), (DID)(msg->data.did));
- }
-
- /* Event deletion */
- (void)VehicleDeleteEvent(event_id);
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "-");
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensGetVehicleData
-* ABSTRACT : Vehicle sensor information acquisition
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetVehicleData(const VEHICLE_MSG_GET_VEHICLE_DATA *msg) {
- void *share_top; /* Start address of shared memory */
- u_int32 share_size; /* Size of shared memory area */
- u_int8 get_method; /* Data collection way */
- VEHICLESENS_DATA_MASTER master; /* Data master */
- RET_API ret_api;
- int32 ret_val;
- int32 event_val;
- EventID event_id;
- SENSOR_MSG_GPSDATA_DAT gps_master; /* GPS Data Master */
-
- /* Check the DID */
- ret_val = VehicleSensCheckDid(msg->data.did);
- if (VEHICLESENS_INVALID != ret_val) { // LCOV_EXCL_BR_LINE 6:did always valid
- /* DID normal */
-
- /* Link to shared memory */
- ret_api = _pb_LinkShareData(const_cast<char *>(VEHICLE_SHARE_NAME), &share_top, &share_size);
- if (RET_NORMAL == ret_api) {
- /* Acquire the specified data from the data master. */
- get_method = VehicleSensGetSelectionItemList(msg->data.did);
- if ((VEHICLESENS_GETMETHOD_GPS == get_method) &&
- ((msg->data.did != VEHICLE_DID_LOCATION_LONLAT) &&
- (msg->data.did != VEHICLE_DID_LOCATION_ALTITUDE) &&
- (msg->data.did != VEHICLE_DID_MOTION_HEADING))) {
- /* _CWORD71_ processing speed(Memset modification) */
- /* Retrieval of the data master fails.,Initialize size to 0 to prevent unauthorized writes */
- gps_master.us_size = 0;
- VehicleSensGetGpsDataMaster(msg->data.did, get_method, &gps_master);
- /* Check the data size */
- if (msg->data.size < gps_master.us_size) {
- /* Shared memory error(Insufficient storage size) */
- event_val = VEHICLE_RET_ERROR_OUTOF_MEMORY;
- } else {
- /* Write data master to shared memory */
- PosSetShareData(share_top,
- msg->data.offset, (const void *)&gps_master.uc_data, gps_master.us_size);
-
- /* Set Successful Completion */
- event_val = VEHICLE_RET_NORMAL;
- SensLogWriteOutputData(SENSLOG_DATA_O_UNSPECIFIED,
- msg->data.did, msg->data.pno,
- reinterpret_cast<uint8_t *>(&(gps_master.uc_data[0])),
- gps_master.us_size, SENSLOG_RES_SUCCESS);
- }
- } else {
- (void)memset(reinterpret_cast<void *>(&master), 0, sizeof(VEHICLESENS_DATA_MASTER));
- VehicleSensGetDataMaster(msg->data.did, get_method, &master);
-
- /* Check the data size */
- if (msg->data.size < master.us_size) {
- /* Shared memory error(Insufficient storage size) */
- event_val = VEHICLE_RET_ERROR_OUTOF_MEMORY;
- } else {
- /* Write data master to shared memory */
- PosSetShareData(share_top,
- msg->data.offset, (const void *)master.uc_data, master.us_size);
-
- /* Set Successful Completion */
- event_val = VEHICLE_RET_NORMAL;
- SensLogWriteOutputData(SENSLOG_DATA_O_UNSPECIFIED,
- msg->data.did, msg->data.pno,
- reinterpret_cast<uint8_t *>(&(master.uc_data[0])),
- master.us_size, SENSLOG_RES_SUCCESS);
- }
- }
- } else {
- /* Shared memory error */
- event_val = VEHICLE_RET_ERROR_OUTOF_MEMORY;
- }
- } else {
- /* DID error */
- event_val = VEHICLE_RET_ERROR_DID;
- }
-
- /* Event Generation */
- event_id = VehicleCreateEvent(msg->data.pno);
-
- /* Publish Events */
- ret_api = _pb_SetEvent(event_id, SAPI_EVSET_ABSOLUTE, event_val);
- if (RET_NORMAL != ret_api) {
- /* Event issuance failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SetEvent ERROR!! [ret_api = %d]", ret_api);
- }
-
- /* Event deletion */
- (void)VehicleDeleteEvent(event_id);
-
- return;
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensWatchStopPage
-* ABSTRACT : Vehicle sensor interruption monitoring
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensWatchStopPage(const VEHICLE_MSG_WATCH_STOPPAGE *msg) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Not used(Delete Used Functions After Investigation) */
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensPkgDeliveryEntry
-* ABSTRACT : Vehicle sensor information package delivery registration
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensPkgDeliveryEntry(const SENSOR_MSG_DELIVERY_ENTRY *msg) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- int32 event_val;
- EventID event_id;
-
- /* Call the process of creating the delivery destination management table */
- event_val = static_cast<int32>(VehicleSensEntryPkgDeliveryCtrl(msg , VEHICLESENS_EXT_OFF));
- /* #Polaris_003 */
-
- /* Event Generation */
- event_id = PosCreateEvent(msg->data.pno);
-
- /* Publish Events */
- (void)_pb_SetEvent(msg->data.event_id, SAPI_EVSET_ABSOLUTE, event_val);
-
- if (VEHICLE_RET_NORMAL == event_val) {
- /* Successful delivery registration */
- /* Deliver package data for the first time */
- VehicleSensFirstPkgDelivery(&msg->data);
- }
-
- /* Event deletion */
- (void)PosDeleteEvent(event_id);
-}
-// LCOV_EXCL_STOP
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensPkgDeliveryEntryExt
-* ABSTRACT : Vehicle Sensor Information Extended Package Delivery Registration
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensPkgDeliveryEntryExt(const SENSOR_MSG_DELIVERY_ENTRY *msg) {
- int32 event_val;
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- /* Call the process of creating the delivery destination management table */
- event_val = static_cast<int32>(VehicleSensEntryPkgDeliveryCtrl(msg , VEHICLESENS_EXT_ON));
-
- /* Event Generation */
- (void)PosCreateEvent(msg->data.pno);
-
- /* Publish Events */
- (void)_pb_SetEvent(msg->data.event_id, SAPI_EVSET_ABSOLUTE, event_val);
-
- if (VEHICLE_RET_NORMAL == event_val) {
- /* Successful delivery registration */
- /* Provide initial expansion package data delivery */
- VehicleSensFirstPkgDeliveryExt(&msg->data);
-
- /* Initial expansion package data delivered */
- g_sent_fst_pkg_delivery_ext = TRUE;
-
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__,
- "FirstPkgDeliveryExt call.[%d]",
- g_sent_fst_pkg_delivery_ext); /* TODO */
- }
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "-");
-}
-
-#else
-/*******************************************************************************
-* MODULE : VehicleSensPkgDeliveryEntryError
-* ABSTRACT : Vehicle Sensor Information Extended Package Delivery Registration
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensPkgDeliveryEntryError(const SENSOR_MSG_DELIVERY_ENTRY *msg) {
- RET_API ret_api;
- EventID event_id;
-
- /* Event Generation */
- event_id = PosCreateEvent(msg->data.pno);
-
- /* Publish Event Set DID Error */
- ret_api = _pb_SetEvent(msg->data.event_id, SAPI_EVSET_ABSOLUTE, VEHICLE_RET_ERROR_DID);
-}
-
-#endif
-
-/*******************************************************************************
-* MODULE : VehicleSensGetVehiclePkgData
-* ABSTRACT : Vehicle sensor information package data acquisition
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGetVehiclePkgData(const SENSOR_MSG_GET_SENSOR_DATA *msg) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensLineSensDataDelivery
-* ABSTRACT : LineSensor Vehicle Signal Notification
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* : p_datamaster_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensLineSensDataDelivery(const LSDRV_MSG_LSDATA *msg, PFUNC_DMASTER_SET_N p_datamaster_set_n) {
- int32 i;
- BOOL sens_ext;
-
- sens_ext = TRUE;
-
- for (i = 0; i < msg->st_para.uc_data_num; i++) {
- /* Setting Vehicle Signal Data from LineSensor as Data Master */
- VehicleSensSetDataMasterLineSens((const LSDRV_LSDATA *) & (msg->st_para.st_data[i]),
- p_datamaster_set_n, sens_ext);
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensLineSensDataDeliveryG
-* ABSTRACT : LineSensor Vehicle Signal Notification
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* : p_datamaster_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensLineSensDataDeliveryG(const LSDRV_MSG_LSDATA_G *msg, PFUNC_DMASTER_SET_N p_datamaster_set_n) {
- int32 i;
- BOOL sens_ext;
-
- sens_ext = TRUE;
- if (g_sent_fst_pkg_delivery_ext == TRUE) {
- /* Initial Expansion Package Data Delivery,Without storing extended data */
- sens_ext = FALSE;
- }
-
- for (i = 0; i < msg->st_para.uc_data_num; i++) {
- /* Setting Vehicle Signal Data from LineSensor as Data Master */
- VehicleSensSetDataMasterLineSensG((const LSDRV_LSDATA_G *) & (msg->st_para.st_data[i]),
- p_datamaster_set_n, sens_ext);
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensLineSensDataDeliveryGyroTrouble
-* ABSTRACT : Gyro Failure Status Notification
-* FUNCTION : Notify of a gyro failure condition
-* ARGUMENT : *msg : message buffer
-* : p_datamaster_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensLineSensDataDeliveryGyroTrouble(const LSDRV_MSG_LSDATA_GYRO_TROUBLE *msg, PFUNC_DMASTER_SET_N p_datamaster_set_n) { // LCOV_EXCL_START 8 : dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Setting Gyro Failure Status Data from LineSensor to Data Master */
- VehicleSensSetDataMasterGyroTrouble((const LSDRV_MSG_LSDATA_DAT_GYRO_TROUBLE *)&(msg->st_para),
- p_datamaster_set_n);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensLineSensDataDeliverySysGpsInterruptSignal
-* ABSTRACT : SYS GPS interrupt notification
-* FUNCTION : Notify SYS GPS interrupt signals
-* ARGUMENT : *msg : message buffer
-* : p_datamaster_set_sharedmemory : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensLineSensDataDeliverySysGpsInterruptSignal(const LSDRV_MSG_LSDATA_GPS_INTERRUPT_SIGNAL *msg, PFUNC_DMASTER_SET_SHARED_MEMORY p_datamaster_set_sharedmemory) { // LCOV_EXCL_START 8 :dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Sets the SYS GPS interrupt data from the LineSensor to the data master. */
- VehicleSensSetDataMasterSysGpsInterruptSignal((const LSDRV_MSG_LSDATA_DAT_GPS_INTERRUPT_SIGNAL *)&(msg->st_para),
- p_datamaster_set_sharedmemory);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensLineSensDataDeliveryGyroConnectStatus
-* ABSTRACT : Gyro Connection Status Notification
-* FUNCTION : Notify the state of the gyro connection
-* ARGUMENT : *msg : message buffer
-* : p_datamaster_set_sharedmemory : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensLineSensDataDeliveryGyroConnectStatus(const LSDRV_MSG_LSDATA_GYRO_CONNECT_STATUS *msg, PFUNC_DMASTER_SET_SHARED_MEMORY p_datamaster_set_sharedmemory) { // LCOV_EXCL_START 8 : dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Setting Gyro Connection Status Data from LineSensor to Data Master */
- VehicleSensSetDataMasterGyroConnectStatus((const LSDRV_MSG_LSDATA_DAT_GYRO_CONNECT_STATUS *)&(msg->st_para),
- p_datamaster_set_sharedmemory);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensLineSensDataDeliveryGpsAntennaStatus
-* ABSTRACT : GPS Antenna Connection Status Notification
-* FUNCTION : Notify the GPS antenna connection status
-* ARGUMENT : *msg : message buffer
-* : p_datamaster_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensLineSensDataDeliveryGpsAntennaStatus(const LSDRV_MSG_LSDATA_GPS_ANTENNA_STATUS *msg, PFUNC_DMASTER_SET_N p_datamaster_set_n) { // LCOV_EXCL_START 8 : dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* Setting GPS Antenna Connection Status Data from LineSensor as Data Master */
- VehicleSensSetDataMasterGpsAntennaStatus((const LSDRV_MSG_LSDATA_DAT_GPS_ANTENNA_STATUS *)&(msg->st_para),
- p_datamaster_set_n);
-}
-// LCOV_EXCL_STOP
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensLineSensDataDeliveryFst
-* ABSTRACT : LineSensor Vehicle Signal Notification(Initial Sensor)
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* : p_datamaster_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensLineSensDataDeliveryFst(const LSDRV_MSG_LSDATA_FST *msg, PFUNC_DMASTER_SET_N p_datamaster_set_n) { // LCOV_EXCL_START 8 : dead code // NOLINT(whitespace/line_length)
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-}
-// LCOV_EXCL_STOP
-#endif
-
-#if CONFIG_SENSOR_EXT_VALID /* Initial Sensor Support */
-/*******************************************************************************
-* MODULE : VehicleSensLineSensDataDeliveryFstG
-* ABSTRACT : LineSensor Vehicle Signal Notification(Initial Sensor)
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* : p_datamaster_set_n : Data Master Set Notification(Callback function)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensLineSensDataDeliveryFstG(const LSDRV_MSG_LSDATA_FST *msg, PFUNC_DMASTER_SET_N p_datamaster_set_n) {
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "+");
-
- if (msg == NULL) { // LCOV_EXCL_BR_LINE 6:msg cannot be null
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "msg == NULL\r\n"); // LCOV_EXCL_LINE 8: dead code
- } else {
- /* Set Vehicle Signal Data from LineSensor (Initial Sensor) as Data Master */
- VehicleSensSetDataMasterLineSensFstG((const LSDRV_MSG_LSDATA_DAT_FST *) & (msg->st_para),
- p_datamaster_set_n);
- }
-
- /* Internal debug log output */
- FRAMEWORKUNIFIEDLOG(ZONE_26, __FUNCTION__, "-");
-}
-#endif
-
-/*******************************************************************************
-* MODULE : VehicleSensGpsDataDelivery
-* ABSTRACT : GPS data notification
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* : p_datamaster_set_n : For Data Master Set Notification(Callback function) delivery
-* : p_datamaster_set_sharedmemory : Data Master Set Notification (Callback Function) Shared Memory Write
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensGpsDataDelivery(SENSOR_MSG_GPSDATA *msg,
- PFUNC_DMASTER_SET_N p_datamaster_set_n,
- PFUNC_DMASTER_SET_SHARED_MEMORY p_datamaster_set_sharedmemory) {
- /* Setting GPS Data as Data Master */
- if (msg->st_para.ul_did == VEHICLE_DID_MAIN_GPS_INTERRUPT_SIGNAL) { // LCOV_EXCL_BR_LINE 6:DID is not used
- // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* [PastModel002 Specifications] GPS->_CWORD102_ interrupt or not is obtained from GPS */
- VehicleSensSetDataMasterMainGpsInterruptSignal((const SENSOR_MSG_GPSDATA_DAT *)&(msg->st_para),
- p_datamaster_set_sharedmemory);
- // LCOV_EXCL_STOP
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__,
- "VehicleSensGpsDataDelivery VehicleSensSetDataMasterGps() -->");
- VehicleSensSetDataMasterGps(reinterpret_cast<SENSOR_MSG_GPSDATA_DAT *>(&(msg->st_para)),
- p_datamaster_set_n);
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__,
- "VehicleSensGpsDataDelivery VehicleSensSetDataMasterGps() <--");
- }
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensDataMasterSetN
-* ABSTRACT : Data master set notification process(Callback function)
-* FUNCTION : Call the data delivery process
-* ARGUMENT : did : Data ID
-* : chg_type : Change type(no change/with change)
-* : get_method : Acquisition method(Direct Line/CAN)
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensDataMasterSetN(DID did, u_int8 chg_type, u_int8 get_method) {
-
- u_int8 chgType;
-
- chgType = chg_type;
-
- switch (did) {
- case POSHAL_DID_SPEED_KMPH:
- {
- if (ChkUnitType(UNIT_TYPE_GRADE1) == TRUE) {
- /* For creating PASCD Sentence of NMEA */
-
- int ret;
- VEHICLESENS_VEHICLE_SPEED_DAT stVehicleSpeed;
-
- ret = clock_gettime(CLOCK_MONOTONIC, &(stVehicleSpeed.ts));
- if (ret != 0) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "clock_gettime error:%m");
- } else {
- VEHICLESENS_DATA_MASTER stData;
- SENSORMOTION_SPEEDINFO_DAT* pSpdInfo;
-
- VehicleSensGetMotionSpeed(&stData, VEHICLESENS_GETMETHOD_INTERNAL); // LCOV_EXCL_BR_LINE 6:unexpected branch //NOLINT (whitespace/line_length)
- pSpdInfo = (SENSORMOTION_SPEEDINFO_DAT*)(stData.uc_data);
-
- stVehicleSpeed.speed = pSpdInfo->Speed;
-
- VehicleSens_StoreVehicleSpeed(&stVehicleSpeed); // LCOV_EXCL_BR_LINE 6:unexpected branch //NOLINT (whitespace/line_length)
- }
- }
-
- break;
- }
- case POSHAL_DID_GPS_NMEA:
- {
- VehilceSens_InitVehicleSpeed();
-
- break;
- }
- default:
- break;
- }
-
- /* Call the data delivery process */
- VehicleSensDeliveryProc( did, chgType, get_method );
-}
-
-/*******************************************************************************
-* MODULE : VehicleSensDataMasterSetSharedMemory
-* ABSTRACT : Data master set notification process(Callback function)
-* FUNCTION : Call Write Shared Memory
-* ARGUMENT : did : Data ID
-* : chg_type : Whether or not data is updated
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensDataMasterSetSharedMemory(DID did, u_int8 chg_type) { // LCOV_EXCL_START 8: dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- /* When there is no change, the shared memory write process is not called. */
- if (chg_type == VEHICLESENS_NEQ) {
- VehicleSensWriteSharedMemory(did);
- }
-}
-// LCOV_EXCL_STOP
-
-/* ++ GPS _CWORD82_ support */
-/*******************************************************************************
-* MODULE : VehicleSensSetVehicleData
-* ABSTRACT : GPS command request processing
-* FUNCTION : Transfer a GPS command request
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetVehicleData(const VEHICLE_MSG_SEND *msg) {
- u_int16 size; /* Data length setting */
- u_int16 all_len; /* Sent message length */
- u_int16 mode; /* Mode information */
- RID req_id = 0; /* Resources ID */
-
- T_APIMSG_MSGBUF_HEADER header; /* Message header */
- TG_GPS_SND_DATA data; /* Message body */
- u_int8 snd_buf[(sizeof(T_APIMSG_MSGBUF_HEADER) + sizeof(TG_GPS_SND_DATA))];
-
- /* Message header generation */
- size = sizeof(data);
- header.signo = 0; /* Signal information */
- header.hdr.sndpno = PNO_VEHICLE_SENSOR; /* Source thread number */
- header.hdr.respno = 0; /* Destination process No. */
- header.hdr.cid = CID_GPS__CWORD82__REQUEST; /* Command ID */
- header.hdr.msgbodysize = size; /* Message data length setting */
- header.hdr.rid = req_id; /* Resource ID Setting */
- header.hdr.reserve = 0; /* Reserved Area Clear */
-
- /* Message body generating */
- data.us_size = msg->data.size;
- memcpy(&(data.ub_data[0]), &(msg->data.data[0]), msg->data.size);
-
- /* Reserved Area Clear */
- data.reserve[0] = 0;
- data.reserve[1] = 0;
- data.reserve[2] = 0;
- data.reserve[3] = 0;
-
- /* Message generation */
- (void)memcpy(&snd_buf[0], &header, sizeof(header));
- (void)memcpy(&snd_buf[sizeof(header)], &data, sizeof(data));
- all_len = static_cast<u_int16>(size + sizeof(header));
- mode = 0;
-
- FRAMEWORKUNIFIEDLOG(ZONE_27, __FUNCTION__, "VehicleSensSetVehicleData NMEA = %s", data.ub_data);
- (void)_pb_SndMsg(PNO_NAVI_GPS_MAIN, all_len, reinterpret_cast<void *>(&snd_buf[0]), mode);
-}
-
-/*******************************************************************************
- * MODULE : VehicleSensDrDeliveryEntry
- * ABSTRACT : Sensor Internal Information Delivery Registration for DR
- * FUNCTION :
- * ARGUMENT : *msg : message buffer
- * NOTE :
- * RETURN : void
- ******************************************************************************/
-void VehicleSensDrDeliveryEntry(const VEHICLE_MSG_DELIVERY_ENTRY *msg) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- int32 event_val;
- EventID event_id;
-
- /* Call the process of creating the delivery destination management table */
- event_val = static_cast<int32>(DeadReckoningEntryDeliveryCtrl((const DEADRECKONING_MSG_DELIVERY_ENTRY*)msg));
- /* #QAC confirmation Rule11.4 Member reference to suppress address reference error in data R/W */
-
- /* Event Generation */
- event_id = VehicleCreateEvent(msg->data.pno);
-
- /* Publish Events */
- (void)_pb_SetEvent(event_id, SAPI_EVSET_ABSOLUTE, event_val);
-
- if (VEHICLE_RET_NORMAL == event_val) {
- /* Successful delivery registration */
- /* Deliver data for the first time */
- DeadReckoningFirstDelivery((PNO)(msg->data.pno), (DID)(msg->data.did));
- }
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
- * MODULE : VehicleSensGetLog
- * ABSTRACT : Log acquisition request
- * FUNCTION :
- * ARGUMENT : *msg : message buffer
- * NOTE :
- * RETURN : void
- ******************************************************************************/
-void VehicleSensGetLog(const VEHICLEDEBUG_MSG_BUF *msg) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- DeadReckoningGetLocationLogStatus(msg->hdr.hdr.sndpno);
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
- * MODULE : VehicleSensSetLog
- * ABSTRACT : Log Setting Request
- * FUNCTION :
- * ARGUMENT : *msg : message buffer
- * NOTE :
- * RETURN : void
- ******************************************************************************/
-void VehicleSensSetLog(const VEHICLEDEBUG_MSG_BUF* msg) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- return;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
- * MODULE : VehicleSensWriteLocalTime
- * ABSTRACT : Set LOCALTIME to non-volatile
- * FUNCTION :
- * ARGUMENT : *msg : message buffer
- * NOTE :
- * RETURN : void
- ******************************************************************************/
-void VehicleSensWriteLocalTime(const CANINPUT_MSG_INFO *msg) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- LOCALTIME localtime = {0};
- int32 time_diff;
- RET_API ret_write_api;
- static u_int8 cnt = 0U; /* For update cycle count */
- if (msg != NULL) {
- memset(&time_diff, 0x00, sizeof(time_diff)); /* Coverity CID:18813 compliant */
-
- /* Determine that the 1s cycle (cnt == 1) has elapsed for 1 second. */
- cnt++;
-
- /* When 5 seconds or more have elapsed since the last update */
- /* Saving Time Information in Non-volatile Memory */
- if (cnt >= NV_UPDATE_CYCLE_LOCALTIME) {
- /* Non-volatile write */
- ret_write_api = VehicleSensWriteNVLocaltime(&localtime, &time_diff);
- if (ret_write_api != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "NV write error.");
- }
- cnt = 0U;
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ARGUMENT NULL");
- }
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensSetEphNumSharedMemory
-* ABSTRACT : Write effective ephemeris number to shared memory
-* FUNCTION :
-* ARGUMENT : *msg : message buffer
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensSetEphNumSharedMemory(const SENSOR_MSG_GPSDATA *msg) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API ret_api;
- u_int8 ephemeris_num;
-
- if (msg != NULL) {
- ephemeris_num = msg->st_para.uc_data[0];
-
- ret_api = VehicleSensWriteDataValidEphemerisNum(ephemeris_num);
-
- if (ret_api != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Share Memory write error.");
- }
- }
-
- return;
-}
-// LCOV_EXCL_STOP
-
-/*******************************************************************************
-* MODULE : VehicleSensDrRcvMsg
-* ABSTRACT : Data delivery for DR,Write location information to shared memory
-* FUNCTION :
-* ARGUMENT : const EPHEMERIS_NUM_DATA_DAT * : Incoming message
-* NOTE :
-* RETURN : void
-******************************************************************************/
-void VehicleSensDrRcvMsg(const DEAD_RECKONING_RCVDATA * msg) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- DEAD_RECKONING_LONLAT_INFO lonlat_info;
-
- if (msg != NULL) {
- DeadReckoningRcvMsg(msg, &lonlat_info);
-
- /* Process for storing location information in non-volatile memory during shutdown */
- /* With a refresh interval of 1 second,Save only when location information is valid data */
- if (lonlat_info.calc_called == TRUE) {
- static u_int8 cnt = 0U; /* For update cycle count */
-
- /* Sensor data is 100ms cycle,Determine that (cnt == 10) has elapsed for 1 second */
- /* Cnt increments to 10 */
- if (cnt < NV_UPDATE_CYCLE_LONLAT) {
- cnt++;
- }
-
- /* When 1 second or more has elapsed since the last update and the location information is valid, */
- /* Saving Location Information in Non-Volatile Memory */
- if ((cnt >= NV_UPDATE_CYCLE_LONLAT) && (lonlat_info.available == static_cast<u_int8>(TRUE))) {
- VehicleSensStoreLonlat(&(lonlat_info.lonlat));
- cnt = 0U;
- }
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ARGUMENT NULL");
- }
-
- return;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Data setting process
- *
- * Setting Specified Data to Data Master
- *
- * @param[in] const VEHICLE_MSG_BUF *msg : message buffer
- * @param[out] PFUNC_DMASTER_SET_N p_datamaster_set_n : Data Master Set Notification(Callback function)
- * @return none
- * @retval none
- */
-void VehicleSensCommonDataDelivery(const VEHICLE_MSG_BUF *msg, PFUNC_DMASTER_SET_N p_datamaster_set_n) {
- const POS_MSGINFO *pstPosMsg = (const POS_MSGINFO *) & (msg->data[0]);
-
- /* Individual processing for each data ID */
- switch (pstPosMsg->did) {
- case VEHICLE_DID_SETTINGTIME:
- {
- /* By checking the evacuation message information,Determine whether the GPS time has already been set and requested */
- if (NULL == g_wait_for_resp_set_n) {
- /* GPS time settable */
- /* GPS time setting data transmission */
- VehicleSensGpsTimeSndMsg(pstPosMsg);
-
- /* Save message information(Used when a response is received.)*/
- (void)memcpy(&g_wait_for_resp_msg, msg, sizeof(VEHICLE_MSG_BUF));
- g_wait_for_resp_set_n = p_datamaster_set_n;
- } else {
- /* GPS time setting process is already in progress:Reply BUSY to requesting processes */
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "SetGpsTime already.");
- }
- break;
- }
- default:
- /* Set the specified data in the data master */
- VehicleSensSetDataMasterData((const POS_MSGINFO *)msg->data, p_datamaster_set_n);
- break;
- }
-
- return;
-}
-
-/**
- * @brief
- * GPS time setting data transmission process
- *
- * Send the specified data to the GPS thread
- *
- * @param[in] const POS_MSGINFO *pos_msg : message buffer
- * @return none
- * @retval none
- */
-void VehicleSensGpsTimeSndMsg(const POS_MSGINFO *pos_msg) {
- RET_API ret_api = RET_NORMAL; /* System API return value */
- u_int16 size = 0; /* Data length setting */
- u_int16 all_len = 0; /* Sent message length */
- u_int16 mode = 0; /* Mode information */
- RID req_id = 0; /* Resources ID */
- T_APIMSG_MSGBUF_HEADER header; /* Message header */
- TG_GPS_SND_DATA data; /* Message body */
- u_int8 snd_buf[(sizeof(T_APIMSG_MSGBUF_HEADER) + sizeof(TG_GPS_SND_DATA))];
-
- memset(&header, 0x00, sizeof(T_APIMSG_MSGBUF_HEADER));
- memset(&data, 0x00, sizeof(TG_GPS_SND_DATA));
-
- /* Message header generation */
- size = sizeof(data);
- header.signo = 0; /* Signal information */
- header.hdr.sndpno = PNO_VEHICLE_SENSOR; /* Source thread number */
- header.hdr.respno = 0; /* Destination process No. */
- header.hdr.cid = CID_GPS_TIMESETTING; /* Command ID */
- header.hdr.msgbodysize = size; /* Message data length setting */
- header.hdr.rid = req_id; /* Resource ID Setting */
-
- /* Message body generating */
- data.us_size = pos_msg->size;
- memcpy(&(data.ub_data[0]), &(pos_msg->data[0]), pos_msg->size);
-
- /* Messaging */
- (void)memcpy(&snd_buf[0], &header, sizeof(header));
- (void)memcpy(&snd_buf[sizeof(header)], &data, sizeof(data));
- all_len = static_cast<u_int16>(size + sizeof(header));
- mode = 0;
- ret_api = _pb_SndMsg(PNO_NAVI_GPS_MAIN, all_len, reinterpret_cast<void *>(&snd_buf[0]), mode);
- if (RET_NORMAL != ret_api) {
- /* Message transmission processing failed */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "send Message failed.");
- }
-
- return;
-}
-
-/**
- * @brief
- * GPS time setting result notification process
- *
- * Setting Specified Data to Data Master
- *
- * @param[in] const VEHICLE_MSG_BUF *msg : message buffer
- * @return none
- * @retval none
- */
-void VehicleSensGpsTimeDelivery(const VEHICLE_MSG_BUF *msg) {
- int32 event_val = POS_RET_ERROR_INNER; /* Event value */
- const TG_GPS_RET_TIMESET_MSG *gps_ret_time; /* GPS time setting response message */
-
- /* Determine the GPS time setting result */
- gps_ret_time = (const TG_GPS_RET_TIMESET_MSG *)msg;
-
- if (GPS_SENDOK == gps_ret_time->status) {
- event_val = POS_RET_NORMAL;
- } else {
- event_val = POS_RET_ERROR_TIMEOUT;
- }
-
- /* Set the specified data in the data master */
- if (POS_RET_NORMAL == event_val) {
- VehicleSensSetDataMasterData((const POS_MSGINFO *)&g_wait_for_resp_msg.data, g_wait_for_resp_set_n);
- }
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__,
- "SetGpsTime Result[%d] EventVal[%d]",
- static_cast<uint32_t>(gps_ret_time->status), static_cast<uint32_t>(event_val));
-
- /* Clear saved message information */
- (void)memset(&g_wait_for_resp_msg, 0x00, sizeof(VEHICLE_MSG_BUF));
- g_wait_for_resp_set_n = NULL;
-
- return;
-}
-
-/**
- * @brief
- * Specified process No. event transmission processing
- *
- * Send an event to the specified process No.
- *
- * @param[in] uint16_t snd_pno : Destination process number
- * @param[in] int32_t event_val : Sent event value
- * @return RET_API
- * @retval RET_NORMAL Normal completion<br>
- * RET_ERROR Event generation failure<br>
- * RET_ERRPARAM Configuration mode error<br>
- * RET_EV_NONE Specified event does not exist<br>
- * RET_EV_MAX The set event value exceeds the maximum value<br>
- * RET_EV_MIN The set event value is below the minimum value.
- */
-RET_API VehicleSensSendEvent(uint16_t snd_pno, int32_t event_val) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- RET_API ret_val = RET_ERROR; /* Return value */
- EventID event_id = 0; /* Event ID */
-
- /* Event Generation */
- event_id = VehicleCreateEvent(snd_pno);
- if (0 != event_id) {
- /* Event publishing(Release Event Wait) */
- ret_val = _pb_SetEvent(event_id, SAPI_EVSET_ABSOLUTE, event_val);
- if (RET_NORMAL != ret_val) {
- /* Event issuance failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "set Event failed.");
- }
-
- /* Event deletion */
- (void)VehicleDeleteEvent(event_id);
- } else {
- /* Event generation failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "create Event failed.");
- }
-
- return ret_val;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Pos_Main thread stop processing
- */
-void VehicleSensThreadStopProcess(void) {
- /* Exit Process Implementation Point >>> */
-
-
- /* <<< Exit Process Implementation Point */
-
- /* Thread stop processing */
- PosTeardownThread(ETID_POS_MAIN);
-
- /* don't arrive here */
- return;
-}
-
-/**
- * @brief
- * Initialization of data interruption monitoring process<br>
- * 1.Initial data reception monitoring timer issuance
- */
-static void VehicleSensInitDataDisrptMonitor(void) {
-
- /* Initial sensor data reception monitoring timer */
- VehicleUtilitySetTimer(SNS_FST_TIMER);
-
- return;
-}
-
-/**
- * @brief
- * Data disruption monitoring process<br>
- * 1.Stop timer for monitoring initial data reception<br>
- * 2.Stop timer for periodic data reception monitoring<br>
- * 3.Periodic data reception monitoring timer issuance
- *
- * @param[in] did Data type
- */
-static void VehicleSensDataDisrptMonitorProc(DID did) {
- static BOOL is_rcv_sns_data = FALSE;
-
- switch (did) {
- case POSHAL_DID_GYRO_X:
- case POSHAL_DID_GYRO_Y:
- case POSHAL_DID_GYRO_Z:
- case POSHAL_DID_GSNS_X:
- case POSHAL_DID_GSNS_Y:
- case POSHAL_DID_GSNS_Z:
- case POSHAL_DID_SPEED_PULSE:
- case POSHAL_DID_REV:
- case POSHAL_DID_GPS_ANTENNA:
- case POSHAL_DID_GYRO_EXT:
- case POSHAL_DID_GYRO_TEMP:
- case POSHAL_DID_PULSE_TIME:
- case POSHAL_DID_SNS_COUNTER:
- {
- if (is_rcv_sns_data == FALSE) {
- /* Initial sensor data reception monitoring timer */
- VehicleUtilityStopTimer(SNS_FST_TIMER);
- is_rcv_sns_data = TRUE;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "is_rcv_sns_data=TRUE");
- }
-
- /* Cyclic sensor data reception monitoring timer stopped */
- VehicleUtilityStopTimer(SNS_CYCLE_TIMER);
- /* Cyclic sensor data reception monitoring timer setting */
- VehicleUtilitySetTimer(SNS_CYCLE_TIMER);
- /* Sensor data interruption log output timer */
- VehicleUtilityStopTimer(SNS_DISRPT_TIMER);
-
- break;
- }
- default:
- {
- /* nop */
- }
- }
-
- return;
-}
-
-/**
- * @brief
- * Timeout message reception processing
- *
- * @param[in] rcv_msg Incoming message
- */
-static void VehicleSensRcvMsgTout(TimerToutMsg* rcv_msg) {
- uint8_t tim_kind = static_cast<uint8_t>(rcv_msg->TimerSeq >> 8);
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+ ### TIMEOUT ### Seq=0x%04x", rcv_msg->TimerSeq);
- switch (tim_kind) {
- case SNS_FST_TIMER:
- case SNS_CYCLE_TIMER:
- case SNS_DISRPT_TIMER:
- {
- /* Sensor data interruption log output timer setting */
- VehicleUtilityStopTimer(SNS_DISRPT_TIMER);
- VehicleUtilitySetTimer(SNS_DISRPT_TIMER);
- break;
- }
- default:
- {
- /* nop */
- }
- }
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
- return;
-}
-
-
-/**
- * @brief
- * Initialize Vehilce Speed Information
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can initialize the buffer of Vehicle Speed Information.
- */
-static void VehilceSens_InitVehicleSpeed(void) {
- (void)memset(&g_vehicle_speed_info, 0x00, sizeof(g_vehicle_speed_info));
- return;
-}
-
-/**
- * @brief
- * Store Vehilce Speed Data
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can store Vehicle Speed Information for a cycle.
- *
- * @param[in] VEHICLESENS_VEHICLE_SPEED_DAT* pVehicleSpeed : Speed [m/s] and TimeSpec
- */
-static void VehicleSens_StoreVehicleSpeed(VEHICLESENS_VEHICLE_SPEED_DAT* pVehicleSpeed) {
- VEHICLESENS_VEHICLE_SPEED_INFO* pInfo = &g_vehicle_speed_info;
-
-
-// if (pInfo->sampleCount < VEHICLESENS_NMEA_PASCD_SAMPLECOUNT_MAX) {
- if (pInfo->sampleCount == 0) {
- (void)memcpy((pInfo->listSpd) + (pInfo->sampleCount), pVehicleSpeed, sizeof(VEHICLESENS_VEHICLE_SPEED_DAT));
- pInfo->sampleCount++;
-
- } else if (pInfo->sampleCount < VEHICLESENS_NMEA_PASCD_SAMPLECOUNT_MAX) {
- (void)_pb_memcpy((pInfo->listSpd) + (pInfo->sampleCount), pVehicleSpeed, sizeof(VEHICLESENS_VEHICLE_SPEED_DAT));
-
- VEHICLESENS_VEHICLE_SPEED_DAT* pS0 = &(pInfo->listSpd[0]);
- VEHICLESENS_VEHICLE_SPEED_DAT* pS = &(pInfo->listSpd[pInfo->sampleCount]);
- uint32_t ts_i; /* Interger Part of timestamp [s] */
- if (pS->ts.tv_nsec - pS0->ts.tv_nsec >= 0) { // LCOV_EXCL_BR_LINE 200: can not less than zero
- ts_i = (pS->ts.tv_sec - pS0->ts.tv_sec) % VEHICLESENS_NMEA_PASCD_TS_MAX;
- } else {
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- ts_i = (pS->ts.tv_sec - pS0->ts.tv_sec - 1) % VEHICLESENS_NMEA_PASCD_TS_MAX; // LCOV_EXCL_LINE 8: invalid
- }
- if (ts_i == 0) { /* Offset is 0 to 1 second */
- pInfo->sampleCount++;
- }
-
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "WARNING: Num of stored datas is over 50. (%ld.%ld spd = %d)",
- pVehicleSpeed->ts.tv_sec, pVehicleSpeed->ts.tv_nsec, pVehicleSpeed->speed );
- }
-
- return;
-}
-
-/**
- * @brief
- * Load Vehicle Speed Information (Vehicle Speed Data x 50(max))
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can load Vehicle Speed Informations from the last initialization.
- *
- * @param[in] VEHICLESENS_VEHICLE_SPEED_INFO* pVehicleSpeedInfo : Speeds [m/s] and TimeSpecs
- */
-static void VehicleSens_LoadVehicleSpeed(VEHICLESENS_VEHICLE_SPEED_INFO* pVehicleSpeedInfo) {
- (void)memcpy(pVehicleSpeedInfo, &g_vehicle_speed_info, sizeof(g_vehicle_speed_info));
- return;
-}
-
-/**
- * @brief
- * Concatenate NMEA Sentence Fields with Delimiter
- *
- * @details This is for creating NMEA Sentence. <br>
- * You can concatenate the two strings given as arguments 'str1' and 'str2'. <br>
- * And at the time, it puts the delimiter between 'str1' and 'str2' automaticaly.
- *
- * @param[in] char* str1 : destination
- * @param[in] const size_t size : buffer size of destination
- * @param[in] const char* str2 : source
- * @param[in] const size_t n : copy size of source
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static RET_API VehicleSens_CatNmeaSentenceFieldWithDelimiter(char* str1, const size_t size,
- const char* str2, const size_t n) {
- RET_API ret_api = RET_NORMAL;
-
- size_t len1 = strlen(str1);
- size_t len2 = strlen(str2);
- size_t len3 = strlen(VEHICLESENS_NMEA_FIELDDELIMITER);
- size_t sn = n;
-
- if (sn > len2) { // LCOV_EXCL_BR_LINE 200: can not exceed size
- sn = len2;
- }
-
- if (len1 + len3 + sn <= size - 1) {
- (void)strncat(str1, VEHICLESENS_NMEA_FIELDDELIMITER, len3); /* Add Delimiter (,) */
- (void)strncat(str1, str2, sn);
- } else {
- ret_api = RET_ERROR;
-
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: Buffer size is too small to connatenate. len1:%d len2:%d len3:%d n:%d", len1, len2, len3, n);
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Concatenate NMEA Sentence Fields without Delimiter
- *
- * @details This is for creating NMEA Sentence. <br>
- * You can concatenate the two strings given as arguments 'str1' and 'str2'.
- *
- * @param[in] char* str1 : destination
- * @param[in] const size_t size : buffer size of destination
- * @param[in] const char* str2 : source
- * @param[in] const size_t n : copy size of source
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static RET_API VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(char* str1, const size_t size,
- const char* str2, const size_t n) {
- RET_API ret_api = RET_NORMAL;
-
- size_t len1 = strlen(str1);
- size_t len2 = strlen(str2);
- size_t sn = n;
-
- if (sn > len2) { // LCOV_EXCL_BR_LINE 200: can not exceed size
- sn = len2;
- }
-
- if (len1 + sn <= size - 1) {
- (void)strncat(str1, str2, sn);
- } else {
- ret_api = RET_ERROR;
-
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: Buffer size is too small to connatenate. len1:%d len2:%d n:%d", len1, len2, n);
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Generate ID Field of PASCD Sentence
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can generate ID Field of PASCD Sentence and <br>
- * concatenate it with the string given as argument 'pascd'. <br>
- * It should be called in the specific order.
- *
- * @param[in/out] char* pascd : buffer pointer for PASCD Sentence
- * @param[in] size_t size : buffer size
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static inline RET_API VehicleSens_GeneratePASCDFieldId(char* pascd, size_t size) {
- RET_API ret_api;
-
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size, VEHICLESENS_NMEA_PASCD_ID, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithoutDelimiter:%d", ret_api);
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Generate Timestamp Field of PASCD Sentence
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can generate Timestamp Field of PASCD Sentence and <br>
- * concatenate it with the string given as argument 'pascd'. <br>
- * It should be called in the specific order.
- *
- * @param[in/out] char* pascd : buffer pointer for PASCD Sentence
- * @param[in] size_t size : buffer size
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static inline RET_API VehicleSens_GeneratePASCDFieldTimestamp(char* pascd, size_t size) {
- RET_API ret_api;
-
- VEHICLESENS_VEHICLE_SPEED_INFO stVehicleSpeedInfo;
-
- uint32_t ts_i; /* Interger Part of timestamp [s] */
- uint32_t ts_f; /* Fractional Part of timestamp [ms] */
- char ts_ci[32]; /* ts_i in charactor */
- char ts_cf[32]; /* ts_f in charactor */
-
- VehicleSens_LoadVehicleSpeed(&stVehicleSpeedInfo);
-
-
-#if 1 /* PASCD *//* Suppose that GPS NMEA data are updated 1 sec interval */
- ts_i = gPseudoSecClockCounter; /* Synchronize: GPS NMEA */
- ts_f = 0u;
- gPseudoSecClockCounter += 1u; /* PASCD *//* Suppose that GPS NMEA data are updated 1 sec interval */
- if (gPseudoSecClockCounter >= VEHICLESENS_NMEA_PASCD_TS_MAX) {
- gPseudoSecClockCounter = 0u;
- }
-#else /* PASCD *//* Suppose that GPS NMEA data are updated 1 sec interval */
-
- ts_i = stVehicleSpeedInfo.listSpd[0].ts.tv_sec % VEHICLESENS_NMEA_PASCD_TS_MAX;
- ts_f = stVehicleSpeedInfo.listSpd[0].ts.tv_nsec;
-
-#endif /* PASCD *//* Suppose that GPS NMEA data are updated 1 sec interval */
-
- (void)snprintf(ts_ci, sizeof(ts_ci), "%d", ts_i);
- (void)snprintf(ts_cf, sizeof(ts_cf), "%06d", ts_f);
-
- /* Integer Part */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithDelimiter(pascd, size, ts_ci, VEHICLESENS_NMEA_PASCD_TS_INT_LEN_MAX);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithoutDelimiter:%d", ret_api);
- }
-
- /* Decimal Point */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size, VEHICLESENS_NMEA_DECIMALPOINT, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithoutDelimiter:%d", ret_api);
- }
-
- /* Fractional Part */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size,
- ts_cf, VEHICLESENS_NMEA_PASCD_TS_FRA_LEN_MAX);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithDelimiter:%d", ret_api);
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Generate SensorType Field of PASCD Sentence
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can generate SensorType Field of PASCD Sentence and <br>
- * concatenate it with the string given as argument 'pascd'. <br>
- * It should be called in the specific order.
- *
- * @param[in/out] char* pascd : buffer pointer for PASCD Sentence
- * @param[in] size_t size : buffer size
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static inline RET_API VehicleSens_GeneratePASCDFieldSensorType(char* pascd, size_t size) {
- RET_API ret_api;
-
- ret_api = VehicleSens_CatNmeaSentenceFieldWithDelimiter(pascd, size, VEHICLESENS_NMEA_PASCD_SENSORTYPE_C, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithDelimiter:%d", ret_api);
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Generate TransmissionState Field of PASCD Sentence
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can generate TransmissionState Field of PASCD Sentence and <br>
- * concatenate it with the string given as argument 'pascd'. <br>
- * It should be called in the specific order.
- *
- * @param[in/out] char* pascd : buffer pointer for PASCD Sentence
- * @param[in] size_t size : buffer size
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static inline RET_API VehicleSens_GeneratePASCDFieldTransmissionState(char* pascd, size_t size) {
- RET_API ret_api = RET_NORMAL;
- EFrameworkunifiedStatus eStatus;
-
- uint8_t ucType; /* type of transmission */
- uint8_t ucShift;
-
-#if 1 /* For Plus _CWORD27_ Gear Data Support 180115 */
- uint8_t ucPkb; /* state of parking brake */
-#endif /* For Plus _CWORD27_ Gear Data Support 180115 */
-
- BOOL bIsAvailable;
-
- /* Get Type of Transmission */
-
-// eStatus = VehicleIf_GetTypeOfTransmission(&ucType, &bIsAvailable);
- eStatus = VehicleIf_GetTypeOfTransmission(&ucType, &ucPkb, &bIsAvailable);
- if ((bIsAvailable != true) || (eStatus != eFrameworkunifiedStatusOK)) {
- if (bIsAvailable == TRUE) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleIf_GetTypeOfTransmission:%d", eStatus);
- }
- ret_api = RET_ERROR;
- }
-
- if (ret_api != RET_ERROR) {
- /* Get Shift Position */
- eStatus = VehicleIf_GetShiftPosition(&ucShift, &bIsAvailable);
- if ((bIsAvailable != true) || (eStatus != eFrameworkunifiedStatusOK)) {
- if (bIsAvailable == TRUE) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleIf_GetShiftPosition:%d", eStatus);
- }
- ret_api = RET_ERROR;
- }
- }
-
- if (ret_api != RET_ERROR) {
- VEHICLESENS_TRANSMISSION_PKG tsmPkg;
-
- tsmPkg.type = ucType;
- tsmPkg.shift = ucShift;
-
-#if 1 /* For Plus _CWORD27_ Gear Data Support 180115 */
- tsmPkg.pkb = ucPkb;
-#endif /* For Plus _CWORD27_ Gear Data Support 180115 */
-
-
- ret_api = VehicleSens_DeriveTransmissionStateFor_CWORD27_(&tsmPkg);
- if (ret_api != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSensDeriveTransmissionStateFor_CWORD27_:%d", ret_api);
- } else {
- ret_api = VehicleSens_CatNmeaSentenceFieldWithDelimiter(pascd, size, tsmPkg.state, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithDelimiter:%d", ret_api);
- }
- }
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Generate SlipDetect Field of PASCD Sentence
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can generate SlipDetect Field of PASCD Sentence and <br>
- * concatenate it with the string given as argument 'pascd'. <br>
- * It should be called in the specific order.
- *
- * @param[in/out] char* pascd : buffer pointer for PASCD Sentence
- * @param[in] size_t size : buffer size
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static inline RET_API VehicleSens_GeneratePASCDFieldSlipDetect(char* pascd, size_t size) {
- RET_API ret_api;
-
- ret_api = VehicleSens_CatNmeaSentenceFieldWithDelimiter(pascd, size, VEHICLESNES_NMEA_PASCD_NOSLIP, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithDelimiter:%d", ret_api);
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Generate SampleCount Field of PASCD Sentence
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can generate SampleCount Field of PASCD Sentence and <br>
- * concatenate it with the string given as argument 'pascd'. <br>
- * It should be called in the specific order.
- *
- * @param[in/out] char* pascd : buffer pointer for PASCD Sentence
- * @param[in] size_t size : buffer size
- */
-static inline RET_API VehicleSens_GeneratePASCDFieldSampleCount(char* pascd, size_t size) {
- RET_API ret_api;
-
- VEHICLESENS_VEHICLE_SPEED_INFO stVehicleSpeedInfo;
- char cSampleCount[32];
-
- VehicleSens_LoadVehicleSpeed(&stVehicleSpeedInfo);
- (void)snprintf(cSampleCount, sizeof(cSampleCount), "%d", stVehicleSpeedInfo.sampleCount);
-
- ret_api = VehicleSens_CatNmeaSentenceFieldWithDelimiter(pascd, size, cSampleCount, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithDelimiter:%d", ret_api);
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Generate TimeOffset and Speed Field of PASCD Sentence
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can generate TimeOffset and Speed Field of PASCD Sentence and <br>
- * concatenate it with the string given as argument 'pascd'. <br>
- * It should be called in the specific order.
- *
- * @param[in/out] char* pascd : buffer pointer for PASCD Sentence
- * @param[in] size_t size : buffer size
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static inline RET_API VehicleSens_GeneratePASCDFieldTimeOffsetNSpeed(char* pascd, size_t size) {
- RET_API ret_api = RET_ERROR;
-
- VEHICLESENS_VEHICLE_SPEED_INFO stVehicleSpeedInfo;
- VEHICLESENS_VEHICLE_SPEED_DAT *pS0 = &(stVehicleSpeedInfo.listSpd[0]);
-
- int32_t i;
-
- VehicleSens_LoadVehicleSpeed(&stVehicleSpeedInfo);
-
- for (i = 0; i < stVehicleSpeedInfo.sampleCount; i++) {
- VEHICLESENS_VEHICLE_SPEED_DAT *pS = &(stVehicleSpeedInfo.listSpd[i]);
-
- /* timeoffset */
- uint32_t ts_i; /* Interger Part of timestamp [s] */
- uint32_t ts_f; /* Fractional Part of timestamp [us] */
- char ts_ci[32]; /* ts_i in charactor */
- char ts_cf[32]; /* ts_f in charactor */
-
- if (pS->ts.tv_nsec - pS0->ts.tv_nsec >= 0) { // LCOV_EXCL_BR_LINE 200: can not less than zero
- ts_i = (pS->ts.tv_sec - pS0->ts.tv_sec) % VEHICLESENS_NMEA_PASCD_TS_MAX;
- ts_f = (pS->ts.tv_nsec - pS0->ts.tv_nsec) / 1000; /* [ns] -> [us] */
- } else {
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- ts_i = (pS->ts.tv_sec - pS0->ts.tv_sec - 1) % VEHICLESENS_NMEA_PASCD_TS_MAX;
- ts_f = (1000000000 + pS->ts.tv_nsec - pS0->ts.tv_nsec) / 1000; /* [ns] -> [us] */
- // LCOV_EXCL_STOP
- }
-
- (void)snprintf(ts_ci, sizeof(ts_ci), "%d", ts_i);
- (void)snprintf(ts_cf, sizeof(ts_cf), "%06d", ts_f);
-
- /* Integer Part */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithDelimiter(pascd, size, ts_ci, size);
- if (ret_api == RET_ERROR) { // LCOV_EXCL_BR_LINE 200: can not exceed buffer size
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithDelimiter:%d", ret_api);
- break;
- // LCOV_EXCL_STOP
- }
-
- /* Decimal Point */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size, VEHICLESENS_NMEA_DECIMALPOINT, size);
- if (ret_api == RET_ERROR) { // LCOV_EXCL_BR_LINE 200: can not exceed buffer size
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithoutDelimiter:%d", ret_api);
- break;
- // LCOV_EXCL_STOP
- }
-
- /* Fractional Part */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size,
- ts_cf, VEHICLESENS_NMEA_PASCD_TO_FRA_LEN_MAX);
- if (ret_api == RET_ERROR) { // LCOV_EXCL_BR_LINE 200: can not exceed buffer size
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithoutDelimiter:%d", ret_api);
- break;
- // LCOV_EXCL_STOP
- }
-
- /* speed */
- uint16_t spd_i; /* Interger Part of speed [m/s] */
- uint16_t spd_f; /* Fractional Part of speed [mm/s] */
- char spd_ci[32]; /* spd_i in charactor */
- char spd_cf[32]; /* spd_f in charactor */
-
- spd_i = pS->speed / 100; /* [0.01m/s] -> [m/s] */
- spd_f = (pS->speed % 100) * 10; /* [0.01m/s] -> [mm/s] */
-
- (void)snprintf(spd_ci, sizeof(spd_ci), "%d", spd_i);
- (void)snprintf(spd_cf, sizeof(spd_cf), "%03d", spd_f);
-
- /* Integer Part */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithDelimiter(pascd, size, spd_ci, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithDelimiter:%d", ret_api);
- break;
- }
-
- /* Decimal Point */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size, VEHICLESENS_NMEA_DECIMALPOINT, size);
- if (ret_api == RET_ERROR) { // LCOV_EXCL_BR_LINE 200: can not exceed buffer size
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithoutDelimiter:%d", ret_api);
- break;
- // LCOV_EXCL_STOP
- }
-
- /* Fractional Part */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size,
- spd_cf, VEHICLESENS_NMEA_PASCD_SPD_FRA_LEN_MAX);
- if (ret_api == RET_ERROR) { // LCOV_EXCL_BR_LINE 200: can not exceed buffer size
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithoutDelimiter:%d", ret_api);
- break;
- // LCOV_EXCL_STOP
- }
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Generate Checksum Field of PASCD Sentence
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can generate Checksum Field of PASCD Sentence and <br>
- * concatenate it with the string given as argument 'pascd'. <br>
- * It should be called in the specific order.
- *
- * @param[in/out] char* pascd : buffer pointer for PASCD Sentence
- * @param[in] size_t size : buffer size
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static inline RET_API VehicleSens_GeneratePASCDFieldChecksum(char* pascd, size_t size) {
- RET_API ret_api;
-
- size_t length;
- uint8_t chk = 0;
- char cChk[3];
- uint16_t i = 0;
-
- length = strnlen(pascd, size);
-
- /* Calculate Checksum (start with the 2th Bype except '$') */
- for (i = 1; i < length; i++) {
- chk ^= pascd[i];
- }
- (void)snprintf(cChk, sizeof(cChk), "%02X", chk);
-
- /* Set Astarisk before Checksum */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size, VEHICLESENS_NMEA_ASTARISK, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithoutDelimiter:%d", ret_api);
- }
-
- /* Set Checksum */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size, cChk, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithDelimiter:%d", ret_api);
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Generate CR & LF Field of PASCD Sentence
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can generate CRLF Field of PASCD Sentence and <br>
- * concatenate it with the string given as argument 'pascd'. <br>
- * It should be called in the specific order.
- *
- * @param[in/out] char* pascd : buffer pointer for PASCD Sentence
- * @param[in] size_t size : buffer size
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static inline RET_API VehicleSens_GeneratePASCDFieldCRLF(char* pascd, size_t size) {
- RET_API ret_api;
-
- /* Set Carriage Return */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size, VEHICLESENS_NMEA_CR, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithDelimiter:%d", ret_api);
- }
-
- /* Set Line Feed */
- ret_api = VehicleSens_CatNmeaSentenceFieldWithoutDelimiter(pascd, size, VEHICLESENS_NMEA_LF, size);
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: VehicleSens_CatNmeaSentenceFieldWithDelimiter:%d", ret_api);
- }
-
- return ret_api;
-}
-
-/**
- * @brief
- * Derive Transmission State For _CWORD27_
- *
- * @details This is for creating PASCD Sentence of NMEA. <br>
- * You can derive transmissionState from the transmission type and <br>
- * the shift positiong from Vehicle Service.
- *
- * @param[in/out] VEHICLESENS_TRANSMISSION_PKG* pPkg : source data set for Transmission State
- *
- * @return RET_NORMAL : success
- * @return RET_ERROR : failed
- */
-static RET_API VehicleSens_DeriveTransmissionStateFor_CWORD27_(VEHICLESENS_TRANSMISSION_PKG* pPkg) {
- RET_API ret_api = RET_NORMAL;
- uint32_t i;
-
- static const VEHICLESENS_TRANSMISSION_PKG TmsLut[VEHICLEIF_TRANSMISSION_TYPE_NUM * VEHICLEIF_SHIFT_POSITION_NUM] = {
-
-// /* Transmission Type : MT */
-// { VEHICLEIF_TRANSMISSION_TYPE_MT, VEHICLEIF_SHIFT_POSITION_U, VEHICLESENS_NMEA_PASCD_TMS_D },
-// { VEHICLEIF_TRANSMISSION_TYPE_MT, VEHICLEIF_SHIFT_POSITION_R, VEHICLESENS_NMEA_PASCD_TMS_R },
-// { VEHICLEIF_TRANSMISSION_TYPE_MT, VEHICLEIF_SHIFT_POSITION_P, VEHICLESENS_NMEA_PASCD_TMS_D },
-// { VEHICLEIF_TRANSMISSION_TYPE_MT, VEHICLEIF_SHIFT_POSITION_N, VEHICLESENS_NMEA_PASCD_TMS_D },
-// { VEHICLEIF_TRANSMISSION_TYPE_MT, VEHICLEIF_SHIFT_POSITION_D, VEHICLESENS_NMEA_PASCD_TMS_D },
-// /* Tranmission Type : AT */
-// { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_U, VEHICLESENS_NMEA_PASCD_TMS_U },
-// { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_R, VEHICLESENS_NMEA_PASCD_TMS_R },
-// { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_P, VEHICLESENS_NMEA_PASCD_TMS_P },
-// { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_N, VEHICLESENS_NMEA_PASCD_TMS_U },
-// { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_D, VEHICLESENS_NMEA_PASCD_TMS_D },
-// /* Transmission Type : UNKNOWN */
-// { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_U, VEHICLESENS_NMEA_PASCD_TMS_U },
-// { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_R, VEHICLESENS_NMEA_PASCD_TMS_U },
-// { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_P, VEHICLESENS_NMEA_PASCD_TMS_U },
-// { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_N, VEHICLESENS_NMEA_PASCD_TMS_U },
-// { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_D, VEHICLESENS_NMEA_PASCD_TMS_U },
- /* Transmission Type : MT */
- { VEHICLEIF_TRANSMISSION_TYPE_MT, VEHICLEIF_SHIFT_POSITION_U, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
- { VEHICLEIF_TRANSMISSION_TYPE_MT, VEHICLEIF_SHIFT_POSITION_R, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_R },
- { VEHICLEIF_TRANSMISSION_TYPE_MT, VEHICLEIF_SHIFT_POSITION_P, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
- { VEHICLEIF_TRANSMISSION_TYPE_MT, VEHICLEIF_SHIFT_POSITION_N, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
- { VEHICLEIF_TRANSMISSION_TYPE_MT, VEHICLEIF_SHIFT_POSITION_D, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
- /* Tranmission Type : AT */
-#if 1 /* For Plus _CWORD27_ Gear Data Support 180115 */
- { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_U, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_U },
-#else /* For Plus _CWORD27_ Gear Data Support 180115 */
- { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_U, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
-#endif /* For Plus _CWORD27_ Gear Data Support 180115 */
- { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_R, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_R },
- { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_P, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_P },
- { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_N, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_N }, /* However, the Vehicle does not notify you by Phase3. */
- { VEHICLEIF_TRANSMISSION_TYPE_AT, VEHICLEIF_SHIFT_POSITION_D, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
- /* Transmission Type : UNKNOWN */
-#if 1 /* For Plus _CWORD27_ Gear Data Support 180115 */
- { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_U, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_U },
- { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_R, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_U },
- { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_P, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_U },
- { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_N, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_U },
- { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_D, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_U },
-#else /* For Plus _CWORD27_ Gear Data Support 180115 */
- { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_U, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
- { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_R, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
- { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_P, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
- { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_N, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
- { VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN, VEHICLEIF_SHIFT_POSITION_D, VEHICLEIF_PKB_UNKNOWN, VEHICLESENS_NMEA_PASCD_TMS_D },
-#endif /* For Plus _CWORD27_ Gear Data Support 180115 */
-
- };
-
- for (i = 0; i < VEHICLEIF_TRANSMISSION_TYPE_NUM * VEHICLEIF_SHIFT_POSITION_NUM; i++) {
- if ((pPkg->type == TmsLut[i].type) && (pPkg->shift == TmsLut[i].shift)) {
- strncpy(pPkg->state, TmsLut[i].state, sizeof(pPkg->state));
- break;
- }
- }
-
-
-#if 1 /* For Plus _CWORD27_ Gear Data Support 180115 */
- if ((pPkg->type == VEHICLEIF_TRANSMISSION_TYPE_MT) && (pPkg->pkb == VEHICLEIF_PKB_ON)) {
- strncpy(pPkg->state, VEHICLESENS_NMEA_PASCD_TMS_P, sizeof(VEHICLESENS_NMEA_PASCD_TMS_P));
- }
-#endif /* For Plus _CWORD27_ Gear Data Support 180115 */
-
-
- if (i == VEHICLEIF_TRANSMISSION_TYPE_NUM * VEHICLEIF_SHIFT_POSITION_NUM) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FORBIDDEN ERROR: Can't find Transmission State. type:%d shift:%d", pPkg->type, pPkg->shift);
- ret_api = RET_ERROR;
- }
-
- return ret_api;
-}
diff --git a/vehicleservice/positioning/server/src/Sensor/VehicleUtility.cpp b/vehicleservice/positioning/server/src/Sensor/VehicleUtility.cpp
deleted file mode 100755
index 0201326..0000000
--- a/vehicleservice/positioning/server/src/Sensor/VehicleUtility.cpp
+++ /dev/null
@@ -1,455 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/***************************************************************************
-@file VehicleUtility.cpp
-@detail Common processing function of Vehicle
-*****************************************************************************/
-
-#include "VehicleUtility.h"
-#include <vehicle_service/positioning_base_library.h>
-
-#include "gps_hal.h"
-#include "positioning_common.h"
-
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-/** Timer management table */
-static VEHICLEUTILITY_TIM_MNG g_st_tim_mng;
-
-/** Timer setting information table */
-static const VEHICLEUTILITY_TIM_INFO g_tim_info[TIM_NUM] = {
- /* GSP-related */
- {TIMVAL_GPS_STARTUP, PNO_NAVI_GPS_MAIN}, /* Start confirmation monitoring timer */
- {TIMVAL_GPS_RCVCYCLDAT, PNO_NAVI_GPS_MAIN}, /* Periodic reception data monitoring timer */
- {TIMVAL_GPS_RCVACK, PNO_NAVI_GPS_MAIN}, /* ACK reception monitoring timer */
- {TIMVAL_GPS_NAVIFST, PNO_NAVI_GPS_MAIN}, /* Initial Navigation Monitoring Timer */
- {TIMVAL_GPS_NAVICYCLE, PNO_NAVI_GPS_MAIN}, /* Navi monitoring timer */
- {TIMVAL_GPS_NAVIDISRPT, PNO_NAVI_GPS_MAIN}, /* Navigation Monitoring Disruption Log Output Timer */
- {TIMVAL_GPS_DIAGCLKGUARD, PNO_NAVI_GPS_MAIN}, /* Diag provision time guard monitoring timer */
- {TIMVAL_GPS_NMEADATAGUARD, PNO_NAVI_GPS_MAIN}, /* NMEA data-providing guard monitoring timer */
- {TIMVAL_GPS_RECOVERY, PNO_NAVI_GPS_MAIN}, /* GPS recovery timer */
- {TIMVAL_GPS_RECEIVERERR, PNO_NAVI_GPS_MAIN}, /* GPS receiver anomaly detection timer */
- /* Sensor Related Extensions */
- {TIMVAL_SNS_RCVFSTDAT, PNO_VEHICLE_SENSOR}, /* Initial cyclic sensor data reception monitoring timer */
- {TIMVAL_SNS_RCVCYCLDAT, PNO_VEHICLE_SENSOR}, /* Cyclic sensor data reception monitoring timer */
- {TIMVAL_SNS_RCVDISRPT, PNO_VEHICLE_SENSOR}, /* Cyclic sensor data interruption log output timer */
-};
-
-/*---------------------------------------------------------------------------------*
- * Prototype *
- *---------------------------------------------------------------------------------*/
-static uint16_t VehicleUtilityTimeMakSeqNo(VEHICLEUTILITY_TIM_KIND tim_kind);
-
-/***************************************************************************
-@brief send message function for Vehicle domain.
-@outline send message function with put error diag function if error occurred.
-@type Completion return type
-@param[in] PNO pno : PNO
-@param[in] u_int16 size : size of message data
-@param[in] void* msgbuf : message data
-@param[in] u_int16 mode : mode
-@threshold
-@return RET_API
-@retval RET_NORMAL : Normal end
-@retval RET_ERROR : Abnormal end
-*****************************************************************************/
-RET_API VehicleUtilitySndMsg(PNO pno, u_int16 size, void *msgbuf, u_int16 mode) {
- RET_API ret_api;
- if (msgbuf != NULL) { // LCOV_EXCL_BR_LINE 6: msgbuf cannot be null
- ret_api = _pb_SndMsg(pno, size, msgbuf, mode);
- /* RET_ERROR: Execute _pb_Exit() after dialog registration */
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SndMsg ERROR [ret_api:%d]", ret_api);
- }
- } else {
- ret_api = RET_ERRPARAM;
- }
-
- return ret_api;
-}
-
-/***************************************************************************
-@brief send message function for Vehicle domain.
-@outline receive message function with put error diag function if error occurred.
-@type Completion return type
-@param[in] PNO pno : PNO
-@param[in] u_int16 size : size of message data
-@param[in] void* msgbuf : message data
-@param[in] u_int16 mode : mode
-@threshold
-@return RET_API
-@retval RET_NORMAL : Normal end
-@retval RET_ERROR : Abnormal end
-*****************************************************************************/
-RET_API VehicleUtilityRcvMsg(PNO pno, u_int16 size, void **msgbuf, u_int16 mode)
-{
- RET_API ret_api;
-
- if (msgbuf != NULL) { // LCOV_EXCL_BR_LINE 6: msgbuf cannot be null
- ret_api = _pb_RcvMsg(pno, size, msgbuf, mode);
- /* For RET_ERROR Sys_Exit() after dialog registration */
- if (ret_api == RET_ERROR) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_RcvMsg ERROR [ret_api:%d]", ret_api);
- }
- } else {
- ret_api = RET_ERRPARAM;
- }
-
- return ret_api;
-}
-
-/***************************************************************************
-@brief Diagcode submit for Vehicle domain.
-@outline submit the DiagCode for Vehicle domain.
-@type Completion return type
-@param[in] u_int32 err_id : Diag Code
-@param[in] u_int16 positioning_code : Positioning Code
-@param[in] void* msgbuf : message data
-@return void
-*****************************************************************************/
-void VehicleUtilityDiagCodePut(u_int32 err_id, u_int16 positioning_code) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Timer function initialization processing
- *
- */
-void VehicleUtilityInitTimer(void) {
- VEHICLEUTILITY_TIM_MNG *pst_tim_mng;
- u_int32 i;
-
- pst_tim_mng = &g_st_tim_mng;
-
- /* Initialize timer management table */
- memset(pst_tim_mng, 0x00, sizeof(VEHICLEUTILITY_TIM_MNG));
-
- for (i = 0; i < TIM_NUM; i++) {
- pst_tim_mng->sts[i].flag = TIMER_OFF;
- pst_tim_mng->sts[i].cnt = 0;
- }
-}
-
-/**
- * @brief
- * Timer start processing<br>
- *
- * Starts a timer of the specified type<br>
- * 1.Increment total number of timer start<br>
- * 2.Timer Sequence Number Creation<br>
- * 3.Get timeout value<br>
- * 4.Timer start<br>
- *
- * @param[in] Tim_kind Timer type
- *
- * @return TRUE Normal completion<br>
- * FALSE abend<br>
- */
-BOOL VehicleUtilitySetTimer(VEHICLEUTILITY_TIM_KIND tim_kind) {
- VEHICLEUTILITY_TIM_MNG *pst_tim_mng;
- const uint32_t *p_time_val;
- const PNO *p_pno;
- RET_API api_ret; /* Timer API return value */
- u_int16 seq_no;
- BOOL ret = TRUE;
-
- pst_tim_mng = &g_st_tim_mng;
-
- p_time_val = &(g_tim_info[tim_kind].timer_val); /* Timer set value */
- p_pno = &(g_tim_info[tim_kind].pno); /* Notify party PNO */
-
- if (pst_tim_mng->sts[tim_kind].flag == TIMER_ON) {
- /*-----------------------------------------------------------------------*/
- /* When the same timer has already started */
- /* Terminate without starting the timer because the timer is set multiple times. */
- /*-----------------------------------------------------------------------*/
- ret = FALSE;
- } else {
- /*-----------------------------------------------------------------------*/
- /* Count up the timer counter of the corresponding timer by 1. */
- /*-----------------------------------------------------------------------*/
- if (pst_tim_mng->sts[tim_kind].cnt >= TIM_CNTMAX) {
- /*-----------------------------------------------------------------------*/
- /* When the count reaches the maximum number,Count again from 1 */
- /*-----------------------------------------------------------------------*/
- pst_tim_mng->sts[tim_kind].cnt = TIM_CNTMIN;
- } else {
- /*-----------------------------------------------------------------------*/
- /* If the count has not reached the maximum,Count up */
- /*-----------------------------------------------------------------------*/
- pst_tim_mng->sts[tim_kind].cnt++;
- }
-
- /*-----------------------------------------------------------------------*/
- /* Creating Timer Sequence Numbers */
- /*-----------------------------------------------------------------------*/
- seq_no = VehicleUtilityTimeMakSeqNo(tim_kind);
-
- /*-----------------------------------------------------------------------*/
- /* Start the timer */
- /*-----------------------------------------------------------------------*/
- api_ret = _pb_ReqTimerStart(*p_pno, seq_no, TIMER_TYPE_USN, (u_int32)*p_time_val);
- if (api_ret != RET_NORMAL) {
- ret = FALSE;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, \
- "_pb_ReqTimerStart ERROR!! [api_ret=%d]", api_ret);
- } else {
- /*-----------------------------------------------------------------------*/
- /* Successful timer start */
- /* Set the start/stop flag of the corresponding timer to start (MCSUB_ON) */
- /*-----------------------------------------------------------------------*/
- pst_tim_mng->sts[tim_kind].flag = TIMER_ON;
- }
- }
-
- return ret;
-}
-
-/**
- * @brief
- * Timer stop processing<br>
- *
- * Stops a timer of the specified type<br>
- * 1.Get the sequence number of the specified type<br>
- * 2.Timer stop<br>
- *
- * @param[in] Tim_kind Timer type
- * @param[in] pno Process number
- *
- * @return TRUE Normal completion<br>
- * FALSE abend<br>
- */
-BOOL VehicleUtilityStopTimer(VEHICLEUTILITY_TIM_KIND tim_kind) {
- VEHICLEUTILITY_TIM_MNG *pst_tim_mng;
- const PNO *p_pno;
- BOOL ret = TRUE;
- RET_API api_ret;
- u_int16 seq_no;
-
- pst_tim_mng = &g_st_tim_mng;
-
- p_pno = &(g_tim_info[tim_kind].pno); /* Notify party PNO */
-
- /* Check timer start/stop flag */
- if (pst_tim_mng->sts[tim_kind].flag == TIMER_OFF) {
- /* If it is already stopped, do nothing. */
- ret = FALSE;
- } else {
- /*-----------------------------------------------------------------------*/
- /* Creating Timer Sequence Numbers */
- /*-----------------------------------------------------------------------*/
- seq_no = VehicleUtilityTimeMakSeqNo(tim_kind);
-
- /*-----------------------------------------------------------------------*/
- /* Set the corresponding timer to stop */
- /*-----------------------------------------------------------------------*/
- api_ret = _pb_TimerStop(*p_pno, seq_no, TIMER_TYPE_USN);
- if (api_ret != RET_NORMAL) {
- ret = FALSE;
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_TimerStop ERROR!! [api_ret=%d]", api_ret);
- }
-
- /*-----------------------------------------------------------------------*/
- /* Set the start/stop flag of the corresponding timer to stop (MCSUB_OFF) */
- /* Set the ID of the corresponding timer to invalid (DEV_TED_INVALID) */
- /*-----------------------------------------------------------------------*/
- pst_tim_mng->sts[tim_kind].flag = TIMER_OFF;
- }
- return ret;
-}
-
-/**
- * @brief
- * Timer Sequence Number Determination<br>
- *
- * Determine whether the timer sequence number corresponds to the one being managed
- *
- * @param[in] seqno Timer Sequence Number
- *
- * @return TRUE Normal completion(No problem)<br>
- * FALSE abend(Unusual number)<br>
- */
-BOOL VehicleUtilityTimeJdgKnd(uint16_t seqno) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- VEHICLEUTILITY_TIM_MNG *pst_tim_mng;
- BOOL ret;
- u_int8 timekind;
- u_int8 count;
-
- pst_tim_mng = &g_st_tim_mng;
-
- timekind = (u_int8)((seqno & 0xff00) >> 8);
- count = (u_int8)(seqno & 0x00ff);
-
- /* Timer type is unexpected */
- if (timekind >= TIM_NUM) {
- ret = FALSE;
- } else {
- if ((pst_tim_mng->sts[timekind].cnt == count) &&
- (pst_tim_mng->sts[timekind].flag == TIMER_ON)) {
- /* The counter matches and the counter start/stop flag is "Start". */
- ret = TRUE;
- } else {
- /* Not applicable due to differences */
- ret = FALSE;
- }
- }
-
- return ret;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Timer Sequence Number Creation<br>
- *
- * Creating a Sequence Number for a Timer<br>
- * 1. The upper 1 byte is the timer type.,So that the lower 1 times is the total number of timer starts
- * Create a sequence number.
- *
- * @param[in] Tim_kind Timer type
- *
- * @return Timer Sequence Number
- */
-static uint16_t VehicleUtilityTimeMakSeqNo(VEHICLEUTILITY_TIM_KIND tim_kind) {
- VEHICLEUTILITY_TIM_MNG *pst_tim_mng;
- u_int16 seq_no; /* Timer Sequence Number */
-
- pst_tim_mng = &g_st_tim_mng;
-
- /*------------------------------------------------------------------------*/
- /* Definition of Sequence Number */
- /* |------------------- Sequence number(2Byte) -----------------------| */
- /* 15 8 7 0 */
- /* +-------------------------------+-----------------------------------+ */
- /* | Timer type(1Byte) | Counter(1Byte)(0x01 ? 0xFF) | */
- /* +-------------------------------+-----------------------------------+ */
- /* For the timer type,0x00 ? (Number of timers-1) */
- /* For counters,0x01 ? 0xFF(Do not use 0x00.) */
- /* (Counters are counted up each time a timer is started. */
- /* Count up when counter is 0xFF, */
- /* Be counted up from the 0x01) */
- /*------------------------------------------------------------------------*/
- seq_no = static_cast<u_int16>(((u_int16)tim_kind << 8) | (pst_tim_mng->sts[tim_kind].cnt));
-
- return seq_no;
-}
-
-/**
- * @brief
- * External pin status request
- */
-void LineSensDrvExtTermStsReq(void) {
- T_APIMSG_MSGBUF_HEADER st_snd_msg;
- RET_API lret;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- memset(&st_snd_msg, 0x00, sizeof(st_snd_msg));
-
- st_snd_msg.hdr.sndpno = PNO_LINE_SENS_DRV;
- st_snd_msg.hdr.respno = 0x0000;
- st_snd_msg.hdr.cid = CID_EXTTERM_REQ;
- st_snd_msg.hdr.msgbodysize = 0x00; /* No data */
- st_snd_msg.hdr.rid = 0x00;
-
- /* Messaging */
- lret = _pb_SndMsg(PNO_LINE_SENS_DRV, sizeof(T_APIMSG_MSGBUF_HEADER), &st_snd_msg, 0);
- if (lret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SndMsg ERROR!! lret=%d", lret);
- lret = RET_ERROR;
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
-
- return;
-}
-
-
-/**
- * @brief
- * Backup data read request send processing<BR>
- *
- * @return RET_NORMAL Normal completion
- * @return RET_ERROR ABENDs
- */
-RET_API DEVGpsSndBackupDataLoadReq(void) {
- RET_API lret;
- T_APIMSG_MSGBUF_HEADER st_snd_msg;
-
- /** Create GPS Data Notification Message */
- (void)memset(&st_snd_msg, 0x00, sizeof(st_snd_msg)); /* QAC 3200 */
- /** Message header */
- st_snd_msg.hdr.sndpno = 0x0000;
- st_snd_msg.hdr.respno = 0x0000;
- st_snd_msg.hdr.cid = CID_GPS_BACKUPDATA_LOAD;
- st_snd_msg.hdr.msgbodysize = 0x00;
- st_snd_msg.hdr.rid = 0x00;
-
- /* Messaging */
- lret = _pb_SndMsg(PNO_NAVI_GPS_MAIN, sizeof(st_snd_msg), &st_snd_msg, 0);
- if (lret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SndMsg ERROR!! [lret=%d]", lret);
- lret = RET_ERROR;
- }
-
- return(lret);
-}
-
-/**
- * @brief
- * Acquisition of GPS-format error count information (dump)
- *
- * @param[out] p_buf Dump information
- */
-void DEVGpsGetDebugGpsFormatFailCnt(void* p_buf) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- if (p_buf != NULL) {
- snprintf(reinterpret_cast<char *>(p_buf), \
- 512, "GPS Format Fail Count is not supported.\n"); // NOLINT(readability/nolint)
- }
- return;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Initial sensor data reception flag acquisition
- */
-u_int8 LineSensDrvGetSysRecvFlag(void) { // LCOV_EXCL_START 7: uesd only in FrameworkunifiedOnDebugDump
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- return 0;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * Get GPS Rollover Standard Week Number
- *
- * @return GPS rollover base week number
- */
-uint16_t DEVGpsGetWknRollover(void) { // LCOV_EXCL_START 7: uesd only in FrameworkunifiedOnDebugDump
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- return 0;
-}
-// LCOV_EXCL_STOP
-
-/* end of file */
diff --git a/vehicleservice/positioning/server/src/ServiceInterface/BackupMgrIf.cpp b/vehicleservice/positioning/server/src/ServiceInterface/BackupMgrIf.cpp
deleted file mode 100755
index da5dba2..0000000
--- a/vehicleservice/positioning/server/src/ServiceInterface/BackupMgrIf.cpp
+++ /dev/null
@@ -1,211 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * BackupMgrIf.cpp
- * @brief
- * BackupMgr service-to-service interface
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "BackupMgrIf.h"
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Structre *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Local Function Prototype *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-
-// static BOOL g_backup_mgr_availability = FALSE;
-BOOL g_backup_mgr_availability = FALSE;
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-
-/**
- * @brief
- * BackupMgr Services IF Availability Change Notification Registration
- *
- * @param[in] fp_on_cmd Callback function
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus BackupMgrIfNotifyOnBackupMgrAvailability(CbFuncPtr fp_on_cmd) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (happ != NULL) {
- /* NS_BackupMgr/Availability Changing notification registration */
- estatus = FrameworkunifiedSubscribeNotificationWithCallback(happ, NTFY_BackupMgr_Availability, (CbFuncPtr)fp_on_cmd); // LCOV_EXCL_BR_LINE 6:unexpected branch //NOLINT (whitespace/line_length)
- if (eFrameworkunifiedStatusOK != estatus) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, \
- "PositioningSubscriveNotificationswithCallback ERROR!! [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * BackupMgr Services IF-Availability Settings
- *
- * @param[in] b_is_available Available state
- * @return none
- */
-void BackupMgrIfSetAvailability(BOOL b_is_available) {
- g_backup_mgr_availability = b_is_available;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, \
- "g_backup_mgr_availability=%d", g_backup_mgr_availability);
-
- return;
-}
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-/**
- * @brief
- * BackupMgr Services IF-Availability Acquisition
- *
- * @param[in] none
- * @return gb_BackupMgrAvailability
- */
-
-BOOL BackupMgrIf_GetAvailability(void)
-{
- return g_backup_mgr_availability;
-}
-#ifdef __cplusplus
-}
-#endif
-
-/**
- * @brief
- * Import BackupMgr Services IFs
- *
- * @param[in] tag_id
- * @param[in] ui_offset
- * @param[in] *pv_buf
- * @param[in] ui_size
- * @param[out] pb_is_available Available state
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus BackupMgrIfBackupDataRd(PCSTR tag_id, uint32_t ui_offset, void *pv_buf, \
- uint32_t ui_size, BOOL* pb_is_available) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- int32_t lret;
-
- if (BackupMgrIf_GetAvailability() == TRUE) {
- lret = Backup_DataRd(tag_id, ui_offset, pv_buf, ui_size);
- if (lret == BKUP_RET_NORMAL) {
- /* 8Byte fixed outputs */
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, \
- "Backup_DataRd Done [tag_id=%s, pv_buf(Hex):%02x %02x %02x %02x %02x %02x %02x %02x, offset=%d, size=%d]",
- tag_id,
- *(reinterpret_cast<int8_t*>(pv_buf)),
- *((reinterpret_cast<int8_t*>(pv_buf))+1),
- *((reinterpret_cast<int8_t*>(pv_buf))+2),
- *((reinterpret_cast<int8_t*>(pv_buf))+3),
- *((reinterpret_cast<int8_t*>(pv_buf))+4),
- *((reinterpret_cast<int8_t*>(pv_buf))+5),
- *((reinterpret_cast<int8_t*>(pv_buf))+6),
- *((reinterpret_cast<int8_t*>(pv_buf))+7),
- ui_offset, ui_size);
-
- estatus = eFrameworkunifiedStatusOK;
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, \
- "Backup_DataRd ERROR!! [lret=%d, tag_id=%s, ui_offset=%d, pv_buf=%p, ui_size=%d]", \
- lret, tag_id, ui_offset, pv_buf, ui_size);
- }
- } else {
- /* nop */
- }
-
- *pb_is_available = BackupMgrIf_GetAvailability();
-
- return estatus;
-}
-
-/**
- * @brief
- * BackupMgr Services IF Write
- *
- * @param[in] tag_id
- * @param[in] *pv_buf
- * @param[in] ui_offset
- * @param[in] ui_size
- * @param[out] pb_is_available Available state
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus BackupMgrIfBackupDataWt(PCSTR tag_id, void *pv_buf, uint32_t ui_offset, \
- uint32_t ui_size, BOOL* pb_is_available) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- int32_t lret;
-
- if (BackupMgrIf_GetAvailability() == TRUE) {
- lret = Backup_DataWt(tag_id, pv_buf, ui_offset, ui_size);
- if (lret == BKUP_RET_NORMAL) {
- /* 8Byte fixed outputs */
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__,
- "Backup_DataWt Done [tag_id=%s, pv_buf(Hex):%02x %02x %02x %02x %02x %02x %02x %02x, offset=%d, size=%d]",
- tag_id,
- *(reinterpret_cast<int8_t*>(pv_buf)),
- *((reinterpret_cast<int8_t*>(pv_buf))+1),
- *((reinterpret_cast<int8_t*>(pv_buf))+2),
- *((reinterpret_cast<int8_t*>(pv_buf))+3),
- *((reinterpret_cast<int8_t*>(pv_buf))+4),
- *((reinterpret_cast<int8_t*>(pv_buf))+5),
- *((reinterpret_cast<int8_t*>(pv_buf))+6),
- *((reinterpret_cast<int8_t*>(pv_buf))+7),
- ui_offset, ui_size);
-
- estatus = eFrameworkunifiedStatusOK;
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, \
- "Backup_DataWt ERROR!! [lret=%d, tag_id=%s, pv_buf=%p, ui_offset=%d, ui_size=%d]", \
- lret, tag_id, pv_buf, ui_offset, ui_size);
- }
- } else {
- /* nop */
- }
-
- *pb_is_available = BackupMgrIf_GetAvailability();
-
- return estatus;
-}
diff --git a/vehicleservice/positioning/server/src/ServiceInterface/ClockIf.cpp b/vehicleservice/positioning/server/src/ServiceInterface/ClockIf.cpp
deleted file mode 100755
index 52fd4cf..0000000
--- a/vehicleservice/positioning/server/src/ServiceInterface/ClockIf.cpp
+++ /dev/null
@@ -1,138 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * ClockIf.cpp
- * @brief
- * Clock service-to-service interface
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "ClockIf.h"
-#include <stub/clock_notifications.h>
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Structre *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Local Function Prototype *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-static BOOL g_clock_availability = FALSE;
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Clock Services IF Availability Change Notification Registration
- *
- * @param[in] fp_on_cmd Callback function
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus ClockIfNotifyOnClockAvailability(CbFuncPtr fp_on_cmd) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (happ != NULL) {
- /* Clock/Availability Changing notification registration */
- estatus = FrameworkunifiedSubscribeNotificationWithCallback(happ, NTFY_Clock_Availability, fp_on_cmd); // LCOV_EXCL_BR_LINE 6:unexpected branch //NOLINT (whitespace/line_length)
- if (eFrameworkunifiedStatusOK != estatus) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "PositioningSubscriveNotificationswithCallback ERROR!! [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * Clock Services IF-Availability Settings
- *
- * @param[in] b_is_available Available state
- * @return none
- */
-void ClockIfSetAvailability(BOOL b_is_available) {
- g_clock_availability = b_is_available;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "g_clock_availability=%d", g_clock_availability);
-
- return;
-}
-
-/**
- * @brief
- * Clock Services IF GPS Time
- *
- * @param[in] *gps_time GPS time
- * @param[out] *b_is_available Available state
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus ClockIfDtimeSetGpsTime(const SENSOR_MSG_GPSTIME *pst_gps_time, BOOL* pb_is_available) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
- T_DTIME_MSG_GPSTIME st_dtime_gpstime;
-
- if (g_clock_availability == TRUE) {
- happ = _pb_GetAppHandle();
- if (happ != NULL) { // LCOV_EXCL_BR_LINE 4: nsfw error
- st_dtime_gpstime.utc.year = pst_gps_time->utc.year;
- st_dtime_gpstime.utc.month = pst_gps_time->utc.month;
- st_dtime_gpstime.utc.date = pst_gps_time->utc.date;
- st_dtime_gpstime.utc.hour = pst_gps_time->utc.hour;
- st_dtime_gpstime.utc.minute = pst_gps_time->utc.minute;
- st_dtime_gpstime.utc.second = pst_gps_time->utc.second;
- st_dtime_gpstime.tdsts = pst_gps_time->tdsts;
-
- /* Set GPS time for Clock services */
- estatus = DTime_setGpsTime(happ, &st_dtime_gpstime);
- if (estatus != eFrameworkunifiedStatusOK) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, \
- "DTime_setGpsTime ERROR!! [ret=%d, y=%d, m=%d, d=%d, h=%d, n=%d, s=%d, sts=%d]", \
- estatus, st_dtime_gpstime.utc.year, st_dtime_gpstime.utc.month, st_dtime_gpstime.utc.date, \
- st_dtime_gpstime.utc.hour, st_dtime_gpstime.utc.minute, st_dtime_gpstime.utc.second, \
- st_dtime_gpstime.tdsts);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
- } else {
- /* nop */
- }
-
- *pb_is_available = g_clock_availability;
-
- return estatus;
-}
-
diff --git a/vehicleservice/positioning/server/src/ServiceInterface/CommUsbIf.cpp b/vehicleservice/positioning/server/src/ServiceInterface/CommUsbIf.cpp
deleted file mode 100755
index b776ff0..0000000
--- a/vehicleservice/positioning/server/src/ServiceInterface/CommUsbIf.cpp
+++ /dev/null
@@ -1,147 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * CommUsbIf.cpp
- * @brief
- * CommUSB service-to-service interface
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "CommUsbIf.h"
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Structre *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Local Function Prototype *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-static BOOL g_comm_usb_availability = FALSE;
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Registering CommUSB Services IF Callback Functions
- *
- * @param[in] *p_msg_handler Callback function table
- * @param[in] Ui_handler_count Number of callback functions
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus CommUsbIfAttachCallbacksToDispatcher( // NOLINT(readability/nolint)
- _FrameworkunifiedProtocolCallbackHandler const* p_msg_handler,
- unsigned int ui_handler_count) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (happ != NULL) {
- estatus = FrameworkunifiedAttachCallbacksToDispatcher(happ, "NS_ANY_SRC", p_msg_handler, ui_handler_count);
- if (eFrameworkunifiedStatusOK != estatus) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedAttachCallbacksToDispatcher ERROR!! [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * Remove CommUSB Services IF Callback Functions
- *
- * @param[in] *p_msg_handler CID table
- * @param[in] ui_handler_count Number of CIDs
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus CommUsbIfDetachCallbacksFromDispatcher(const PUI_32 pui_cmd_array, UI_32 ui_command_count) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (happ != NULL) {
- estatus = FrameworkunifiedDetachCallbacksFromDispatcher(happ, "NS_ANY_SRC", pui_cmd_array, ui_command_count, NULL);
- /* In the event of failure */
- if (estatus != eFrameworkunifiedStatusOK) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, \
- "PositioningDetachCallbacksToDispatcher Failed in FrameworkunifiedOnStop [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * CommUSB Services IF Availability Change Notification Registration
- *
- * @param[in] fp_on_cmd Callback function
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus CommUsbIfNotifyOnCommUSBAvailability(CbFuncPtr fp_on_cmd) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (happ != NULL) { // LCOV_EXCL_BR_LINE 4: nsfw error
- /* PS_CommUSB/Availability Changing notification registration */
- estatus = FrameworkunifiedSubscribeNotificationWithCallback(happ, NTFY_CommUSB_Availability, fp_on_cmd); // LCOV_EXCL_BR_LINE 6:unexpected branch //NOLINT (whitespace/line_length)
- if (eFrameworkunifiedStatusOK != estatus) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "PositioningSubscriveNotificationswithCallback ERROR!! [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * CommUSB Services IF-Availability Settings
- *
- * @param[in] pb_is_available
- * @return none
- */
-void CommUsbIfSetAvailability(BOOL b_is_available) {
- g_comm_usb_availability = b_is_available;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "g_comm_usb_availability=%d", g_comm_usb_availability);
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/ServiceInterface/DevDetectSrvIf.cpp b/vehicleservice/positioning/server/src/ServiceInterface/DevDetectSrvIf.cpp
deleted file mode 100755
index 800429f..0000000
--- a/vehicleservice/positioning/server/src/ServiceInterface/DevDetectSrvIf.cpp
+++ /dev/null
@@ -1,279 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * DevDetectSrvIf.cpp
- * @brief
- * DevDetectSrv service-to-service interface
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "DevDetectSrvIf.h"
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Structre *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Local Function Prototype *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-static BOOL g_dev_detect_srv_availability = FALSE;
-
-/** Device insertion detection */
-DeviceDetectionServiceIf g_if_ss_dev;
-
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * DevDetectSrv Services IF-Availability Settings
- *
- * @param[in] b_is_available Available state
- * @return none
- */
-void DevDetectSrvIfSetAvailability(BOOL b_is_available) {
- g_dev_detect_srv_availability = b_is_available;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, \
- "g_dev_detect_srv_availability=%d", g_dev_detect_srv_availability);
-
- return;
-}
-
-/**
- * @brief
- * DevDetectSrv Services IF-Initialization
- *
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus DevDetectSrvIfInitialize(void) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- BOOL bret;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (happ != NULL) {
- bret = g_if_ss_dev.Initialize(happ);
- if (bret == TRUE) {
- estatus = eFrameworkunifiedStatusOK;
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, \
- "g_if_ss_dev::Initialize ERROR!! [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * DevDetectSrv Services IF Availability Change Notification Registration
- *
- * @param[in] fp_call_back_fn Callback function
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus DevDetectSrvIfNotifyOnDeviceDetectionAvailability(CbFuncPtr fp_call_back_fn) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
-
- estatus = g_if_ss_dev.NotifyOnDeviceDetectionAvailability(fp_call_back_fn);
- if (eFrameworkunifiedStatusOK != estatus) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "DeviceDetectionServiceIf Availability ERROR!! [estatus = %d]", estatus);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * DevDetectSrv Services IF OpenSessionRequest Complete Answer Receive Callback Registration
- *
- * @param[in] fp_call_back_fn Callback function
- * @param[out] pb_is_available Available state
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus DevDetectSrvIfNotifyOnOpenSessionAck(CbFuncPtr fp_call_back_fn, BOOL* pb_is_available) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
-
- if (g_dev_detect_srv_availability == TRUE) {
- estatus = g_if_ss_dev.NotifyOnOpenSessionAck(fp_call_back_fn);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "g_dev_detect_srv_availability=FALSE");
- }
-
- *pb_is_available = g_dev_detect_srv_availability;
-
- return estatus;
-}
-
-/**
- * @brief
- * DevDetectSrv Services IF CloseSessionRequest Complete Answer Receive Callback Registration
- *
- * @param[in] fp_call_back_fn Callback function
- * @param[out] pb_is_available Available state
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus DevDetectSrvIfNotifyOnCloseSessionAck(CbFuncPtr fp_call_back_fn, BOOL* pb_is_available) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
-
- if (g_dev_detect_srv_availability == TRUE) {
- estatus = g_if_ss_dev.NotifyOnCloseSessionAck(fp_call_back_fn);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "g_dev_detect_srv_availability=FALSE");
- }
-
- *pb_is_available = g_dev_detect_srv_availability;
-
- return estatus;
-}
-
-/**
- * @brief
- * DevDetectSrv Service IF Service and Session Generation
- *
- * @param[out] pb_is_available Available state
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus DevDetectSrvIfOpenSessionRequest(BOOL* pb_is_available) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
-
- if (g_dev_detect_srv_availability == TRUE) {
- estatus = g_if_ss_dev.OpenSessionRequest();
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "g_dev_detect_srv_availability=FALSE");
- }
-
- *pb_is_available = g_dev_detect_srv_availability;
-
- return estatus;
-}
-
-/**
- * @brief
- * DevDetectSrv Services IF-Session Id Retention
- *
- * @param[out] pb_is_available Available state
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus DevDetectSrvIfDecodeOpenSessionResponse(BOOL* pb_is_available) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
-
- if (g_dev_detect_srv_availability == TRUE) {
- estatus = g_if_ss_dev.DecodeOpenSessionResponse();
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "g_dev_detect_srv_availability=FALSE");
- }
-
- *pb_is_available = g_dev_detect_srv_availability;
-
- return estatus;
-}
-
-/**
- * @brief
- * DevDetectSrv Services IF-Device Event Receive Callback Registration
- *
- * @param[in] fe_dev_detect_event
- * @param[in] fp_call_back_fn
- * @param[in] p_file_path
- * @param[out] pb_is_available Available state
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus DevDetectSrvIfRegisterForDeviceDetectionEvent(SS_DeviceDetectionServerEvents fe_dev_detect_event, \
- CbFuncPtr fp_call_back_fn, PCSTR p_file_path, BOOL* pb_is_available) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
-
- if (g_dev_detect_srv_availability == TRUE) {
- estatus = g_if_ss_dev.RegisterForDeviceDetectionEvent(fe_dev_detect_event, fp_call_back_fn, p_file_path);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "g_dev_detect_srv_availability=FALSE");
- }
-
- *pb_is_available = g_dev_detect_srv_availability;
-
- return estatus;
-}
-
-/**
- * @brief
- * DevDetectSrv Services IF DeviceDetectionServiceIf Callback Release
- *
- * @param[in] fe_dev_detect_event
- * @param[out] pb_is_available Available state
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus DevDetectSrvIfUnRegisterForDeviceDetectionEvent(SS_DeviceDetectionServerEvents fe_dev_detect_event, \
- BOOL* pb_is_available) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
-
- if (g_dev_detect_srv_availability == TRUE) {
- estatus = g_if_ss_dev.UnRegisterForDeviceDetectionEvent(fe_dev_detect_event);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "g_dev_detect_srv_availability=FALSE");
- }
-
- *pb_is_available = g_dev_detect_srv_availability;
-
- return estatus;
-}
-
-/**
- * @brief
- * DevDetectSrv Service IF Service and Destroy Sessions
- *
- * @param[out] pb_is_available Available state
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus DevDetectSrvIfCloseSessionRequest(BOOL* pb_is_available) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
-
- if (g_dev_detect_srv_availability == TRUE) {
- estatus = g_if_ss_dev.CloseSessionRequest();
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "g_dev_detect_srv_availability=FALSE");
- }
-
- *pb_is_available = g_dev_detect_srv_availability;
-
- return estatus;
-}
-
diff --git a/vehicleservice/positioning/server/src/ServiceInterface/DiagSrvIf.cpp b/vehicleservice/positioning/server/src/ServiceInterface/DiagSrvIf.cpp
deleted file mode 100755
index 195555e..0000000
--- a/vehicleservice/positioning/server/src/ServiceInterface/DiagSrvIf.cpp
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * DiagSrvIf.cpp
- * @brief
- * DiagSrv service-to-service interface
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "DiagSrvIf.h"
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Structre *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Local Function Prototype *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-static BOOL g_registration_permission = FALSE; /* Whether or not the dialog code can be registered */
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * DiagSrv Services IF Registration Enable Status Setting
- *
- * @param[in] b_is_true
- * @return none
- */
-void DiagSrvIfSetRegistrationPermission(BOOL b_is_true) {
- g_registration_permission = b_is_true;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, \
- "g_registration_permission=%d", g_registration_permission);
-
- return;
-}
diff --git a/vehicleservice/positioning/server/src/ServiceInterface/Makefile b/vehicleservice/positioning/server/src/ServiceInterface/Makefile
deleted file mode 100755
index fba98e8..0000000
--- a/vehicleservice/positioning/server/src/ServiceInterface/Makefile
+++ /dev/null
@@ -1,54 +0,0 @@
-#
-# @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-######### installed library(*.a) #############
-INST_LIBS = libPOS_ServiceInterface
-
-######### compiled sources #############
-libPOS_ServiceInterface_SRCS += BackupMgrIf.cpp
-libPOS_ServiceInterface_SRCS += ClockIf.cpp
-libPOS_ServiceInterface_SRCS += CommUsbIf.cpp
-libPOS_ServiceInterface_SRCS += DevDetectSrvIf.cpp
-libPOS_ServiceInterface_SRCS += DiagSrvIf.cpp
-libPOS_ServiceInterface_SRCS += PSMShadowIf.cpp
-libPOS_ServiceInterface_SRCS += VehicleIf.cpp
-
-######### add include path #############
-CPPFLAGS += -I../../include/common/
-CPPFLAGS += -I../../include/nsfw/
-CPPFLAGS += -I../../include/ServiceInterface
-
-CPPFLAGS += -I../../../client/include
-
-#CPPFLAGS += -I../../../../diag_code/library/include
-
-######### add compile option #############
-CPPFLAGS += -DLINUX
-
-LDFLAGS += -Wl,--no-undefined
-LDFLAGS += -Wl,--no-as-needed
-CPPFLAGS += -Werror=implicit-function-declaration
-CPPFLAGS += -Werror=format-security
-CPPFLAGS += -Wconversion
-CPPFLAGS += -Wint-to-pointer-cast
-CPPFLAGS += -Wpointer-arith
-CPPFLAGS += -Wformat
-
-######### add library path #############
-LDFLAGS +=
-
-include ../../../../vehicle_service.mk
-
diff --git a/vehicleservice/positioning/server/src/ServiceInterface/PSMShadowIf.cpp b/vehicleservice/positioning/server/src/ServiceInterface/PSMShadowIf.cpp
deleted file mode 100755
index 99d9a52..0000000
--- a/vehicleservice/positioning/server/src/ServiceInterface/PSMShadowIf.cpp
+++ /dev/null
@@ -1,102 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * PSMShadowIf.cpp
- * @brief
- * PSMShadow service-to-service interface
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include "PSMShadowIf.h"
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Structre *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Local Function Prototype *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * PSMShadow Services IF Availability Change Notification Registration
- *
- * @param[in] fp_on_cmd Callback function
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus PSMShadowIfNotifyOnPSMShadowAvailability(CbFuncPtr fp_on_cmd) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (happ != NULL) {
- /* PS_PSMShadow/Availability Changing notification registration */
- estatus = FrameworkunifiedSubscribeNotificationWithCallback(happ, NTFY_PSMShadowService_Availability, fp_on_cmd); // LCOV_EXCL_BR_LINE 6:unexpected branch //NOLINT (whitespace/line_length)
- if (eFrameworkunifiedStatusOK != estatus) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "PositioningSubscriveNotificationswithCallback ERROR!! [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * Register PSMShadow services IF start completion notification
- *
- * @param[in] fp_on_cmd Callback function
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus PSMShadowIfNotifyOnPSMShadowInitComp(CbFuncPtr fp_on_cmd) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (happ != NULL) {
- /* PS_PSMShadow startup completion notice */
- estatus = FrameworkunifiedSubscribeNotificationWithCallback(happ, NTFY_PSM_INITCOMP, fp_on_cmd); // LCOV_EXCL_BR_LINE 6:unexpected branch //NOLINT (whitespace/line_length)
- if (eFrameworkunifiedStatusOK != estatus) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "PositioningSubscriveNotificationswithCallback ERROR!! [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
diff --git a/vehicleservice/positioning/server/src/ServiceInterface/VehicleIf.cpp b/vehicleservice/positioning/server/src/ServiceInterface/VehicleIf.cpp
deleted file mode 100755
index 0ef5e15..0000000
--- a/vehicleservice/positioning/server/src/ServiceInterface/VehicleIf.cpp
+++ /dev/null
@@ -1,364 +0,0 @@
-/*
- * @copyright Copyright (c) 2018-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * VehilceIf.cpp
- * @brief
- * Vehicle Service Interface
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <vehicle_service/positioning_base_library.h>
-#include <stub/Vehicle_Sensor_Common_API.h>
-#include <stub/Vehicle_API.h>
-#include <stub/vehicle_notifications.h>
-
-#include "VehicleIf.h"
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Structre *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Local Function Prototype *
- *---------------------------------------------------------------------------------*/
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-static BOOL gb_vehicleAvailability = FALSE;
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Registering Vehicle Services IF Callback Functions
- *
- * @param[in] *p_msg_handler Callback function table
- * @param[in] Ui_handler_count Number of callback functions
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus VehicleIfAttachCallbacksToDispatcher( // NOLINT(readability/nolint)
- _FrameworkunifiedProtocolCallbackHandler const* p_msg_handler,
- unsigned int ui_handler_count) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (NULL != happ) {
- estatus = FrameworkunifiedAttachCallbacksToDispatcher(happ, "NS_ANY_SRC", p_msg_handler, ui_handler_count);
- if (eFrameworkunifiedStatusOK != estatus) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedAttachCallbacksToDispatcher ERROR!! [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * Vehicle IF: Set Availability Status
- *
- * @details This function sets status of Vehicle/Availablity stored in local. <br>
- * Only when the status is true, Vehicle I/F is called by wrappers.
- *
- * @param[in] BOOL bIsAvailable : Availability Status
- */
-void VehicleIf_SetAvailability(BOOL bIsAvailable)
-{
- gb_vehicleAvailability = bIsAvailable;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "gb_vehicleAvailability=%d", gb_vehicleAvailability);
-
- return;
-}
-
-/**
- * @brief
- * Remove Vehicle Services IF Callback Functions
- *
- * @param[in] *p_msg_handler CID table
- * @param[in] ui_handler_count Number of CIDs
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus VehicleIfDetachCallbacksFromDispatcher(const PUI_32 pui_cmd_array, UI_32 ui_command_count) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (NULL != happ) {
- estatus = FrameworkunifiedDetachCallbacksFromDispatcher(happ, "NS_ANY_SRC", pui_cmd_array, ui_command_count, NULL);
- /* In the event of failure */
- if (eFrameworkunifiedStatusOK != estatus) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "PositioningDetachCallbacksToDispatcher Failed in FrameworkunifiedOnStop [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * Vehicle IF: Get Type of Transmission
- *
- * @details This function is wrapper function of Vehicle I/F. <br>
- * You can get the type of transmission of the vehicle.
- *
- * @param[out] uint8_t* pType : Type of Transmission
- * @param[out] BOOL* bIsAvailable : Availability Status
- *
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-
-//EFrameworkunifiedStatus VehicleIf_GetTypeOfTransmission(uint8_t* pType, BOOL* pbIsAvailable)
-EFrameworkunifiedStatus VehicleIf_GetTypeOfTransmission(uint8_t* pType, uint8_t* pPkb, BOOL* pbIsAvailable)
-{
- EFrameworkunifiedStatus eStatus = eFrameworkunifiedStatusFail;
- VEHICLE_RET_API ret;
- HANDLE hApp;
- uint8_t ucVartrm;
-
-#if 1 /* Plus _CWORD27_ Gear Data Support 180115 */
- uint8_t ucPkb;
-#endif /* Plus _CWORD27_ Gear Data Support 180115 */
-
-
- if (gb_vehicleAvailability == TRUE)
- {
- hApp = _pb_GetAppHandle();
- if (hApp != NULL)
- {
- ret = Vehicle_GetVehicleData(hApp, VEHICLE_DID_VARTRM1, &ucVartrm, sizeof(ucVartrm));
- if (ret < VEHICLE_RET_NORMAL)
- {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ERROR: Vehicle_GetVehicleData:%d", ret);
- }
- else
- {
- eStatus = eFrameworkunifiedStatusOK;
-
- switch (ucVartrm)
- {
- case VEHICLE_SNS_VARTRM1_AT:
- case VEHICLE_SNS_VARTRM1_CVT:
- case VEHICLE_SNS_VARTRM1_HV_AT:
- {
- *pType = VEHICLEIF_TRANSMISSION_TYPE_AT;
- break;
- }
- case VEHICLE_SNS_VARTRM1_MT:
- case VEHICLE_SNS_VARTRM1_MMT:
- case VEHICLE_SNS_VARTRM1_SMT:
- {
- *pType = VEHICLEIF_TRANSMISSION_TYPE_MT;
- break;
- }
- case VEHICLE_SNS_VARTRM1_UNCERTAINTY:
- {
- *pType = VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN;
- break;
- }
- default:
- {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: Type of transmission is unknown. (%d)", ucVartrm);
-
- *pType = VEHICLEIF_TRANSMISSION_TYPE_UNKNOWN;
- break;
- }
- }
- }
-
-#if 1 /* Plus _CWORD27_ Gear Data Support 180115 */
- ret = Vehicle_GetVehicleData(hApp, VEHICLE_DID_PKB, &ucPkb, sizeof(ucPkb));
- if (ret < VEHICLE_RET_NORMAL)
- {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ERROR: Vehicle_GetVehicleData:%d", ret);
- }
- else
- {
- eStatus = eFrameworkunifiedStatusOK;
-
- switch (ucPkb)
- {
- case VEHICLE_SNS_OFF: // R-state
- //case VEHICLE_SNS_ANTI: // Antilock(Vehicle undefined)
- {
- *pPkb = VEHICLEIF_PKB_OFF;
- break;
- }
- case VEHICLE_SNS_ON: // Lock state
- {
- *pPkb = VEHICLEIF_PKB_ON;
- break;
- }
- default:
- {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "ERROR: State of parking brake is unknown. (%d)", ucPkb);
-
- *pPkb = VEHICLEIF_PKB_OFF;
- break;
- }
- }
- }
-#endif /* Plus _CWORD27_ Gear Data Support 180115 */
-
- }
- else
- {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ERROR: _pb_GetAppHandle hApp:%p", hApp);
- }
- }
- else
- {
- /* nop */
- }
-
- *pbIsAvailable = gb_vehicleAvailability;
-
- return eStatus;
-}
-
-/**
- * @brief
- * Vehicle Services IF Availability Change Notification Registration
- *
- * @param[in] fp_on_cmd Callback function
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus VehicleIfNotifyOnVehicleAvailability(CbFuncPtr fp_on_cmd) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
-
- happ = _pb_GetAppHandle();
- if (NULL != happ) {
- /* Vehicle/Availability Changing notification registration */
- estatus = FrameworkunifiedSubscribeNotificationWithCallback(happ, NTFY_Vehicle_Availability, fp_on_cmd); // LCOV_EXCL_BR_LINE 6:unexpected branch //NOLINT (whitespace/line_length)
- if (eFrameworkunifiedStatusOK != estatus) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "PositioningSubscriveNotificationswithCallback ERROR!! [estatus=%d]", estatus);
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
-
- return estatus;
-}
-
-/**
- * @brief
- * Vehicle IF: Get Shift Position
- *
- * @details This function is wrapper function of Vehicle I/F. <br>
- * You can get the shift position of the vehicle.
- *
- * @param[out] uint8_t* pShift : Shift Position
- * @param[out] BOOL* bIsAvailable : Availability Status
- *
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-EFrameworkunifiedStatus VehicleIf_GetShiftPosition(uint8_t* pShift, BOOL* pbIsAvailable)
-{
- EFrameworkunifiedStatus eStatus = eFrameworkunifiedStatusFail;
- VEHICLE_RET_API ret;
- HANDLE hApp;
-
- if (gb_vehicleAvailability == TRUE)
- {
- hApp = _pb_GetAppHandle();
- if (hApp != NULL)
- {
- ret = Vehicle_GetVehicleData(hApp, VEHICLE_DID_SHIFT, pShift, sizeof(*pShift));
- if (ret < VEHICLE_RET_NORMAL)
- {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ERROR: Vehicle_GetVehicleData:%d", ret);
- }
- else
- {
- eStatus = eFrameworkunifiedStatusOK;
- }
- }
- else
- {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "ERROR: _pb_GetAppHandle hApp:%p", hApp);
- }
- }
- else
- {
- /* nop */
- }
-
- *pbIsAvailable = gb_vehicleAvailability;
-
- return eStatus;
-}
-
-
-/**
- * @brief
- * Vehicle services IF Info data-delivery registry
- *
- * @param[in] ul_did
- * @return eFrameworkunifiedStatusOK
- * @return eFrameworkunifiedStatusFail
- */
-
-EFrameworkunifiedStatus VehicleIfDeliveryEntry(uint32_t ul_did) {
- EFrameworkunifiedStatus estatus = eFrameworkunifiedStatusFail;
- HANDLE happ;
- VEHICLE_RET_API iret;
-
- if (TRUE == gb_vehicleAvailability) {
- happ = _pb_GetAppHandle();
- if (NULL != happ) {
- /* Sensor data delivery registration */
- iret = Vehicle_DeliveryEntry(happ, (PCSTR)POS_THREAD_NAME, ul_did,
- VEHICLE_DELIVERY_REGIST, VEHICLE_DELIVERY_TIMING_UPDATE);
- if (VEHICLE_RET_NORMAL != iret) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "Vehicle_DeliveryEntry ERROR!! [iret=%d]", iret);
- } else {
- estatus = eFrameworkunifiedStatusOK;
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_GetAppHandle ERROR!! [happ=%p]", happ);
- }
- } else {
- /* nop */
- }
- return estatus;
-}
-
diff --git a/vehicleservice/positioning/server/src/nsfw/Makefile b/vehicleservice/positioning/server/src/nsfw/Makefile
deleted file mode 100755
index 403e29f..0000000
--- a/vehicleservice/positioning/server/src/nsfw/Makefile
+++ /dev/null
@@ -1,89 +0,0 @@
-#
-# @copyright Copyright (c) 2017-2020 TOYOTA MOTOR CORPORATION.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-######### installed program #############
-INST_PROGS = Positioning
-
-######### compiled sources #############
-Positioning_SRCS += ps_main.cpp
-Positioning_SRCS += positioning_application.cpp
-
-ifeq ($(ARCH),arm64)
-LDLIBS += -Wl,-Bdynamic -lpositioning_hal
-else
-LDLIBS += -Wl,-Bdynamic -lpositioning_hal
-endif #($(ARCH),arm64)
-
-######### add include path #############
-CPPFLAGS += -I../../../client/include
-CPPFLAGS += -I../../include/common/
-CPPFLAGS += -I../../include/Sensor/
-CPPFLAGS += -I../../include/ServiceInterface/
-CPPFLAGS += -I../../include/nsfw/
-#CPPFLAGS += -I../../../../diag_code/library/include
-
-######### add compile option #############
-CPPFLAGS += -DLINUX
-CPPFLAGS += -DIMPL_AGL_APPLICATION_CALLBACKS_PRE_BACKGROUND
-LDFLAGS += -Wl,--no-undefined
-LDFLAGS += -Wl,--no-as-needed
-CPPFLAGS += -Werror=implicit-function-declaration
-CPPFLAGS += -Werror=format-security
-CPPFLAGS += -Wconversion
-CPPFLAGS += -Wint-to-pointer-cast
-CPPFLAGS += -Wpointer-arith
-CPPFLAGS += -Wformat
-
-######### linked library(static) #############
-LDLIBS += -Wl,-Bstatic -lPOS_Sensor
-LDLIBS += -Wl,-Bstatic -lPOS_ServiceInterface
-
-# LDLIBS += -Wl,-Bstatic -lVehicle_API
-
-######### linked library (dynamic) #############
-ifeq (arm64, $(ARCH))
-LDLIBS += -Wl,-Bdynamic -lpositioning_hal
-LDLIBS += -Wl,-Bdynamic -lVehicle_API
-endif
-LDLIBS += -Wl,-Bdynamic -lClock_API
-#LDLIBS += -Wl,-Bdynamic -lMM_DREC_API
-#LDLIBS += -Wl,-Bdynamic -lextension
-LDLIBS += -Wl,-Bdynamic -lPOS_base_API
-LDLIBS += -Wl,-Bdynamic -lPOS_common_API
-LDLIBS += -Wl,-Bdynamic -lPOS_gps_API
-LDLIBS += -Wl,-Bdynamic -lPOS_sensor_API
-LDLIBS += -Wl,-Bdynamic -lz
-LDLIBS += -Wl,-Bdynamic -lSS_SystemIfUnified
-LDLIBS += -Wl,-Bdynamic -lNS_FrameworkUnified
-LDLIBS += -Wl,-Bdynamic -lns_backup
-LDLIBS += -Wl,-Bdynamic -lssver
-LDLIBS += -Wl,-Bdynamic -lstdc++
-#LDLIBS += -Wl,-Bdynamic -lDiagCodeAPI
-LDLIBS += -Wl,-Bdynamic -lDTime_Api
-LDLIBS += -Wl,-Bdynamic -lVehicle_API
-LDLIBS += -Wl,-Bdynamic -lvp
-LDLIBS += -Wl,-Bdynamic -lev
-LDLIBS += -Wl,-Bdynamic -lCommUSB
-
-######### add library path #############
-LDFLAGS += -L../../positioning_hal
-LDFLAGS += -L../Sensor
-LDFLAGS += -L../ServiceInterface
-LDFLAGS += -L../../../client/src/POS_common_API
-LDFLAGS += -L../../../client/src/POS_gps_API
-LDFLAGS += -L../../../client/src/POS_sensor_API
-
-include ../../../../vehicle_service.mk
diff --git a/vehicleservice/positioning/server/src/nsfw/positioning_application.cpp b/vehicleservice/positioning/server/src/nsfw/positioning_application.cpp
deleted file mode 100755
index d23daad..0000000
--- a/vehicleservice/positioning/server/src/nsfw/positioning_application.cpp
+++ /dev/null
@@ -1,2593 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @file
- * positioning_application.cpp
- * @brief
- * Module : POSITIONING
- * Implements Vehicle service functionality
- */
-
-/*---------------------------------------------------------------------------------*
- * Include Files *
- *---------------------------------------------------------------------------------*/
-#include <native_service/frameworkunified_application.h>
-#include <native_service/frameworkunified_framework_if.h>
-#include <native_service/frameworkunified_multithreading.h>
-#include <native_service/frameworkunified_service_protocol.h>
-#include <native_service/frameworkunified_types.h>
-#include <native_service/ns_message_center_if.h>
-#include <peripheral_service/ps_services.h>
-#include <vehicle_service/POS_sensor_API.h>
-#include <vehicle_service/POS_gps_API.h>
-#include <system_service/ss_sm_client_if.h>
-#include <vehicle_service/positioning_base_library.h>
-#include <stub/vehicle_notifications.h>
-#include <peripheral_service/communication_notifications.h>
-#include <other_service/VP_GetEnv.h>
-#include <cstdlib>
-#include <iostream>
-
-#include "SensorLog.h"
-#include "positioning_common.h"
-#include "POS_private.h"
-#include "Gps_API_private.h"
-#include "POS_common_private.h"
-#include "Vehicle_API.h"
-#include "Vehicle_API_private.h"
-#include "Sensor_API_private.h"
-#include "Naviinfo_API.h"
-#include "VehicleSensor_Thread.h"
-#include "ClockGPS_Process_Proto.h"
-#include "VehicleSens_Common.h"
-#include "VehicleSens_DataMaster.h"
-#include "VehicleSens_DeliveryCtrl.h"
-#include "VehicleUtility.h"
-#include "BackupMgrIf.h"
-#include "ClockIf.h"
-#include "CommUsbIf.h"
-#include "DevDetectSrvIf.h"
-#include "DiagSrvIf.h"
-#include "PSMShadowIf.h"
-#include "VehicleIf.h"
-#include "positioning_hal.h"
-#include "gps_hal.h"
-#include "CommonDefine.h"
-
-#include "VehicleIf.h"
-
-/*---------------------------------------------------------------------------------*
- * Definition *
- *---------------------------------------------------------------------------------*/
-#define DATMOD_RETRY (3) /* Number of shared memory generation retries */
-#define DATMOD_PREINIT (0) /* Shared Memory State Before Initialization */
-#define PRIM_NAME_MAX (32) /* Maximum Name Size */
-
-/* Mask for managing various notification reception conditions */
-#define NTFY_MSK_NONE (0x00)
-/* Service availability notification */
-#define NTFY_MSK_COMMUNICATION_AVAILABILITY (0x01)
-#define NTFY_MSK_PS_COMMUSB_AVAILABILITY (0x02)
-#define NTFY_MSK_PS_PSMSHADOW_AVAILABILITY (0x04)
-#define NTFY_MSK_CLOCK_AVAILABILITY (0x08)
-#define NTFY_MSK_NS_BACKUPMGR_AVAILABILITY (0x10)
-#define NTFY_MSK_SS_DEVDETSRV_AVAILABILITY (0x20)
-#define NTFY_MSK_VS_VEHICLE_AVAILABILITY (0x40)
-/* Other Notices */
-#define NTFY_MSK_PS_PSMSHADOW_INIT_COMP (0x01) /* PSMShadow startup completion notice */
-
-/* Thread state */
-#define THREAD_STS_NOEXIST (0x00)
-#define THREAD_STS_CREATING (0x01)
-#define THREAD_STS_CREATED (0x02)
-
-#define POS_SNDMSG_DTSIZE_1 1 /* SndMSG data size 1Byte */
-#define POS_SNDMSG_DTSIZE_2 2 /* SndMSG data size 2Byte */
-#define POS_SNDMSG_DTSIZE_20 20 /* SndMSG data size of 20 bytes */
-#define POS_SNDMSG_DTSIZE_132 132 /* SndMSG data size: 132 bytes */
-
-/* PositioningLogFlag */
-#define POSITIONINGLOG_FLAG_NAVI 9
-
-/* Definition for thinning out sensor log at anomaly */
-#define POSITIONINGLOG_SYS_1_ABNORMAL_DATA_NUM 3
-#define POSITIONINGLOG_SYS_2_ABNORMAL_DATA_NUM 4
-#define POSITIONINGLOG_SYS_3_ABNORMAL_DATA_NUM 4
-#define POSITIONINGLOG_SYS_4_ABNORMAL_DATA_NUM 129
-#define POSITIONINGLOG_SYS_ABNORMAL_DATA_NUM (POSITIONINGLOG_SYS_1_ABNORMAL_DATA_NUM + \
- POSITIONINGLOG_SYS_2_ABNORMAL_DATA_NUM + \
- POSITIONINGLOG_SYS_3_ABNORMAL_DATA_NUM + \
- POSITIONINGLOG_SYS_4_ABNORMAL_DATA_NUM)
-#define POSITIONINGLOG_SYS_1_ABNORMAL_DATA_OFFSET 11
-#define POSITIONINGLOG_SYS_2_ABNORMAL_DATA_OFFSET 32
-#define POSITIONINGLOG_SYS_3_ABNORMAL_DATA_OFFSET 54
-#define POSITIONINGLOG_SYS_4_ABNORMAL_DATA_OFFSET 114
-#define POSITIONINGLOG_SYS_1_ABNORMAL_SET_DATA_OFFSET 0
-#define POSITIONINGLOG_SYS_2_ABNORMAL_SET_DATA_OFFSET POSITIONINGLOG_SYS_1_ABNORMAL_DATA_NUM
-#define POSITIONINGLOG_SYS_3_ABNORMAL_SET_DATA_OFFSET (POSITIONINGLOG_SYS_1_ABNORMAL_DATA_NUM + POSITIONINGLOG_SYS_2_ABNORMAL_DATA_NUM)
-#define POSITIONINGLOG_SYS_4_ABNORMAL_SET_DATA_OFFSET (POSITIONINGLOG_SYS_1_ABNORMAL_DATA_NUM + \
- POSITIONINGLOG_SYS_2_ABNORMAL_DATA_NUM + \
- POSITIONINGLOG_SYS_3_ABNORMAL_DATA_NUM)
-#define POSITIONINGLOG_SYS_OPC_OFFSET 9
-#define POSITIONINGLOG_SYS_PULSE_TIME_NUM_OFFSET 114
-#define POSITIONINGLOG_SYS_NORMAL_DATA 0xC1
-#define POSITIONINGLOG_SYS_FST_DATA 0xF4
-#define _pb_strcat(pdest, psrc, size) (strncat(pdest, psrc, size) , (0))
-
-// Vehicle sensor information notification message
-typedef struct {
- uint32_t did; // Data ID corresponding to vehicle sensor information
- uint16_t size; // Data size of vehicle sensor information
- uint8_t rcv_flag; // Vehicle sensor information reception flag
- uint8_t reserve; // Reserved
- uint8_t data[VEHICLE_VSINFO_DSIZE]; // Vehicle sensor information
-} VEHICLE_UNIT_MSG_VSINFO_DAT;
-
-// Vehicle sensor information notification message
-typedef struct {
- VEHICLE_UNIT_MSG_VSINFO_DAT data; // Message data
-} VEHICLE_UNIT_MSG_VSINFO;
-/*---------------------------------------------------------------------------------*
- * Structre *
- *---------------------------------------------------------------------------------*/
-/*!
- @brief Structure to create shared data
-*/
-typedef struct {
- char share_data_name[PRIM_NAME_MAX]; /**< Shared data name */
- u_int32 data_size; /**< Shared data size */
-} ST_SHAREDATA;
-
-/*!
- @brief Thread management information
-*/
-typedef struct {
- EnumTID_POS id; /**< Thread ID */
- const int8_t* p_name; /**< Thread name */
- PNO pno; /**< Process number */
- CbFuncPtr routine; /**< Start Routine */
- uint8_t msk_available; /**< Dependent services Availability */
- uint8_t msk_ntfy; /**< Dependency notification */
- uint8_t msk_thread; /**< Dependent threads */
- BOOL is_depended; /**< Positioning/Availability->TRUE change dependency */
- uint8_t status; /**< Thread activation state */
- uint8_t order; /**< Boot Sequence(Performance) */
- uint8_t reserve[2];
-} ST_THREAD_CREATE_INFO;
-
-
-/* GPS fix count information */
-typedef struct {
- uint32_t ul3d; /* 3D */
- uint32_t ul2d; /* 2D */
- uint32_t ul_else; /* Not fix */
- uint8_t dummy[4]; /* Dummy */
-} ST_GPS_FIX_CNT;
-
-/*!
- @brief Structure that stores the time set by the time setting or the time updated(For GRADE1)
-*/
-typedef struct {
- u_int16 year; /* Year */
- u_int8 month; /* Month */
- u_int8 date; /* Day */
- u_int8 hour; /* Hour */
- u_int8 minute;/* Minutes */
- u_int8 second;/* Minutes */
- u_int8 flag; /* Whether or not the time is set */
-} ST_GPS_SET_TIME;
-
-/*---------------------------------------------------------------------------------*
- * Local Function Prototype *
- *---------------------------------------------------------------------------------*/
-static EFrameworkunifiedStatus PositioningOnStartImpl(const HANDLE hApp, const EPWR_SC_WAKEUP_TYPE wakeupType,
- const ESMDataResetModeInfo dataResetMode);
-static EFrameworkunifiedStatus PosNotifyCommunicationAvailability(HANDLE h_app);
-static EFrameworkunifiedStatus PosNotifyCommUSBAvailability(HANDLE h_app);
-static EFrameworkunifiedStatus PosNotifyPSMShadowAvailability(HANDLE h_app);
-static EFrameworkunifiedStatus PosNotifyPSMShadowInitComp(HANDLE h_app);
-static EFrameworkunifiedStatus PosNotifyClockAvailability(HANDLE h_app);
-static EFrameworkunifiedStatus PosNotifyNSBackupMgrAvailability(HANDLE h_app);
-static EFrameworkunifiedStatus PosNotifyDevDetectSrvAvailability(HANDLE h_app);
-static EFrameworkunifiedStatus PosNotifyVehicleAvailability(HANDLE h_app);
-
-static EFrameworkunifiedStatus PosStopThreadDummy(HANDLE h_app);
-static void PosCreateSharedMemory(void);
-static void PosCreateThread(HANDLE h_app);
-static void PosStopThread(void);
-static void PosBackupDataInit(void);
-
-/* Message Dispatching Functions */
-static EFrameworkunifiedStatus PosThreadCreateComp(HANDLE h_app);
-static EFrameworkunifiedStatus PosThreadStopComp(HANDLE h_app);
-static EFrameworkunifiedStatus PosPosifRegisterListenerPkgSensorData(HANDLE h_app);
-static EFrameworkunifiedStatus PosPosifRegisterListenerSensorData(HANDLE h_app);
-static EFrameworkunifiedStatus PosPosifReqGpsSetting(HANDLE h_app);
-static EFrameworkunifiedStatus PosPosifSetGpsInfo(HANDLE h_app);
-static EFrameworkunifiedStatus PosPosifGetGpsInfo(HANDLE h_app);
-static EFrameworkunifiedStatus PosPosifSetData(HANDLE h_app);
-static EFrameworkunifiedStatus PosPosifReqGpsReset(HANDLE h_app);
-static EFrameworkunifiedStatus PosVehicleInfoRcv(HANDLE h_app);
-static uint32_t PosGetMsg(HANDLE h_app, void** p_buf, uint32_t size);
-static RET_API PosSndMsg(PNO pno, CID cid, void* p_msg_body, uint32_t size);
-static void PosOutputDebugDumpLog(uint8_t* p_buf);
-
-/* Function scan for device insertion detection */
-static EFrameworkunifiedStatus PosOnDevDetectOpenSessionAck(HANDLE h_app);
-static EFrameworkunifiedStatus PosOnDevDetectCloseSessionAck(HANDLE h_app);
-static EFrameworkunifiedStatus PosOnDevDetectEvent(HANDLE h_app);
-
-/*---------------------------------------------------------------------------------*
- * Grobal Value *
- *---------------------------------------------------------------------------------*/
-/* Thread name */
-static const int8_t kThreadNamePosMain[15] = "POS_Main";
-static const int8_t kThreadNamePosSens[15] = "POS_Sens";
-static const int8_t kThreadNamePosGps[15] = "POS_Gps";
-static const int8_t kThreadNamePosGpsRecv[15] = "POS_Gps_Recv";
-static const int8_t kThreadNamePosGpsRollover[15] = "POS_Gps_Rolovr";
-
-/** Shared memory generation table */
-static ST_SHAREDATA g_sharedata_tbl[] = {
- /* Shared data name to be generated, Shared data size */
- { {VEHICLE_SHARE_NAME}, 512 * 11 }, /* Vehicle sensor information acquisition */
-#if 0 /* Less than 0.1 SBU,Not used in _CWORD71_ */
- { {"SENSOR_SHARE_MEMORY"}, 512 * 11 }, /* Vehicle sensor information Pkg acquisition */
- { {"GPS_INT_SIGNAL_SHARE_MEMORY"}, 4 }, /* GPS Interrupt Signal Acquisition */
- { {"LOG_SETTING_SHARE_MEMORY"}, 36 }, /* DR feature log acquisition */
- { {"GYRO_CONNECT_STTS_SHARE_MEMORY"}, 4 }, /* Get Gyro Connection Status */
- { {"EPHEMERIS_NUM_SHARE_MEMORY"}, 4 }, /* For acquiring effective ephemeris count at shutdown */
- { {"LOCALTIME_SHARE_MEMORY"}, 12 }, /* Local time acquisition at shutdown */
- { {"LONLAT_SHARE_MEMORY"}, 8 }, /* Location acquisition at shutdown */
-#endif
- { {'\0'}, 0 } /* Termination */
-};
-
-/** Sub-thread creation table
- (1) Thread ID (Locally defined Enumeration)
- (2) Thread name
- (3) Process number
- (4) Start Routine
- (5) Dependent Availability
- (6) Dependency notification
- (7) Dependent threads * If there are dependent threads, do not create them until those threads are created.
- (8) Positioning/Availability->TRUE depending on change
- (9) Thread activation state (THREAD_STS_NOEXIST:Not started,THREAD_STS_CREATING:Starting,THREAD_STS_CREATED:Completion of the activation)
- (10) Boot Sequence(Performance) (0,1,2, ... Note : 0 = Initial value(Not started)) Time of termination,Be destroyed in the reverse order of startup
- */
-static ST_THREAD_CREATE_INFO g_pos_thread_create_info_Grade1[] = { // LCOV_EXCL_BR_LINE 11: unexpected branch
- { /* Pos_main */
- ETID_POS_MAIN, /* (1) */
- kThreadNamePosMain, /* (2) */
- PNO_VEHICLE_SENSOR, /* (3) */
- &VehicleSensThread, /* (4) */
- (NTFY_MSK_NONE), /* (5) */
- (NTFY_MSK_NONE), /* (6) */
- 0, /* (7) */
- TRUE, /* (8) */
- THREAD_STS_NOEXIST, /* (9) */
- 0 /* (10) */
- },
- { /* Pos_sens */
- ETID_POS_SENS, /* (1) */
- kThreadNamePosSens, /* (2) */
- PNO_LINE_SENS_DRV, /* (3) */
- &StartLineSensorThreadPositioning, /* (4) */
- (NTFY_MSK_PS_PSMSHADOW_AVAILABILITY), /* (5) */
- (NTFY_MSK_NONE), /* (6) */
- THREAD_STS_MSK_POS_MAIN, /* (7) */
- FALSE, /* (8) */
- THREAD_STS_NOEXIST, /* (9) */
- 0 /* (10) */
- },
- { /* Pos_gps */
- ETID_POS_GPS, /* (1) */
- kThreadNamePosGps, /* (2) */
- PNO_NAVI_GPS_MAIN, /* (3) */
- &StartGpsMainThreadPositioning, /* (4) */
- (NTFY_MSK_NONE), /* (5) */
- (NTFY_MSK_NONE), /* (6) */
- THREAD_STS_MSK_POS_MAIN, /* (7) */
- TRUE, /* (8) */
- THREAD_STS_NOEXIST, /* (9) */
- 0 /* (10) */
- },
- { /* Pos_gps_recv */
- ETID_POS_GPS_RECV, /* (1) */
- kThreadNamePosGpsRecv, /* (2) */
- PNO_NAVI_GPS_RCV, /* (3) */
- &StartGpsRecvThreadPositioning, /* (4) */
- (NTFY_MSK_NONE), /* (5) */
- (NTFY_MSK_NONE), /* (6) */
- THREAD_STS_MSK_POS_GPS, /* (7) */
- FALSE, /* (8) */
- THREAD_STS_NOEXIST, /* (9) */
- 0 /* (10) */
- },
- { /* Pos_gps_rollover */
- ETID_POS_GPS_ROLLOVER, /* (1) */
- kThreadNamePosGpsRollover, /* (2) */
- PNO_CLK_GPS, /* (3) */
- &StartGpsRolloverThreadPositioning, /* (4) */
- (NTFY_MSK_NS_BACKUPMGR_AVAILABILITY), /* (5) */
- (NTFY_MSK_NONE), /* (6) */
- THREAD_STS_MSK_POS_GPS, /* (7) */
- FALSE, /* (8) */
- THREAD_STS_NOEXIST, /* (9) */
- 0 /* (10) */
- },
- { /* Termination */
- ETID_POS_MAX, NULL, 0, NULL, NTFY_MSK_NONE, NTFY_MSK_NONE, 0, FALSE, THREAD_STS_NOEXIST, 0
- },
-};
-
-/* State Management Variables */
-static bool g_start_flg = false; /** Start Processed Flag */
-static EnumExeSts_POS g_exe_sts; /** Positioning running status */
-static EnumSetupMode_POS g_setup_mode; /** Thread activation mode */
-static uint8_t g_last_thread_sts; /** Latest internal thread activation state */
-static uint8_t g_last_srv_sts; /** Latest service availability */
-static uint8_t g_last_ntfy_sts; /** Receive state of latest notification */
-static uint8_t g_last_num_of_thread; /** Number of Current Startup Threads */
-
-/** Sub-thread creation table */
-static ST_THREAD_CREATE_INFO* g_pos_thread_create_info;
-
-/** Interprocess message receive buffer */
-static uint8_t g_rcv_msg_buf[MAX_MSG_BUF_SIZE];
-
-/** Dispatcher Registration Callback Table */
-static const FrameworkunifiedProtocolCallbackHandler kPositioningPcbhs[] = { // LCOV_EXCL_BR_LINE 11: unexpected branch
- {CID_THREAD_CREATE_COMP, &PosThreadCreateComp }, /* Thread start completion notification */
- {CID_THREAD_STOP_COMP, &PosThreadStopComp }, /* Thread stop completion notice */
- {CID_SENSORIF_PKG_DELIVERY_ENTRY_EXT, &PosPosifRegisterListenerPkgSensorData},
- {CID_VEHICLEIF_DELIVERY_ENTRY, &PosPosifRegisterListenerSensorData },
- {CID_SENSORIF__CWORD82__REQUEST, &PosPosifReqGpsSetting },
- {CID_NAVIINFO_DELIVER, &PosPosifSetGpsInfo },
- {CID_VEHICLEIF_GET_VEHICLE_DATA, &PosPosifGetGpsInfo },
- {CID_POSIF_SET_DATA, &PosPosifSetData },
- {CID_GPS_REQRESET, &PosPosifReqGpsReset },
-};
-
-static const FrameworkunifiedProtocolCallbackHandler kPositioningPcbhsVehicle[] = { // LCOV_EXCL_BR_LINE 11: unexpected branch
- {CID_VEHICLESENS_VEHICLE_INFO, &PosVehicleInfoRcv},
-};
-
-/** Dispatcher unregister command ID table */
-static uint32_t g_positioning_cids[] = {
- CID_THREAD_CREATE_COMP,
- CID_THREAD_STOP_COMP,
- CID_SENSORIF_PKG_DELIVERY_ENTRY_EXT,
- CID_VEHICLEIF_DELIVERY_ENTRY,
- CID_SENSORIF__CWORD82__REQUEST,
- CID_NAVIINFO_DELIVER,
- CID_VEHICLEIF_GET_VEHICLE_DATA,
- CID_POSIF_SET_DATA,
- CID_GPS_REQRESET,
-};
-
-static uint32_t g_positioning_cids_vehicle[] = {
- CID_VEHICLESENS_VEHICLE_INFO,
-};
-
-
-
-/** Stop request flag for GPS reception thread */
-BOOL g_thread_stop_req;
-
-/*---------------------------------------------------------------------------------*
- * Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * FrameworkunifiedOnInitialization<br>
- * Sends message to Notification Service
- *
- * Mm 21 API perform initialization.<br>
- * Generatings shared memories used by Vehicle function block..<br>
- * Creates a sub-thread of the Vehicle feature block..
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- * eFrameworkunifiedStatusFail ABENDs
- */
-EFrameworkunifiedStatus FrameworkunifiedOnInitialization(HANDLE h_app) {
- RET_API ret_api;
- EFrameworkunifiedStatus e_status = eFrameworkunifiedStatusOK;
- uint8_t* p_last_srv_sts = &g_last_srv_sts;
- uint8_t* p_last_thread_sts = &g_last_thread_sts;
- uint8_t* p_last_ntfy_sts = &g_last_ntfy_sts;
- ST_THREAD_CREATE_INFO** pp_thr_cre_info = &g_pos_thread_create_info;
- uint8_t* p_last_num_thr = &g_last_num_of_thread;
- BOOL* p_thr_stop_req = &g_thread_stop_req;
- EnumExeSts_POS* p_exe_sts = &g_exe_sts;
- EnumSetupMode_POS* pe_mode = &g_setup_mode;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- /* Global variable initialization */
- *p_last_srv_sts = 0;
- *p_last_thread_sts = 0;
- *p_last_ntfy_sts = 0;
- *pp_thr_cre_info = g_pos_thread_create_info_Grade1;
- *p_last_num_thr = 0;
- *p_thr_stop_req = FALSE;
- *p_exe_sts = EPOS_EXE_STS_STOP;
- *pe_mode = EPOS_SETUP_MODE_NORMAL;
-
- /* null check */
- if (h_app == NULL) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "h_app is NULL");
- e_status = eFrameworkunifiedStatusFail;
- } else {
- /* Positioning Base API initialization */
- ret_api = _pb_Setup_CWORD64_API(h_app);
- if (ret_api != RET_NORMAL) { // LCOV_EXCL_BR_LINE 4: can not return error
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "_pb_Setup_CWORD64_API ERROR!! [ret_api = %d]",
- ret_api);
-
- e_status = eFrameworkunifiedStatusFail;
- // LCOV_EXCL_STOP
- } else {
- /* Availability at Positioning startup,Set internal thread activation state */
- if (ChkUnitType(UNIT_TYPE_GRADE1) == true) { /* GRADE1 environment */
- *pp_thr_cre_info = g_pos_thread_create_info_Grade1;
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__,
- "*pp_thr_cre_info = g_pos_thread_create_info_Grade1");
- } else if (ChkUnitType(UNIT_TYPE_GRADE2) == true) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "_pb_ChkUnitType UNKNOWN!!");
- }
-
- /* Shared Memory Creation */
- PosCreateSharedMemory();
-
- if (e_status == eFrameworkunifiedStatusOK) {
- /* Register callback functions for Positioning internals */
- e_status = FrameworkunifiedAttachCallbacksToDispatcher(h_app,
- "NS_ANY_SRC",
- kPositioningPcbhs,
- _countof(kPositioningPcbhs)); // LCOV_EXCL_BR_LINE 4:nsfw error
- if (e_status != eFrameworkunifiedStatusOK) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedAttachCallbacksToDispatcher ERROR!! [e_status = %d]", e_status);
- }
-
- (void)VehicleIfAttachCallbacksToDispatcher(kPositioningPcbhsVehicle,
- _countof(kPositioningPcbhsVehicle));
- }
-
- if (e_status == eFrameworkunifiedStatusOK) { // LCOV_EXCL_BR_LINE 4: nsfw error
- /* Positioning/Availability registration */
- e_status = FrameworkunifiedRegisterServiceAvailabilityNotification(h_app, POS_AVAILABILITY);
- if (eFrameworkunifiedStatusOK != e_status) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedRegisterServiceAvailabilityNotification ERROR!! [e_status = %d]", e_status);
- }
- }
-
- if (e_status == eFrameworkunifiedStatusOK) { // LCOV_EXCL_BR_LINE 4: nsfw error
- /* Positioning/Availability -> FALSE */
- e_status = FrameworkunifiedPublishServiceAvailability(h_app, FALSE);
- if (eFrameworkunifiedStatusOK != e_status) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedPublishServiceAvailability ERROR!! [e_status = %d]", e_status);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "Positioning/Availability -> FALSE");
- }
- }
-
- /* Communication/Availability Changing notification registration */
- FrameworkunifiedSubscribeNotificationWithCallback(h_app, NTFY_Communication_Availability, &PosNotifyCommunicationAvailability); // LCOV_EXCL_BR_LINE 6: not a branch // NOLINT(whitespace/line_length)
-
- /* PS_CommUSB/Availability Changing notification registration */
- (void)CommUsbIfNotifyOnCommUSBAvailability(&PosNotifyCommUSBAvailability); // LCOV_EXCL_BR_LINE 6: not a branch // NOLINT(whitespace/line_length)
-
- /* PS_PSMShadow/Availability Changing notification registration */
- (void)PSMShadowIfNotifyOnPSMShadowAvailability(&PosNotifyPSMShadowAvailability); // LCOV_EXCL_BR_LINE 6: not a branch // NOLINT(whitespace/line_length)
- /* PS_PSMShadow Startup completion notification registration */
- (void)PSMShadowIfNotifyOnPSMShadowInitComp(&PosNotifyPSMShadowInitComp); // LCOV_EXCL_BR_LINE 6: not a branch // NOLINT(whitespace/line_length)
-
- /* Clock/Availability Changing notification registration */
- (void)ClockIfNotifyOnClockAvailability(&PosNotifyClockAvailability); // LCOV_EXCL_BR_LINE 6: not a branch // NOLINT(whitespace/line_length)
-
- /* NS_BackupMgr/Availability Changing notification registration */
- (void)BackupMgrIfNotifyOnBackupMgrAvailability(&PosNotifyNSBackupMgrAvailability); // LCOV_EXCL_BR_LINE 6: not a branch // NOLINT(whitespace/line_length)
-
- /* Regist Vehilce Availability Notification */
- (void)VehicleIfNotifyOnVehicleAvailability(&PosNotifyVehicleAvailability); // LCOV_EXCL_BR_LINE 6: not a branch // NOLINT(whitespace/line_length)
-
- /* DeviceDetectionServiceIf initialization */
- if (DevDetectSrvIfInitialize() == eFrameworkunifiedStatusOK) {
- /* SS_DevDetectSrv/Availability Changing notification registration */
- (void)DevDetectSrvIfNotifyOnDeviceDetectionAvailability(&PosNotifyDevDetectSrvAvailability); // LCOV_EXCL_BR_LINE 6: not a branch // NOLINT(whitespace/line_length)
- }
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- return e_status;
-}
-
-/**
- * @brief
- * PositioningOnStartImpl
- */
-static EFrameworkunifiedStatus PositioningOnStartImpl(const HANDLE hApp, const EPWR_SC_WAKEUP_TYPE wakeupType,
- const ESMDataResetModeInfo dataResetMode) {
- EnumExeSts_POS* p_exe_sts = &g_exe_sts;
- EnumSetupMode_POS* pe_mode = &g_setup_mode;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- if (g_start_flg == false) {
- g_start_flg = true;
-
- /* Running */
- *p_exe_sts = EPOS_EXE_STS_RUNNING;
-
- /* Cold start */
- if (wakeupType == epsstCOLDSTART) {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "wakeupType:COLDSTART");
-
- *p_exe_sts = EPOS_EXE_STS_RUNNING_COLDSTART;
-
- /* Initialize GPS time setting information */
- PosBackupDataInit();
- } else { /* Time of warm start */
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "wakeupType:WARMSTART");
- }
-
- /* Time of factory initialization */
- if (dataResetMode == e_SS_SM_DATA_RESET_MODE_FACTORY) {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "dataResetMode:FACTORYRESET");
-
- /* Set thread start mode to ""data reset start"" */
- *pe_mode = EPOS_SETUP_MODE_DATA_RESET;
-
- /* Initialize GPS time setting information */
- PosBackupDataInit();
- }
-
- PosCreateThread(hApp);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * FrameworkunifiedOnStart
- */
-EFrameworkunifiedStatus FrameworkunifiedOnStart(HANDLE hApp) {
- EFrameworkunifiedStatus ret = eFrameworkunifiedStatusFail;
- uint32_t size;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- size = PosGetMsg(hApp, reinterpret_cast<void**>(&g_rcv_msg_buf), MAX_MSG_BUF_SIZE);
- if (size != 0) {
- T_SS_SM_START_DataStructType* p_start_data;
- p_start_data = reinterpret_cast<T_SS_SM_START_DataStructType*>(g_rcv_msg_buf);
-
- ret = PositioningOnStartImpl(hApp, p_start_data->wakeupType, p_start_data->dataResetMode);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
- return ret;
-}
-
-/**
- * @brief
- * FrameworkunifiedOnStop
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- * eFrameworkunifiedStatusFail ABENDs
- */
-EFrameworkunifiedStatus FrameworkunifiedOnStop(HANDLE h_app) {
- EFrameworkunifiedStatus e_status;
- EnumExeSts_POS* p_exe_sts = &g_exe_sts;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- /* null check */
- if (h_app == NULL) { // LCOV_EXCL_BR_LINE 200: can not NULL
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "h_app is NULL");
- // LCOV_EXCL_STOP
- } else {
- *p_exe_sts = EPOS_EXE_STS_STOP;
-
- e_status = FrameworkunifiedPublishServiceAvailability(h_app, FALSE);
- if (eFrameworkunifiedStatusOK != e_status) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedPublishServiceAvailability ERROR!! [e_status = %d]",
- e_status);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "Positioning/Availability -> FALSE");
- }
-
- PosStopThread();
-
- g_start_flg = false;
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- /* Return end response to SM at timing after completion of internal thread stop */
- return eFrameworkunifiedStatusFail;
-}
-
-/**
- * @brief
- * FrameworkunifiedOnPreStart
- */
-EFrameworkunifiedStatus FrameworkunifiedOnPreStart(HANDLE hApp) {
- EFrameworkunifiedStatus ret = eFrameworkunifiedStatusFail;
- uint32_t size;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- size = PosGetMsg(hApp, reinterpret_cast<void**>(&g_rcv_msg_buf), MAX_MSG_BUF_SIZE);
- if (size != 0) {
- T_SS_SM_START_DataStructType* p_start_data;
- p_start_data = reinterpret_cast<T_SS_SM_START_DataStructType*>(g_rcv_msg_buf);
-
- ret = PositioningOnStartImpl(hApp, p_start_data->wakeupType, p_start_data->dataResetMode);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
- return ret;
-}
-
-/**
- * @brief
- * FrameworkunifiedOnPreStop
- */
-EFrameworkunifiedStatus FrameworkunifiedOnPreStop(HANDLE hApp) {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * FrameworkunifiedOnBackgroundStart
- */
-EFrameworkunifiedStatus FrameworkunifiedOnBackgroundStart(HANDLE hApp) {
- EFrameworkunifiedStatus ret = eFrameworkunifiedStatusFail;
- uint32_t size;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- size = PosGetMsg(hApp, reinterpret_cast<void**>(&g_rcv_msg_buf), MAX_MSG_BUF_SIZE);
- if (size != 0) {
- T_SS_SM_START_DataStructType* p_start_data;
- p_start_data = reinterpret_cast<T_SS_SM_START_DataStructType*>(g_rcv_msg_buf);
-
- ret = PositioningOnStartImpl(hApp, p_start_data->wakeupType, p_start_data->dataResetMode);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
- return ret;
-}
-
-/**
- * @brief
- * FrameworkunifiedOnBackgroundStop
- */
-EFrameworkunifiedStatus FrameworkunifiedOnBackgroundStop(HANDLE hApp) {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * FrameworkunifiedOnDestroy (Not mounted)
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- * eFrameworkunifiedStatusFail ABENDs
- */
-EFrameworkunifiedStatus FrameworkunifiedOnDestroy(HANDLE h_app) { // LCOV_EXCL_START 14 Resident process, not called by NSFW
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
- return eFrameworkunifiedStatusOK;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * FrameworkunifiedOnDebugDump
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- * eFrameworkunifiedStatusFail ABENDs
- */
-EFrameworkunifiedStatus FrameworkunifiedOnDebugDump(HANDLE h_app) { // LCOV_EXCL_START 7: debug code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- static uint8_t buf_tmp[256];
- static uint8_t buf_proc[128];
- static uint8_t buf_thread[512];
- static uint8_t buf_message[4][DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_mutex[3][DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_timer[DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_event[9][DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_memory[DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_other[DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_nand[256];
- static uint8_t buf_ram[256];
- static uint8_t buf_gps_format_fail[512];
- static uint8_t buf_antenna[256];
- static uint8_t buf_gps_info[DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_navi_info[DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_deli_ctrl_tbl[DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_deli_ctrl_tbl_mng[DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_pkg_deli_tbl_mng[DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_deli_pno_tbl[DEBUG_DUMP_MAX_SIZE];
- static uint8_t buf_sys[128];
- int32_t i;
- ST_THREAD_CREATE_INFO* p_thr_cre_info = g_pos_thread_create_info;
- ST_GPS_FIX_CNT st_gps_fix_cnt;
- ST_GPS_SET_TIME st_gps_set_time;
- uint8_t len_msg = 4;
- uint8_t len_mtx = 3;
- uint8_t len_evt = 9;
- EFrameworkunifiedStatus e_status;
- BOOL b_is_available;
- UNIT_TYPE e_type = UNIT_TYPE_NONE;
- u_int8 sys_recv_flg;
- uint16_t wkn_rollover;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- memset(&buf_proc[0], 0x00, sizeof(buf_proc));
- memset(&buf_thread[0], 0x00, sizeof(buf_thread));
- memset(&buf_nand[0], 0x00, sizeof(buf_nand));
- memset(&buf_ram[0], 0x00, sizeof(buf_ram));
- memset(&buf_gps_format_fail[0], 0x00, sizeof(buf_gps_format_fail));
- memset(&buf_antenna[0], 0x00, sizeof(buf_antenna));
- memset(&buf_gps_info[0], 0x00, sizeof(buf_gps_info));
- memset(&buf_navi_info[0], 0x00, sizeof(buf_navi_info));
- memset(&buf_deli_ctrl_tbl[0], 0x00, sizeof(buf_deli_ctrl_tbl));
- memset(&buf_deli_ctrl_tbl_mng[0], 0x00, sizeof(buf_deli_ctrl_tbl_mng));
- memset(&buf_pkg_deli_tbl_mng[0], 0x00, sizeof(buf_pkg_deli_tbl_mng));
- memset(&buf_deli_pno_tbl[0], 0x00, sizeof(buf_deli_pno_tbl));
- memset(&buf_sys[0], 0x00, sizeof(buf_sys));
-
- for (i = 0; i < len_msg; i++) {
- memset(&buf_message[i][0], 0x00, sizeof(buf_message[i]));
- }
- for (i = 0; i < len_mtx; i++) {
- memset(&buf_mutex[i][0], 0x00, sizeof(buf_mutex[i]));
- }
- memset(&buf_timer[0], 0x00, sizeof(buf_timer));
- for (i = 0; i < len_evt; i++) {
- memset(&buf_event[i][0], 0x00, sizeof(buf_event[i]));
- }
- memset(&buf_memory[0], 0x00, sizeof(buf_memory));
- memset(&buf_other[0], 0x00, sizeof(buf_other));
- e_type = GetEnvSupportInfo();
-
- /* Availability status of related processes */
- snprintf(reinterpret_cast<char *>(&buf_proc[0]), sizeof(buf_proc),
- "Availability\n thread:0x%02x, srv:0x%02x, ntfy:0x%02x",
- g_last_thread_sts, /* Latest internal thread activation state */
- g_last_srv_sts, /* Latest service availability */
- g_last_ntfy_sts); /* Receive state of latest notification */
-
- /* Internal thread activation state */
- snprintf(reinterpret_cast<char *>(&buf_thread[0]), sizeof(buf_thread), "Thread");
- for (i = 0; i < ETID_POS_MAX; i++) {
- memset(&buf_tmp[0], 0x00, sizeof(buf_tmp));
- snprintf(reinterpret_cast<char *>(&buf_tmp[0]), sizeof(buf_tmp),
- "\n [%d]id:%d, pno:0x%04x, name:%16s, sts:0x%02x, order:%d",
- i,
- p_thr_cre_info->id, /* Thread ID */
- p_thr_cre_info->pno, /* Process number */
- p_thr_cre_info->p_name, /* Thread name */
- p_thr_cre_info->status, /* Thread activation state */
- p_thr_cre_info->order); /* Boot Sequence */
- _pb_strcat(reinterpret_cast<char *>(&buf_thread[0]), reinterpret_cast<char *>(&buf_tmp[0]), sizeof(buf_tmp));
- p_thr_cre_info++;
- }
-
- /* BASE API control data */
- /* Message */
- (void)_pb_GetDebugMsgMngTbl(&buf_message[0][0], &len_msg);
- /* Mutex */
- (void)_pb_GetDebugMutexMngTbl(&buf_mutex[0][0], &len_mtx);
- /* Timer */
- (void)_pb_GetDebugTimerMngTbl(&buf_timer[0]);
- /* Event */
- (void)_pb_GetDebugEventMngTbl(&buf_event[0][0], &len_evt);
- /* Shared Memory */
- (void)_pb_GetDebugMemoryMngTbl(&buf_memory[0]);
- /* Other */
- (void)_pb_GetDebugOtherMngTbl(&buf_other[0]);
-
- /* NAND data */
- snprintf(reinterpret_cast<char *>(&buf_nand[0]), sizeof(buf_nand), "NAND");
- /* GPS fix count */
- memset(&buf_tmp[0], 0x00, sizeof(buf_tmp));
- memset(&st_gps_fix_cnt, 0x00, sizeof(st_gps_fix_cnt));
-
- e_status = BackupMgrIfBackupDataRd(D_BK_ID_POS_GPS_FIX_CNT,
- 0,
- &st_gps_fix_cnt,
- sizeof(st_gps_fix_cnt), &b_is_available);
- snprintf(reinterpret_cast<char *>(&buf_tmp[0]), sizeof(buf_tmp),
- "\n %20s rd:0x%08x av:%d, 3d:%d, 2d:%d, else:%d, dmy:0x%02x%02x%02x%02x",
- "GPS_FIX_CNT",
- e_status,
- b_is_available,
- st_gps_fix_cnt.ul3d,
- st_gps_fix_cnt.ul2d,
- st_gps_fix_cnt.ul_else,
- st_gps_fix_cnt.dummy[0], st_gps_fix_cnt.dummy[1], st_gps_fix_cnt.dummy[2], st_gps_fix_cnt.dummy[3]);
- _pb_strcat(reinterpret_cast<char *>(&buf_nand[0]), reinterpret_cast<char *>(&buf_tmp[0]), sizeof(buf_tmp));
-
- /* Data of the backup RAM */
- snprintf(reinterpret_cast<char *>(&buf_ram[0]), sizeof(buf_ram), "BackupRAM");
- /* Set GPS date and time(Information) */
- memset(&buf_tmp[0], 0x00, sizeof(buf_tmp));
- (void)memset( reinterpret_cast<void *>(&st_gps_set_time), 0, (size_t)sizeof(st_gps_set_time) );
-
- e_status = BackupMgrIfBackupDataRd(D_BK_ID_POS_GPS_TIME_SET_INFO,
- 0,
- &st_gps_set_time,
- sizeof(st_gps_set_time),
- &b_is_available);
- snprintf(reinterpret_cast<char *>(&buf_tmp[0]), sizeof(buf_tmp),
- "\n %20s rd:0x%08x av:%d, %d/%d/%d %d:%d:%d flag:0x%02x",
- "GPS_TIME_SET_INFO",
- e_status,
- b_is_available,
- st_gps_set_time.year,
- st_gps_set_time.month,
- st_gps_set_time.date,
- st_gps_set_time.hour,
- st_gps_set_time.minute,
- st_gps_set_time.second,
- st_gps_set_time.flag);
- _pb_strcat(reinterpret_cast<char *>(&buf_ram[0]), reinterpret_cast<char *>(&buf_tmp[0]), sizeof(buf_tmp));
-
- if (e_type == UNIT_TYPE_GRADE1) {
- /* GPS format anomaly counter */ /* There is no lock control. */
- (void)DEVGpsGetDebugGpsFormatFailCnt(&buf_gps_format_fail[0]);
-
- /* GPS antenna connection status */ /* There is no lock control. */
- VEHICLESENS_DATA_MASTER st_sns_data = {0};
- (void)VehicleSensGetGpsAntenna(&st_sns_data, VEHICLESENS_GETMETHOD_LINE);
- snprintf(reinterpret_cast<char *>(&buf_antenna[0]), sizeof(buf_antenna),
- "Antenna\n sts:0x%02x",
- st_sns_data.uc_data[0]);
-
- /* GPS position time */ /* There is no lock control. */
- (void)VehicleSensGetDebugPosDate(&buf_gps_info[0], VEHICLESENS_GETMETHOD_GPS);
- }
-
- if (e_type == UNIT_TYPE_GRADE1) {
- /* Navigation position time */ /* There is no lock control. */
- (void)VehicleSensGetDebugPosDate(&buf_navi_info[0], VEHICLESENS_GETMETHOD_NAVI);
- }
-
- /* Delivery table */ /* There is no lock control. */
- (void)VehicleSensGetDebugDeliveryCtrlTbl(&buf_deli_ctrl_tbl[0]);
- (void)VehicleSensGetDebugDeliveryCtrlTblMng(&buf_deli_ctrl_tbl_mng[0]);
- (void)VehicleSensGetDebugPkgDeliveryTblMng(&buf_pkg_deli_tbl_mng[0]);
- (void)VehicleSensGetDebugDeliveryPnoTbl(&buf_deli_pno_tbl[0]);
-
- /* Initial Sensor Data Status from Sys */
- sys_recv_flg = LineSensDrvGetSysRecvFlag();
- snprintf(reinterpret_cast<char *>(&buf_sys[0]), sizeof(buf_sys),
- "Rx 1st Sensor Data %d\n", sys_recv_flg);
-
- /* Dump Information Out */
- PosOutputDebugDumpLog(&buf_proc[0]);
- PosOutputDebugDumpLog(&buf_thread[0]);
- for (i = 0; i < len_msg; i++) {
- PosOutputDebugDumpLog(&buf_message[i][0]);
- }
- for (i = 0; i < len_mtx; i++) {
- PosOutputDebugDumpLog(&buf_mutex[i][0]);
- }
- PosOutputDebugDumpLog(&buf_timer[0]);
- for (i = 0; i < len_evt; i++) {
- PosOutputDebugDumpLog(&buf_event[i][0]);
- }
- PosOutputDebugDumpLog(&buf_memory[0]);
- PosOutputDebugDumpLog(&buf_other[0]);
- PosOutputDebugDumpLog(&buf_nand[0]);
- PosOutputDebugDumpLog(&buf_ram[0]);
- if (e_type == UNIT_TYPE_GRADE1) {
- PosOutputDebugDumpLog(&buf_gps_format_fail[0]);
- PosOutputDebugDumpLog(&buf_antenna[0]);
- PosOutputDebugDumpLog(&buf_gps_info[0]);
- }
- if (e_type == UNIT_TYPE_GRADE1) {
- PosOutputDebugDumpLog(&buf_navi_info[0]);
- }
- PosOutputDebugDumpLog(&buf_deli_ctrl_tbl[0]);
- PosOutputDebugDumpLog(&buf_deli_ctrl_tbl_mng[0]);
- PosOutputDebugDumpLog(&buf_pkg_deli_tbl_mng[0]);
- PosOutputDebugDumpLog(&buf_deli_pno_tbl[0]);
- PosOutputDebugDumpLog(&buf_sys[0]);
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
- return eFrameworkunifiedStatusOK;
-}
-// LCOV_EXCL_STOP
-
-/**
- * @brief
- * FrameworkunifiedCreateStateMachine (Not mounted)
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- * eFrameworkunifiedStatusFail ABENDs
- */
-EFrameworkunifiedStatus FrameworkunifiedCreateStateMachine(HANDLE h_app) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
- return eFrameworkunifiedStatusOK;
-}
-// LCOV_EXCL_STOP
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-/**
- * @brief
- * Common processing after thread startup
- *
- * Thread naming,Create Message Queue,Thread activation response
- *
- * @param[in] h_app Application handle
- * @param[in] e_tid Thread ID
- *
- * @return Thread activation mode
- */
-EnumSetupMode_POS PosSetupThread(HANDLE h_app, EnumTID_POS e_tid) {
- RET_API ret;
- ST_THREAD_CREATE_INFO* p_thr_cre_info = g_pos_thread_create_info;
- ST_THREAD_CREATE_INFO* p_info;
- ST_THREAD_SETUP_INFO st_setup_info;
- ST_THREAD_SETUP_INFO* pst_setup_info = &st_setup_info;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- p_info = p_thr_cre_info + e_tid;
-
- /* Application handle setting */
- _pb_SetAppHandle(h_app);
-
- /* Create Message Queue */
- _pb_CreateMsg(p_info->pno);
-
- /* Get Thread Startup Information */
- pst_setup_info->e_mode = EPOS_SETUP_MODE_NORMAL;
- (void)PosGetMsg(h_app, reinterpret_cast<void**>(&pst_setup_info), sizeof(ST_THREAD_SETUP_INFO));
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "[e_mode = %d]", pst_setup_info->e_mode);
-
- /* Issue thread creation completion notice */
- ret = _pb_SndMsg_Ext(POS_THREAD_NAME, CID_THREAD_CREATE_COMP, sizeof(EnumTID_POS), (const void*)&e_tid, 0);
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SndMsg_Ext ERROR!! [ret = %d]", ret);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- return pst_setup_info->e_mode;
-}
-
-/**
- * @brief
- * Common Processing at Thread Stop
- *
- * Thread stop response,Thread destruction
- *
- * @param[in] e_tid Thread ID
- */
-void PosTeardownThread(EnumTID_POS e_tid) {
- RET_API ret;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- /* Issue thread stop completion notice */
- ret = _pb_SndMsg_Ext(POS_THREAD_NAME, CID_THREAD_STOP_COMP, sizeof(EnumTID_POS), (const void*)&e_tid, 0);
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SndMsg_Ext ERROR!! [ret = %d]", ret);
- }
-
- /* Thread destruction */
- _pb_ExitThread((DWORD)0);
-
- /* don't arrive here */
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- return; // LCOV_EXCL_LINE 8 : cannot reach here
-}
-
-#ifdef __cplusplus
-}
-#endif
-
-/**
- * @brief
- * FrameworkunifiedCreateChildThread dummy functions
- *
- * @param[in] Application handle
- *
- * @return eFrameworkunifiedStatusOK successful completion
- */
-static EFrameworkunifiedStatus PosStopThreadDummy(HANDLE h_app) { // LCOV_EXCL_START 8 : dead code
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
- return eFrameworkunifiedStatusOK;
-}
-// LCOV_EXCL_STOP
-
-/*---------------------------------------------------------------------------------*
- * Local Function *
- *---------------------------------------------------------------------------------*/
-/**
- * @brief
- * Communication services Availability notification callback functions
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosNotifyCommunicationAvailability(HANDLE h_app) {
- BOOL isAvailable;
- uint8_t* pLastSrvSts = &g_last_srv_sts;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- isAvailable = FrameworkunifiedIsServiceAvailable(h_app);
- if (isAvailable == TRUE) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Communication/Availability -> TRUE");
-
- *pLastSrvSts |= NTFY_MSK_COMMUNICATION_AVAILABILITY;
-
- PosCreateThread(h_app);
-
- /* Sensor Log Initial Processing(First)*/
- SensLogInitialize(NULL);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Communication/Availability -> FALSE");
-
- *pLastSrvSts = static_cast<uint8_t>(*pLastSrvSts & ~NTFY_MSK_COMMUNICATION_AVAILABILITY);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * CommUSB services Availability notification callback functions
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosNotifyCommUSBAvailability(HANDLE h_app) {
- BOOL isAvailable;
- uint8_t* pLastSrvSts = &g_last_srv_sts;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- isAvailable = FrameworkunifiedIsServiceAvailable(h_app);
- if (isAvailable == TRUE) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PS_CommUSB/Availability -> TRUE");
-
- *pLastSrvSts |= NTFY_MSK_PS_COMMUSB_AVAILABILITY;
-
- PosCreateThread(h_app);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PS_CommUSB/Availability -> FALSE");
-
- *pLastSrvSts = static_cast<uint8_t>(*pLastSrvSts & ~NTFY_MSK_PS_COMMUSB_AVAILABILITY);
- }
-
- /* Update CommUSB I/F availability */
- CommUsbIfSetAvailability(isAvailable);
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * PSMShadow services Availability notification callback functions
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosNotifyPSMShadowAvailability(HANDLE h_app) {
- BOOL isAvailable;
- uint8_t* pLastSrvSts = &g_last_srv_sts;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- isAvailable = FrameworkunifiedIsServiceAvailable(h_app);
- if (isAvailable == TRUE) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PS_PSMShadow/Availability -> TRUE");
-
- *pLastSrvSts |= NTFY_MSK_PS_PSMSHADOW_AVAILABILITY;
-
- PosCreateThread(h_app);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PS_PSMShadow/Availability -> FALSE");
-
- *pLastSrvSts = static_cast<uint8_t>(*pLastSrvSts & ~NTFY_MSK_PS_PSMSHADOW_AVAILABILITY);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * PSMShadow services Callback function for notifying completion of startup
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosNotifyPSMShadowInitComp(HANDLE h_app) {
- uint8_t* pLastNtfySts = &g_last_ntfy_sts;
- ST_THREAD_CREATE_INFO* pThrCreInfo = g_pos_thread_create_info;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- *pLastNtfySts |= NTFY_MSK_PS_PSMSHADOW_INIT_COMP;
-
- /* When the Pos_Sens thread is started */
- if (((pThrCreInfo + ETID_POS_SENS)->status) == THREAD_STS_CREATED) {
- /* External pin status request */
- LineSensDrvExtTermStsReq();
- }
-
- PosCreateThread(h_app);
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Clock Services Availability Notification Callback Functions
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK successful completion
- */
-static EFrameworkunifiedStatus PosNotifyClockAvailability(HANDLE h_app) {
- BOOL isAvailable;
- uint8_t* pLastSrvSts = &g_last_srv_sts;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- isAvailable = FrameworkunifiedIsServiceAvailable(h_app);
- if (isAvailable == TRUE) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "Clock/Availability -> TRUE");
-
- *pLastSrvSts |= NTFY_MSK_CLOCK_AVAILABILITY;
-
- PosCreateThread(h_app);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "Clock/Availability -> FALSE");
-
- *pLastSrvSts = static_cast<uint8_t>(*pLastSrvSts & ~NTFY_MSK_CLOCK_AVAILABILITY);
- }
-
- /* Update Clock I/F availability */
- ClockIfSetAvailability(isAvailable);
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * NS_BackupMgr service Availability notification callback function
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK successful completion
- */
-static EFrameworkunifiedStatus PosNotifyNSBackupMgrAvailability(HANDLE h_app) {
- EnumExeSts_POS* pExeSts = &g_exe_sts;
- uint8_t* pLastSrvSts = &g_last_srv_sts;
- ST_THREAD_CREATE_INFO* pThrCreInfo = g_pos_thread_create_info;
- EnumSetupMode_POS* peMode = &g_setup_mode;
- BOOL bIsAvailable;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- bIsAvailable = FrameworkunifiedIsServiceAvailable(h_app);
-
- /* Update BackupMgr I/F availability */
- BackupMgrIfSetAvailability(bIsAvailable);
-
- if (bIsAvailable == TRUE) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "NS_BackupMgr/Availability -> TRUE");
-
- *pLastSrvSts |= NTFY_MSK_NS_BACKUPMGR_AVAILABILITY;
-
- /* Executing after cold start or during factory initialization*/
- if ((*pExeSts == EPOS_EXE_STS_RUNNING_COLDSTART) ||
- (*peMode == EPOS_SETUP_MODE_DATA_RESET)) {
- /* Backup RAM initialization */
- PosBackupDataInit();
- }
-
- /* When the GPS management thread is started */
- if (((pThrCreInfo + ETID_POS_GPS)->status) == THREAD_STS_CREATED) {
- if ((*pExeSts == EPOS_EXE_STS_RUNNING_COLDSTART) ||
- (*peMode == EPOS_SETUP_MODE_DATA_RESET)) {
- // GPS reset request.
- SENSOR_INTERNAL_MSG_BUF msg_buf = {};
- T_APIMSG_MSGBUF_HEADER *msg_hdr = &msg_buf.hdr;
- msg_hdr->hdr.cid = CID_GPS_REQRESET;
- msg_hdr->hdr.msgbodysize = sizeof(POS_RESETINFO);
- POS_RESETINFO *msg_data = reinterpret_cast<POS_RESETINFO *>(&msg_buf.data);
- msg_data->mode = GPS_RST_COLDSTART;
-
- RET_API ret = _pb_SndMsg(PNO_NAVI_GPS_MAIN, sizeof(msg_buf), &msg_buf, 0);
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "_pb_SndMsg ERROR!! [ret=%d]", ret);
- }
- }
-
- /* Backup data read request to GSP management thread */
- (void)DEVGpsSndBackupDataLoadReq();
- }
- /* Enable Diag Code Writing */
- DiagSrvIfSetRegistrationPermission(TRUE);
-
- PosCreateThread(h_app);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "NS_BackupMgr/Availability -> FALSE");
-
- *pLastSrvSts = static_cast<uint8_t>(*pLastSrvSts & ~NTFY_MSK_NS_BACKUPMGR_AVAILABILITY);
- /* Write prohibited dialog code */
- DiagSrvIfSetRegistrationPermission(FALSE);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * SS_DevDetectSrv service Availability Callback Functions
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK successful completion
- */
-static EFrameworkunifiedStatus PosNotifyDevDetectSrvAvailability(HANDLE h_app) {
- EFrameworkunifiedStatus eStatus = eFrameworkunifiedStatusOK;
- BOOL isAvailable;
- BOOL bDummy;
- uint8_t* pLastSrvSts = &g_last_srv_sts;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- isAvailable = FrameworkunifiedIsServiceAvailable(h_app);
-
- /* Update DevDetectSrv I/F availability */
- DevDetectSrvIfSetAvailability(isAvailable);
-
- if (isAvailable == TRUE) {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "SS_DevDetectSrv/Availability -> TRUE");
- *pLastSrvSts |= NTFY_MSK_SS_DEVDETSRV_AVAILABILITY;
-
- eStatus = DevDetectSrvIfOpenSessionRequest(&bDummy);
- if (eFrameworkunifiedStatusOK != eStatus) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "DeviceDetectionServiceIf OpenSession ERROR!! [eStatus = %d]", eStatus);
- } else {
- eStatus = DevDetectSrvIfNotifyOnOpenSessionAck(&PosOnDevDetectOpenSessionAck, &bDummy);
- if (eFrameworkunifiedStatusOK != eStatus) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "DeviceDetectionServiceIf NotifyOnOpenSessionAck ERROR!! [eStatus = %d]", eStatus);
- }
- }
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "SS_DevDetectSrv/Availability -> FALSE");
- *pLastSrvSts = static_cast<uint8_t>(*pLastSrvSts & ~NTFY_MSK_SS_DEVDETSRV_AVAILABILITY);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-
-/**
- * @brief
- * Vehicle Availability notification callback functions
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- *
- */
-static EFrameworkunifiedStatus PosNotifyVehicleAvailability(HANDLE h_app) {
- BOOL isAvailable;
- uint8_t* pLastSrvSts = &g_last_srv_sts;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- isAvailable = FrameworkunifiedIsServiceAvailable(h_app);
-
- /* Update Vechile I/F Abailability */
- VehicleIf_SetAvailability(isAvailable);
-
- if (isAvailable == TRUE) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "Vehicle/Availability -> TRUE");
-
- *pLastSrvSts |= NTFY_MSK_VS_VEHICLE_AVAILABILITY;
-
- if (eFrameworkunifiedStatusFail == VehicleIfDeliveryEntry(VEHICLE_DID_SPEED)) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "VehicleIfDeliveryEntry SPEED ERROR");
- }
-
- if (eFrameworkunifiedStatusFail == VehicleIfDeliveryEntry(VEHICLE_DID_REV)) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "VehicleIfDeliveryEntry REV ERROR");
- }
-
- if (eFrameworkunifiedStatusFail == VehicleIfDeliveryEntry(VEHICLE_DID_SPEED_PULSE_VEHICLE)) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "VehicleIfDeliveryEntry SPEED PULSE ERROR");
- }
-
- PosCreateThread(h_app);
-
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "Vehicle/Availability -> FALSE");
-
- *pLastSrvSts &= ~NTFY_MSK_VS_VEHICLE_AVAILABILITY;
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Shared Memory Creation for Positioning Function
- *
- * @return RET_NORMAL Normal completion
- * RET_ERROR ABENDs
- */
-static void PosCreateSharedMemory(void) {
- RET_API ret_api = RET_NORMAL;
- void *mod_exec_dmy; /* Module data pointer(dummy) */
- int retry; /* Retry counter */
- ST_SHAREDATA *p_shm_tbl;
-
- /* Configure Shared Data Generating Tables */
- p_shm_tbl = g_sharedata_tbl;
-
- while ( *(p_shm_tbl->share_data_name) != '\0' ) {
- for ( retry = 0; retry < DATMOD_RETRY; retry++ ) {
- /* Shared Memory Generation */
- ret_api = _pb_CreateShareData(p_shm_tbl->share_data_name, p_shm_tbl->data_size, &mod_exec_dmy);
- if (ret_api == RET_NORMAL) { /* If successful */
- /* Set the shared memory status flag to ""Before initialization (0)"" */
- *reinterpret_cast<u_int32 *>(mod_exec_dmy) = DATMOD_PREINIT;
-
- break;
- } else { /* In the event of failure */
- /* Error Handling */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "_pb_CreateShareData ERROR [ret_api:%d]",
- ret_api);
- }
- }
-
- if (retry >= DATMOD_RETRY) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_CreateShareData failed more %d times.",
- DATMOD_RETRY);
-
- _pb_Exit();
- /* don't arrive here. */
- }
-
- /* Next shared memory generation */
- p_shm_tbl++;
- }
-
- return;
-}
-
-/**
- * @brief
- * Positioning in-process thread creation
- *
- * @param[in] hApp application handles
- */
-static void PosCreateThread(HANDLE h_app) {
- HANDLE threadHandle;
- EFrameworkunifiedStatus eStatus = eFrameworkunifiedStatusOK;
- EnumSetupMode_POS* peMode = &g_setup_mode;
- int32_t i;
- uint8_t* pLastSrvSts = &g_last_srv_sts;
- uint8_t* pLastThreadSts = &g_last_thread_sts;
- uint8_t* pLastNtfySts = &g_last_ntfy_sts;
- EnumExeSts_POS* pExeSts = &g_exe_sts;
- ST_THREAD_CREATE_INFO* pThrCreInfo = g_pos_thread_create_info;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- for (i = 0; i < ETID_POS_MAX; i++) {
- if ((pThrCreInfo->status == THREAD_STS_NOEXIST) && (pThrCreInfo->routine != NULL)) {
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__,
- "i=%d, mskThread=0x%02x, *pLastThreadSts=0x%02x,"\
- "mskAvailable=0x%02x, *pLastSrvSts=0x%02x, mskNtfy=0x%02x, *pLastNtfySts=0x%02x",
- i,
- pThrCreInfo->msk_thread,
- *pLastThreadSts,
- pThrCreInfo->msk_available,
- *pLastSrvSts,
- pThrCreInfo->msk_ntfy,
- *pLastNtfySts);
-
- if ((*pExeSts != EPOS_EXE_STS_STOP)
- && ((((pThrCreInfo->msk_thread) & (*pLastThreadSts)) == pThrCreInfo->msk_thread)
- || (pThrCreInfo->msk_thread == 0))
- && ((((pThrCreInfo->msk_available) & (*pLastSrvSts)) == pThrCreInfo->msk_available)
- || (pThrCreInfo->msk_available == NTFY_MSK_NONE))
- && ((((pThrCreInfo->msk_ntfy) & (*pLastNtfySts)) == pThrCreInfo->msk_ntfy)
- || (pThrCreInfo->msk_ntfy == NTFY_MSK_NONE))) {
- if (pThrCreInfo->pno == PNO_LINE_SENS_DRV || \
- pThrCreInfo->pno == PNO_NAVI_GPS_MAIN || \
- pThrCreInfo->pno == PNO_NAVI_GPS_RCV ||
- pThrCreInfo->pno == PNO_CLK_GPS) {
- (pThrCreInfo->routine)(h_app);
- } else {
- /* Thread creation */
- threadHandle = FrameworkunifiedCreateChildThread(h_app,
- (PCSTR)(pThrCreInfo->p_name),
- pThrCreInfo->routine,
- &PosStopThreadDummy);
- if (threadHandle == NULL) { /* If the thread creation fails */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedCreateChildThread ERROR!! [tHandle=%p]",
- threadHandle);
- _pb_Exit();
- /* don't arrive here. */
- } else {
- /* Thread activation (Notify the startup mode) */
- eStatus = FrameworkunifiedStartChildThread(h_app,
- threadHandle,
- sizeof(EnumSetupMode_POS),
- reinterpret_cast<void*>(peMode));
- if (eStatus != eFrameworkunifiedStatusOK) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedStartChildThread ERROR!! [eStatus=%d, name=%s]",
- eStatus,
- pThrCreInfo->p_name);
- } else {
- pThrCreInfo->status = THREAD_STS_CREATING;
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "name=%s", pThrCreInfo->p_name);
- }
- }
- }
- }
- }
-
- pThrCreInfo++;
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- return;
-}
-
-
-/**
- * @brief
- * Termination of Positioning in-process threads
- */
-static void PosStopThread(void) {
- RET_API ret;
- ST_THREAD_CREATE_INFO* p_thr_cre_info = g_pos_thread_create_info;
- BOOL *p_thr_stop_req = &g_thread_stop_req;
- uint8_t uc_msg = 0;
- uint8_t uc_order = 0;
- PNO us_pno = 0;
- int32_t i;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- for (i = 0; i < ETID_POS_MAX; i++) {
- if (uc_order < p_thr_cre_info->order) {
- uc_order = p_thr_cre_info->order;
- us_pno = p_thr_cre_info->pno;
- }
- p_thr_cre_info++;
- }
-
- if (uc_order != 0) {
- /* Send Thread Termination Request */
- if (us_pno == PNO_NAVI_GPS_RCV) {
- /* Pos_gps_recv Only thread flag control */
- *p_thr_stop_req = TRUE;
- } else {
- ret = PosSndMsg(us_pno, CID_THREAD_STOP_REQ, &uc_msg, sizeof(uc_msg));
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "PosSndMsg ERROR!! [ret = %d]",
- ret);
- }
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- return;
-}
-
-/**
- * @brief
- * Backup RAM initialization
- */
-static void PosBackupDataInit(void) {
- UNIT_TYPE e_type = UNIT_TYPE_NONE;
- EFrameworkunifiedStatus e_status;
- BOOL b_is_available;
- ST_GPS_SET_TIME st_gps_set_time;
-
- (void)memset( reinterpret_cast<void *>(&st_gps_set_time), 0, (size_t)sizeof(st_gps_set_time) );
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- e_type = GetEnvSupportInfo();
- if (e_type == UNIT_TYPE_GRADE1) {
- /* Set GPS date and time */
- e_status = BackupMgrIfBackupDataWt(D_BK_ID_POS_GPS_TIME_SET_INFO,
- &st_gps_set_time,
- 0,
- sizeof(st_gps_set_time),
- &b_is_available);
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "D_BK_ID_POS_GPS_TIME_SET_INFO:W:Clear");
- if (e_status != eFrameworkunifiedStatusOK) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "BackupMgrIfBackupDataWt ERROR!! [e_status=%d, b_is_available=%d]",
- e_status,
- b_is_available);
- }
- } else if (e_type == UNIT_TYPE_GRADE2) {
- /*
- * Note.
- * This feature branches processing depending on the unit type.
- */
- } else {
- /* No processing */
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- return;
-}
-
-/**
- * @brief
- * Callback function for registering the dispatcher()
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosThreadCreateComp(HANDLE h_app) {
- EFrameworkunifiedStatus eStatus = eFrameworkunifiedStatusOK;
- uint8_t* pRcvMsg;
- uint32_t size;
- uint8_t* pLastThreadSts = &g_last_thread_sts;
- ST_THREAD_CREATE_INFO* pThrCreInfo = g_pos_thread_create_info;
- uint8_t* pLastNumThr = &g_last_num_of_thread;
- uint8_t* pLastSrvSts = &g_last_srv_sts;
- uint8_t* pLastNtfySts = &g_last_ntfy_sts;
- EnumTID_POS eTid;
- int32_t i;
- static BOOL isSetAvailable = FALSE;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- pRcvMsg = g_rcv_msg_buf;
-
- size = PosGetMsg(h_app, reinterpret_cast<void**>(&pRcvMsg), MAX_MSG_BUF_SIZE);
- if (size != 0) { // LCOV_EXCL_BR_LINE 4: nsfw error
- (*pLastNumThr)++;
-
- eTid = *(reinterpret_cast<EnumTID_POS*>(pRcvMsg));
-
- FRAMEWORKUNIFIEDLOG(ZONE_17, __FUNCTION__,
- "Get message = [Sender:%s][CID:0x%X]",
- (pThrCreInfo + eTid)->p_name,
- CID_THREAD_CREATE_COMP);
-
- /* Thread Management Variable Updates */
- *pLastThreadSts = static_cast<uint8_t>(*pLastThreadSts | (0x1u << eTid));
- (pThrCreInfo + eTid)->status = THREAD_STS_CREATED;
- (pThrCreInfo + eTid)->order = *pLastNumThr;
-
- /* Individual processing of started threads */
- switch (eTid) {
- case ETID_POS_SENS: /* When sensor driver thread startup is completed */
- {
- /* When PSMShadow startup completion notice has been received */
- if (((NTFY_MSK_PS_PSMSHADOW_INIT_COMP) & (*pLastNtfySts)) == NTFY_MSK_PS_PSMSHADOW_INIT_COMP) {
- /* External pin status request */
- LineSensDrvExtTermStsReq();
- }
- break;
- }
- case ETID_POS_GPS: /* When the GPS management thread has started */
- {
- /* NSBackupMgr/Availability=When TRUE notification has been received */
- if (((NTFY_MSK_NS_BACKUPMGR_AVAILABILITY) & (*pLastSrvSts)) == NTFY_MSK_NS_BACKUPMGR_AVAILABILITY) {
- /* Backup data read request to GSP management thread */
- (void)DEVGpsSndBackupDataLoadReq();
- }
- break;
- }
- default: /* Other thread startup completion time */
- break;
- }
-
- PosCreateThread(h_app);
-
- for (i = 0; i < ETID_POS_MAX; i++) {
- if ((pThrCreInfo->is_depended == TRUE) && (pThrCreInfo->status != THREAD_STS_CREATED)) {
- break; /* Positioning/Availability->TRUE condition does not meet */
- }
- pThrCreInfo++;
- }
-
- if ((i == ETID_POS_MAX) && (isSetAvailable == FALSE)) {
- /* Positionig/Availability -> TRUE */
- eStatus = FrameworkunifiedPublishServiceAvailability(h_app, TRUE);
- if (eFrameworkunifiedStatusOK != eStatus) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedPublishServiceAvailability ERROR!! [eStatus = %d]",
- eStatus);
- } else {
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "Positioning/Availability -> TRUE");
- isSetAvailable = TRUE;
- }
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-
-/**
- * @brief
- * Callback function for registering the dispatcher()
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosThreadStopComp(HANDLE h_app) {
- EFrameworkunifiedStatus eStatus;
- BOOL bIsAvailable;
-
- uint8_t* pRcvMsg;
- uint32_t size;
- uint8_t* pLastThreadSts = &g_last_thread_sts;
- ST_THREAD_CREATE_INFO* pThrCreInfo = g_pos_thread_create_info;
- uint8_t* pLastNumThr = &g_last_num_of_thread;
- BOOL *pThrStopReq = &g_thread_stop_req;
- EnumTID_POS eTid;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- pRcvMsg = g_rcv_msg_buf;
-
- size = PosGetMsg(h_app, reinterpret_cast<void**>(&pRcvMsg), MAX_MSG_BUF_SIZE);
- if (size != 0) { // LCOV_EXCL_BR_LINE 4: nsfw error
- (*pLastNumThr)--;
-
- eTid = *(reinterpret_cast<EnumTID_POS*>(pRcvMsg));
-
- FRAMEWORKUNIFIEDLOG(ZONE_17, __FUNCTION__,
- "Get message = [Sender:%s][CID:0x%X]",
- (pThrCreInfo + eTid)->p_name,
- CID_THREAD_STOP_COMP);
-
- *pLastThreadSts = static_cast<uint8_t>(*pLastThreadSts & ~(0x1u << eTid));
-
- (pThrCreInfo + eTid)->status = THREAD_STS_NOEXIST;
- (pThrCreInfo + eTid)->order = 0;
-
- if ((pThrCreInfo + eTid)->pno == PNO_NAVI_GPS_RCV) {
- *pThrStopReq = FALSE;
- }
- }
-
- PosStopThread();
-
- /* When all threads have stopped */
- if (*pLastThreadSts == 0) {
- /* Unregister callback function */
- eStatus = FrameworkunifiedDetachCallbacksFromDispatcher(h_app,
- "NS_ANY_SRC",
- (const PUI_32)g_positioning_cids,
- _countof(g_positioning_cids), NULL);
- if (eStatus != eFrameworkunifiedStatusOK) { /* In the event of failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "PositioningDetachCallbacksToDispatcher Failed in FrameworkunifiedOnStop [eStatus:%d]",
- eStatus);
- }
-
- /* Sensor log stop processing */
- SensLogTerminate();
-
- /* DeviceDetectionServiceIf termination process */
- eStatus = DevDetectSrvIfUnRegisterForDeviceDetectionEvent(SS_DEV_DETECT_ANY_USB_EV, &bIsAvailable);
- if (eStatus != eFrameworkunifiedStatusOK) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "DeviceDetectionServiceIf UnRegisterEvent ERROR!! [sts:%d, ava:%d]",
- eStatus,
- bIsAvailable);
- } else {
- eStatus = DevDetectSrvIfCloseSessionRequest(&bIsAvailable);
- if (eFrameworkunifiedStatusOK != eStatus) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "DeviceDetectionServiceIf CloseSession ERROR!! [sts=%d, ava:%d]",
- eStatus,
- bIsAvailable);
- }
- }
-
- (void)VehicleIfDetachCallbacksFromDispatcher((const PUI_32)g_positioning_cids_vehicle,
- _countof(g_positioning_cids_vehicle));
-
- /* Releasing Base API Resources */
- _pb_Teardown_CWORD64_API();
-
- /* Stop processing completion response */
- SendInterfaceunifiedOnStopResponseToSystemManager(eFrameworkunifiedStatusOK);
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Callback function for registering the dispatcher(POS_RegisterListenerPkgSensData)
- *
- * Send a message to an internal thread.
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosPosifRegisterListenerPkgSensorData(HANDLE h_app) {
- RET_API ret;
- uint8_t* pRcvMsg;
- uint32_t size;
- EventID ulEventId;
- PCSTR pName;
- static const PCSTR pNone = "-";
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "+");
-
- pRcvMsg = g_rcv_msg_buf;
-
- size = PosGetMsg(h_app, reinterpret_cast<void**>(&pRcvMsg), MAX_MSG_BUF_SIZE);
- if (size != 0) { // LCOV_EXCL_BR_LINE 4: nsfw error
- pName = _pb_CnvPno2Name((reinterpret_cast<SENSOR_MSG_DELIVERY_ENTRY_DAT*>(pRcvMsg))->pno);
- if (pName == NULL) {
- pName = pNone;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_17, __FUNCTION__,
- "Get message = [Sender:%s][CID:0x%X",
- pName,
- CID_SENSORIF_PKG_DELIVERY_ENTRY_EXT);
-
- /* Send Messages to Internal Thread */
- ret = PosSndMsg(PNO_VEHICLE_SENSOR, CID_SENSORIF_PKG_DELIVERY_ENTRY_EXT, pRcvMsg, size);
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosSndMsg ERROR!! [ret = %d]", ret);
- /* Event Generation */
- ulEventId = PosCreateEvent((reinterpret_cast<SENSOR_MSG_DELIVERY_ENTRY_DAT*>(pRcvMsg))->pno);
- if (ulEventId != 0) {
- /* Event publishing */
- ret = _pb_SetEvent(ulEventId, SAPI_EVSET_ABSOLUTE, SENSOR_RET_ERROR_INNER);
- if (ret != RET_NORMAL) {
- /* Event issuance failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SetEvent ERROR!! [ret = %d]", ret);
- }
- /* Event deletion */
- (void)PosDeleteEvent(ulEventId);
- } else {
- /* Event generation failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosCreateEvent ERROR!!");
- }
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Callback function for registering the dispatcher(POS_RegisterListenerSensData)
- *
- * Send a message to an internal thread.
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosPosifRegisterListenerSensorData(HANDLE h_app) {
- RET_API ret;
- uint8_t* pRcvMsg;
- uint32_t size;
- EventID ulEventId;
- PCSTR pName;
- static const PCSTR pNone = "-";
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "+");
-
- pRcvMsg = g_rcv_msg_buf;
-
- size = PosGetMsg(h_app, reinterpret_cast<void**>(&pRcvMsg), MAX_MSG_BUF_SIZE);
- if (size != 0) { // LCOV_EXCL_BR_LINE 4: nsfw error
- pName = _pb_CnvPno2Name((reinterpret_cast<VEHICLE_MSG_DELIVERY_ENTRY_DAT*>(pRcvMsg))->pno);
- if (pName == NULL) {
- pName = pNone;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_17, __FUNCTION__,
- "Get message = [Sender:%s][CID:0x%X]",
- pName,
- CID_VEHICLEIF_DELIVERY_ENTRY);
-
- /* Send Messages to Internal Thread */
- ret = PosSndMsg(PNO_VEHICLE_SENSOR, CID_VEHICLEIF_DELIVERY_ENTRY, pRcvMsg, size);
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosSndMsg ERROR!! [ret = %d]", ret);
- /* Event Generation */
- ulEventId = VehicleCreateEvent((reinterpret_cast<VEHICLE_MSG_DELIVERY_ENTRY_DAT*>(pRcvMsg))->pno);
- if (ulEventId != 0) {
- /* Event publishing */
- ret = _pb_SetEvent(ulEventId, SAPI_EVSET_ABSOLUTE, SENSOR_RET_ERROR_INNER);
- if (ret != RET_NORMAL) {
- /* Event issuance failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SetEvent ERROR!! [ret = %d]", ret);
- }
- /* Event deletion */
- (void)VehicleDeleteEvent(ulEventId);
- } else {
- /* Event generation failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "VehicleCreateEvent ERROR!!");
- }
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Callback function for registering the dispatcher(POS_ReqGPSSetting)
- *
- * Send a message to an internal thread.
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosPosifReqGpsSetting(HANDLE h_app) {
- RET_API ret;
- uint8_t* pRcvMsg;
- uint32_t size;
- uint8_t ucResult = SENSLOG_RES_FAIL;
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "+");
-
- pRcvMsg = g_rcv_msg_buf;
-
- size = PosGetMsg(h_app, reinterpret_cast<void**>(&pRcvMsg), MAX_MSG_BUF_SIZE);
- if (size != 0) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_17, __FUNCTION__,
- "Get message = [Sender:-][CID:0x%X]",
- CID_SENSORIF__CWORD82__REQUEST);
- ucResult = SENSLOG_RES_SUCCESS;
-
- /* Send Messages to Internal Thread */
- ret = PosSndMsg(PNO_VEHICLE_SENSOR, CID_SENSORIF__CWORD82__REQUEST, pRcvMsg, size);
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosSndMsg ERROR!! [ret = %d]", ret);
- }
- }
-
- SensLogWriteInputData(SENSLOG_DATA_I_GPSSET, 0, 0, pRcvMsg, static_cast<uint16_t>(size),
- ucResult, SENSLOG_ON, SENSLOG_ON);
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Callback function for registering the dispatcher(POS_SetGPSInfo)
- *
- * Send a message to an internal thread.
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosPosifSetGpsInfo(HANDLE h_app) {
- RET_API ret;
- uint8_t* pRcvMsg;
- uint32_t size;
- uint8_t ucResult = SENSLOG_RES_FAIL;
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "+");
-
- pRcvMsg = g_rcv_msg_buf;
-
- size = PosGetMsg(h_app, reinterpret_cast<void**>(&pRcvMsg), MAX_MSG_BUF_SIZE);
- if (size != 0) { // LCOV_EXCL_BR_LINE 4: nsfw error
- FRAMEWORKUNIFIEDLOG(ZONE_17, __FUNCTION__,
- "Get message = [Sender:-][CID:0x%X]",
- CID_NAVIINFO_DELIVER);
- ucResult = SENSLOG_RES_SUCCESS;
-
- /* Send Messages to Internal Thread */
- ret = PosSndMsg(PNO_NAVI_GPS_MAIN, CID_NAVIINFO_DELIVER, pRcvMsg, size);
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosSndMsg ERROR!! [ret = %d]", ret);
- }
- }
- SensLogWriteInputData(SENSLOG_DATA_I_GPSINF, 0, 0, pRcvMsg, static_cast<uint16_t>(size),
- ucResult, SENSLOG_ON, SENSLOG_ON);
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Callback function for registering the dispatcher(POS_GetGPSInfo)
- *
- * Send a message to an internal thread.
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosPosifGetGpsInfo(HANDLE h_app) {
- RET_API ret;
- uint8_t* pRcvMsg;
- uint32_t size;
- EventID ulEventId;
- PCSTR pName;
- static const PCSTR pNone = "-";
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "+");
-
- pRcvMsg = g_rcv_msg_buf;
-
- size = PosGetMsg(h_app, reinterpret_cast<void**>(&pRcvMsg), MAX_MSG_BUF_SIZE);
- if (size != 0) { // LCOV_EXCL_BR_LINE 4: nsfw error
- pName = _pb_CnvPno2Name((reinterpret_cast<VEHICLE_MSG_GET_VEHICLE_DATA_DAT*>(pRcvMsg))->pno);
- if (pName == NULL) {
- pName = pNone;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_17, __FUNCTION__,
- "Get message = [Sender:%s][CID:0x%X]",
- pName,
- CID_VEHICLEIF_GET_VEHICLE_DATA);
-
- /* Send Messages to Internal Thread */
- ret = PosSndMsg(PNO_VEHICLE_SENSOR, CID_VEHICLEIF_GET_VEHICLE_DATA, pRcvMsg, size);
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosSndMsg ERROR!! [ret = %d]", ret);
- /* Event Generation */
- ulEventId = VehicleCreateEvent((reinterpret_cast<VEHICLE_MSG_GET_VEHICLE_DATA_DAT*>(pRcvMsg))->pno);
- if (ulEventId != 0) {
- /* Event publishing */
- ret = _pb_SetEvent(ulEventId, SAPI_EVSET_ABSOLUTE, POS_RET_ERROR_INNER);
- if (ret != RET_NORMAL) {
- /* Event issuance failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "_pb_SetEvent ERROR!! [ret = %d]",
- ret);
- }
- /* Event deletion */
- (void)VehicleDeleteEvent(ulEventId);
- } else {
- /* Event generation failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "VehicleCreateEvent ERROR!!");
- }
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Callback function for registering the dispatcher(CID_POSIF_SET_DATA)
- *
- * Send a message to an internal thread.
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosPosifSetData(HANDLE h_app) {
- RET_API ret;
- uint8_t* pRcvMsg;
- uint32_t size;
- EventID ulEventId;
- PCSTR pName;
- static const PCSTR pNone = "-";
- uint8_t ucResult = SENSLOG_RES_FAIL;
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "+");
-
- pRcvMsg = g_rcv_msg_buf;
-
- size = PosGetMsg(h_app, reinterpret_cast<void**>(&pRcvMsg), MAX_MSG_BUF_SIZE);
- if (size != 0) { // LCOV_EXCL_BR_LINE 4: nsfw error
- ucResult = SENSLOG_RES_SUCCESS;
-
- pName = _pb_CnvPno2Name((reinterpret_cast<POS_MSGINFO*>(pRcvMsg))->pno);
- if (pName == NULL) {
- pName = pNone;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_17, __FUNCTION__,
- "Get message = [Sender:%s][CID:0x%X][DID:0x%X]",
- pName,
- CID_POSIF_SET_DATA,
- (reinterpret_cast<POS_MSGINFO*>(pRcvMsg))->did);
-
- /* Send Messages to Internal Thread */
- ret = PosSndMsg(PNO_VEHICLE_SENSOR, CID_POSIF_SET_DATA, pRcvMsg, size);
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosSndMsg ERROR!! [ret = %d]", ret);
- if ((reinterpret_cast<POS_MSGINFO*>(pRcvMsg))->did == VEHICLE_DID_SETTINGTIME) {
- /* GPS time setting(When waiting for completion of an event, an event is issued. */
- /* Event Generation */
- ulEventId = VehicleCreateEvent((reinterpret_cast<POS_MSGINFO*>(pRcvMsg))->pno);
- if (ulEventId != 0) {
- /* Event publishing */
- ret = _pb_SetEvent(ulEventId, SAPI_EVSET_ABSOLUTE, POS_RET_ERROR_INNER);
- if (ret != RET_NORMAL) {
- /* Event issuance failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "_pb_SetEvent ERROR!! [ret = %d]",
- ret);
- }
- /* Event deletion */
- (void)VehicleDeleteEvent(ulEventId);
- } else {
- /* Event generation failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "VehicleCreateEvent ERROR!!");
- }
- }
- }
- }
- SensLogWriteInputData(SENSLOG_DATA_I_UNSPECIFIED,
- (reinterpret_cast<POS_MSGINFO*>(pRcvMsg))->did,
- 0,
- pRcvMsg,
- static_cast<uint16_t>(size),
- ucResult,
- SENSLOG_ON,
- SENSLOG_ON);
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Callback function for registering the dispatcher(CID_GPS_REQRESET)
- *
- * Send a message to an internal thread.
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosPosifReqGpsReset(HANDLE h_app) {
- RET_API ret;
- uint8_t* pRcvMsg;
- uint32_t size;
- EventID ulEventId;
- PCSTR pName;
- static const PCSTR pNone = "-";
- uint8_t ucResult = SENSLOG_RES_FAIL;
-
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "+");
-
- pRcvMsg = g_rcv_msg_buf;
-
- size = PosGetMsg(h_app, reinterpret_cast<void**>(&pRcvMsg), MAX_MSG_BUF_SIZE);
- if (size != 0) { // LCOV_EXCL_BR_LINE 4: nsfw error
- ucResult = SENSLOG_RES_SUCCESS;
-
- pName = _pb_CnvPno2Name((reinterpret_cast<POS_RESETINFO*>(pRcvMsg))->snd_pno);
- if (pName == NULL) {
- pName = pNone;
- }
- FRAMEWORKUNIFIEDLOG(ZONE_17, __FUNCTION__,
- "Get message = [Sender:%s][CID:0x%X]",
- pName,
- CID_GPS_REQRESET);
-
- /* Send Messages to Internal Thread */
- ret = PosSndMsg(PNO_NAVI_GPS_MAIN, CID_GPS_REQRESET, pRcvMsg, size);
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosSndMsg ERROR!! [ret = %d]", ret);
-
- /* Event Generation */
- ulEventId = VehicleCreateEvent((reinterpret_cast<POS_RESETINFO*>(pRcvMsg))->snd_pno);
- if (0 != ulEventId) {
- /* Event publishing */
- ret = _pb_SetEvent(ulEventId, SAPI_EVSET_ABSOLUTE, POS_RET_ERROR_INNER);
- if (ret != RET_NORMAL) {
- /* Event issuance failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "_pb_SetEvent ERROR!! [ret = %d]",
- ret);
- }
- /* Event deletion */
- (void)VehicleDeleteEvent(ulEventId);
- } else {
- /* Event generation failure */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "VehicleCreateEvent ERROR!!");
- }
- }
- }
-
- SensLogWriteInputData(SENSLOG_DATA_I_GPSRST, 0, 0, pRcvMsg, static_cast<uint16_t>(size),
- ucResult, SENSLOG_ON, SENSLOG_ON);
- FRAMEWORKUNIFIEDLOG(ZONE_28, __FUNCTION__, "-");
-
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Callback function for registering the dispatcher(CID_VEHICLESENS_VEHICLE_INFO)
- *
- * Send a message to an internal thread.
- *
- * @param[in] h_app Application handle
- *
- * @return eFrameworkunifiedStatusOK Normal completion
- */
-static EFrameworkunifiedStatus PosVehicleInfoRcv(HANDLE h_app) {
- LSDRV_MSG_LSDATA_DAT_G line_sns_data;
- RET_API ret = RET_NORMAL;
-
- memset(&line_sns_data, 0, sizeof(line_sns_data));
- LSDRV_MSG_LSDATA_DAT_G *p_line_sns_data = &line_sns_data;
- VEHICLE_UNIT_MSG_VSINFO *p_vehicle_msg = NULL;
- uint32_t size = 0;
- uint16_t us_speed = 0;
-
- uint8_t* pRcvMsg = g_rcv_msg_buf;
-
- size = PosGetMsg(h_app, reinterpret_cast<void**>(&pRcvMsg), MAX_MSG_BUF_SIZE);
- if (size != 0) { // LCOV_EXCL_BR_LINE 4: nsfw error
- memset(p_line_sns_data, 0x00, sizeof(line_sns_data));
- p_vehicle_msg = (reinterpret_cast<VEHICLE_UNIT_MSG_VSINFO*>(pRcvMsg));
- switch (p_vehicle_msg->data.did) {
- // SPEED info
- case VEHICLE_DID_SPEED:
- {
- p_line_sns_data->uc_data_num = LSDRV_KINDS_MAX;
- p_line_sns_data->st_data[LSDRV_SPEED_KMPH].ul_did = POSHAL_DID_SPEED_KMPH;
- p_line_sns_data->st_data[LSDRV_SPEED_KMPH].uc_size = POS_SNDMSG_DTSIZE_2;
- p_line_sns_data->st_data[LSDRV_SPEED_KMPH].uc_sns_cnt = 0;
-
- char p_env_variable[VP_MAX_LENGTH];
-
- VP_GetEnv("VP__CWORD31__SPEED", p_env_variable);
- if (0 == strcmp(p_env_variable, "direct")) {
- int16_t speed = 0;
- // To obtain the vehicle speed from Direct lanes,1 to 2 bytes of received data
- memcpy(&speed, &p_vehicle_msg->data.data[0], sizeof(speed));
- us_speed = static_cast<uint16_t>(abs(speed));
- // Unit conversion [km/h] -> [0.01km/h]
- us_speed = static_cast<uint16_t>(us_speed * 100);
- } else if (0 == strcmp(p_env_variable, "CAN")) {
- UINT16 speed = 0;
- // To obtain the vehicle speed from CAN,2 to 3 bytes of received data
- memcpy(&speed, &p_vehicle_msg->data.data[1], sizeof(speed));
- us_speed = static_cast<uint16_t>(abs(speed));
- // Unit conversion [km/h] -> [0.01km/h]
- us_speed = static_cast<uint16_t>(us_speed * 100);
- } else {
- // In case of invalid value, the vehicle speed is acquired by CAN.
- UINT16 speed = 0;
- memcpy(&speed, &p_vehicle_msg->data.data[1], sizeof(speed));
- us_speed = static_cast<uint16_t>(abs(speed));
- // Unit conversion [km/h] -> [0.01km/h]
- us_speed = static_cast<uint16_t>(us_speed * 100);
- }
-
- memcpy(&p_line_sns_data->st_data[LSDRV_SPEED_KMPH].uc_data[0], &us_speed, sizeof(us_speed));
-
- ret = PosSndMsg(PNO_VEHICLE_SENSOR, CID_LINESENS_VEHICLE_DATA_G,
- reinterpret_cast<void*>(p_line_sns_data), sizeof(line_sns_data));
-
- break;
- }
- // REV information
- case VEHICLE_DID_REV:
- {
- p_line_sns_data->uc_data_num = LSDRV_KINDS_MAX;
- p_line_sns_data->st_data[LSDRV_REV].ul_did = VEHICLE_DID_REV;
- p_line_sns_data->st_data[LSDRV_REV].uc_size = POS_SNDMSG_DTSIZE_1;
- p_line_sns_data->st_data[LSDRV_REV].uc_sns_cnt = 0;
- p_line_sns_data->st_data[LSDRV_REV].uc_data[0] = p_vehicle_msg->data.data[0];
-
- ret = PosSndMsg(PNO_VEHICLE_SENSOR, CID_LINESENS_VEHICLE_DATA_G,
- reinterpret_cast<void*>(p_line_sns_data), sizeof(line_sns_data));
- break;
- }
-
- // Speed Pulse information
- case VEHICLE_DID_SPEED_PULSE_VEHICLE:
- {
- p_line_sns_data->uc_data_num = LSDRV_KINDS_MAX;
- p_line_sns_data->st_data[LSDRV_SPEED_PULSE].ul_did = POSHAL_DID_SPEED_PULSE;
- p_line_sns_data->st_data[LSDRV_SPEED_PULSE].uc_size = sizeof(float);
- p_line_sns_data->st_data[LSDRV_SPEED_PULSE].uc_sns_cnt = 0;
-
- memcpy(&p_line_sns_data->st_data[LSDRV_SPEED_PULSE].uc_data[0],
- &p_vehicle_msg->data.data[0], sizeof(float));
-
- p_line_sns_data->st_data[LSDRV_PULSE_TIME].ul_did = POSHAL_DID_PULSE_TIME;
- p_line_sns_data->st_data[LSDRV_PULSE_TIME].uc_size = sizeof(float);
- p_line_sns_data->st_data[LSDRV_PULSE_TIME].uc_sns_cnt = 0;
-
- memcpy(&p_line_sns_data->st_data[LSDRV_PULSE_TIME].uc_data[0],
- &p_vehicle_msg->data.data[sizeof(float)], sizeof(float));
-
- ret = PosSndMsg(PNO_VEHICLE_SENSOR, CID_LINESENS_VEHICLE_DATA_G,
- reinterpret_cast<void*>(p_line_sns_data), sizeof(line_sns_data));
-
- break;
- }
- default:
- break;
- }
-
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "PosSndMsg ERROR!! [ret = %d]", ret);
- }
- }
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * Get Message
- *
- * Get messages received by the dispatcher
- *
- * @param[in] h_app Application handle
- * @param[out] p_buf Pointer to receive data storage buffer
- * @param[in] Sizes of size receive data storage buffers
- *
- * @return Received data size(0:Receiving error)
- */
-static uint32_t PosGetMsg(HANDLE h_app, void** p_buf, uint32_t size) {
- EFrameworkunifiedStatus eStatus;
- uint32_t ulSize = 0;
- void* pRcvBuf;
-
- /* null check */
- if ((h_app == NULL) || (p_buf == NULL)) { // LCOV_EXCL_BR_LINE 200: can not NULL
- // LCOV_EXCL_START 8: invalid
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "Argument ERROR!! [h_app = %p, p_buf = %p]",
- h_app,
- p_buf);
- // LCOV_EXCL_STOP
- } else {
- /* Check the size of received data */
- ulSize = FrameworkunifiedGetMsgLength(h_app);
- if (ulSize > size) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "Message size ERROR!! [ulSize = %d, maxsize = %d]",
- ulSize,
- size);
- ulSize = 0;
- } else {
- /* Obtain data */
- eStatus = FrameworkunifiedGetDataPointer(h_app, &pRcvBuf);
- if (eStatus == eFrameworkunifiedStatusOK) {
- *p_buf = pRcvBuf;
- } else if (eStatus == eFrameworkunifiedStatusInvldBufSize) {
- eStatus = FrameworkunifiedGetMsgDataOfSize(h_app, *p_buf, ulSize);
- /* When acquisition fails */
- if (eStatus != eFrameworkunifiedStatusOK) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedGetMsgDataOfSize ERROR [eStatus:%d]",
- eStatus);
- ulSize = 0;
- }
- } else {
- /* When acquisition fails */
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedGetDataPointer ERROR [eStatus:%d]",
- eStatus);
- ulSize = 0;
- }
- }
- }
-
- return ulSize;
-}
-
-/**
- * @brief
- * Sending Messages for Internal Threads
- *
- * Adds a header to the message received by the dispatcher and sends it to the internal thread..
- *
- * @param[in] pno PNO
- * @param[in] cid Command ID
- * @param[in] p_msg_body Sent message body
- * @param[in] size Send message size
- *
- * @return RET_NORAML Normal completion
- * RET_ERROR ABENDs
- */
-static RET_API PosSndMsg(PNO pno, CID cid, void* p_msg_body, uint32_t size) {
- RET_API ret = RET_NORMAL;
- T_APIMSG_MSGBUF_HEADER* p;
- static u_int8 sndMsgBuf[MAX_MSG_BUF_SIZE + sizeof(T_APIMSG_MSGBUF_HEADER)];
-
- if ((p_msg_body == NULL) || (size > MAX_MSG_BUF_SIZE)) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Argument ERROR!! [p_msg_body = %p, size = %d]", p_msg_body, size);
- ret = RET_ERROR;
- } else {
- p = reinterpret_cast<T_APIMSG_MSGBUF_HEADER*>(sndMsgBuf);
-
- /* Message header addition */
- p->hdr.cid = cid;
- p->hdr.msgbodysize = static_cast<uint16_t>(size);
-
- /* Copy of the data section */
- memcpy((p + 1), p_msg_body, size);
-
- /* Send a message to an internal thread */
- ret = _pb_SndMsg(pno, static_cast<uint16_t>(size + sizeof(T_APIMSG_MSGBUF_HEADER)), p, 0);
- /* When transmission fails */
- if (ret != RET_NORMAL) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "_pb_SndMsg ERROR [ret = %d]", ret);
- ret = RET_ERROR;
- }
- }
-
- return ret;
-}
-
-/**
- * @brief
- * SS_DevDetectSrv service OpenSessionAck Callback Functions
- *
- * @param none
- *
- * @return eFrameworkunifiedStatusOK successful completion
- */
-static EFrameworkunifiedStatus PosOnDevDetectOpenSessionAck(HANDLE h_app) {
- EFrameworkunifiedStatus eStatus = eFrameworkunifiedStatusOK;
- BOOL bIsAvailable;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- eStatus = DevDetectSrvIfDecodeOpenSessionResponse(&bIsAvailable);
- if (eFrameworkunifiedStatusOK != eStatus) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "DeviceDetectionServiceIf OpenSession ERROR!! [sts=%d, ava=%d]", eStatus, bIsAvailable);
- } else {
- eStatus = DevDetectSrvIfRegisterForDeviceDetectionEvent(SS_DEV_DETECT_ANY_USB_EV,
- &PosOnDevDetectEvent,
- NULL,
- &bIsAvailable);
- if (eFrameworkunifiedStatusOK != eStatus) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "DeviceDetectionServiceIf RegisterEvent ERROR!! [sts=%d, ava=%d]", eStatus, bIsAvailable);
- } else {
- eStatus = DevDetectSrvIfNotifyOnCloseSessionAck(&PosOnDevDetectCloseSessionAck, &bIsAvailable);
- if (eFrameworkunifiedStatusOK != eStatus) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "DeviceDetectionServiceIf CloseSessionAck ERROR!! [sts=%d, ava=%d]",
- eStatus,
- bIsAvailable);
- }
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * SS_DevDetectSrv service CloseSessionAck Callback Functions
- *
- * @param none
- *
- * @return eFrameworkunifiedStatusOK successful completion
- */
-static EFrameworkunifiedStatus PosOnDevDetectCloseSessionAck(HANDLE h_app) {
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "+");
-
- /* Sensor log stop processing */
- SensLogTerminate();
-
- FRAMEWORKUNIFIEDLOG(ZONE_INFO, __FUNCTION__, "-");
- return eFrameworkunifiedStatusOK;
-}
-
-/**
- * @brief
- * SS_DevDetectSrv service Event Callback Functions
- *
- * @param none
- *
- * @return eFrameworkunifiedStatusOK successful completion
- */
-static EFrameworkunifiedStatus PosOnDevDetectEvent(HANDLE h_app) {
- SS_MediaDetectInfo stMedia;
- EFrameworkunifiedStatus eStatus = eFrameworkunifiedStatusOK;
- uint32_t ulSize = 0;
- uint8_t mode;
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "+");
-
- /* Check the size of received data */
- ulSize = FrameworkunifiedGetMsgLength(h_app);
- if (ulSize > sizeof(SS_MediaDetectInfo)) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__, "Message size ERROR!! [ulSize = %d, maxsize = %ld]",
- ulSize, sizeof(SS_MediaDetectInfo));
- ulSize = 0;
- } else {
- /* Obtain data */
- eStatus = FrameworkunifiedGetMsgDataOfSize(h_app, &stMedia, ulSize);
- /* When acquisition fails */
- if (eStatus != eFrameworkunifiedStatusOK) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "FrameworkunifiedGetMsgDataOfSize ERROR [eStatus:%d]", eStatus);
- ulSize = 0;
- } else {
- if (eUSB == stMedia.dev_type) {
- if (TRUE == stMedia.bIsDeviceAvailable) {
- /* Mount detection */
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__,
- "USB mounted sts=[%d] path=[%s] fusedav=[%d]",
- stMedia.bIsDeviceAvailable, stMedia.deviceMountpath, stMedia.bIsFuseDav);
-
- /* NOTE: bIsFuseDav -> From the _CWORD80_'s point of view, */
- /* TRUE(With a USB flash drive inserted into the _CWORD84_,Be synchronized on the FuseDav)*/
- /* FALSE(USB memory is inserted into the _CWORD80_.) */
-
- if (stMedia.bIsFuseDav == FALSE) {
- /* Inserted into your USB port */
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "SensLog Initialize start.");
- /* Get Debug/Release setting */
- eStatus = NsLogGetFrameworkunifiedLogFlag(POSITIONINGLOG_FLAG_NAVI, &mode);
- /* When acquisition fails */
- if (eStatus != eFrameworkunifiedStatusOK) {
- FRAMEWORKUNIFIEDLOG(ZONE_ERR, __FUNCTION__,
- "NsLogGetFrameworkunifiedLogFlag ERROR [eStatus:%d]", eStatus);
- } else {
- if (mode == FRAMEWORKUNIFIEDLOG_FLAG_MODE_DEBUG) {
- /* Sensor Log Initial Processing(Normal)*/
- SensLogInitialize(reinterpret_cast<uint8_t *>(stMedia.deviceMountpath));
- }
- }
- } else {
- /* TODO: Mounts (FuseDav synchronized) that are not inserted into your device's USB port are not supported. */
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "Don't output SensLog.");
- }
- } else {
- /* Unmount detection */
- if (stMedia.bIsFuseDav == FALSE) {
- /* When it is unmounted to its own USB */
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__,
- "USB umounted sts=[%d] fusedav=[%d]",
- stMedia.bIsDeviceAvailable, stMedia.bIsFuseDav);
-
- /* Sensor log stop processing */
- SensLogTerminate();
- }
- }
- }
- }
- }
-
- FRAMEWORKUNIFIEDLOG(ZONE_INIT, __FUNCTION__, "-");
- return eStatus;
-}
-
-/**
- * @brief Debug dump log output function
- *
- * @param[in] *p_buf Pointer to the output string
- */
-static void PosOutputDebugDumpLog(uint8_t* p_buf) { // LCOV_EXCL_START 7: uesd only in FrameworkunifiedOnDebugDump
- AGL_ASSERT_NOT_TESTED(); // LCOV_EXCL_LINE 200: test assert
- SSDEBUGDUMP("%s\n", p_buf);
- MilliSecSleep(1);
- return;
-}
-// LCOV_EXCL_STOP
-
diff --git a/vehicleservice/positioning/server/src/nsfw/ps_main.cpp b/vehicleservice/positioning/server/src/nsfw/ps_main.cpp
deleted file mode 100755
index de2732a..0000000
--- a/vehicleservice/positioning/server/src/nsfw/ps_main.cpp
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-#include <native_service/frameworkunified_dispatcher.h>
-#include <native_service/frameworkunified_application.h>
-#include <peripheral_service/ps_services.h>
-#include <native_service/ns_version_if.h>
-#include <system_service/ss_system_if.h>
-#include <vehicle_service/positioning_base_library.h>
-#include <cstdlib>
-#include <iostream>
-#include "vehicle_version.h"
-
-const CHAR kAppName[PS_APPNAME_MAX] = "Positioning";
-
-CFrameworkunifiedVersion g_FrameworkunifiedVersion(MAJORNO, // NOLINT(readability/nolint)
- MINORNO, // NOLINT(readability/nolint)
- REVISION);
-
-/* FRAMEWORKUNIFIEDLOGPARAM : g_FrameworkunifiedLogParams : definition for LOG */
-FRAMEWORKUNIFIEDLOGPARAM g_FrameworkunifiedLogParams = { // NOLINT(readability/nolint)
- FRAMEWORKUNIFIEDLOGOPTIONS,
- {
- ZONE_TEXT_10, ZONE_TEXT_11, ZONE_TEXT_12,
- ZONE_TEXT_13, ZONE_TEXT_14, ZONE_TEXT_15,
- ZONE_TEXT_16, ZONE_TEXT_17, ZONE_TEXT_18,
- ZONE_TEXT_19, ZONE_TEXT_20, ZONE_TEXT_21,
- ZONE_TEXT_22, ZONE_TEXT_23, ZONE_TEXT_24,
- ZONE_TEXT_25, ZONE_TEXT_26, ZONE_TEXT_27,
- ZONE_TEXT_28, ZONE_TEXT_29, ZONE_TEXT_30,
- ZONE_TEXT_31,
- ZONE_POS_SYS_IN, ZONE_POS_GPS_IN, ZONE_POS_CMD_IN, ZONE_POS_NAV_IN
- },
- FRAMEWORKUNIFIEDLOGZONES
-};
-
-/* Function : main */
-int main(int argc, char *argv[]) {
- EFrameworkunifiedStatus e_status = eFrameworkunifiedStatusOK;
- FrameworkunifiedDefaultCallbackHandler cb_funcs;
- FRAMEWORKUNIFIED_MAKE_DEFAULT_CALLBACK(cb_funcs);
-
- FRAMEWORKUNIFIED_SET_ZONES();
- e_status = FrameworkunifiedDispatcher(kAppName, &cb_funcs);
-
- return e_status;
-} // LCOV_EXCL_BR_LINE 10:The final line