Cannot get serial in working

N
Nate posted Feb 3, 19:22:

I am having a very very tough time getting the serial MIDI to work. I check all connections, I try different connections, I substitute 6N138 optocouplers of different manufacturers, I swap out Pi boards (2B and 3), I try different codes, .... It looks like everyone and their dog can get this, but I can't-- very frustrating.

The USB MIDI works, so I know for sure that the issue is in the optocoupler configuration. Is it possible to blow the serial port? It never got brought to 5V.

Have I missed anything?

N
Nimbo77 posted Feb 4, 20:44:

Hi Nate.
Two things:

  1. Have you confirmed your audio setup is working? Is it possible that midi is triggering, but you just can't hear it?

  2. Are you able to post a picture of your circuit?
N
Nate posted Feb 6, 02:59:

Yes, I've used the USB port on my keyboard, and it works. The keyboard MIDI works in my rack synth but not into the Pi, so it's not a no power issue.

I don't know how to post a picture here.

N
Nate posted Feb 6, 03:00:

It isn't in the audio out; that is clearly working.

N
Nate posted Feb 7, 19:42:

Okay, I realized that I wasn't testing the 2015 card. I tried it out, but all it does on the 2B v1.2 is flash the ACT four times slow and four times fast (no matter what is plugged in)-- no sound for either USB MIDI in or the serial circuit.

According to the popular discussion, serial in should work for the 2015 code.

I tried a brand new card and installed the image, and it does the same thing. This seems to be getting ridiculous.

N
Nate posted Feb 7, 20:50:

Finally got it! I used a model B v1.1 with the 2015 code. Whew!

N
Nate posted Feb 7, 20:51:

Pi 2, to add

N
Nate posted Feb 7, 21:28:

The two main things I was doing wrong:

  1. I used a 7.5K resistor instead of 10K-- doesn't make the cut, apparently.
  2. I was sending MIDI data before the Pi was initialized. If that initial time is messed up, it will not read any data afterwards. However, the USB in doesn't require that no data standby time; it'll ignore data until it is ready.
...

  (not published)
  I want to post as guest
 

Post