Build your own MIDI projects
FAQ
Frequently Asked Questions.
Details
 
MIDI & Music
MIDI and Music Information
Details
 
MIDI IN & OUT Board

 

MIDI IN and OUT

 

The MIDI IN/OUT board can be used with any microcontroller which contains a UART, including the PIC, ATmega etc. microntrollers, to send and receive MIDI  messages.

 

The MIDI IN/OUT board can be mounted directly on an Uno,  Duemilanove, Mega or Diecimila  Arduino, connecting the MIDI-IN to the Arduino's hardware RX pin and the MIDI-OUT to the TX pin. All of the Arduino's digital and analog pins, as well as power and ground busses, are available as well.

 

The MIDI IN/OUT board can also be connected to other microcontroller/microprocessor units, via the individual pins required.

 

The MIDI IN/OUT board provides an opto-isolated MIDI-IN port as well as a MIDI-OUT port. It also contains a 4-way DIL switch to allow selection of individual MIDI Channels (1 to 16), if required.

  

Also if you already own an Uno,  Duemilanove, Mega or Diecimila Arduino then this circuit design allows you to directly connect MIDI IN and OUT to your Arduino board via the 8-way male header. Also other Arduino boards can be wired to the individual pins required.

 

 

 

MIDI IN & OUT BOARD

ITEM#: MIDIINOUTBOARD

PRICE:  €15.00


 

Note: This price includes the MIDI IN and OUT sockets and an assembled board.

 

  

Circuit Schematic:

A circuit schematic of the MIDI IN/OUT board shows the Input/Output connections. The unit can be connected directly to an Arduino Uno, Duemilanove, Mega or Diecimila. Arduino Pin D0/RX is connected to the output of the Opto-coupler whose input is connected to the MIDI IN socket. Arduino Pin D1/TX is connected to the MIDI OUT socket via resistor R5. Arduino Pins D2 and D3 provide +5 Volt and 0 Volt(GND) but they need to be set correctly in the software. Arduino Pins D4, D5, D6 and D7 are connected to the 4-way DIL switch, which can be used to select the MIDI Channel (1 to 16).

 

So 8 Pins (D0 to D7) are used  when the MIDI IN/OUT board is plugged into the Arduino. All other pins are still accessible. 

 

Layout:

The PCB layout is shown without the components and with the components.

 

Software:

Details to set Arduino Pins D2 and D3 to provide +5 Volt and 0 Volt(GND), and to set Arduino Pins D4, D5, D6 and D7, connected to the 4-way DIL switch,  to select the MIDI Channel (1 to 16) are shown on the software page.

 

MIDI Wiring:

 

MIDI_IN_OUT_CONNECTIONS.JPG (212235 bytes)

   *Click to Enlarge*

 

 

 

 

The MIDI IN and OUT connectors use a  5-Pin 180 degree DIN sockets. Note that the MIDI IN/OUT wiring is polarised and the correct pins should be used.

 

 

 

Download:

Open the  source code file and copy and paste it into the Arduino programme.

 

 

 

DIL Switch Selections

MIDI 

Channel

4 3 2 1
on on on on 1
on on on off 2
on  on  off on 3
on on off off 4
on off on on 5
on off on off 6
on off off on 7
on off off off 8
off on on on 9
off on on off 10
off on  off on 11
off on off off 12
off off on on 13
off off on off 14
off off off on 15
off off off off 16

Table 1 MIDI Channel

 

 

Connections:

The MIDI IN/OUT board can be used with all variations of Arduino boards. The connections required are TX to TX, RX to RX, +5 Volt and 0 Volt (GND). The DIL 4-way switch is optional, but can be connected to D4, D5, D6 and D7. In fact the board can work with the serial port on any microcontroller/microprocessor capable of running at 31250 Baud.