I first read about FONT_PATTERN here:
Then in the POD:
The first problem I have is with the POD itself:
- when an asterix (
*
) is used in the text, instead of showing an*
symbol, I will start to see text in italic starting where the first*
was supposed to show and finishing when the next*
was supposed to appear but doesn’t however the text is “no longer in italic” (I am using Firefox browser on Windows10 if that makes any difference)
I know that I am not supposed to post screenshot of text (and I will be very happy to delete this screenshot) but this is what I see:
Edit: screenshot deleted.
No asterix (*
) is showing in the text. I can only understand the POD because I re-read multiple times both the POD and the “gearing-up-for-os8” thread about FONT_PATTERN. By the way, the define “FONT_PATTERN” text doesn’t seem to be able to “automatically” turn itself into a link like CONFIG_TOP does.
Now that my preliminary thoughts about FONT_PATTERN are out of the way, I will try my best to explain what I thought it would be able to do when I first read about it, what I think it actually does & what I think it “should” be able to do.
- what I thought it would do:
- Let’s imagine OS8.x is live (no longer in Beta testing)
- the config generator has been updated to the latest OS8.x bells and whistles
- a new to ProffieOS user comes along and make his first ever simple OS8 config with 1 blade and 2 buttons. I would imagine it would look like this:
// ProffieOS8 config
#ifdef CONFIG_TOP
#include "proffieboard_v3_config.h"
#define NUM_BLADES 1
#define NUM_BUTTONS 2
#define VOLUME 1000
const unsigned int maxLedsPerStrip = 144;
#define CLASH_THRESHOLD_G 1.0
// <- note the "missing defines" that are no longer here because they are "ON" by default in OS8, including the new #define FONT_PATTERN "*;common"
#endif
#ifdef CONFIG_PRESETS
Preset presets[] = {
{ "TeensySF", "tracks/venus.wav",
StyleNormalPtr<CYAN, WHITE, 300, 800>(), "cyan"},
{ "SmthJedi", "tracks/mars.wav",
StylePtr<InOutSparkTip<EASYBLADE(BLUE, WHITE), 300, 800> >(), "blue"},
{ "SmthGrey", "tracks/mercury.wav",
StyleFirePtr<RED, YELLOW>(), "fire"},
{ "SmthFuzz", "tracks/uranus.wav",
StyleNormalPtr<RED, WHITE, 300, 800>(), "red"},
{ "RgueCmdr", "tracks/venus.wav",
StyleFirePtr<BLUE, CYAN>(), "blue fire"},
{ "TthCrstl", "tracks/mars.wav",
StylePtr<InOutHelper<EASYBLADE(OnSpark<GREEN>, WHITE), 300, 800> >(), "green"},
{ "TeensySF", "tracks/mercury.wav",
StyleNormalPtr<WHITE, RED, 300, 800, RED>(), "white"},
{ "SmthJedi", "tracks/uranus.wav",
StyleNormalPtr<AudioFlicker<YELLOW, WHITE>, BLUE, 300, 800>(), "yellow"},
{ "SmthGrey", "tracks/venus.wav",
StylePtr<InOutSparkTip<EASYBLADE(MAGENTA, WHITE), 300, 800> >(), "magenta"},
{ "SmthFuzz", "tracks/mars.wav",
StyleNormalPtr<Gradient<RED, BLUE>, Gradient<CYAN, YELLOW>, 300, 800>(), "gradient"},
{ "RgueCmdr", "tracks/mercury.wav",
StyleRainbowPtr<300, 800>(), "rainbow"},
{ "TthCrstl", "tracks/uranus.wav",
StyleStrobePtr<WHITE, Rainbow, 15, 300, 800>(), "strobe"},
{ "TeensySF", "tracks/venus.wav",
&style_pov, "POV"},
{ "SmthJedi", "tracks/mars.wav",
&style_charging, "Battery\nLevel"}
};
BladeConfig blades[] = {
{ 0, WS281XBladePtr<144, bladePin, Color8::GRB, PowerPINS<bladePowerPin2, bladePowerPin3> >(), CONFIGARRAY(presets) },
};
#endif
#ifdef CONFIG_BUTTONS
Button PowerButton(BUTTON_POWER, powerButtonPin, "pow");
Button AuxButton(BUTTON_AUX, auxPin, "aux");
#endif
Then that user would add a CONFIG_PROP section with a prop file that needs a voicepack.
4) that same user would have downloaded and “installed” the default SD font/tracks package on his SD card and a voicepack in a common folder on his SD card as well (let’s just say for the sake of arguments that all the files “that should be on his SD-card” are exactly where they should be, “lucky first try user”)
5) he is not aware that the default presets could and should be changed from “TeensySF” to “TeensySF;common” so he doesn’t do it.
6) because of the hidden “magic” of FONT_PATTERN, everything worked perfectly on the first try. What a lucky first time user!
That is what I was expecting/hoping FONT_PATTERN would do after reading the “gearing-up-for-os8” thread for the first time. I don’t think it can do that?
-
what I now think it does:
- if a user wants his common folder to be named anything else than “common”, let’s use “_my_common” for this discussion.
- That same user has all his presets programmed correctly: “TeensySF;_my_common”, “SmthJedi;_my_common”, …
- and he has
#define FONT_PATTERN "*;_my_common"
in his config. - he starts using Edit Mode via one of the MENU_SPEC_TEMPLATE option and edit his presets. His edited NewFont preset will have
"NewFont;_my_common"
as a search path for his “*.wav
” files. - I don’t know if this will also apply with saber_fett263_buttons.h if
#define FETT263_EDIT_MODE_MENU
is defined instead of MENU_SPEC_TEMPLATE or not?
-
what I whish it could do: everything I wrote about above, plus be some sort of an “OS wide
*.wav
(and maybe even*.bmp/pbm/pqf
) global search path” for any non-font specific file like voicepack/sound_library sounds, error sounds, multi_prop sounds, any and all spoken digits/numbers, battery, …
First ProffieOS looks in the font folder, then in the FONT_PATTERN “default folder” no matter if it is in the preset “font folder path” or not. And then only after that a beeper or talkie sound could be initiated if the*.wav
file is missing. Maybe I am dreaming ?