Skip to content
Snippets Groups Projects
Verified Commit 300108f3 authored by Andreas Horn's avatar Andreas Horn
Browse files

adds 6th valve

parent bcccf173
No related branches found
No related tags found
No related merge requests found
......@@ -6,28 +6,29 @@
#define MIDI_IN_PIN 0
#define VALVE_0 4
#define VALVE_1 5
#define VALVE_2 6
#define VALVE_3 7
#define VALVE_4 8
#define VALVE_5 9
#define NUM_VALVES 5
#define NUM_VALVES 6
// array of currently active notes, index 0 is the oldest one
int16_t notes[NUM_VALVES] = {-1, -1, -1, -1, -1};
int16_t notes[NUM_VALVES] = {-1, -1, -1, -1, -1, -1};bbb
// array of the length of the tone period required to create the tone
uint16_t periods[NUM_VALVES] = {0, 0, 0, 0, 0};
uint16_t periods[NUM_VALVES] = {0, 0, 0, 0, 0, 0};
// array of the current state of the valve pins (for tone periods)
uint8_t states[NUM_VALVES] = {0, 0, 0, 0, 0};
uint8_t states[NUM_VALVES] = {0, 0, 0, 0, 0, 0};
// array for the period timer helpers
uint64_t lastNoteMicros[NUM_VALVES] = {0, 0, 0, 0, 0};
uint64_t lastNoteMicros[NUM_VALVES] = {0, 0, 0, 0, 0, 0};
// array of the valve pin numbers
const uint8_t valves[NUM_VALVES] = {VALVE_1, VALVE_2, VALVE_3, VALVE_4, VALVE_5};
const uint8_t valves[NUM_VALVES] = {VALVE_0, VALVE_1, VALVE_2, VALVE_3, VALVE_4, VALVE_5};
// MIDI parameter overview
// First parameter is the event type (0x0B = control change).
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment