What I don't know (actually expect the answer is no) is if I can do something like:
like you might do with:
And if it were still Christmas ...
I am with Frank and wishing for easier ability for each project(sketch) to better control different settings and features... I personally HATE libraries that have internal setting files that assume you only have one setup... Like RA8875 or ...
Again I don't know how easy some of these work or don't, and I know some of these have been talked about before, but they probably require a lot of @Paul's time which is probably already reasonably full
. But maybe some can be experimented with by others and if they work do a Pull Request... Example different linker scripts. How hard is it to change some of the default locations? I don't know never tried, but if not hard. Then can we create a couple or a few and then simply add new menu item in boards.txt to choose which one?
I still don't understand the usage/power of has_include?
That is with something like we are trying with some of the font files that looks like:
Code:
#if __has_include(<RA8875.h>)
#include "RA8875.h"
#elif __has_include(<ILI9488_t3.h>)
#include "ILI9488_t3.h"
#elif __has_include(<ILI9341_t3n.h>)
#include "ILI9341_t3n.h"
#elif __has_include(<ILI9341_t3.h>)
#include "ILI9341_t3.h"
#elif __has_include(<ST7735_t3.h>)
#include "ST7735_t3.h"
#endif
Can this be used with libraries (or core), with something like:
#if __has_include("user_settings.h")
#include "user_settings.h"
#endif
Again at some point would like to experiment with this.
FLASHMEM or not to FLASHMEM...
The difficulty I have with going through library code and adding FLASHMEM to everything is, it is so project dependent. That is suppose I should go through ILI9341_t3n and mark everything as FLASHMEM? Especially if in some projects, the display is only updated at low frequency, like maybe the time a well pump last ran... BUT then the next project may be to display an RPM meter and the person needs the display code to run as fast as possible? So then maybe I should invent some new define, like: DISPLAY_CODE_SPEED which can be set to FLASHMEM or not. But then how granular? Maybe this sketch only uses ILI fonts? So the GFX font support could/should be left in FLASH (or gone)... Maybe I use tft.printf(...) so now I want printf support in fast memory, other times maybe not...