I have been keeping track of my flash and RAM usage since I know I'm getting close to filling up my STM32F030R8T6 microcontroller. Mostly I'm running out of Flash, but RAM is getting full too.
From lots of form posts, I'm pretty confident that my flash usage is Code + RO-data + RW-data, and that makes sense to me. But today I compiled and linked successfully, even though they add up to more flash space than my micro has.
linking...Program Size: Code=49516 RO-data=13604 RW-data=3304 ZI-data=3544 FromELF: creating hex file...
linking...
Program Size: Code=49516 RO-data=13604 RW-data=3304 ZI-data=3544
FromELF: creating hex file...
So this would be 49516 + 13604 + 3304 = 66424 bytes. This is larger than the 64K (65536 bytes) available on the Flash. I am running my target device and everything is working fine.
So my question is, am I misinterpreting the Program Size readout as it pertains to flash space, or am I misinterpreting the datasheet for the STM32F030R8T6 flash size?