

When uploading a sketch I disconnect the MIDI so it doesn't interfere, and when actually running the sketch I'm not attempting to use the serial I/O for anything except MIDI. The board I'm using is an Arduino Uno, and I am using digital pin 0 (the serial in) for MIDI in. When I try to look at the output from the circuit however, I'm not able to detect anything not with the saleae or just a LED. I've actually got a saleae logic analyzer, so tested the inputs by putting a 1k ? resistor between pin 5 and 4 of the MIDI input and have been able to see the signal coming off of devices using the saleae. What I'm seeing now is that the LED hard wired to pin 13 comes on and stays on. In my initial tests I'm just looking to flash the LED on pin 13 on when a note-on is received. To be more specific than "no luck", my project's eventual aim is to handle note-on/off and control change messages.

The only difference from the MMA spec is that I'm using two 220 ? resistors in place of a 470 ?, but it's something I read others have done without any issue

Regarding the photo, I've uploaded one of the actual circuit I'm using. This will prevent sketch upload and MIDI in from getting in each other's way.Īlso, you should not attempt to send debug or status messages over the serial to USB connection, once you have enabled MIDI-in. You should therefore pick a digital output pin to enable MIDI-in, which is low by default and which your sketch sets high to enable MIDI. Providing a serial to DIN connection to the MIDI-in (and out, if you have one), at 31250 baud.Providing a serial to USB serial connnection, for debug messages and so on often at 9600 baud.Providing a USB to serial connection to the computer, for uploading compiled sketches to the Arduino.Your serial connection is thus doing two or three things: Unless you are using a board like a Mega, you have only one UART.

How are you determining what they give you?Īnd when uploading to the Arduino I've found I need to disconnect it from any MIDI device, or the upload will fail. I've tried MIDI outputs from two difference devices a Oxygen 8 keyboard and a old emagic mt4. However, when I connect a midi device to the input I get no luck.Ĭould you be more specific about the lack of luck? What is your sketch trying to do - what are the expected results and what are the observed results? Looking at your photo I don't see the diode from the MMA circuit. Could this be a short somewhere?Īny help or guidance would be great, I've been stuck on this for far too many evenings! I'm using very simple test programs, but what happens is the LED does the initialization blink, then goes on, and stays on, until i disconnect the input from the serial rx (pin 0). The LED hard-wired into pin 13 has done some strange things when everything is connected and powered up. And when uploading to the Arduino I've found I need to disconnect it from any MIDI device, or the upload will fail. When trying to test the MIDI input I've got got the Arduino on it's own power supply, not USB power. However if I put a LED & resistor between the output of the optoisolator and ground I get no flashing at all, it just stays on, which is curious. If I put a LED and a ~220 ? resistor between pins 2 & 5 of the MIDI input I can faintly see it glow as events are sent, so I have to assume that everything looks good there and it's providing enough power for the LED in the optoisolator. However, when I connect a midi device to the input I get no luck. I've been able to verify that the optoisolator is working fine I've built a test circuit with a LED connected to the output of the optoisolator, when I power up the circuit the LED comes on and if I apply a couple volts across the emitter it shuts off. I've built the MIDI input circuit using a Sharp PC900V, so basically keeping as close to the official spec as possible. I'm having trouble getting midi input working.
