I am trying to send MIDI messages using jackclient-python and I am seeing the issue that JACK repeats outgoing messages. I've managed to break this down to this minimal example:
import jack
cl = jack.Client('Test')
mo = cl.midi_outports.register('p2')
sent = False
@cl.set_process_callback
def process(frames):
global sent
if not sent:
mo.write_midi_event(1, b'\x80\x2f\x32')
mo.write_midi_event(2, b'\x80\x2f\x33')
print("Sent!")
sent = True
with cl:
input()
The write_midi_event code is indeed only called once, but when I attach a MIDI analyzer (midisnoop in my case) I see that the two messages are rapidly repeated:
Am I doing something wrong here in the usage of the library?
I am trying to send MIDI messages using jackclient-python and I am seeing the issue that JACK repeats outgoing messages. I've managed to break this down to this minimal example:
The
write_midi_event
code is indeed only called once, but when I attach a MIDI analyzer (midisnoop in my case) I see that the two messages are rapidly repeated:Am I doing something wrong here in the usage of the library?