Skip to content

Commit 677323e

Browse files
committed
wip
1 parent 9827a40 commit 677323e

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

cores/esp8266/core_esp8266_main.cpp

+7-2
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,8 @@ extern "C" void ICACHE_RAM_ATTR app_entry (void)
214214

215215
extern "C" void user_pre_init (void)
216216
{
217-
// NOT WORKING
217+
// need to get those numbers from board/generator
218+
// NOT WORKING - need to get numbers from board/generator
218219
// 4M
219220
#define SPI_FLASH_SIZE_MAP 4
220221
#define SYSTEM_PARTITION_RF_CAL_ADDR (0x400000 - 0x3000 - 0x1000 - 0x1000)
@@ -227,7 +228,11 @@ extern "C" void user_pre_init (void)
227228
{ SYSTEM_PARTITION_SYSTEM_PARAMETER,SYSTEM_PARTITION_SYSTEM_PARAMETER_ADDR, 0x3000},
228229
{ SYSTEM_PARTITION_CUSTOMER_BEGIN, 0x1000, 0x8000},
229230
};
230-
system_partition_table_regist(partitions, sizeof(partitions) / sizeof(partitions[0]), SPI_FLASH_SIZE_MAP);
231+
if (!system_partition_table_regist(partitions, sizeof(partitions) / sizeof(partitions[0]), SPI_FLASH_SIZE_MAP))
232+
{
233+
os_printf("system_partition_table_regist: failed\n");
234+
while(1);
235+
}
231236
}
232237

233238
extern "C" void user_init(void) {

0 commit comments

Comments
 (0)