mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-12 06:53:40 +00:00
machine/usb/hid/joystick: handle case where we cannot find the correct HID descriptor
Signed-off-by: deadprogram <ron@hybridgroup.com>
This commit is contained in:
@@ -30,7 +30,7 @@ func UseSettings(def Definitions, rxHandlerFunc func(b []byte), setupFunc func(s
|
||||
State: def.NewState(),
|
||||
}
|
||||
if setupFunc == nil {
|
||||
setupFunc = js.setupFunc
|
||||
setupFunc = hid.DefaultSetupHandler
|
||||
}
|
||||
machine.EnableJoystick(js.handler, rxHandlerFunc, setupFunc, hidDesc)
|
||||
Joystick = js
|
||||
|
||||
Reference in New Issue
Block a user