korg_wavedrum_midification
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
korg_wavedrum_midification [2013/06/09 13:23] – added link to source midisaron | korg_wavedrum_midification [2014/03/24 20:11] – midisaron | ||
---|---|---|---|
Line 1: | Line 1: | ||
**The Korg Wavedrum MIDIfied** | **The Korg Wavedrum MIDIfied** | ||
- | ====History==== | + | ====History |
In 1994 Korg released their first // | In 1994 Korg released their first // | ||
In 2009, Korg had stopped making Wavedrums a long time ago, a new // | In 2009, Korg had stopped making Wavedrums a long time ago, a new // | ||
Line 9: | Line 9: | ||
To keep the price low, Korg had to cut cost wherever possible. All newer Wavedrums came with a very limited user interface (no text let alone graphics - only a 3-digit seven segment display! 8-o), and they had no MIDI or other computer interface at all! I felt the urgent need to do something about that. | To keep the price low, Korg had to cut cost wherever possible. All newer Wavedrums came with a very limited user interface (no text let alone graphics - only a 3-digit seven segment display! 8-o), and they had no MIDI or other computer interface at all! I felt the urgent need to do something about that. | ||
- | ====MIDIfying the Wavedrum==== | + | ====MIDIfying the Wavedrum |
- | ===Hardware=== | + | ===Signals from the wavedrum=== |
- | ==Signals from the wavedrum== | + | |
The //WD-X//, the // | The //WD-X//, the // | ||
- | ==Interfacing the LPCXpresso board== | + | ===Interfacing the LPCXpresso board=== |
The LPC1769 microprocessor on the LPCXpresso board has an on-chip 12 bit A/D converter. Sampling both the head and the rim pickup at a rate of 10 kHz each, their waveforms can be captured quite accurately. While it would be possible to get the signals from the piezos directly, I decided to take them from the outputs of the buffer amplifiers located on the Wavedrum' | The LPC1769 microprocessor on the LPCXpresso board has an on-chip 12 bit A/D converter. Sampling both the head and the rim pickup at a rate of 10 kHz each, their waveforms can be captured quite accurately. While it would be possible to get the signals from the piezos directly, I decided to take them from the outputs of the buffer amplifiers located on the Wavedrum' | ||
Line 25: | Line 24: | ||
{{: | {{: | ||
- | ==Power supply for the LPCXPresso board== | + | ===Power supply for the LPCXPresso board=== |
The Wavedrum is powered from an external 9V/1.7A wall wart supply. Since the Wavedrum draws much less current than 1.7 amps it is possible to power the LPCXpresso board from the wall wart too. I use a simple linear regulator to get 3.3 volts from the 9 volts. The LPCXpresso board is quite a current hog, so the LM317 runs rather hot and needs a small heat sink. I placed the regulator on an extra board, but with a clever layout perhaps it would be possible to fit it onto the board carrying the LPCXpresso and the preamp too.\\ | The Wavedrum is powered from an external 9V/1.7A wall wart supply. Since the Wavedrum draws much less current than 1.7 amps it is possible to power the LPCXpresso board from the wall wart too. I use a simple linear regulator to get 3.3 volts from the 9 volts. The LPCXpresso board is quite a current hog, so the LM317 runs rather hot and needs a small heat sink. I placed the regulator on an extra board, but with a clever layout perhaps it would be possible to fit it onto the board carrying the LPCXpresso and the preamp too.\\ | ||
The Wavedrum is a quite noisy (electrically) environment. There are several DC/DC converters in there. The ground connection to the extra circuitry is critical. After a few experiments I found that noise is suppressed best with a single heavy wire ground connection from the sheet metal that holds the KLM-2739 board to pin 1 of the LPCXpresso board. The 9 volts are taken from the small board with the power supply jack and the on/off switch. Maybe there are better options. | The Wavedrum is a quite noisy (electrically) environment. There are several DC/DC converters in there. The ground connection to the extra circuitry is critical. After a few experiments I found that noise is suppressed best with a single heavy wire ground connection from the sheet metal that holds the KLM-2739 board to pin 1 of the LPCXpresso board. The 9 volts are taken from the small board with the power supply jack and the on/off switch. Maybe there are better options. | ||
Line 31: | Line 30: | ||
{{: | {{: | ||
- | ==Schematics== | + | ===Schematics=== |
{{: | {{: | ||
{{: | {{: | ||
- | ==User interface== | + | ===User interface=== |
Sorry, no user interface yet. At the moment all user-alterable parameters can be edited via MIDI Sysex only. | Sorry, no user interface yet. At the moment all user-alterable parameters can be edited via MIDI Sysex only. | ||
- | ===Software=== | + | ====MIDIfying the Wavedrum - Software==== |
- | {{: | + | {{: |
==Capturing the head's and the rim's signals== | ==Capturing the head's and the rim's signals== | ||
- | The ADC takes a sample every 50 microseconds. When idle, the head piezo, the rim piezos and the force sensor are sampled in turns. When a trigger on the head or on the rim is detected, i. e. a threshold is crossed, the force sensor is temporarily not sampled until 64 samples on the triggered channel (head or rim) are recorded and the event is processed. During that time the non-trigered | + | The ADC takes a sample every 50 microseconds. When idle, the head piezo, the rim piezos and the force sensor are sampled in turns. When a trigger on the head or on the rim is detected, i. e. a threshold is crossed, the force sensor is temporarily not sampled until 64 samples on the triggered channel (head or rim) are recorded and the event is processed. During that time the non-triggered |
- | ==Processing the signals== | + | Optionally all 64 samples are output via MIDI Sysex, so the recorded signal can be viewed. Here are a few examples recorded this way: |
- | When hit, a MIDI drum usually generates a Note On message with a fixed note number and a velocity value depending on how strong the drum was hit. To determine the strength I use the maximum deviation from idle level at the moment. Because the whole signal (64 samples) is available, many other ways are thinkable. | + | |
{{: | {{: | ||
Line 54: | Line 52: | ||
(The screenshots are taken from SoundDiver. I'm still using Apple' | (The screenshots are taken from SoundDiver. I'm still using Apple' | ||
- | ==Auto-zero== | ||
- | There are two trimpots to adjust the zero levels for the head and the rim signal (see schematics above). However, to determine the zero levels more precisely the levels at the three ADC inputs are measured on startup (after waiting for a few seconds, to allow for things to warm up). The zero levels of the head and the rim signals are also adjusted dynamically while waiting for trigger events. | ||
- | ==Crosstalk suppression== | + | ===Crosstalk suppression=== |
On the Wavedrum there is always crosstalk between head and rim. In some situations it may be desirable that only one MIDI message is generated when a trigger is detected on both pickups at the same time. When recording the head or rim signal is completed while on the other channel there' | On the Wavedrum there is always crosstalk between head and rim. In some situations it may be desirable that only one MIDI message is generated when a trigger is detected on both pickups at the same time. When recording the head or rim signal is completed while on the other channel there' | ||
- | ==Processing the force sensor== | + | ===Processing the signals=== |
- | When the voltage at the force sensor changes, a MIDI Control Change, Aftertouch or Pitch Bend message can be generated. | + | After 64 samples of the head or rim signal have been captured, a FFT (Fast Fourier Transform) on these samples is performed. This results in 33 (usable) frequency bins representing the spectrum of the signal. I did not program the FFT myself but took it from NXP's |
+ | [[http:// | ||
+ | I think it's amazing that the humble LPC1769 can calculate a 64-points-FFT so quickly that the delay is not noticable (at least to me). There are countless ways how the result of a FFT can be used. For the head signal, the high frequency components are stronger when the head is hit with a harder object (drumstick rather than hand), and when it's hit closer to the rim. This way a crude position detection is possible.\\ | ||
+ | Only the absolute values of the complex frequency bin values are used. The correct formula would be | ||
+ | < | ||
+ | but I skip the square root to save execution time. So the squares of the absolute values are used rather than the absolute values themselves.\\ | ||
+ | At the moment, I extract three parameters out of the FFT result: // | ||
+ | |||
+ | ===Auto-zero=== | ||
+ | There are two trimpots to adjust the zero levels for the head and the rim signal (see schematics above). However, to determine the zero levels more precisely the levels at the three ADC inputs are measured on startup (after waiting for a few seconds, to allow for things to warm up). The zero levels of the head and the rim signals are also adjusted dynamically while waiting for trigger events. | ||
+ | |||
+ | ===Processing the force sensor=== | ||
+ | When the voltage at the force sensor changes, a MIDI Control Change, Aftertouch or Pitch Bend message can be generated. | ||
+ | |||
+ | ===MIDI=== | ||
+ | |||
+ | ==Note On== | ||
+ | When the drum is hit at the head or at the rim, a Note On message is sent. The note number can be influenced by the //center frequency// of the FFT output (higher frequencies give higher note numbers), and by the pressure applied to the force sensor.\\ | ||
+ | The velocity can be taken from the // | ||
+ | The MIDI channel can be set individually for the head and for the rim. | ||
+ | |||
+ | ==Note Off== | ||
+ | If there' | ||
+ | |||
+ | ==Control Change, Aftertouch and Pitch Bend messages== | ||
+ | In addition to the Note On message a CC# message representing the // | ||
- | ==MIDI== | + | ==System Exclusive== |
- | When hit at the head or at the rim, a Note On message is sent. The note number and the MIDI channel can be set individually for the head and for the rim. If there' | + | |
Various user-settable parameters can be transmitted to the software via MIDI Sysex messages. The bulk dump format is as follows: | Various user-settable parameters can be transmitted to the software via MIDI Sysex messages. The bulk dump format is as follows: | ||
Line 104: | Line 124: | ||
- | ===Future plans=== | + | ====MIDIfying the Wavedrum - Future plans==== |
- | ==Replacing the force sensor== | + | ===Replacing the force sensor=== |
It's sometimes mentioned that the rebound of the Wavedrum is not great (playing with sticks, rebound helps when playing snare rolls etc). Some say this is because the force sensor pushes against the bottom side of the drum head. I think it should be possible to replace the mechanical sensor with a reflective optical sensor like the CNY70. This would not be in touch with the drum head at all, hence no impact on rebound. The sensitivity of the head pickup might be improved too. Regarding the Wavedrum' | It's sometimes mentioned that the rebound of the Wavedrum is not great (playing with sticks, rebound helps when playing snare rolls etc). Some say this is because the force sensor pushes against the bottom side of the drum head. I think it should be possible to replace the mechanical sensor with a reflective optical sensor like the CNY70. This would not be in touch with the drum head at all, hence no impact on rebound. The sensitivity of the head pickup might be improved too. Regarding the Wavedrum' | ||
- | ==Separating the two rim sensors== | + | ===Separating the two rim sensors=== |
As mentioned, there are two sensors attached to the rim, but these are just wired in series. Interpreting the two sensors' | As mentioned, there are two sensors attached to the rim, but these are just wired in series. Interpreting the two sensors' | ||
- | ==User interface== | + | ===User interface=== |
At least a text display and a few buttons. Unfortunately there isn't much room for this in the Wavedrum. | At least a text display and a few buttons. Unfortunately there isn't much room for this in the Wavedrum. | ||
- | ==Improving the Wavedrum' | + | ===Improving the Wavedrum' |
At the moment everything is coded into three digits or letters (letters that can reasonably be displayed in a seven-segment digit, that is). It's impossible to edit the Wavedrum' | At the moment everything is coded into three digits or letters (letters that can reasonably be displayed in a seven-segment digit, that is). It's impossible to edit the Wavedrum' | ||
With a text display the Wavedrum' | With a text display the Wavedrum' | ||
Yes, I'm aware that this is a huge programming task.:-o | Yes, I'm aware that this is a huge programming task.:-o | ||
- | ==Position sensing== | + | ===Position sensing=== |
Unlike the Roland HPD, the Wavedrum cannot sense //where// the drum head is hit. There are application notes from NXP on capacitive touch sensing with the LPC processors (AN11023, AN11095). I have no idea if this is feasible, but maybe regions of the drumhead can be covered with some conductive paint (from the bottom side perhaps), and, with hand playing, the region that was hit can be detected. | Unlike the Roland HPD, the Wavedrum cannot sense //where// the drum head is hit. There are application notes from NXP on capacitive touch sensing with the LPC processors (AN11023, AN11095). I have no idea if this is feasible, but maybe regions of the drumhead can be covered with some conductive paint (from the bottom side perhaps), and, with hand playing, the region that was hit can be detected. | ||
korg_wavedrum_midification.txt · Last modified: 2015/02/09 17:55 by midisaron