This is an awesome guide, thank you! I do have one question though.
> Our firmware will be copied to the flash region at offset 0x8000000, but our data section should reside in RAM
> therefore our _reset() function should copy the contents of the .data section to RAM.
> Also it has to write zeroes to the whole .bss section.
I'm confused by this. The linker places these sections on flash memory. How does the compiler know to use section we copied to RAM for the variables in the code?
> Our firmware will be copied to the flash region at offset 0x8000000, but our data section should reside in RAM
> therefore our _reset() function should copy the contents of the .data section to RAM.
> Also it has to write zeroes to the whole .bss section.
I'm confused by this. The linker places these sections on flash memory. How does the compiler know to use section we copied to RAM for the variables in the code?