Tell us about your experience with Open.Theremin

Posted: 12/6/2013 10:20:10 PM
gaudi

From: Switzerland (CH)

Joined: 8/6/2010

Oh, nice calculations and measurements ILYA. Have not made any measurement for a while myself ;-) . Did.you use the serial USB to record measurements? Can you provide a download link that I can have a closer look. Should definitely document the software. You seem to have understood well. Two "tricks" I used is the offset of the zero beat and the 1/x to linearize/extend linearity. And concerning Roys findings: The Open.Theremin has two simmilar heterodyne circuits for pitch and volume (unlike most theremin). The two circuits use different base frequencies to avoid interference (similar to two different radio stations). This is why it is pretty simple to make the polyphonic theremin.

 

Urs

Posted: 12/7/2013 12:11:33 PM
ILYA

From: Theremin Motherland

Joined: 11/13/2005

Hi Urs,

I did not make any measurements, it was just an analysis of operation, the some kind of reverse engineering. The input data are hypothetical and were taken from dewster's Excel Theremin Simulator.

I am not familar with AVR, but your software is written on C so I had spent not a lot of time for making calculations.

My congratulations, you have a viable design with great potential. So viable that I'm ready stop my R&D in some another direction and slightly convert my stuff for your approach :-). 

Posted: 12/7/2013 2:04:56 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

"Two "tricks" I used is the offset of the zero beat and the 1/x to linearize/extend linearity" - Urs

Not taking the heterodyning all the way to zero beat and then numerically offsetting this in software is very elegant.  I briefly investigated using the period rather than the frequency and didn't see an immediate benefit, but I should look into this again.

Urs, do you know what the response time of your circuit is?  This is the equivalent of the -3dB point of a low pass filter.  In my tests anything significantly below 1kHz made very quick hand movements get somewhat damped out.

