This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM2634: qspi flash erase and write

Part Number: AM2634
Other Parts Discussed in Thread: SYSCONFIG

Tool/software:

I'm having issues getting basic erase and write to work with the NOR flash on the AM2634-C launchpad.  Could someone please let me know an easy way to implement erase, write, and read.

I've tried the below example code from MCU plus.  The RxBuf is always 0.

QSPI_init();
QSPI_Handle qspiHandle = QSPI_getHandle(CONFIG_QSPI0);
err = QSPI_norFlashInit(qspiHandle);
err = QSPI_norFlashRead(qspiHandle, FLASH_OFFSET, gQspiRxBuf, 256);
err = QSPI_norFlashErase(qspiHandle, FLASH_OFFSET);
err = QSPI_norFlashRead(qspiHandle, FLASH_OFFSET, gQspiRxBuf, 256);

I've also tried the below code (by copying in an example.syscfg file).  but my project doesn't start.  I set a breakpoint at the beginning of main() but it doesn't get there.  If I use my own example.syscfg in CCS, the SYSCFG tool crashes when I add in the "flash" module.

Flash_getAttrs(CONFIG_FLASH0);
(void) Flash_offsetToBlkPage(gFlashHandle[CONFIG_FLASH0],offset,&blk,&page);
(void) Flash_eraseBlk(gFlashHandle[CONFIG_FLASH0], blk);
Flash_read(gFlashHandle[CONFIG_FLASH0], offset, gQspiRxBuf, APP_QSPI_DATA_SIZE);

Here are the details:

at iteratee (webpack://sysconfig/src/pinmux/services/objectManagers/validationLogger.ts:40:11) at baseMap (webpack://sysconfig/node_modules/lodash/lodash.js:653:23) at Function.map (webpack://sysconfig/node_modules/lodash/lodash.js:9621:51) at getValidatableObjs (webpack://sysconfig/src/pinmux/services/objectManagers/validationLogger.ts:37:12) at log (webpack://sysconfig/src/pinmux/services/objectManagers/validationLogger.ts:63:10) at Proxy.logError (webpack://sysconfig/src/pinmux/services/objectManagers/validationLogger.ts:67:3) at checkSameFieldName (C:\ti\mcu_plus_sdk_am263x_09_02_00_56\source\.meta\common.syscfg.js:162:20) at Object.checkSameInstanceName (C:\ti\mcu_plus_sdk_am263x_09_02_00_56\source\.meta\common.syscfg.js:360:13) at Object.validate (C:\ti\mcu_plus_sdk_am263x_09_02_00_56\source\drivers\.meta\qspi\v0\qspi_v0.syscfg.js:364:21) at H.validate (webpack://sysconfig/src/pinmux/services/objectManagers/moduleInstance.ts:618:16)