'note' reacting to 'crtl' bug. fix.
This commit is contained in:
parent
bd6abfe95c
commit
f404c19270
1 changed files with 19 additions and 15 deletions
|
|
@ -18,7 +18,9 @@
|
||||||
//============<sampler>============
|
//============<sampler>============
|
||||||
//optionally pin3 will go HIGH/LOW in sync w/ sound PLAY/STOP
|
//optionally pin3 will go HIGH/LOW in sync w/ sound PLAY/STOP
|
||||||
#define MOTOR_PIN 3
|
#define MOTOR_PIN 3
|
||||||
// #define FAN_ACTION // this is noisy....
|
// #define FAN_ACTION // this is noisy.... ==> not so recommendable..
|
||||||
|
#define NOTE_MIN 24
|
||||||
|
#define NOTE_MAX 84
|
||||||
//============</sampler>===========
|
//============</sampler>===========
|
||||||
|
|
||||||
//HACK: let auto-poweroff speakers stay turned ON! - (creative muvo mini)
|
//HACK: let auto-poweroff speakers stay turned ON! - (creative muvo mini)
|
||||||
|
|
@ -184,6 +186,7 @@ void receiveEvent(int numBytes) {
|
||||||
|
|
||||||
//
|
//
|
||||||
int key = str_key.toInt();
|
int key = str_key.toInt();
|
||||||
|
if (key >= NOTE_MIN && key <= NOTE_MAX) {
|
||||||
sample_now = key;
|
sample_now = key;
|
||||||
//
|
//
|
||||||
int velocity = str_velocity.toInt(); // 0 ~ 127
|
int velocity = str_velocity.toInt(); // 0 ~ 127
|
||||||
|
|
@ -200,6 +203,7 @@ void receiveEvent(int numBytes) {
|
||||||
Serial.println("sample_player_start_task");
|
Serial.println("sample_player_start_task");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// SD TEST
|
// SD TEST
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue