2.1.3.2 DIAG_EEPROM_ValidateCRC()

diag_result_t DIAG_EEPROM_ValidateCRC (eeprom_address_t startAddress, uint16_t length, eeprom_address_t refAddress)

Validates the CRC of a given EEPROM memory region by recalculating and comparing it with the reference CRC stored by DIAG_EEPROM_CalculateStoreCRC.

Parameters:
in startAddress

- Starting address of EEPROM memory region to be considered for CRC

in length

- Number of bytes from startAddress to be considered for CRC

in refAddress

- The EEPROM address where reference CRC is available

Returns:

DIAG_PASS - CRC validation for given EEPROM region is successful  

DIAG_FAIL - CRC validation for given EEPROM region is unsuccessful  

DIAG_INVALID_ARG - An invalid argument is passed to the function