Theremin Thursday - origin story and progress to date

 This project began sometime last year because I wanted a theremin to play around with (the instrument you play with gestures). I very nearly sprang for an Open Theremin kit, but thought I might be able to make myself something that worked well for much less. 

Cheaper kits use light-sensing components, which work optically but not optimally and are affected by ambient light.

I thought that there must be sensors that can read distance accurately - and there are. These lidar sensors are allegedly millimetre-accurate and aren't significantly affected by ambient light. I'm using ones with a 50cm sensing distance.


And so the project was born. The first few challenges were fun. Although the sensors are very accurate, they are noisy and you have to smooth that. This isn't very difficult and is the same as smoothing out paddles on a commodore computer*. You have to find the sweet spot where you take out the noise without losing too much responsiveness.  

I also had to learn about generating audio output. This requires a DAC chip and I had to learn how to send a sine wave, vary the pitch and volume and keep that smooth. Here I'm using a PCM5100A dev board. The other board is a MPR121 capacitive touch chip, my temporary touch pads give octave up/octave down (It currently plays an octave and a half, and I can shift 8 octaves).

The wilderness months

The project then sat on a shelf for a long time. I can identify three problems that made me lose interest. One was a bit of glitchiness that needed working through. Another was that eventually, to build this on a single custom pcb (ie without just plugging together development boards as I'm doing here) will require scary surface-mount work. The third was the MIDI output (I want both audio and MIDI). It worked but it was 'stepped' chromatically. I've since learned how pitch bends work in MIDI and suddenly I could see how to get smooth transitions  and produce any frequency. At that point I found the enthusiasm to sit and iron out the glitches and get the thing working as nicely as you see in the video below (yes the playing needs practice and the result a bit painful!)  (There is a long intro. The backing track is played using SID voices and the subject of a future post.)

I don't yet have the MIDI fully working, but here I have it sending some note on/off messages and note values.




* you take 9 tenths of the old value and a tenth of the new value. This gives you a 'rolling average'. 




Comments

Popular posts from this blog

e-ther 2 - Announcement and full rundown of features

Enclosures for MIDISID

MIDISID - second batch and giveaway