From 1a67795fd37d6cc5391b06f08afef6fa7b316268 Mon Sep 17 00:00:00 2001 From: deadprogram Date: Fri, 28 Apr 2023 18:20:38 +0200 Subject: [PATCH] examples/usb-midi: remove serial communication from MIDI example Signed-off-by: deadprogram --- src/examples/usb-midi/main.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/examples/usb-midi/main.go b/src/examples/usb-midi/main.go index c9b71313..02ef6b73 100644 --- a/src/examples/usb-midi/main.go +++ b/src/examples/usb-midi/main.go @@ -2,9 +2,8 @@ package main import ( "machine" - "machine/usb/midi" + "machine/usb/adc/midi" - "encoding/hex" "time" ) @@ -16,12 +15,11 @@ func main() { led.Configure(machine.PinConfig{Mode: machine.PinOutput}) button := machine.BUTTON - button.Configure(machine.PinConfig{Mode: machine.PinInputPullup}) + button.Configure(machine.PinConfig{Mode: machine.PinInputPulldown}) m := midi.Port() m.SetHandler(func(b []byte) { led.Set(!led.Get()) - println(hex.EncodeToString(b)) m.Write(b) })