How to program STM32F103RE on Creality v4.2.7 silent 3D Printer board [solved]
I have written an open source 3D Printer firmware for Arduino Mega - RAMPS 1.6 board which i have uploaded to github: https://github.com/3DHexfw/3DHex
Now i am trying to port the code to Creality v4.2.7 board (STM32F103RE on board). To do so i have downloaded SMT32Cube in order to initilize the peripherals, write and build the code.
Creality v4.2.7 board comes with pre-installed bootloader so the firmware.bin(compiled) can be uploaded directly from micro-SD card without the need of external programmer.
My first attempt was just to set HIGH one of the output pins, code on github: https://github.com/3DHexfw/3DHex/blob/master/MCU/Creality/Creality_v4.2.7_Silent/Core/Src/main.c
The steps i followed:
- Build the source with STM32Cube
- Move generated firmware.bin to SD card
- Insert the SD with firmware.bin to the slot
- Power up the board to load the firmware
For the time being i cannot make it to work.
Do i have to edit the linker file for the STM32 project, so that it doesn't try to use the flash memory space used by the bootloader? I am not sure how to do it and what is the offset.
Any suggestions?
Notes:
- I can upload any other 3d printer firmware.bin at any time, no issue here.
- It is important to be able to upload the firmware.bin by micro sd
