MIDI Arduino projects that whack on objects to produce a sound (bells, found objects, surfaces, actual instruments (drums, etc.) might use a component called a "solenoid" as an actuator.
A solenoid is an electromagnet -- a coil of wire and a magnetically-conductive rod that moves when a voltage is applied to the coil.
In 2015, Jiffer Harriman (CU ATLAS PhD), developed custom hardware and software to enable controlling motors and solenoids using the MIDI standard. Here's his SoundNoise installation and performance which:
".. is a robotic music ensemble that explores new techniques to make music by triggering a variety of motors to produce sound by physically striking, shaking, tapping or blowing on different physical objects, including the architecture of the space itself."
Let's take a look: https://www.jifferharriman.com/solidnoise
We have a single solenoid example to demonstrate at the workshop.
A small modification to the servo sketch adds a solenoid on MIDI channel 10. (Channel 10 is often used for drums/percussion.)
MIDI_ON pulls in the solenoid, and MIDI_OFF releases it.
The solenoid controller is connected to output pin 5 and ground.
Here's the sketch:
MIDI_pot_note_servo_solenoid_ProMicro.ino
A solenoid, and other electromagnet devices like motors, use a lot more current than microcontrollers can output.
In this example, the small solenoid uses about 600 mA.
The output pins on the ATMega32U4 microcontroller used in the Pro Micro have a maximum output current of 40ma. [atmega32u4 data sheet]
Therefore, we need a circuit that that handle the high current of the solenoid. We used an inexpensive MOSFET transistor module.
5 volt power supply
other misc hardware ...
Want to experiment with the solenoid demo? OK!
Do you have other ideas for MIDI user interfaces or actuators that can be interfaced to the Arduino kit? Let's discuss.