Build your own MIDI circuits
FAQ
Frequently Asked Questions.
Details
 
MIDI & Music
MIDI and Music Information
Details
 
Infrared Sensors to MIDI Control Change Commands
  

Infrared Sensors to MIDI

This design uses Infrared distance sensors to convert physical movement/gestures (e.g. hand, leg, head etc.) to MIDI Control Change messages. These MIDI messages can be used to control various elements within a MIDI software or hardware synthesiser/module.

 

The 6 Infrared (IR) distance sensors control MIDI Control Change data numbers 48 to 61 inclusive. The MSB is first (0 to 127 e.g. CC#48), then the LSB is second (0 to 7 eg CC#49). This is the first pair of CC messages for a 10 bit data output.

 

These values can be assigned in MIDI programmes e.g. Reason, Live, Sonar, Cubase etc. to control various parameters within these programmes. The MIDI output channel (1 to 16) can be selected by the 4-way DIP switch.

 

 

 

 

*Click to Enlarge*

 

 

6 IR SENSORS TO MIDI CC

ITEM#: 6IR2MIDI

PRICE:  €45.00


 

 

 

 

 

 

The MIDI  6-way IR Sensor unit utilizes:

  • An assembled, built and tested Arduino board including a suitable pre-programmed microcontroller,
  • A 2.1mm power socket, and associated LED, 
  • A MIDI activity LED,
  • A 4-way DIP switch, which selects the MIDI channel at power-on, shown in table 1
  • A 150mm wired MIDI 5-pin DIN input socket,
  • A 150mm wired MIDI 5-pin DIN output socket, 
  • The MIDI IN/OUT circuit schematic is also available.
  • The complete circuit schematic is available,

 

 

  

  

The MIDI  6-way IR Sensor unit requires:

  • A 9 Volt battery or equivalent 9 Volt DC power source
  • 6 Infrared Distance Sensors, Analogue Outputs

 

MIDI IN/OUT Wiring:

 

 MIDI_IN_OUT_CONNECTIONS.JPG (212235 bytes)

     *Click to Enlarge*

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

 

 

 

  

 

Operation:

The design uses Sharp analogue output Infrared distance sensors. There are various types available with different sensor ranges. Some examples are of 4-30 cm distance GP2D120XJ00F and 10-80 cm distance GP2D12J0000F.  The MIDI channel, that the volume controller affects, is set by the 4-way DIP switch selection, shown in Table 1 below.

 

NOTE: You need to connect ALL Sensor inputs to either a sensor or to Ground (GND). Any unconnected sensor will pick up noise or iinterference and produce a random MIDI CC output. So the unit can work with just 1 sensor but all other sensor inputs then need to be connected to Ground (GND).

   

Circuit Schematic:

A circuit schematic of the MIDI IN/OUT and the Arduino, combined with the Infrared distance sensors, shows the Input/Output connections. 

  

Power Supply:

The  Arduino can be powered via the USB connection or with an external power supply. The power source is selected automatically.

  

External (non-USB) power can come either from an AC-to-DC adapter (wall-wart) or battery. The adapter can be connected by plugging a 2.1mm center-positive plug into the board's power jack. Leads from a battery can be inserted in the Gnd and Vin pin headers of the POWER connector. A low dropout regulator provides improved energy efficiency.

 

The board can operate on an external supply of 7 to 20 volts. If supplied with less than 7V, however, the 5V pin may supply less than five volts and the board may be unstable. If using more than 12V, the voltage regulator may overheat and damage the board. The recommended range is 7 to 12 volts.

              

Note, that the current needs of the IR sensors usually require the use of a separate external power supply for the IR sensors.

 

 

 

 

 

DIP 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