I need to access the internal flash to store the downloaded image from server.
Internal 4 MB Flash to be partitioned in three sections as shown below,
- Currently executing image. This image will download the other image from server.
- Downloaded image.
- User Data
Here, I am looking for the mechanism to access the second partition of internal flash from first partition (i.e. code executing from partition 1).
Currently I am using the I.MXRT1064EVK board and downloaded the sample code flexspi_nor_polling_transfer from SDK. This code is for accessing the external flash connected to FLEXSPI1.
I need the example code which can access (Read/Write/Erase) the internal 4MB flash (internally connected to FLEXSPI2) from program executing from address 0x7000_0000.
I tried modifying the flexspi_nor_polling_transfer to use FLEXSPI2 but it is not working.
Now I have following questions,
1. Can flexspi_nor_polling_transfer be modified to access internal 4MB flash?
2. Is there any code which I can use in program executing from 0x7000_0000 (e.g. emwin_gui_demo) to access any memory (outside of the current executing program area) of internal flash?