Have you ever been in the pecculiar situation, where you want to program your STM32xx but the only interface you have left over on your super awesome pcb is the I2C pins?
Me neither, but i still created this tool, to allow you, me and everyone to flash their STM32xx with nothing but an Arduino mega and their computer.
The aim of this project is to make a tool to easily flash STM32xx microprocessors over I2C with the Arduino, as well as making porting the code to another architecture (STM32xx probably) as easy as possible.
While doing this, i will hopefully become better at and/or learn about:
- Writing classes
- Virtual functions
- Abstract and interface classes
- I2C communication
- UART communication
- Python stuffs
Well I'm glad you asked:
- Use the python script
bin_to_h.py
to convert any.bin
file to a header file - Edit the cpp file to use your new header file
- Flash the program to your arduino mega
- Connect the I2C line from the arduino to the STM32xx
- Reboot the STM32xx into system boot mode
- Run the arduino code
- Profit
This is a work in progress.
It has therefore only been tested on the STM32H7B0VBT.
My code is probably full of bugs
The following datasheets, application notes and reference manuals have been used to some degree in this project:
If you're interested in that kinda stuff, it can be found right here