I am trying to use the JLink pro to configure, flash and then protect an STM32G4 microcontroller in single bank mode using a jlink commander cli script. I went to the stm32g4 wiki, but have some questions.
Regarding the option bits. The note says that all the option bits should be configured at once. Does this have to be done using the loadfile command?
Also, I configured a jlinkdevices.xml file as described in the wiki.segger.com/STM32G4 page, and used the provided flashloader elf file for single bank mode, but I also wanted to add the 2 option byte sectors to the xml device file. I was wondering if there is a flashloader elf file that could be used for the two option bank sectors. I tried switching between the single bank device setup and dual bank device setup when I needed to program the option bytes, but I am getting RAM errors, and other problems when I try to erase, or adjust the option bytes, and it seems like it would be safer to have it all wrapped into a single device.
Regarding the option bits. The note says that all the option bits should be configured at once. Does this have to be done using the loadfile command?
Also, I configured a jlinkdevices.xml file as described in the wiki.segger.com/STM32G4 page, and used the provided flashloader elf file for single bank mode, but I also wanted to add the 2 option byte sectors to the xml device file. I was wondering if there is a flashloader elf file that could be used for the two option bank sectors. I tried switching between the single bank device setup and dual bank device setup when I needed to program the option bytes, but I am getting RAM errors, and other problems when I try to erase, or adjust the option bytes, and it seems like it would be safer to have it all wrapped into a single device.