Part Number: CC2650
Tool/software: Code Composer Studio
Hello,
I'm extending the Zero Project and want it to use the flash memory on the board.
I'm using ExtFlash.h api.
My code looks as following:
static bool ExtFlash_init(void)
{
if (!ExtFlash_open()) {
return false;
}
ExtFlashInfo_t* extFalshInfo = ExtFlash_info();
Log_info3("Opened extflash device (size: %d, dev id: %d, manf id: %d)", extFalshInfo->deviceSize, extFalshInfo->devId, extFalshInfo->manfId);
return true;
}
static void ExtFlash_testForRead(void)
{
uint8_t buffer[11] = {0};
if (!ExtFlash_read(0, sizeof(buffer) - 1, buffer)) {
Log_error0("Read failed!");
return;
}
}
static void ProjectZero_init(void)
{
if (!ExtFlash_init()) {
Log_error0("Error initializing ExtFlash");
Task_exit();
}
Log_info0("Extflash initialized");
ExtFlash_testForRead();
/* ALL OTHER PROJECT ZERO INIT CODE */
}
The problem is that once I run the ExtFlash_read function, I get stuck and the application doesn't continue...
In addition, I don't get any UART logs before and after the ExtFlash_read function (I guess it's because flushing stuff, how can I manually flush?)
Thanks in advance.