I have a stupid question. I'm busy with a project where I want to incorporate MIDI in and out.
I want to use the MIDILibrary form the playground (http://www.arduino.cc/playground/Main/MIDILibrary). I made a "shield" to do this using a 6n137 optocoupler for the input side.
Works great. But it gives me a signal that goes from Low to High. Thus:
Doesn't that need to go from High to Low? Like:
I have no experience with Midi, and I don't have any MIDI equipment to test. At the moment I have only one Arduino.
Do I need to invert the MIDI signal I got (picture 1)?
I search the webs but couldn't find a real answer. Hope the question is clear?
Which "signal" is it that goes from Low to High? In other words, what schematic are you using and where on the schematic are you measuring the signal that you sketched?
The MegaRAM shield (http://ruggedcircuits.com/html/megaram.html): add 128 kilobytes of external RAM to your Arduino Mega/Mega2560
I used the schematics from:
Instead of the Sharp PC-900 or HP 6N138 optocoupler I use a 6n137 as mentioned above. And I changed the resistor values a bit, instead of 280 Ohm I use 220 Ohm.
I generate a midi signal with my Arduino, a tone sweep example I found somewhere. That signal is normally high and pulls down.
On the 6n137 the midi input goes to pin 2. I measured the output on pin 6 (Vo) of the 6n137. If necessary I could use a transistor to invert the signal, should be an easy fix.
I normally draw my schematics, but i just installed new firmware for my Wacom tablet and now it doesn't le me draw no more. I'm sorry if my explanation isn't clear. Not a native English speaker, and I absolutely have no technical electronics lingo.
I never worked with MIDI. Normally a MIDI signal is high and pulls down? That's the thing I can't figure out.
I think you have it miswired. If you are transmitting MIDI, you don't even need an optoisolator (see the "MIDI OUT" part of the schematic you referenced). That schematic also shows how to keep the polarity correct and not have the inversion you're seeing.
For the MIDI signal coming in, hook it up as shown on the schematic and it should not be inverted.
The Flexible MIDI Shield (http://ruggedcircuits.com/html/flexible_midi_shield.html): MIDI IN/OUT, stacking headers, your choice of I/O pins