Brendan, an electro-mechanical, computer-controlled system to play the hammer dulcimer
Updated: Mar 23, 2022
In October 2021, I was approached by Stan Humphries, a New Mexico based electrical and computer engineer, who obviously had too much time on his hands. He had already mechanized his harpsichord and wanted to try his hand at doing the same with a hammered dulcimer. He needed a fully chromatic version so he had me build him a 10/19/18/8 Linear Chromatic with piano markings and 7/8" string spacing.
Once Stan got the instrument he immediately got to work. The following is a description of the process and thinking in his own words.
I designed and built Brendan, an electro-mechanical, computer-controlled system to play the hammer dulcimer. The project followed a previous system created for a harpsichord (https://www.fieldp.us/performance/). The aesthetic reason to choose the hammer dulcimer was its complex, ethereal sound, attractive for solo performances. There were also two practical reasons:
* In common with the harpsichord, the method to initiate a note is simple and straight forward. In comparison, it would be difficult (if not impossible) to mechanize an instrument like a violin.
* The linear chromatic dulcimer from James Jones Instruments offered a full 51 note range (my harpsichord has 52). This opened access to a a broad repertoire of keyboard and guitar music.
The Brendan system is more than a novelty. A human performance on a hammer dulcimer is limited to two hammers then must move relatively large distances to strike different notes. In contrast, the 51 independent hammers of Brendan are optimally positioned to make consistent strikes on the strings. They can play complex chords and transition between notes almost instantaneously. Hence, the mechanical system offers opportunities to experiment with musical works that are inaccessible to human performers.
Compared to the harpsichord system, Brendan presented challenges in four areas:
* On the harpsichord, the solenoids were arranged in two parallel, linear banks for the white and black keys. Brendan required a more complex geometry to follow the four bridges and the active courses.
* While the harpsichord provided mechanical support, it was necessary to build a dedicated stand and solenoid frame for Brendan.
* Support for dynamics in Brendan required translation of velocity values in MIDI files to the force of hammer strikes.
* For effective hammer strikes, the timing of solenoid activation required accuracies better than a millisecond.
Brendan integrated technology development in three areas: mechanical design, electronics design and computer programing.
The mechanical system consisted of three components: a stand, a removable frame that supports the hammer assemblies and electronics and a lid to protect the dulcimer and act as a sound reflector. It was essential that the stand and frame were rigid to prevent vibration or shifting of the dulcimer relative to the hammers. On the other hand, I sought to minimize the structural elements for good transmission of sound. The dulcimer was mounted horizontally so that the hammers could operate vertically, minimizing stress on the solenoid and noise. I used small, agile solenoids that fit within the 3/4" spacing between courses. From previous experiments on a system for a steel-tongue drum, I was confident that the force was sufficient for a full dulcimer sound. The hammers were maple spheres with a thin leather patches at the strike point. There were 51 independent hammer assemblies with adjustable position and height. Position tuning insured that a hammer would strike both strings of a course equally. The height adjustment was necessary to balance the response of the courses. The activation pulse lengths for the solenoids varied between 8 ms (piano) and 12 ms (forte).
The fundamental component of both the harpsichord and dulcimer systems was the Arduino Mega 2560 board, a device with 68 available digital outputs controlled by a computer through a USB cable. The 5 V digital signal controlled a diode-protected MOSFET, providing 0.9 A to drive a solenoid. For the dulcimer application, the on-board program of the Mega board was simple. One range of serial bytes representing MIDI note numbers turned a corresponding pin ON, and another range turned the pin OFF. For the dulcimer, the hammer drive pulse was much shorter than the resulting note, so the solenoid duty cycle was low. The system could run for hours with little solenoid heating.
Computer programs to control the Arduino board and to convert MIDI files into a format for the percussive instrument were the most critical and innovative components of Brendan. The software was an outgrowth of my work on the harpsichord and the creation of performance software for electronic instruments (https://kbd-infinity.com/). MIDI files provide a extensive source of musical information, but are unsuitable in their original form for the dulcimer application for two reasons:
* The NoteON and NoteOff messages are organized for press-and-hold instruments like pianos rather than percussive instruments which require a single short strike per note.
* The pulse timing method in MIDI files is insufficient for the required sub-millisecond accuracy of the hammer pulse.
I wrote the program DCorrect to analyze the content of MIDI files and to translate the musical information into a special format for the dulcimer. DCorrect can work on an individual file or bulk transform all MIDI files in a folder. DCorrect performs a set of operations too complex to describe here. Included are correction of the range to match that of the dulcimer and the application of filters to account for individual response variations of the instrument courses. The end result is a file in DCM text format, with content like the following:
DCM file: AnEmigrantsDaughter.DCM
* Auto range correction: OFF
* Manual range correction: OFF
* Pulse length min: 8.5 (ms)
* Pulse length max: 10.5 (ms)
* Instrument note min: 43
* Instrument note max: 93
* Tempo factor: 1
The file has a data line for each note with three columns: 1) the absolute time from the start of the piece in microseconds, 2) the MIDI note number and 3) the strike pulse length (volume) in microseconds. The text DCM file is more accessible than a binary MIDI file. DCM files can be created with an editor or spreadsheet. It is also easy to edit then to match the characteristics of the instrument (Fig. dcorrect_edit.png). For example, in response to the BOOST TREBLE command, the program raises pulselength values by a factor proportional to the MIDI note number minus the lowest MIDI note on the instrument. For the TRANSPOSE command, the program add or subtracts a specified integer from the MIDI note number. The final software component is the DControl program, shown in Fig. dcontrol.png. This program is a general player that analyzes the DCM file and sends synchronized signals over the serial line to the Arduino board.
Brendan is a work in progress (I am still making improvements to the harpsichord system after two years). The technology is in place, so I am concentrating my current effort on experiments with repertoire. Some pieces work, some don't and others are unusual surprises.
For more information and to listen to additional tunes, visit https://www.fieldp.us/instruments/brendanleahy/