ProffieOS6 & 7 Edit Mode

ProffieOS6 & 7 Edit Mode

One of the largest additions in OS6 is the new "Edit Mode" which allows you to make nearly all fine-tuning edits to your saber without the need to re-upload your config via Arduino. "Edit Mode". I designed Edit Mode to not only help new users and installers but to let your Proffieboard saber work like a hybrid between everything that makes Proffieboard so powerful with very simple, easy to use controls for adjusting your saber without the need to hook up to a computer. Working very closely with Fredrik I've built out a feature-rich, user-friendly menu system that lets you quickly and easily edit nearly every aspect of your saber. In addition, the capabilities that make Edit Mode possible will also allow you to edit your saber using the .ini files on your SD or via WebUSB as well. So there will be many ways to edit your saber.

Proffieboard v3.6 Plugin for Arduino required:


 

To enable Editing capabilities you must include:

#define ENABLE_ALL_EDIT_OPTIONS

To enable the on-board menu system you will also need to use:

#define FETT263_EDIT_MODE_MENU

If you choose not to enable the menu system you can still take advantage of Edit Mode with WebUSB using Fredrik's "ProffieOS Workbench" or by manually editing .ini files on your SD card.

#define DISABLE_BASIC_PARSER_STYLES

Required for my prop and edit mode. The Edit Mode styles replace the need for the basic parser styles, this define saves a lot of memory and you can add more styles with more functionality and get same results.

It is also strongly recommended you include:

#define DISABLE_DIAGNOSTIC_COMMANDS

Recommended for additional memory saving, will disable most Serial Monitor commands.


*requirements for ProffieOS Workbench: https://github.com/profezzorn/ProffieOS/wiki/WebUSB

NOTE: Your SD card contents (particularly the .ini files), in addition to making a backup copy of your config and all of your fonts on your computer or other storage device it is also strongly recommended that you save copies of your .ini files so that if an SD card is damaged, corrupted or reformatted you can easily re-apply your edits. Once you have your saber set up how you want it is a "best practice" to save the .ini files with all of the SD card content.

Fett263 Patreon:

Many of the new features are the result of my over-active imagination, brought to life with a lot of help and guidance from Fredrik. I've put in countless hours for R&D, testing, coding and debugging already with a lot more to come. While I do this for the fun of the hobby and to keep pushing the envelope of what is possible with Proffieboard lightsabers, there's a lot of time and effort involved. I've already begun building the ALL NEW! ProffieOS6 Style Library and it will have a ton of new features and styles but it's going to take even more time and effort to build and maintain it going forward, for this reason I am launching a Patreon page for those that want to help out by becoming patrons.

I appreciate all who've donated in the past on my previous libraries and once OS6 releases a lot of time will continue to go into creation for the new OS6 library and documentation to support everything possible.


 

Edit Mode

Nearly every aspect of the saber can be edited, if set up to do so when uploading. Please note you can only "Edit" what exists on the board, if you need to add features or styles you still need to upload a new config and OS.

Edit Mode Menu Controls

Controls while using the Edit Mode menu, while in Edit Mode all other controls and effects are disabled.

2 / 3 Button:

  • Enter Edit Mode = While Off, Hold AUX + Hold PWR
    • If menu prompt wav files are missing from preset you will get "Error in Font Directory" warning, refer to Edit Mode setup and requirements

While in Edit Mode the controls are as follows:

  • Rotate Forward, Increase Value, Confirm "Yes" = Turn Right
  • Rotate Back, Decrease Value, Confirm "No" = Turn Left
  • Select, Save, Enter = Click PWR
  • Cancel, Revert, Go Back = Click AUX
  • Go to Main Menu (from sub-menu) - Hold AUX
  • Exit Edit Mode - Hold AUX (or rotate to "Exit") while in Main Menu, saber returns to normal operation

"Edit Color" Additional Control

  • "Color List" and "Adjust Color Hue" Zoom Mode = Long Click PWR

1 Button:

  • Enter Edit Mode = While Off, Double Click and Hold PWR
    • If menu prompt wav files are missing from preset you will get "Error in Font Directory" warning, refer to Edit Mode setup and requirements

While in Edit Mode controls are as follows:

  • Rotate Forward, Increase Value, Confirm "Yes" = Turn Right
  • Rotate Back, Decrease Value, Confirm "No" = Turn Left
  • Select, Save, Enter = Click PWR
  • Cancel, Revert, Go Back = Long Click PWR
  • Go to Main Menu (from sub-menu) = Hold PWR
  • Exit Edit Mode = Hold PWR (or rotate to "Exit") while in Main Menu

"Edit Color" Additional Control

  • "Color List" and "Adjust Color Hue" Zoom Mode = Double Click PWR

 

Menu Structure

  • Edit Style - select from any style uploaded to the board
    • Select Style - change the style for any preset by selecting from style numbers uploaded to the board
      • Style number refers to the original order of styles uploaded via Arduino starting at "Style 0"
    • Edit Style Settings - change settings for styles, ignition, retraction, clash, lockup, drag, emitter effects, preon and more:
      • STYLE_OPTION_ARG
      • IGNITION_OPTION_ARG
      • IGNITION_TIME_ARG
      • IGNITION_DELAY_ARG
      • IGNITION_POWER_UP_ARG
      • RETRACTION_OPTION_ARG
      • RETRACTION_TIME_ARG
      • RETRACTION_DELAY_ARG
      • RETRACTION_COOL_DOWN_ARG
      • LOCKUP_POSITION_ARG
      • DRAG_SIZE_ARG
      • MELT_SIZE_ARG
      • SWING_OPTION_ARG
      • EMITTER_SIZE_ARG
      • OFF_OPTION_ARG
      • PREON_OPTION_ARG
      • PREON_SIZE_ARG
  • Edit Color - edit effect colors individually using Color List, Adjust Color Hue, Adjust White Level and Adjust Black level to achieve all possible colors.
    • Availble Color Arguments:
      • BASE_COLOR_ARG
      • ALT_COLOR_ARG
      • BLAST_COLOR_ARG
      • CLASH_COLOR_ARG
      • LOCKUP_COLOR_ARG
      • DRAG_COLOR_ARG
      • LB_COLOR_ARG
      • STAB_COLOR_ARG
      • PREON_COLOR_ARG
      • IGNITION_COLOR_ARG
      • RETRACTION_COLOR_ARG
      • POSTOFF_COLOR_ARG
      • SWING_COLOR_ARG
      • EMITTER_COLOR_ARG
      • OFF_COLOR_ARG
    • Color List
      • Rotate through specific colors to select
    • Adjust Color Hue
      • Use ColorWheel to change Color Hue
    • Adjust White Level
      • Use White Level to brighten color up to White
    • Adjust Black Level
      • Use Black Level to dim color to "near"-Black.
    • For sabers with multiple blades you can Copy Colors, to re-use set colors for applicable blades on Dual or Crossguard sabers without needing to do each individually
    • You can also Reset Colors to default values loaded in original config
  • Edit Font - easily choose any valid font loaded on your SD card for each preset without needing to re-upload config
  • Edit Track - easily choose any default track from your font or common folder with needing to re-upload config
  • Edit Settings - easily edit many of the settings for you saber:
    • Edit Volume - edit volume, max is based on VOLUME in original config
    • Edit Control Settings - enable/disable individual gesture controls, set control settings for applicable gestures
      • Swing On Ignition
      • Swing On Speed (sets swing speed needed to ignite)
      • Twist On Ignition
      • Thrust On Ignition
      • Stab On Ignition
      • Twist Off Retraction
      • Power Lock (when enabled locks Power button, to turn saber off hold both buttons until saber turns off)
      • Force Push
      • Force Push Length (movement distance to trigger Force Push)
      • Lockup Delay (for Battle Mode - time to "steady" blade after a clash for Lockup to trigger)
      • Clash Detect (for Battle Mode 2.0 - maximum clash strength to detect clash during Battle Mode (0 = disable, 10 = max)
      • Max Clash (maximum clash level for "Real Clash" Sound functionality (8 ~ 16)
    • Edit Clash Threshold - adjust Clash Threshold from the saber menu without needing to re-upload config
    • Edit Blade Length - adjust Blade Length from the saber menu without needing to re-upload
    • Edit Brightness - dim ALL blades from the saber menu without needing to re-upload
  • Copy Presets - make as many copies of your initial presets as you want, then use all of the edit features to created completely new and unique presets; fonts, tracks, style settings, colors and more.
  • Delete Presets - have a preset that you're not using, easily delete it right from the menu

Set Up for Edit Mode

In order to be able to edit the various aspects of the saber they need to be set up correctly before you upload your config and OS via Arduino.

 

Setting up your SD card

#1 - be sure to create a copy of all of your SD card contents AND your config on your PC when uploading. SD cards can go bad so even if you don't plan to use Edit Mode it's recommended practice.

#2 - If you are an installer you must include a copy of the config.h file for all customers, preferably saved in the root directory of the SD card. This will become even more important than usual with OS6 as the config will contain information needed for users as they make edits.

#3 - If you are purchasing from an installer be sure they have included a copy of the config.h file, as noted in #2 this is very important.

#4 - Edit Mode and several other features in my prop file require new spoken prompts. These prompts must either be in each font folder or in a 'common' folder so that they are accessible to the saber no matter what font is active.


*Thank you to Brian Conner for all his work to create multiple versions and languages. You can also create your own, the required prompts and filenames are listed in "Menu Prompts / Sound File Naming".

#5 - 'common' folder (all lowercase) must exist on your SD to use the Edit Mode menu or ProffieOS Workbench. This folder should contain all menu prompt sounds noted above. If this folder and/or the necessary sounds are missing you will not be able to use the Menu system.

#6 - The Track Player and Edit Track functionality require a 'tracks' folder exist in each font and/or the 'common' folder. Track Player and Edit Track search the font and 'common' folders for a 'tracks' folder and use the files found. If you want tracks specific to each font you will add a /tracks folder with those tracks into each font folder on your SD. If you have tracks that you want universally you will add them to the 'common/tracks' folder. Both will be searched when these functions are used. If you have a 'tracks' folder in your root directory it will not be used in either function.

Example:

  • /Luke/tracks/
  • /common/tracks/

#7 - All edits are saved on your SD card as .ini files. After making edits be sure to create backups of these .ini files in case your SD card is corrupted or damaged, this will allow you to keep all edits, otherwise if the .ini files are not on your SD, all presets will return to the default settings from your original config.

Setting up your Config

There are several defines and mutliple things you'll be setting up in your config to enable Edit Mode to function. Once set up Edit Mode will allow you to edit whatever has been set up in the config for editing, if you need to add styles, effects or features you will need to upload a new config.

Required / Recommended defines (must be added to CONFIG_TOP section of config file):

#define ENABLE_ALL_EDIT_OPTIONS // required for Edit Mode functionality

#define FETT263_EDIT_MODE_MENU // required for menu system

#define DISABLE_BASIC_PARSER_STYLES // required for memory saving and using built-in styles for ProffieOS Workbench

#define FETT263_SAY_COLOR_LIST // recommended to enable spoken color names in Color List editing

#define FETT263_SAY_COLOR_LIST_CC // recommended to enable spoken color names for Color List Color Change Mode

#define DISABLE_DIAGNOSTIC_COMMANDS // recommended for additional memory saving, will disable most Serial Monitor commands.

For all other optional defines refer to top section of my prop file.

Setting Max Volume

Edit Volume (and Volume Menu) allow you to set and save the saber's volume. Your config will determine the maximum volume level to protect your speaker.

#define VOLUME 1500 // this value is used as Maximum Volume, determine the best value based on your speaker/saber.

Setting Max Blade Length

Edit Blade Length allows you to adjust the blade length on any blade with more than 1 pixel. The config file will set the maximum length for any blade or sub-blade. This is set in the BladeConfig located at the bottom of your config file. If you expect to use longer blades in the future you will want to set these value accordingly.

BladeConfig blades[] = {
{ 0, WS281XBladePtr<136, bladePin, Color8::GRB, PowerPINS<bladePowerPin2, bladePowerPin3> >(),
WS281XBladePtr<6, blade2Pin, Color8::GRB, PowerPINS<bladePowerPin4> >()
, CONFIGARRAY(presets) },
};

The 136 value is the maxiumum length for the main blade in this particular saber, meaning I can use any blade up to 136 pixels and then set the blade length using Edit Mode. If I need to use a blade longer than 136 pixels I will need to reupload the config with a new maximum length value.

The 6 value is for the accent pixels on this saber, they are technically built into the chassis but could still be edited if I wanted for any value between 1 ~ 6.

The same concept applies to SubBlades, the length set for each SubBlade is used as the maximum length for that blade, you can edit the length between 1 and the maximum length.

Accents or "blades" set as 1 pixel cannot be edited, we can never have zero pixels.

Edit Styles

You can change the style on any preset using Edit Styles, the order of the styles during selection is determined by the config. When rotating through the styles they will be shown based on the order of the presets in the config when uploaded. Changing a style in Edit Mode does not affect this order but styles will begin based on the current active style.

#ifdef CONFIG_PRESETS

Preset presets[] = {

{ "font;common", "font/tracks/track.wav",
style 0
},

{ "font;common", "font/tracks/track.wav",
style 1
},

...

};

For both memory optimization and overall experience it is highly recommended that OS6 editable styles be used. Mixing styles from previous OS versions or that do not contain editable settings and colors can make different styles act differently in Edit Mode.

For Alpha/Beta Testing I have pre-built styles for use until the new OS6 Style Library is completed.


 

Edit Style Settings & Edit Colors

The Edit Style Settings and Edit Colors for both Edit Mode and ProffieOS Workbench require styles be set up to use the Edit Mode Arg values listed above. You can only edit the settings/colors that are set up in each style.

Styles that do not contain Edit Mode Arg values can still Edit Style to change the style but the settings and colors will not be editable. When the ProffieOS6 library is launched it will contain styles built for Edit Mode.

Available Arguments/Variables:

  • Style Settings
    • STYLE_OPTION_ARG
    • IGNITION_OPTION_ARG
    • IGNITION_TIME_ARG
    • IGNITION_DELAY_ARG
    • IGNITION_POWER_UP_ARG
    • RETRACTION_OPTION_ARG
    • RETRACTION_TIME_ARG
    • RETRACTION_DELAY_ARG
    • RETRACTION_COOL_DOWN_ARG
    • LOCKUP_POSITION_ARG
    • DRAG_SIZE_ARG
    • MELT_SIZE_ARG
    • SWING_OPTION_ARG
    • EMITTER_SIZE_ARG
    • OFF_OPTION_ARG
    • PREON_OPTION_ARG
    • PREON_SIZE_ARG
  • Editable Colors
    • BASE_COLOR_ARG
    • ALT_COLOR_ARG
    • BLAST_COLOR_ARG
    • CLASH_COLOR_ARG
    • LOCKUP_COLOR_ARG
    • DRAG_COLOR_ARG
    • LB_COLOR_ARG
    • STAB_COLOR_ARG
    • PREON_COLOR_ARG
    • IGNITION_COLOR_ARG
    • RETRACTION_COLOR_ARG
    • POSTOFF_COLOR_ARG
    • SWING_COLOR_ARG
    • EMITTER_COLOR_ARG
    • OFF_COLOR_ARG

 

Demo Videos:

Edit Mode Menu Controls

ProffieOS6 Workbench (WebUSB, Bluetooth)

 

 



 

©2021 Fett263. All rights reserved.