Index: NVDataMgmt.c =================================================================== diff -u -rf19e6d7c27e0a94329d5609f38348ffb3c9293ec -rd51c904ba7bcd18c7c1bcb864964a3b19cfa8a44 --- NVDataMgmt.c (.../NVDataMgmt.c) (revision f19e6d7c27e0a94329d5609f38348ffb3c9293ec) +++ NVDataMgmt.c (.../NVDataMgmt.c) (revision d51c904ba7bcd18c7c1bcb864964a3b19cfa8a44) @@ -76,14 +76,15 @@ #define MAX_NUM_OF_EVENTS_IN_SECTOR1 ((MAX_NUM_OF_SECTORS_FOR_LOG_DATA - 2) * MAX_LOG_DATA_PER_SECTOR) ///< Max number of accumulated logs in sector 1 (512). // Data addresses and length in RTC RAM -#define LOG_RECORD_START_ADDRESS 0x00000000 // 0 ///< Log record start address in RTC RAM (0). -#define HD_USAGE_INFO_START_ADDRESS 0x00000010 // 16 ///< HD usage info start address in RTC RAM (16). -#define DG_USAGE_INFO_START_ADDRESS 0x00000030 // 48 ///< DG usage info start address in RTC RAM (48). +#define LOG_RECORD_START_ADDRESS 0x00000000 /* 0 */ ///< Log record start address in RTC RAM (0). +#define HD_USAGE_INFO_START_ADDRESS 0x00000010 /* 16 */ ///< HD usage info start address in RTC RAM (16). +#define DG_USAGE_INFO_START_ADDRESS 0x00000030 /* 48 */ ///< DG usage info start address in RTC RAM (48). #define DG_SCHEDULED_RUNS_START_ADDRESS (DG_USAGE_INFO_START_ADDRESS + sizeof(DG_SERVICE_GROUP_T)) ///< DG scheduled runs start address in RTC RAM. #define DG_HEATERS_INFO_START_ADDRESS (DG_SCHEDULED_RUNS_START_ADDRESS + sizeof(DG_HEATERS_INFO_GROUP_T))///< DG heaters info start address in RTC RAM. -#define SW_CONFIGS_START_ADDRESS 0x00000100 // 256 ///< Software configurations start address in RTC RAM. +#define SW_CONFIGS_START_ADDRESS 0x00000100 /* 256 */ ///< Software configurations start address in RTC RAM. #define COMMAND_TIME_OUT (1 * MS_PER_SECOND) ///< Timeout for an EEPROM or RTC command in ms. + /// EEPROM functions use the buffer length as the size of U32. So before send the length to any of FAPI functions, it should be divided by 4. #define EEPROM_OPS_SIZE_OF_CONVERTER 4 @@ -105,7 +106,7 @@ // to round up. The result is then multiplied by 16 bytes to get the number of bytes needed and is subtracted from the size of the structure and CRC. #define RECORD_PADDING_LENGTH(rcrd, buf) (RECORD_BYTE_SIZE(rcrd) % buf == 0 ? 0 : \ ((((RECORD_BYTE_SIZE(rcrd) / buf) + 1)) * buf) \ - - RECORD_BYTE_SIZE(rcrd)) /// DG padding length macro. + - RECORD_BYTE_SIZE(rcrd)) ///< DG padding length macro. #define RECORD_DEFAULT_TIME 0U ///< Record default time (calibration/set). #define RECORD_FOURTH_ORDER_COEFF 0.0F ///< Record fourth order coefficient.