[LAD] alsa driver and arduino stuff

Gordon JC Pearce gordonjcp at gjcp.net
Wed Nov 17 07:21:15 UTC 2010

On Tue, 2010-11-16 at 13:35 -0800, Joan Quintana wrote:
> > I'm not too sure what I'd call it. Thiago Teixeira called it
> ttymidi:
> > http://www.varal.org/ttymidi/
> > Should do exactly what your looking for I think. Just run his
> program, and any USB/Serial > device
> > can send data to ALSA MIDI. :-)
> > Cheers, -Harry
> > PS: Might be nice to send the author a "thanks" if you like it
> Thanks for make me remember ttymidi. I tried it and is perfect for the
> purpose to connect arduino to fluidsynth.
> Returning to the problem..., I imagine something like plugging arduino
> and appearing automatically in aconnect. Maybe the solution is to hack
> the FTDI driver. FTDI is the chipset that converts serial to USB, and
> needs an FTDI driver to create a virtual COM port: /dev/ttyUSB0. The
> solution could be hacking the FTDI driver with the ALSA libraries
> driver and making it an ALSA sequencer port.
> Joan Q

In theory you could reprogram the FTDI chip to appear to be a
class-compliant MIDI device.  Since a MIDI port is just a serial port
with a funny baud rate and a current-loop interface, it shouldn't be
hard - you don't care about the physical interface and the software
interface just throws bytes down a serial port.

You could use ttymidi to receive data from the arduino, but not send
MIDI to it.  Of course, you could launch ttymidi from a udev script so
that when you plug in the arduino it fires up and lets the port appear.

Gordon MM0YEQ

More information about the Linux-audio-dev mailing list