Config.h / Style / Workbench Questions

I’ll try to answer, although a little confused on a few things.

Let’s start at the top, Workbench can only edit what exists on the board already (from a previous upload). This goes for styles, colors, options, etc. (Fonts would be the exception since they reside on your SD outside the OS). So to be able to change a style for any given preset it had to have been uploaded to some preset via your config previously.

This is also why we can’t integrate the library and the Workbench, you have to first upload the style code the library generates to your board via Arduino for it to exist, then once it exists on the board it can be used in any preset you want. There’s no way to take the style code directly from the library to the Workbench.

If you’re asking if you can remove your 2nd blade from your config but add it back via Workbench, then the answer is “No”, the blade exists in more than just the style, your BladeConfig needs to know the second blade exists to include the code necessary to run it, so it must be there in your config and uploaded via Arduino for it to exist to be edited.

You can reduce the “repetition” in your config if you are just reusing the same styles in multiple presets via a “using”, the Library can output this for you, see this thread:

This will allow you to simplify the presets where you’re repeating the same styles.

You can also use the library to build “Option Styles” this will make it so you can edit the style via “Style Option” instead of “builtin 01” as you can combine several base styles into one and designate the base style via “Style Option”, this is handled by the library as well and also saves additional memory as it reuses other layers that would normally be replicated. You can build these from the first screen of the library by adding additional “Style Options” before going into the “Preview / Enhancement Screen” and you can generate the “Using Function” as noted above to then have the style options built out to be repeated.

Note, the library will generate the copyright comment with the assigned Style Option # for each selected base style, the comments generated by the library are your receipt and are meant to be used with either Edit Mode or Workbench to help you identify the style or option.
“builtin 0 1” refers to the style for first preset (0) and first blade (1) so you can keep a copy of your config to determine which style that represents. I’m not sure there’d be a way to rename the “builtin 0 1” etc. as the OS reads those to determine the style code to use.

I discussed more “space saving” with Megtooth in this video, it might be worth a watch as well.

1 Like