-
Notifications
You must be signed in to change notification settings - Fork 43
/
ConfigMenu.h
42 lines (31 loc) · 2.17 KB
/
ConfigMenu.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
/*
* Config.h
*
* author: Sebastien CAPOU (neskweek@gmail.com) and Andras Kun (kun.andras@yahoo.de)
* Source : https://github.com/Protonerd/FX-SaberOS
*/
#include <Arduino.h>
#include "Config_HW.h"
#include "Config_SW.h"
#if not defined CONFIGMENU_H_
#define CONFIGMENU_H_
#include <WS2812.h>
enum SaberStateEnum {S_STANDBY, S_SABERON, S_CONFIG, S_SLEEP, S_JUKEBOX};
enum ActionModeSubStatesEnum {AS_HUM, AS_IGNITION, AS_RETRACTION, AS_BLADELOCKUP, AS_PREBLADELOCKUP, AS_TIPMELT, AS_BLASTERDEFLECTMOTION, AS_BLASTERDEFLECTPRESS, AS_CLASH, AS_SWING, AS_SPIN, AS_FORCE, AS_LASTMEMBER}; // never delete AS_LASTMEMBER!!! Needed to calculate number of elements in the enum type!!!
// configure the config menu based on the blade type
#if defined LEDSTRINGS
enum ConfigModeSubStatesEnum {CS_SOUNDFONT, CS_FLICKERTYPE, CS_MAINCOLOR, CS_CLASHCOLOR, CS_BLASTCOLOR, CS_SWINGSENSITIVITY, CS_VOLUME, CS_SLEEPINIT, CS_BATTERYLEVEL, CS_LASTMEMBER, CS_POWERONOFFTYPE, CS_STORAGEACCESS, CS_UARTMODE}; // never delete CS_LASTMEMBER!!! Needed to calculate number of elements in the enum type!!!
#endif
#if defined STAR_LED or defined ADF_PIXIE_BLADE
enum ConfigModeSubStatesEnum {CS_SOUNDFONT, CS_FLICKERTYPE, CS_MAINCOLOR, CS_CLASHCOLOR, CS_BLASTCOLOR, CS_SWINGSENSITIVITY, CS_VOLUME, CS_SLEEPINIT, CS_BATTERYLEVEL, CS_LASTMEMBER, CS_POWERONOFFTYPE, CS_STORAGEACCESS, CS_UARTMODE}; // never delete CS_LASTMEMBER!!! Needed to calculate number of elements in the enum type!!!
#endif
#if defined PIXELBLADE
enum ConfigModeSubStatesEnum {CS_SOUNDFONT, CS_FLICKERTYPE, CS_MAINCOLOR, CS_CLASHCOLOR, CS_BLASTCOLOR, CS_SWINGSENSITIVITY, CS_VOLUME, CS_SLEEPINIT, CS_BATTERYLEVEL, CS_LASTMEMBER, CS_POWERONOFFTYPE, CS_STORAGEACCESS, CS_UARTMODE}; // never delete CS_LASTMEMBER!!! Needed to calculate number of elements in the enum type!!!
#endif
// ====================================================================================
// === CONFIG MODE FUNCTIONS ===
// ====================================================================================
void confParseValue(uint16_t variable, uint16_t min, uint16_t max,
short int multiplier);
void NextConfigState();
#endif /* CONFIG_H_ */