From 6b845bd1b3d0897c30f1649a79f10af493bbca88 Mon Sep 17 00:00:00 2001 From: kevin Date: Mon, 18 Jan 2021 10:32:23 -0500 Subject: [PATCH] MidiDevice.py : get_input() now loops until all available messages are received. --- MidiDevice.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/MidiDevice.py b/MidiDevice.py index f9dce70..0eed869 100644 --- a/MidiDevice.py +++ b/MidiDevice.py @@ -136,10 +136,12 @@ class MidiDevice(object): o_msgL = [] if self.mip is not None: - midi_msg = self.mip.get_message() - if midi_msg and midi_msg[0]: + while True: + midi_msg = self.mip.get_message() + if not midi_msg or not midi_msg[0]: + break; - if self.monitorInFl: + if self.inMonitorFl: o_msgL.append( self._midi_data_to_text_msg(True,midi_msg[0]) ) if self.throughFl and self.mop is not None: