-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a8b6f78
commit f08a5a0
Showing
3 changed files
with
23 additions
and
94 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,42 @@ | ||
// It won't void any kind of stupid warranty, but things will *definitely* break at this point if you change this number. | ||
#define NUM_LEDS ( 128 ) | ||
|
||
#define NUM_FREQS ( 64 ) // Number of Goertzel instances running in parallel | ||
#define MAX_WEBSOCKET_CLIENTS ( 4 ) // Max simultaneous remote controls allowed at one time | ||
// Number of Goertzel instances running in parallel | ||
#define NUM_FREQS ( 64 ) | ||
|
||
#define NOVELTY_HISTORY_LENGTH (1024) // 50 FPS for 20.48 seconds | ||
// Max simultaneous remote controls allowed at one time | ||
#define MAX_WEBSOCKET_CLIENTS ( 4 ) | ||
|
||
// Number of times per second "novelty" is logged | ||
#define NOVELTY_LOG_HZ (50) | ||
|
||
#define NUM_TEMPI (96) // TEMPO_LOW to TEMPO_HIGH | ||
#define BEAT_SHIFT_PERCENT (0.16) | ||
// 50 FPS for 20.48 seconds | ||
#define NOVELTY_HISTORY_LENGTH (1024) | ||
|
||
// TEMPO_LOW to TEMPO_HIGH | ||
#define NUM_TEMPI (96) | ||
|
||
#define TEMPO_LOW (48) // BPM | ||
// BPM range | ||
#define TEMPO_LOW (48) | ||
#define TEMPO_HIGH (TEMPO_LOW + NUM_TEMPI) | ||
|
||
// How far forward or back in time the beat phase is shifted | ||
#define BEAT_SHIFT_PERCENT (0.16) | ||
|
||
// Set later by physical traces on the PCB | ||
uint8_t HARDWARE_VERSION = 0; | ||
|
||
// WiFi credentials | ||
char wifi_ssid[64] = { 0 }; | ||
char wifi_pass[64] = { 0 }; | ||
|
||
// WTF ERRORs are used when the program enters a state that should be impossible ------------------- | ||
const char* wtf_error_message_header = "^&*@!#^$*WTF?!(%$*&@@^@^$^#&$^ \nWTF ERROR: How the hell did you get here:"; | ||
const char* wtf_error_message_tail = "--------------------------------------------------------------------------"; | ||
|
||
inline void wtf_error(){ | ||
printf("%s\n", wtf_error_message_header); | ||
printf("FILE: %s *NEAR* THIS LINE: %d\n", __FILE__, __LINE__ ); // If I inline this function, will this line number roughly match where this function was called from? | ||
printf("%s\n", wtf_error_message_tail); | ||
} | ||
} | ||
// ------------------------------------------------------------------------------------------------- |