what should be there in between

Things I have:

  1. I have an old type MIDI input device (Piano Keyboard Panel) which has a MIDI "OUT" port (female type jack) that has 5 holes. (and no USB port). it has a 9V power input (AC to DC adapter)

  2. I have a 32 BIT assembled Desktop computer (Intel Microprocessor, Intel Motherboard and an NVIDIA graphics card) running on Windows 7, that has several standard USB sockets (female type).

  3. In my desktop, I have a plenty of ROLL piano apps and MIDI Editor apps, which are asking for a MIDI Input device. Some of them also take input from my TEXT keyboard, but it is stressful for me to use the TEXT keyboard or the mouse as an input device, especially for inserting chords, and hinder fluency.

  4. I have a standard USB (Male type) plug, taken out from a Standard USB Mouse, that has with 4 wires connected to it.

What I am trying to do:

I want to use that MIDI piano keyboard as a MIDI Input device for my Windows 7 MIDI apps.

What I have tried already:

  1. I have downloaded various simple schematics from the internet (not displayed here) that claims to directly connect the MIDI port with an AUX/ RCA/ USB cables. None of the combinations worked. Some of the combination caused horrible buzzing in the built in speaker of the piano keyboard, and bleeping or flashing or flicker of the tiny LCD display screen of the piano input.

  2. The apps keep saying "No MIDI input device found".

  3. The apps show a dropdown list that I have 2 MIDI output / synth interfaces ("Microsoft GS Wavetable Synth" and "Microsoft MIDI Mapper"), but it shows "BLANK" in the field for MIDI input Interface (even after I installed a few drivers from CASIO, ROLLAND, YAMAHA and a few random drivers from web, and restarted the machine for several times).

  4. I have tried searching the In the control panel, the "Device manager" and the "Device and printers" options. They does not show any option for MIDI devices.

So please suggest me :

  1. Proper circuit diagram to connect MIDI to USB port.

  2. Parts list (Veroboards, IC chips, capacitors, resistors, diodes etc) with part number to do this.

  3. How would I make Windows 7 (32 bit) to recognize this incoming USB signal, and to send it to the MIDI applications in an appropriate format?


  1. I Won't be able to put an online order due to some situations. The MIDI TO USB converters are not available in the local radio parts market and musical instrument market. Also not available in computer applience market.

  2. The price is too high. (A reliable MIDI to USB converter such as ROLLAND UM-ONE MK2 costing about INR 3000. WIDI Master MIDI to Bluetooth costs INR 10,263).

  3. I won't be able to purchase a separate microcontroller. I want to only adjust the voltage of the MIDI signal and I want to make the entire conversion and recognition through a custom made driver pack (.EXE, .DLL etc) within my existing system hardware.

  • \$\begingroup\$ Just purchase a midi-to-USB interface from a reputable dealer and, install drivers at the PC. It'll be cheaper in the long run. \$\endgroup\$
    – Andy aka
    Jan 12 at 10:27

2 Answers 2


With those specs, you can't build anything that works..

MIDI is not audio, do not connect it to audio input. MIDI is data.

You need a MIDI to USB adapter, or build one from a microcontroller or MCU board that can present itself as USB device, and write firmware that makes it look like USB MIDI adapter.

But you may have damaged the MIDI output already with incorrect cables so it may not work any more.

