Hello folks,
I have started playing with latest version (18.2.1), and the built binary for F412ZG demo is around 300kB. When I was using CubeMX and freertos demo for usb, the code size was 30kB. What are some of the things you suggest me to look at in the config/build process. I am a relative newbie so any insights would help! Thanks.
chibios - demo binary size
Moderator: RoccoMarco
Re: chibios - demo binary size
Usually the test harness is included in the build, which generates a printout to some serial port triggered by a button on the hardware.
Look in the loop at the end of main() to see this; remove the call, and maybe remove from makefile
Look in the loop at the end of main() to see this; remove the call, and maybe remove from makefile
- Giovanni
- Site Admin
- Posts: 14893
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 997 times
Re: chibios - demo binary size
Correct, you need to remove the test code from the demo and make sure to compile using -O2, some demos are defaulted to -O0 (no optimizations).
Giovanni
Giovanni
-
chibi-habibi
- Posts: 4
- Joined: Sat Nov 10, 2018 5:46 am
Re: chibios - demo binary size
@steved/@giovanni: Thanks for the quick responses -- will check it out.