File tree Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Expand file tree Collapse file tree 1 file changed +12
-3
lines changed Original file line number Diff line number Diff line change 1414# - adafruit_debouncer
1515# - adafruit_displayio_ssd1306
1616# - adafruit_display_text
17+ # - adafruit_midi
1718# Install them all with:
18- # circup install asyncio adafruit_debouncer adafruit_displayio_ssd1306 adafruit_display_text
19+ # circup install asyncio adafruit_debouncer adafruit_displayio_ssd1306 adafruit_display_text adafruit_midi
1920#
2021#
2122import asyncio
@@ -136,10 +137,18 @@ def check_touch():
136137 touch .update ()
137138 if touch .rose :
138139 print ("touch press" ,i )
139- note_on (midi_notes [i ])
140+ midi_note = midi_notes [i ]
141+ note_on (midi_note )
142+ msg = NoteOn (midi_note , velocity = 100 )
143+ midi_usb .send ( msg )
144+ midi_uart .send ( msg )
140145 if touch .fell :
141146 print ("touch release" , i )
142- note_off (midi_notes [i ])
147+ midi_note = midi_notes [i ]
148+ note_off (midi_note )
149+ msg = NoteOff (midi_note , velocity = 0 )
150+ midi_usb .send ( msg )
151+ midi_uart .send ( msg )
143152
144153# print to REPL current state of knobs, button, and touchpads
145154async def debug_printer ():
You can’t perform that action at this time.
0 commit comments