Cheap USB MIDI adapters do exist, but they often are unreliable. If you pay much less than half the price of the proper known brand adapter you mentioned, they are likely garbage products that almost work but are not built up to MIDI standards.

  • \$\begingroup\$ I can tell you the exact connection i tried. Are you sure I have damaged my MIDI device? \$\endgroup\$ Jan 12 at 7:44
  • 2
    \$\begingroup\$ I can't know the MIDI output port implementation of your device, so of course I am not sure, but there is a possibility you have damaged devices. If you did that, both the MIDI output and laptop USB port may have been damaged. Do not connect USB to anywhere else than USB compatible device. Don't blindly believe what people say on the internet how to connect things, they may be trolls, just like mobile phones can't be charged in a microwave oven or they don't become waterproof with OS update. \$\endgroup\$
    – Justme
    Jan 12 at 8:22
  • 1
    \$\begingroup\$ @AlwaysConfused No they are not ridiculous. To save space you can have a TRS connector instead of the big DIN connector. It is still a MIDI port. You can use TRS plugs for anything you want, such as guitar audio, headphones, MIDI data, power supply, and it does not mean you can't expect things to work together even if they have matcing connectors - like would you connect headphones to 12V power supply just because they have matching connectors? \$\endgroup\$
    – Justme
    Jan 12 at 8:38
  • 1
    \$\begingroup\$ No of course not. MIDI is digital serial data sent as 5mA current loop. \$\endgroup\$
    – Justme
    Jan 12 at 8:45
  • 1
    \$\begingroup\$ Not a TRS jack for audio. Just a TRS jack for MIDI. \$\endgroup\$
    – Justme
    Jan 12 at 8:53

Just to back up Justme's answer, you cannot make a USB-to-MIDI adapter with these restrictions - it is not possible.

The reason is that your computer software - even the driver - doesn't have direct access to the wires of the USB port. The USB port is connected to a USB Host Controller, a chip that speaks the USB protocol ("USB language") and translates to the CPU. The Host Controller performs functions like detecting whether something is plugged in, and polling each device 8000 times a second, and then telling the driver if it detects something actually happened. And it's hard-wired to use the USB protocol for this. So whatever you plug into a USB port absolutely must speak the USB protocol, not the MIDI protocol.

However, I can think of one possible way to make a cheap adapter. MIDI uses a very common framing protocol known as "UART", which is also used by the PC serial port - which is now obsolete, but still used by many people and it is very easy to get a USB UART adapter for just a few dollars (few hundred rupees) - example (but you should find one for yourself).

Wikipedia shows an example schematic. The left half shows the wiring inside the keyboard. The right half shows the wiring inside your adapter. As you can see, it's just a few components - and I think the diode isn't even needed, because it's just for safety (protects the opto-isolator from damage if the cable is somehow plugged in backwards).

MIDI in/out schematic

So where it says "to UART", just wire that to the receive/RX line on your UART; 5V to 5V; ground to ground; then plug the UART's USB plug into your computer. It will show up as a serial port. If you set the baud rate to 31250 baud, you should be able to receive MIDI data.

How to make your computer treat it as a MIDI port, and not a serial port, I'm not sure. Thanks to Super User I see there is this Linux called ttyMIDI but I haven't tried it. It should be much easier on Linux than Windows, just because Linux is a lot more customizable, but maybe someone has created a way to do it on Windows.

The UART adapter must be able to do 31250 baud. I think most of these adapters are fine with it, but it's not a usual baud rate for PC serial ports, so maybe some adapters (that are designed to work as PC serial ports) don't allow it. I'm not sure if Linux also has a problem with it - I found this regarding USB adapters on Linux.

It should also be possible to use a PC serial port adapter (example) instead of a UART adapter, but it will be slightly more difficult because the voltage is different, the voltage is reversed, and because you have to attach one of those serial port plugs, assuming that you want to plug your circuit into the adapter, not cut it apart and solder directly to the wires. I think most of these adapters do allow non-standard baud rates, just like the UART adapters.

  • \$\begingroup\$ The USB serial ports are basically similar to what you call USB UART adapters; but they just have the RS-232 transceiver and DE-9 connector. Any will do if you start modifying the adapter. Serial MIDI drivers do exist. \$\endgroup\$
    – Justme
    Jan 12 at 10:45
  • \$\begingroup\$ @Justme yeah, but then you have to modify the adapter. I'm aware that a serial port is a UART plus a circuit to convert the voltage (much like a MIDI port is a UART plus a different circuit to convert the voltage!) \$\endgroup\$
    – user253751
    Jan 12 at 10:47

Not the answer you're looking for? Browse other questions tagged or ask your own question.