I am facing an issue for finishing my embedded instrument with Odroid. I can play all examples with Tickle and Pd without issues. However, I have created a script which basically automatizes all operations needed to play the Tickle at startup:
Basically hw:Device is the name of the external usb audiocard, 24:0 is the ID of both MIDI in and out ports for Tickle. Pure data is identified in the 128:0 and 128:1. With this configuration everything works if I run it manually.
The issue that I have is that, after running this script at startup, Pd receives audio and CC messages correctly from Tickle but Pd does not receive any MIDI note from Tickle (from notein). Sometimes only one MIDI note at the beginning and stops receiving any other.
What could be the reason to receive one thing but not the other? Does it remind it to any line of code ;)? Could it be possible that it disconnects from USB MIDI host somehow at startup? But then, how does it send CC messages?
Second questions, shouldn’t Tickle create two MIDI ports with different IDs? I only have 24:0 both for in and out.
If you have QjackCtl running on the Odroid, you could also leave autoconnection of Jack audio and ALSA MIDI to QjackCtl.
Is there any particular reason why you run Jack with 44100 and not with 48000 Hz? On some systems 48kHz perfoms better than 44.1.
Please be super careful to avoid unplugging the Tickle while zita-a2j is accessing it. zita-a2j unfortunately eats up all the memory until your system becomes unstable.
hi,
I tried with your startup flags and unfortunately it continues making the same, it receives CC but no MIDI notes.
The interesting point is that after the issue happens, if I kill all processes involved, unplug and plug again Tickle, and finally I run the same script everything works ok. Definitely there is some mess in how MIDI connections are managed. I will continue testing and try qjackctl with autoconnect and not aconnect.
BTW my acconnect -l in my laptop but similar in my odroid:
$ aconnect -l
client 0: 'System' [type=kernel]
0 'Timer '
1 'Announce '
client 14: 'Midi Through' [type=kernel]
0 'Midi Through Port-0'
client 28: 'tickle' [type=kernel,card=3]
0 'tickle MIDI 1 '
client 128: 'TiMidity' [type=user,pid=1367]
0 'TiMidity port 0 '
1 'TiMidity port 1 '
2 'TiMidity port 2 '
3 'TiMidity port 3 '
client 129: 'Pure Data' [type=user,pid=24165]
0 'Pure Data Midi-In 1'
1 'Pure Data Midi-Out 1'
I think this is normal behavior for hardware. While software has ports 0,1,... hardware seems to only have ports 0.
This is how it looks in the QjackCtl Graph:
I can give Pd more in and outs, the ports will be numbered starting at 0. Port 1 is not necessarily a source if there are more than one sink. The generalization 0=sink, 1=source is not correct.
hi,
thanks Max.
At least we can discard these hypothesis.
I think my issue of not receiving MIDI notes (but receiving CCs) when using a startup bash script has to do more with the way Ubuntu Mate (what I run in Odroid) deals with hardware. Or even the version of jack for arch linux. I have tried with other MIDI devices and I get similar issues. But this doesnt happen in my laptop.
I will continue investigating the issue, and even I will try next week with a raspi4.