aboutsummaryrefslogtreecommitdiffstats
path: root/Demos/Device/LowLevel/MIDI
diff options
context:
space:
mode:
Diffstat (limited to 'Demos/Device/LowLevel/MIDI')
-rw-r--r--Demos/Device/LowLevel/MIDI/MIDI.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Demos/Device/LowLevel/MIDI/MIDI.c b/Demos/Device/LowLevel/MIDI/MIDI.c
index 954cbcbf6..8aed527db 100644
--- a/Demos/Device/LowLevel/MIDI/MIDI.c
+++ b/Demos/Device/LowLevel/MIDI/MIDI.c
@@ -117,7 +117,7 @@ void MIDI_Task(void)
static uint8_t PrevJoystickStatus;
/* Device must be connected and configured for the task to run */
- if (!(USB_IsConnected) || !(USB_ConfigurationNumber))
+ if (USB_DeviceState != DEVICE_STATE_Configured)
return;
Endpoint_SelectEndpoint(MIDI_STREAM_IN_EPNUM);