From e699262728a85c3ffe8a6cb9486007b8b0a485a3 Mon Sep 17 00:00:00 2001 From: cfif Date: Thu, 12 Dec 2024 17:25:48 +0300 Subject: [PATCH] Fix --- DeviceDataNonVolatile.c | 4 ++++ DeviceDataNonVolatile.h | 5 ++++- DeviceDataNonVolatile_AddToVarTab.c | 5 +++-- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/DeviceDataNonVolatile.c b/DeviceDataNonVolatile.c index 42846fc..6d31fdb 100644 --- a/DeviceDataNonVolatile.c +++ b/DeviceDataNonVolatile.c @@ -7,7 +7,11 @@ void DeviceDataNonVolatile_InitDefaults(tDeviceDataNonVolatile *env) { DeviceStorageInitDeviceSettings(&env->device); + +#ifdef UVEOS_ADD_TELEMATICA DeviceStorageInitTelematicSettings(&env->deviceTeledataStorageData.telematica); +#endif + vUveosGostSettingsInitDefaults(&env->gost); DeviceStorageInitCodec(&env->audioCodec); CarFlipDetection_InitSettings(&env->flip); diff --git a/DeviceDataNonVolatile.h b/DeviceDataNonVolatile.h index 044163e..ddef8ba 100644 --- a/DeviceDataNonVolatile.h +++ b/DeviceDataNonVolatile.h @@ -76,7 +76,10 @@ typedef struct { tCarFlipDetectionSettings flip; tDeviceSettings device; - tDeviceTeledataStorageData deviceTeledataStorageData; + +#ifdef UVEOS_ADD_TELEMATICA +tDeviceTeledataStorageData deviceTeledataStorageData; +#endif tEraGlonassMsdTable msdTable; } tDeviceDataNonVolatile; diff --git a/DeviceDataNonVolatile_AddToVarTab.c b/DeviceDataNonVolatile_AddToVarTab.c index ed6c77d..a7c9d06 100644 --- a/DeviceDataNonVolatile_AddToVarTab.c +++ b/DeviceDataNonVolatile_AddToVarTab.c @@ -58,6 +58,8 @@ void DeviceDataNonVolatile_AddToVarTab( ADD_VAR_STR_OBJ(STRING, CODEC_CONF, env->device.codecConf); + +#ifdef UVEOS_ADD_TELEMATICA //Telematic ADD_VAR_STR_OBJ(STRING, EGTS_PROFILE_SIM_ERA, env->deviceTeledataStorageData.telematica.EGTS_PROFILE_SIM_ERA); ADD_VAR_STR_OBJ(STRING, EGTS_PROFILE_SIM_INTERNET, env->deviceTeledataStorageData.telematica.EGTS_PROFILE_SIM_INTERNET); @@ -91,8 +93,7 @@ void DeviceDataNonVolatile_AddToVarTab( // Изменение курсового угла после которого нужно послать данные (градусы) ADD_VAR(UINT32, EGTS_FLEET_COURSE_THRESHOLD, &env->deviceTeledataStorageData.telematica.EGTS_FLEET_COURSE_THRESHOLD); - - +#endif }