Skip to content

Saving Memory

Fredrik Hubinette edited this page Sep 30, 2019 · 7 revisions

If you see this when trying to compile ProffieOS

`.text' will not fit in region `FLASH'

Then the combination of all the features and styles takes up too much space to fit on the board. Here is a list of things you can try to make it fit:

Use "smallest size"

In tools->optimization, you can select "smallest size". This will disable some optimizations that usually make the compiled code bigger. The program will run a little slower, but that is generally not a problem.

Don't use the POV style.

The POV style uses a lot of memory, and most people never really use it. Look for "&pov_style" in your config file and either replace those styles with something else, or remove the preset completely.

Disable diagnostic commands

ProffieOS contains several serial monitor commands which are very useful for diagnosing problems, like "top", "monitor" and "dir". However, disabling these commands can save some memory. To do so you can add

#define DISABLE_DIAGNOSTIC_COMMANDS

to your config file. Note that this define is only available in ProffieOS 3.x and over.

Reduce number of presets, or use simpler styles.

If all else fails, you'll need to reduce the number of presets you use, or use less complicated blade styles.

Clone this wiki locally