Bizarre malfunction..... Serial I/O only works when 5v sent into input - Page 1
Forum section: electronics / beginners

author: Mp3
author_rank: Frequent Contributor
timestamp: September 08, 2018, 07:16:22 am
content: Hey everyone,I started a thread about this MIDI sequencer I am repairing here, before i came to realize there are larger problems:https://www.eevblog.com/forum/beginners/dead-speaker-repair-diagnosing/For anyone wondering about the title, basically MIDI is a serial protocol sent over a 5 pin DIN, specification sends +5v on pin 4. It's common for sequencers and other "master" controllers to send 5v on that line. It is not very common input devices like keyboards, controllers etc do. I have the service manual for this device and will quote how it describes the serial I/O implementation:QuoteAfter attempting to revive the speaker with no luck, i continued using it, and came to realize it was not recording and input from a MIDI keyboard properly. Only a couple notes made it through. I switched to a known good sequencer (the same model) and everything worked as expected.Since sometimes notes would make it through and sometimes not, and i happened to know the MIDi keyboard i was using didn't send 5v on pin 4 (most don't, but it's common for sequencers to send 5v), i decided to try with a keyboard I knew sent 5v on pin 4. Suddenly everything worked almost perfectly - once in a while the sequencer would mix up a note and accidentally play it back the note next to it (for instance, if I press key 50, it might register key 51 once in a while).I then took out the PCB to look for damage, and saw none, but i noted the MIDI DIN connectors were ever so slightly loose, so i added new solder to all of them. I noticed the reliability of recognizing incoming notes improved just slightly.I explained my situation to a friend who then suggested I replace the optoisolator. Does anyone else have suggestions for what i may try? The circuit makes use of a couple 2N4401 transistors, so i may attempt to replace them with new 2N4401 i have here. I don't have any resistors to replace but i will order some when I buy a new optoisolator.I'm wondering if the optoisolator could have anything to do with the missing click track referenced in the other thread, or if that's indicative of a different problem.

author: JS
author_rank: Frequent Contributor
timestamp: September 08, 2018, 07:47:26 am
content: It might have a problem with the internal supply, not feeding the 5V for the midi to work properly so when you add the external supply it powers from there and some things works as it should. Clearly there's another problem, hence why you still have a problem. Being the PS issue I'd start with just that, maybe the decoupling caps got damaged in the fight of the supply and makes a noisy environment reading/writing the wrong data.JS

author: Mp3
author_rank: Frequent Contributor
timestamp: September 08, 2018, 08:18:29 am
content: Quote from: JS on September 08, 2018, 07:47:26 amI should have checked this first for sure; the system runs on 9V AC and has a single 5V 7805 regulator. I will measure it when powered on with my multimeter and see what it shows. But if i have to remove it from the circuit for proper testing, i might as well replace it with a brand new one.I'll also be sure to test out the decoupling caps with my ESR meter.

author: HB9EVI
author_rank: Frequent Contributor
timestamp: September 08, 2018, 08:54:35 am
content: If you study the docs to MIDI, there is always +5V on pin 5 on midi-out devices; that has to be like that since the opto is inverting the logic of the signal; the signal on the sender side is common 5V and shifts out on pin 5 to ground, so that on the receiver side the signal is non-inverted.my Midi keyboard has 5V steady on pin 4

author: Mp3
author_rank: Frequent Contributor
timestamp: September 08, 2018, 09:20:57 am
content: Quote from: HB9EVI on September 08, 2018, 08:54:35 amThanks but this is not a question of studying the docs or not. I made sure I had my facts straight, but I was being lazy in my speech.The reality is many devices don't offer enough current on the 5V line, and there are many MIDI devices that operate on 3.3v instead of 5v. (It is a well known issue with unpowered MIDI thru boxes. To avoid ground loops, MIDI thru boxes are either unpowered or have the MIDI ground isolated from the power supply if it is powered.)I had found anything I had that was capable of powering an unpowered thru box, even if just taking an input and spitting it back out via the Thru port, would make the MIDI I/O on the defective sequencer work perfectly.

author: Cervisia
author_rank: Regular Contributor
timestamp: September 12, 2018, 10:46:34 am
content: Quote from: Mp3 on September 08, 2018, 07:16:22 amMIDI is actually a current loop. The specification suggests a circuit that does have 5 V on that pin, but if a sender uses a different circuit, and if a receiver relies on a characteristic of the original circuit except the current between pins 4 and 5, then those two devices will probably not work with each other.QuoteQuoteThis sounds as if it might be the problem that you're having. (Do you have a schematic? If not, what are the component values?)But it's more likely that the optocoupler's LED is damaged.QuoteHow did you measure this?I suspect that this did not actually change anything.