diff --git a/Application/BSP/BSP_EE24.c b/Application/BSP/BSP_EE24.c index aee5e08..bebb7e1 100644 --- a/Application/BSP/BSP_EE24.c +++ b/Application/BSP/BSP_EE24.c @@ -47,7 +47,7 @@ void BSP_EE24_TableMigrate(uint32_t ee_version); */ void BSP_EE24_InitTable() { uint32_t address = 0; // Start at address 0 - for (int i = 1; i < __BSP_EE24_PART_MAX__; i++) { + for (int i = 0; i < __BSP_EE24_PART_MAX__; i++) { if (PartionTable[i].len > 0) { PartionTable[i].address = address; address += PartionTable[i].len; @@ -60,6 +60,7 @@ void BSP_EE24_InitTable() { * Initializes the EEPROM driver and performs any necessary migrations. */ bool BSP_EE24_Init(void) { + BSP_EE24_InitTable(); // Initialize the EE24 driver with the I2C interface and address bool status = EE24_Init(&hee24,BSP_EE24_I2C,BSP_EE24_ADDRESS); if(!status) {