You can use aconnectgui if you don't want to use qjackctl.
Also, you can use the device name with aconnect. Here's an excerpt of a script
I rote to start Pd on my wearable 10 years ago. The trick is that you need to
wait until Pd sets up its MIDI ports before trying to connect to them in a
script.
-----
echo "rc_starts_pd: strating pd"
pd -rt -nogui -alsa -audiodev 4 -audiobuf 10 -alsamidi $PATCH &
# wait for pd to initialize
KA=$(aconnect -i -o | grep "Pure Data")
while [ "$KA" = "" ]
do
sleep 1
echo "rc_starts_pd: pd alsamidi not ready"
KA=$(aconnect -i -o | grep "Pure Data")
done
echo "rc_starts_pd: pd alsmidi is ready"
# connect the UA-25 midi to Pure Data
echo "rc_starts_pd: alsa midi connect 'UA-25' <-> 'Pure Data'"
aconnect 'UA-25' 'Pure Data'
aconnect 'Pure Data':1 'UA-25':0
-----
> On Nov 30, 2018, at 4:57 PM, [email protected] wrote:
>
> Date: Fri, 30 Nov 2018 16:47:21 +0100
> From: "Ingo" <[email protected] <mailto:[email protected]>>
> To: "'Jaime Oliver'" <[email protected]
> <mailto:[email protected]>>
> Cc: "'Pd-List'" <[email protected] <mailto:[email protected]>>
> Subject: Re: [PD] Recognizing USB MIDI interfaces on Pd 0.48.1 (Debian
> 9.5)
> Message-ID: <[email protected]
> <mailto:[email protected]>>
>
> Thanks, Jamie!
>
> got it finally to connect or disconnect now.
>
> I didn't have the correct client and ID numbers.
> I'll have to find a way to retrieve the port number of an unknown USB
> interface first automatically before I can connect it to Pd automatically.
> I couldn't find any way to connect an existing new port without knowing its
> number.
>
> I tried aconnect *:0 128:0 instead of aconnect 24:0 128:0
> but it didn't work.
> Obviously havin * become 128 would cause a feedback loop - so it makes sense
> not to work.
>
> I had also installed qjackctl as IOhannes suggested.
> This also works.
--------
Dan Wilcox
@danomatika <http://twitter.com/danomatika>
danomatika.com <http://danomatika.com/>
robotcowboy.com <http://robotcowboy.com/>
_______________________________________________
[email protected] mailing list
UNSUBSCRIBE and account-management ->
https://lists.puredata.info/listinfo/pd-list