Stability fix
This commit is contained in:
+2
-5
@@ -15,7 +15,7 @@
|
||||
#include "UIThread.h"
|
||||
#include "SharedState.h"
|
||||
|
||||
|
||||
static Step local_sequence[NUM_TRACKS][NUM_STEPS];
|
||||
|
||||
static void handleInput();
|
||||
static void drawUI();
|
||||
@@ -106,8 +106,7 @@ static void generateSequenceData(int themeType, Step (*target)[NUM_STEPS]) {
|
||||
}
|
||||
|
||||
void generateTheme(int themeType) {
|
||||
Step local_sequence[NUM_TRACKS][NUM_STEPS];
|
||||
generateSequenceData(themeType, sequence);
|
||||
generateSequenceData(themeType, local_sequence);
|
||||
|
||||
midi.lock();
|
||||
memcpy(sequence, local_sequence, sizeof(local_sequence));
|
||||
@@ -353,7 +352,6 @@ static void drawUI() {
|
||||
bool local_trackMute[NUM_TRACKS];
|
||||
int local_midiChannel;
|
||||
MelodyStrategy* local_strategy;
|
||||
Step local_sequence[NUM_TRACKS][NUM_STEPS];
|
||||
int local_playbackStep;
|
||||
int local_scaleNotes[12];
|
||||
|
||||
@@ -401,7 +399,6 @@ static void drawUI() {
|
||||
static void updateLeds() {
|
||||
// Make local copies of shared data inside a critical section
|
||||
// to avoid holding the lock during slow LED update operations.
|
||||
Step local_sequence[NUM_TRACKS][NUM_STEPS];
|
||||
int local_playbackStep;
|
||||
bool local_isPlaying;
|
||||
UIState local_currentState;
|
||||
|
||||
Reference in New Issue
Block a user