changed motor settings

This commit is contained in:
Peter Slattery 2021-04-07 12:16:01 -07:00
parent e5be1298d1
commit 249082170b
1 changed files with 14 additions and 56 deletions

View File

@ -19,8 +19,8 @@ gs_const_string Flower2AssemblyPath = ConstString("data/ss_blumen_three.fold");
gs_const_string PhraseMapCSVPath = ConstString("data/flower_codes.csv"); gs_const_string PhraseMapCSVPath = ConstString("data/flower_codes.csv");
char PhraseMapCSVSeparator = ','; char PhraseMapCSVSeparator = ',';
// Search Strings for which folders to find ambient animation files and // Search Strings for which folders to find ambient animation files and
// voice animation files in. // voice animation files in.
// these search patterns should always end in *.foldanim so they only // these search patterns should always end in *.foldanim so they only
// return valid animation files // return valid animation files
gs_const_string AmbientPatternFolder = ConstString("data/blumen_animations/ambient_patterns/*.foldanim"); gs_const_string AmbientPatternFolder = ConstString("data/blumen_animations/ambient_patterns/*.foldanim");
@ -30,57 +30,15 @@ gs_const_string VoicePatternFolder = ConstString("data/blumen_animations/audio_r
// these are in the format { Start_Hour, Start_Minute, End_Hour, End_Minute } // these are in the format { Start_Hour, Start_Minute, End_Hour, End_Minute }
// Hours are in the range 0-23 inclusive // Hours are in the range 0-23 inclusive
// Minutes are in the range 0-59 inclusive // Minutes are in the range 0-59 inclusive
// NOTE: There is no need to modify the MotorOpenTimesCount variable - // NOTE: There is no need to modify the MotorOpenTimesCount variable -
// it is a compile time constant that gets calculated automatically // it is a compile time constant that gets calculated automatically
global time_range MotorOpenTimes[] = { global time_range MotorOpenTimes[] = {
{ 00, 30, 00, 40 }, { 08, 45, 17, 45 },
{ 00, 50, 01, 00 }, { 19, 00, 23, 00 },
{ 01, 10, 01, 20 },
{ 01, 30, 01, 40 },
{ 01, 50, 02, 00 },
{ 02, 10, 02, 20 },
{ 02, 30, 02, 40 },
{ 02, 50, 03, 00 },
{ 03, 10, 03, 20 },
{ 03, 30, 03, 40 },
{ 03, 50, 04, 00 },
{ 04, 10, 04, 20 },
{ 04, 30, 04, 40 },
{ 04, 50, 05, 00 },
{ 05, 10, 05, 20 },
{ 05, 30, 05, 40 },
{ 05, 50, 06, 00 },
{ 06, 10, 06, 20 },
{ 06, 30, 06, 40 },
{ 06, 50, 07, 00 },
{ 07, 10, 07, 20 },
{ 07, 30, 07, 40 },
{ 07, 50, 8, 00 },
{ 8, 10, 8, 20 },
{ 8, 30, 8, 40 },
{ 8, 50, 9, 00 },
{ 9, 10, 9, 20 },
{ 9, 30, 9, 40 },
{ 9, 50, 10, 00 },
{ 10, 10, 10, 20 },
{ 10, 30, 10, 40 },
{ 10, 50, 11, 00 },
{ 11, 10, 11, 20 },
{ 11, 30, 11, 40 },
{ 11, 50, 12, 00 },
{ 12, 10, 12, 20 },
{ 12, 30, 12, 40 },
{ 12, 50, 13, 00 },
{ 13, 10, 13, 20 },
{ 13, 30, 13, 40 },
{ 13, 50, 14, 00 },
{ 14, 10, 14, 20 },
{ 14, 30, 14, 40 },
{ 14, 50, 15, 00 },
}; };
global u32 MotorOpenTimesCount = CArrayLength(MotorOpenTimes); // do not edit global u32 MotorOpenTimesCount = CArrayLength(MotorOpenTimes); // do not edit
// How long it takes to fade from the default pattern to the // How long it takes to fade from the default pattern to the
// voice activated pattern // voice activated pattern
r32 VoiceCommandFadeDuration = 1.0f; // in seconds r32 VoiceCommandFadeDuration = 1.0f; // in seconds
@ -90,14 +48,14 @@ r32 VoiceCommandFadeDuration = 1.0f; // in seconds
// ie. // ie.
// if this is set to 30 seconds, upon receiving a voice command // if this is set to 30 seconds, upon receiving a voice command
// lumenarium will fade to the requested pattern/color palette // lumenarium will fade to the requested pattern/color palette
// and then wait 30 seconds before fading back to the original // and then wait 30 seconds before fading back to the original
// pattern. If, in that 30 second window, another voice command // pattern. If, in that 30 second window, another voice command
// is issued, lumenarium will reset the 30 second counter. // is issued, lumenarium will reset the 30 second counter.
r64 VoiceCommandSustainDuration = 30.0; // in seconds r64 VoiceCommandSustainDuration = 30.0; // in seconds
// When we send a Motor Close command, we don't want the upper leds to // When we send a Motor Close command, we don't want the upper leds to
// immediately turn off. Instead, we want to wait until the flower is // immediately turn off. Instead, we want to wait until the flower is
// at least some of the way closed. This variable dictates how long // at least some of the way closed. This variable dictates how long
// we wait for. // we wait for.
// For example: // For example:
// 1. We send a 'motor close' command to the clear core // 1. We send a 'motor close' command to the clear core
@ -105,7 +63,7 @@ r64 VoiceCommandSustainDuration = 30.0; // in seconds
// 3. We begin a timer // 3. We begin a timer
// 4. When the timer reaches the value set in this variable, // 4. When the timer reaches the value set in this variable,
// we turn the upper leds off. // we turn the upper leds off.
// //
// NOTE: This is not a symmetric operation. When we send a 'motor open' // NOTE: This is not a symmetric operation. When we send a 'motor open'
// command, we want to immediately turn the upper leds on so they appear // command, we want to immediately turn the upper leds on so they appear
// to have been on the whole time. // to have been on the whole time.
@ -118,7 +76,7 @@ r64 TurnUpperLedsOffAfterMotorCloseCommandDelay = 5.0; // in seconds
// HighTemperatureBrightnessPercent (below) // HighTemperatureBrightnessPercent (below)
// //
// NOTE: this is an 8bit signed integer so its range is // NOTE: this is an 8bit signed integer so its range is
// -128 to 127, not that we should need either of those extremes for // -128 to 127, not that we should need either of those extremes for
// this, but just a note that you can't just put anything in here. // this, but just a note that you can't just put anything in here.
s8 MinHighTemperature = 0; s8 MinHighTemperature = 0;
@ -131,18 +89,18 @@ r32 HighTemperatureBrightnessPercent = .25f;
// The percent brightness we set leds to when no other conditions apply // The percent brightness we set leds to when no other conditions apply
// A value in the range 0:1 inclusive. // A value in the range 0:1 inclusive.
// Probably wants to be something high like 1 but we might want to // Probably wants to be something high like 1 but we might want to
// lower it for heat reasons? // lower it for heat reasons?
r32 FullBrightnessPercent = 1.0f; r32 FullBrightnessPercent = 1.0f;
// A global modifier so Joerg can just slow all the patterns right down // A global modifier so Joerg can just slow all the patterns right down
// XD // XD
// This is a percent - so 1 is full speed, 0.1f is 1/10 full speed and // This is a percent - so 1 is full speed, 0.1f is 1/10 full speed and
// 2 is 2x as fast. // 2 is 2x as fast.
r32 GlobalAnimSpeed = 1.0f; r32 GlobalAnimSpeed = 1.0f;
// How often should Lumenarium send its status to the python server? // How often should Lumenarium send its status to the python server?
// //
#define STATUS_PACKET_FREQ_SECONDS 10 // in seconds #define STATUS_PACKET_FREQ_SECONDS 10 // in seconds
#endif //BLUMEN_LUMEN_SETTINGS_H #endif //BLUMEN_LUMEN_SETTINGS_H