I had trouble with "sticky" pitches with my earliest efforts, which were due to truncations in the digital phase locked loop NCO.  One paper I found was quite useful: "Spurious Suppression in Direct Digital Synthesizers" by Wheatley.  Analyzing the "sticky" points was difficult by ear, but recording the audio and examining the spectral frequency view in Adobe Audition (full free version here: http://www.techspot.com/downloads/5733-adobe-audition.html - HIGHLY recommended for all kinds of audio work including multi-tracking and scientific analysis) made the "sticky" points visually jump right out.

My Theremin spreadsheet is at version 9, and all versions can be found here:

https://www.mediafire.com/folder/w36b3brqyg2g3//theremin

Urs, not to denigrate your efforts in any way, but even with all of your excellent ingenuity I imagine you're likely hitting the limits of what the AVR is capable of doing.  Have you given any thought to moving the Open.Theremin project to a more powerful computing platform?

Posted: 12/11/2013 1:16:27 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

Urs, I wonder if the AVR could generate the heterodyning signals directly?  That would eliminate the need for external calibration of the analog oscillators to the crystal divider reference.

Posted: 12/17/2013 2:25:57 PM
Thierry

From: Colmar, France

Joined: 12/31/2007

Everybody who wants may meet (among others) Urs Gaudenz, the inventor of the open.theremin, Carolina Eyck and myself on January 25th, 2014 in Lausanne/Switzerland.

More info here: http://www.node-rdv.ch

Posted: 8/14/2014 4:51:56 PM
xtheremin8

From: züriCH

Joined: 3/15/2014

hello world,

i recently bought one of latest board versions off urs's production and entered the arduino world. theremins are sometimes confusing, but arduino gives me the rest! not mentioning 1v/oct issues ;-) 

so i would like to share my experiences with the uno and maybe some of the more experienced-ones can give me a push to the right path.

a very minimalistic theremin, just one small button for accessing the calibration etc. lovely. so i first checked both antennas for 600hz. i used a app for that and a plastic screwdriver. you know why. zero beat calibration was a bit tricky, because the calibration time (several bleeping tones) is a bit short. so i placed my volume hand at my liked distance over the antenna, my body at a good distance, about one armlenght away ,pushed the button and tried the pitch field for zero beat. i had to do this several times to get a satisfying pitch field. my first impression was very surprising how the pitch field is linear, imo. the basses are somewhat stretched and sound a bit thin, but my guitar player liked it. i like it when you feel basses physically. (so thanks again thierry, for the espe i put in my ew+). the midrange is very playable and also the higher notes. i doesn't go to earpiercing high notes, like a 145-theremin. i'm used to play with reversed volume antenna {closer=louder} but didn't try it on the uno yet, so i tried as it is the classic way {closer=silent}. i think it affects the tone in a nice way, for example when loaded with the "standard" ¿wavetable. but only in the quieter loudness range of the antenna (1-15%): i achieved cello-like sounds. but further (16-100%) it's just volume control. could this be extended for a bigger range?  i'm using a q-tron sometimes for envelope followed shaped stuff. so this can be compensated externally but would be nice to have it in the instrument. so i tried the three different wavetables, and liked the standard the most. i didn't experiment with the wavetables. just "changing the numbers" is not my cup of tea. and i'm still searching the web  for a understandable explanation of wavetable programming. i also tried cv-output but didn't get anything out of it. so urs told me that it's not assigned in the software, and that he will be updating his incredible great open.theremin blog about cv configuration. so i wait for that to be tested. but i guess it would need additional  circuitry for driving a 1v/oct synth? also on the open.theremin website is a link to the blog  from a japanese artist with some features he did on his theremin. very good documented, but i don't understand it. mostly because of these "webtranslators" in google,bing etc. he added a wavetable-switch and volume control-pot. and also shared the sketch so it would be possible to upload these features on a "leonardo-board", wich i don't have. would that work on a uno? so i didn't tried that.  i would like to add maybe a pushbutton for a wave-switch. there are soldering points on the theremin-shield that go to pin 5 of the arduino for, yeah maybe anything, if you know how that can be done.  has anybody made something useful with that?  so  i stll need a nice housing for it, even if all fits in a packet of lucky strike. and i go for some 1.5mm aeroplywood, but thats another chapter.  i'll post some pictures when done.

my experience is that with the open.theremin.: a real low price full-scale theremin that fits any budget and pocket. very linear imo. but not a arduino beginner piece. (got myself a starter-kit to dive into arduino, but there is no "expand the open.theremin features" chapter.

i like it  very much. and any help on the ?'s would be really appreciated. a digital merit button?

dani

Posted: 8/17/2014 5:19:04 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

I'm looking at the UNO design.  I could have very easily made a math or conceptual mistake somewhere, but it seems that in HW pitch calibration mode, the 600Hz output tone target is the same (or very nearly the same) as the heterodyned difference frequency.  During normal operation and when operating in this nominal range, there is a first order LPF with RC = 4 applied to the sine lookup table pointer increment.  If all of this is true, then F3 for the pitch side is:

  -ln(1-1/RC)*Fc/(2pi) = -ln(1-1/4)*600/(2pi) = 27Hz

So the UNO likely has quite obvious latency associated with the pitch response.  Can anyone confirm this?

The SW null calibration snags the current pitch point and uses it for the secondary difference offset.  This is divided by 2 (not sure why) and 200 is added to the result (perhaps to move the null point a bit).

I haven't simulated the HW heterodyning LPF, but it appears to be 3rd order with a corner frequency around 10kHz.

Posted: 8/17/2014 10:49:23 PM
Thierry

From: Colmar, France

Joined: 12/31/2007

dewster, there are probably a few problems in your thoughts.

- At the point where the calibration mode outputs 600Hz, there will be 0Hz in the playing mode, because the calibration value will be subtracted from the actual pitch value, so that at 600Hz the real pitch step will be zero. 

- The stepping through the wave table and the application of the LPF algorithm is done by a HW interrupt from the 8MHz clock divider with 31250Hz. Thus the time constant of the virtual RC is IMHO 4*32us which makes 128us or an F3 of 1.2kHz

Besides of that, theory is always good, practice is better... I tried the open.theremin playing some of the "usual" classical works for theremin, including Alyabyeff's "Nightingale" and I could not feel whatever delay or latency in the pitch response. I think that some of the engineer's theoretical considerations are meaningless for the musician, while the musician will sometimes detect or "feel" flaws in an academically perfect design...

Posted: 8/17/2014 11:08:49 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

"At the point where the calibration mode outputs 600Hz, there will be 0Hz in the playing mode, because the calibration value will be subtracted from the actual pitch value."   - Thierry

Yes, I understand that.  Is it true that in the HW calibration mode a 600Hz audio output tone corresponds to a heterodyned frequency of 600Hz?

"The stepping through the wave table and the application of the LPF algorithm is done by a HW interrupt from the 8MHz clock divider with 31250Hz. Thus the time constant of the virtual RC is IMHO 4*32us which makes 128us or an F3 of 1.2kHz"

Here is the relevant code:

/* New PITCH value */

  if (TIFR1&(1<<ICF1)){                      // If capture event

    pitch_counter=ICR1;                      // Get Timer-Counter 1 value
    pitch=(pitch_counter-pitch_counter_l);   // Counter change since last interrupt -> pitch value
    pitch_counter_l=pitch_counter;           // Set actual value as new last value

    //if ((pitch>19000)&(pitch<21000)) {PORTA |= (1<<PA0);} else {PORTA &= ~(1<<PA0);}  // LED on if value in range

    pitch_v=pitch;                  // Averaging pitch values
    pitch_v=pitch_l+((pitch_v-pitch_l)>>2);
    pitch_l=pitch_v;   

    switch (mode)                   // set wave frequency for each mode
    {
      case 1: add_val=33554432/pitch_v;           break; // pitch calibration mode
      case 2:                                     break; // volume calibration mode
      case 3: add_val=(pitch_init-pitch_v)/2+200; break; // mode without volume
      case 4: add_val=(pitch_init-pitch_v)/2+200; break; // normal operation
    };

    TIFR1 = (1<<ICF1);                          // Clear pitch capture flag
  }

It seems a flag is tested to see if a new timer value has been latched (?) and if so then the new value is read and filtering takes place.  If that is the case then filtering happens at a much lower rate than the main 31.25kHz loop.  But I could be wrong. 

ILYA, could you comment on this?

Posted: 8/17/2014 11:38:31 PM
FredM

From: Eastleigh, Hampshire, U.K. ................................... Fred Mundell. ................................... Electronics Engineer. (Primarily Analogue) .. CV Synths 1974-1980 .. Theremin developer 2007 to present .. soon to be Developing / Trading as WaveCrafter.com . ...................................

Joined: 12/7/2007

"Besides of that, theory is always good, practice is better... I tried the open.theremin playing some of the "usual" classical works for theremin, including Alyabyeff's "Nightingale" and I could not feel whatever delay or latency in the pitch response. I think that some of the engineer's theoretical considerations are meaningless for the musician, while the musician will sometimes detect or "feel" flaws in an academically perfect design..." - Thierry

Is there actually any point in engineers being here at TW? Perhaps we are redundant, as even an "academically perfect design" can be flawed.. (I dispute that assertion anyway - if there was such a thing as a "academically perfect design" then it would be perfect, both to engineers and to musicians.)

There are musicians who love the E-Pro, and there are those who hate it - Who is "right" and who is "wrong" ?

IMO, we need each other! Neither engineers alone or musicians alone (nor those who believe they embody the skills of both to an advanced level, but we will ignore these egotists ;-)  will advance electronic musical instruments! So who is needed most? Well, technicians to keep old theremins alive and construct theremins designed (in the past) by engineers will always be needed.. And musicians will always be needed for the instruments to be any use..

But are Engineers and academics needed? - No! Not really! - We are just a pain in the butt - we go looking for potential problems, go postulating new ideas, go developing irritating toys .. And worst of all, ask questions! Who the hell do we think we are? How dare we question anything that a musician hasn't questioned ?!

We are no bloody use to the theremin community (except when we are solving problems of those with a malfunctioning theremin or giving practical advice - but there are technicians who will do that if we weren't here ) , and should, as a matter of honor, remove our unsavory presence from anywhere we consume public bandwidth and bore the hell out of  normal people.

And we certainly aren't needed by the theremin community - there are enough pro theremins in circulation that these far exceed the number of pro thereminists! - No need to clutter the market with better theremins or advance the art, Hell, imagine the impact if we ever did that! All these people holding on to their pro instruments waiting to dump them on the market when Ebay prices rose, well, they could lose out!

Fred.

You must be logged in to post a reply. Please log in or register for a new account.