Re: [LAD] Finding ALSA sequencer client/port numbers

From: David Robillard <d@email-addr-hidden>
Date: Sat Apr 23 2011 - 01:06:54 EEST

On Fri, 2011-04-22 at 21:10 +0000, Fons Adriaensen wrote:
> On Fri, Apr 22, 2011 at 04:51:53PM -0400, Paul Davis wrote:
> > On Fri, Apr 22, 2011 at 4:45 PM, Fons Adriaensen <fons@email-addr-hidden> wrote:
> > > Hello all,
> > >
> > > after reading ASLA docs for some hours I've not found an
> > > answer to the following:
> > >
> > > Given the ALSA sequencer client and port _names_, find the
> > > numbers required to set up a connection (a 'subscription'
> > > in ALSA lingo).
> >
> > ALSA MIDI ports have names?
>
> They do. For example:
>
> fons@email-addr-hidden:~> aconnect -i
>
> client 0: 'System' [type=kernel]
> 0 'Timer '
> 1 'Announce '
> client 14: 'Midi Through' [type=kernel]
> 0 'Midi Through Port-0'
> client 20: 'TerraTec EWS88MT' [type=kernel]
> 0 'TerraTec EWS88MT MIDI'
> client 24: 'MPU-401 UART' [type=kernel]
> 0 'MPU-401 UART MIDI'
>
>
> So given e.g. 'TerraTec EWS88MT','TerraTec EWS88MT MIDI'
> how do I find 20,0 (from within an application) ?
>
> Or in other words, what is ALSA's get_port_by_name() ?

Alsa sequencer names aren't unique or intended for use as identifiers,
you probably don't want to do this if it's at all possible to avoid...

-dr

_______________________________________________
Linux-audio-dev mailing list
Linux-audio-dev@email-addr-hidden
http://lists.linuxaudio.org/listinfo/linux-audio-dev
Received on Sat Apr 23 04:15:02 2011

This archive was generated by hypermail 2.1.8 : Sat Apr 23 2011 - 04:15:02 EEST