booting stm32f1 bulephill from srach using gnu toolchain bare minial setup to run c code . not using standard lib and newlib
- On-chip flash 32kb
- on-chip ram 10kb
- STM32F103c6t6
- VS Code with the Cortex-Debug extension
Untitled.video.-.Made.with.Clipchamp.mp4
If you want to link your program without the default C library (libc
), startup files, and linker script, you can use the following arm-none-eabi-gcc
command:
arm-none-none-eabi-gcc -mcpu=cortex-m3 -mthumb -std=c11 -O1 -g -c main.c -o main.o
arm-none-none-eabi-gcc -mcpu=cortex-m3 -mthumb -std=c11 -O1 -g -c boot.c -o boot.o
arm-none-none-eabi-gcc -nolibc -nostartfiles -T linker.ld -Wl,-Map=blink.elf main.o boot.o -o blink.elf