false

false

中文

GR5515. GProgrammer refuses to write to flash

die****com

2021-11-19 02:03:24

While trying to setup a debug environment for GDB, using a modified version of the "qspi_flash" demo as reference I accidentally set to 1 the EXT_EXFLASH_ENABLE parameter in custom_config.h, and flashed the firmware with GProgrammer. While trying to debug that firmware I noticed that the entire flash memory was set to 0s, so I thought that the demo was simply not working on the I0ND soc. After switching to a different firmware that I had in the flash, GProgrammer disconnected, and now after connecting, it will display the entire flash region as empty (no trace of my downloaded firmwares) besides the boot info area and the default NVDS area, and it will refuse to write to flash, neither from the firmware section, nor the flash section. The firmware section shows the error "Totally 1 events commit failed: Add and download firmware.bin failed.", and the flash section shows the error "Download data failed". Even the NVDS area seems to be gone with all values set to N/A, but the "Erase All" flash option seems to do something since it takes a while to complete. I'm not sure whether the flash mode has switched to external when enabling " EXT_EXFLASH_ENABLE ", or what's going on really, since the code for "hal_exflash_read_patch" is not provided, but it seems like the Flash is disabled (except for erasing?) and I cannot write any firmwares anymore. Or maybe it's not related to EXT_EXFLASH_ENABLE at all. Does anyone have any idea what's going on, and how can I recover the flash? Thank you in advance


P.S.: I can still issue commands through J-Link Commander, but I can't read the flash area from there, it returns all 0s

Hot Latest

4 Answers

die****com

2021-11-24 18:42:18

Hi Kellan,

Did you manage to reproduce the issue? Is there any way to recover the ability to write in flash with GProgrammer? Thank you in advance.

0 Comments

Your comment

die****com

2021-11-24 18:42:18

Hi Kellan,

Did you manage to reproduce the issue? Is there any way to recover the ability to write in flash with GProgrammer? Thank you in advance.

2 Comments

Your comment

die****com

2021-11-19 17:51:29

Thank you Kellan, please let me know if you have any additional questions, or anything that I can help with about my setup.

I'm building in Windows 10, with the exact same versions mentioned in your GCC document:

"MSYS-1.0.11" and "gcc-arm-none-eabi-9-2020-q2-update-win32".

Building seems to success and the binary seems to comply with the dfu binary format.

I'm trying to remember if the issue started before or after I set the flag for EXT_EXFLASH_ENABLE, since I managed to get to debug the firmware before setting the flag (or so I thought), but the variable values of the debugged code didn't seem to match the expectations, although in that instance the debugged variables  seemed to have very large negative values instead of all zeros if I remember correctly, so there must have been somehow valid instructions in memory. And when going back to my other firmware before setting the EXT_FLASH_ENABLE flag everything was working fine.

0 Comments

Your comment

{-}{-}

2021-11-19 16:57:38

Hi, 

Thanks for you questions.

We will build an environment to make sure it's ok, we will reply you latter, thanks.


Kellan.


0 Comments

Your comment

4 Records
1

Your Answer