Thanks Dominic for your perpetual support
Summary of other problems found with openocd/str7 (what about setting some bug tracking system? On Savannah for instance?):
- Only one flash bank defined when the MCU has two. Side effects: one can't do 'flash erase 0 0 9' since openocd sectors 8 and 9 are in MCU bank 1 and the MCU refuses to erase sectors in MCU bank 0 and 1 at the same time.
- Always clear FLASH_ER before any kind of flash query.
- GDB is not able to process some 'monitor' commands: for instance 'monitor flash erase 0 0 7' breaks gdb with '.gdbinit:9: Error in sourced command file: Replay contains invalid hex digit 116'.
Features missing:
- To the md* commands (mdb, mdw, etc.) could show ascii characters on the right of the hexadecimal listing.
- a 'search' feature allow one to give hex data or ascii, a starting address and an ending address, for searching data in memory.
- support of 'readline'.
For the flash/write speed increase, someone at my company is also working on it, using the following scheme:
- the code that will write to the flash is written in C, compiled by arm-elf-gcc, converted to a uint8_t array and sent to the target. The script that does this conversion is a small shell script. using C will allow one to re-use this system to a new target much quicker than it was to get cfi.c modified to work for STR7 with ASM code.
- Instead of using registers to pass parameters, parts of the array are modified. The location to modify are given also by the script that makes the array.
- registers are saved/restored, so one can run a program, halt it, modify the flash, then resume execution (well we hope to have that result
). This is nice when one part of the flash holds parameters for the application: no need to rerun completely the target program.