about summary refs log tree commit diff
path: root/HexBoard_V1.1.ino
diff options
context:
space:
mode:
Diffstat (limited to 'HexBoard_V1.1.ino')
-rw-r--r--HexBoard_V1.1.ino13
1 files changed, 8 insertions, 5 deletions
diff --git a/HexBoard_V1.1.ino b/HexBoard_V1.1.ino
index 550f572..fe1c66b 100644
--- a/HexBoard_V1.1.ino
+++ b/HexBoard_V1.1.ino
@@ -689,15 +689,18 @@ void sequencerPlayNextNote(){
     if(lanes[i].state & STATE_MUTE){
       continue;
     }
-    // do the thing.
-    noteOn(midiChannel, lanes[i].instrument % 128, midiVelocity);
-    // TODO: Change when the noteoff is played?
-    noteOff(midiChannel, lanes[i].instrument % 128, 0);
+    int offset = lanes[i].bank * 16;
+    if(lanes[i].steps[sequencerStep+offset]){
+      // do the thing.
+      noteOn(midiChannel, lanes[i].instrument % 128, midiVelocity);
+      // TODO: Change when the noteoff is played?
+      noteOff(midiChannel, lanes[i].instrument % 128, 0);
+    }
   }
   
   // increment and confine to limit
   sequencerStep++;
-  sequencerStep%=32;
+  sequencerStep%=16;
 }
 
 // Return the first note that is currently held.