rsta2 / circle

A C++ bare metal environment for Raspberry Pi with USB (32 and 64 bit)
https://circle-rpi.readthedocs.io
GNU General Public License v3.0
1.85k stars 245 forks source link

Kernel image size increase #386

Closed dlbogdan closed 1 year ago

dlbogdan commented 1 year ago

Hi, I want to embed fonts and other glyphs and graphics in the source thus bloating the kernel image beyond 2MB potentially quite quickly. is there a way to increase the 2MB limit for the kernel image size?

Reference: doc/memorymap.txt

ArnoldUK commented 1 year ago

See include\sysconfig.h and set the value for KERNEL_MAX_SIZE

dlbogdan commented 1 year ago

Thanks! I wasn’t aware of sysconfig.h at all.

rsta2 commented 1 year ago

It's mentioned in the main README. ;)

dlbogdan commented 1 year ago

Oops :) I only read (most of) the readthedocs pages. This is a statement in itself though of how good circle is written that I did not really had to go through all the documentation to start working on projects with Circle.

ArnoldUK commented 1 year ago

Yes, the sysconfig.h was recently updated to allow passing KERNEL_MAX_SIZE in your makefile without having to change the value in sysconfig.h so multiple projects can have a different size kernel. Do Remember to rebuild the circle libs after changing it as I found out after hours of hair pulling.

dlbogdan commented 1 year ago

Oh I rebuild circle, stdlib/newlib lvgl and a few others pretty often (at least once a day) as I test my project with a pi0 and a pi3A+ and I am very interested in performance so it matters to recompile. Thanks for the tip!