Of courese I meant to say: " Unfortunately I do NOT know much about C
programming ..."
> Both the Arduino Micro and the Teensy 2.0 are working great!
> Thanks a lot, Martin!
>
> Now I only need to find out how I can prepend some identifier in the
> Arduino
> patch to be able to route the MIDI data separately while using the other
> pins with the standard firmata at the same time.
>
> Unfortunately I do know much about C programming ...
>
> Ingo
>
>
> ________________________________________
> Von: Martin Peach [mailto:chakekatzil@gmail.com]
> Gesendet: Samstag, 20. Juni 2015 17:11
> An: Ingo
> Cc: pd-list@lists.iem.at
> Betreff: Re: [PD] Arduiano (Micro or Nano) as MIDI interface?
>
> On Sat, Jun 20, 2015 at 6:06 AM, Ingo <ingo@miamiwave.com> wrote:
> Hi there!
>
> I'd like to use an Arduino Micro (or Nano) as a MIDI interface connecting
> the MIDI ports to the digital pins "0" and "1" (TX/RX) and receiving the
> MIDI data via USB in Pd.
> It does not matter in which format it comes into Pd (i.e. it doesn't have
> to
> show up as a MIDI port - like MIDI over USB).
>
> 1) Does anybody know if there is an existing arduino software for this?
>
> No but all you need to do is
> if (Serial.available()) Serial1.write(Serial.read());
> if (Serial1.available()) Serial.write(Serial1.read());
> in your main loop, where Serial1 is the TTL serial and Serial is USB.
>
>
> 2) Does anybody know if there are limitations on some or even all arduinos
> using the serial (digatal 0/1) ports and USB port at the same time?
> Only the micro (or Leonardo or Mega) will work for this as the TTL serial
> is
> separate from the USB. The TTL serial port on pins 0 and 1 shoud be set to
> 31250 baud. Arduinos that use the Atmega168 or 328 use the same serial
> port
> for TTL and USB so there will be conflicts if you try to do both at the
> same
> time. And software serial is probably too slow to receive at 31250 baud
> although it can work to send MIDI that way.
> Teensy2.0 (http://www.pjrc.com/teensy/index.html) will also work for this
> and can also (I believe) be set up as a USB MIDI device.
>
> Martin