Maker Pro
Maker Pro

How to make a Voltage Controlled Oscillator

C

Cem Uzunoglu

You can't hear notes that high. 66 Hz - 5 kHz will do.

Well, believe it or not I do. My phone's ringtone is a 10khz pulsed sine
wave.
In fact I just checked with a frequency generator patch on my PC, I was
still hearing about 16khz, then it fell down quite fast after that. It
can be that my hearing curve comes to and abrupt end there, or the nyquist
effect from my 44.1khz sampling rate sound card kills it.

But I admit many people don't hear >8khz and it is musically m00t. So
let's say 8khz.
 
F

F. Bertolazzi

Cem Uzunoglu:
Well, believe it or not I do. My phone's ringtone is a 10khz pulsed sine
wave.

I believe what you say, I just don't believe that what you're hearing is 10
kHz, unless, by "hearing", you mean "feeling a weird, rather unpleasant
noise".
In fact I just checked with a frequency generator patch on my PC, I was
still hearing about 16khz, then it fell down quite fast after that.

In my first job I drew the PCB for a graphic terminal, but my most
appreciated ability was to spot immediately if the newly programmed synch
generator was working within the CRT's specs.
can be that my hearing curve comes to and abrupt end there, or the nyquist
effect from my 44.1khz sampling rate sound card kills it.
But I admit many people don't hear >8khz and it is musically m00t. So
let's say 8khz.

Let's say 4186 Hz.
 
C

Cem Uzunoglu

What's the source of the Voltage for the VCO? Is it from digital through
a DAC or what? Ken
(DAC = Digital to Analog Converter)

Yes. That was the idea. A basic 8 bit ladder DAC connected to a
microcontroller. But as I understood the complexities like thermal
effects and tuning the oscillator to get even an octave of tuned sounds
out of 8 bits, This seems to be getting very complex for such a simple
project.

There are some digitally controlled oscillators, but they are just too
simple to control. They don't pose any challenge, and what is a hobby
without a challenge? I think I'll implement the oscillator and do the
mixing in the microcontroller.

You know guys, this always happens. Whenever I want to do something the
analog way, it always turns out to be too complex for a hobby project. I
guess I now understand why even the simplest machines by todays standards
were really expensive back in the day.

I never used a UJT, but 555 was my first IC, I programmed PICs and I run
Linux. :) I guess the art of analog circuits is kind of lost on my
generation.

Cheers!
Cem
 
C

Cem Uzunoglu

What you're doing is a DCO (Digital) with 128 frequency choices, I've
designed and built those back before sound cards for PC's (c1980).

So your spec is really confined to 128 frequencies in effect ? That's
fine but you will hear the steps as you go up and down, you know, cuz
you only have 128 frequencies.

Actually 256 frequencies (for an 8bit DAC) but I know what you mean. It
would have been very limited, and to tune the VCO so that all that 256
frequencies would be reasonably near a musical note would have been a
pain in the neck.
How do they do it in digital handheld radios? That oscillator has to span
a really large frequency range in tiny steps, yet it somehow manages. Is
there a really wide DAC there or a completely different approach to make
a DCO?
You can sim that on your PC using the Sound function from QBasic to get
an idea of how that will sound.
I guess I'll opt for a software oscillator implemented in code. That will
be much more flexible I guess.

Cheers,
Cem
 
T

Tim Williams

Cem Uzunoglu said:
Yes. That was the idea. A basic 8 bit ladder DAC connected to a
microcontroller. But as I understood the complexities like thermal
effects and tuning the oscillator to get even an octave of tuned sounds
out of 8 bits, This seems to be getting very complex for such a simple
project.

Does the uC not have an internal timer/oscillator circuit? It's the best
way to go:
http://myweb.msoe.edu/williamstm/Solfeg_Fast.mp3

Heheh, I recorded this song from an 8MHz uC, but the song file was written
for 4MHz. Sounds a little strange, overclocked. The correctly formatted
song file plays in tune at a reasonable tempo, of course.

I have the AVR code used for this player, if that's any help.

Tim
 
J

Jeroen Belleman

Vladimir said:
Hey Jan,
Could you tell WTF is going on France? Looks like idiots are on the
rampage, are they?

They're upset because the government is increasing the legal
retirement age by two years. Quite understandable, in my opinion.
Widespread strikes upset the distribution of goods, especially
fuel, around the country. The situation seems to be gradually
returning to normal now.

Jeroen Belleman
 
M

Martin Brown

Cem Uzunoglu:


I believe what you say, I just don't believe that what you're hearing is 10
kHz, unless, by "hearing", you mean "feeling a weird, rather unpleasant
noise".

Most healthy adults can hear upto at least 12kHz pure sinewave. Some
younger children can hear nearly 20kHz. As a youngster I recall hearing
an annoying whistle from the line flyback transformer on some TVs
(presumably the ones with something loose). That is around 15k6Hz. I can
still just about hear pipestrelle bats calls - though presumably only
sidebands off their chirp since the fundamental is ~45kHz.

I had the opportunity to to test a moderate sized audience with a pure
sine wave pulsed and the kiddies hands started going up at 18kHz last
year. I could hear it at 14kHz and most adults were around 10-12kHz. A
few elderly folk still couldn't hear 5kHz but by then it was getting
annoyingly loud for the rest.
In my first job I drew the PCB for a graphic terminal, but my most
appreciated ability was to spot immediately if the newly programmed synch
generator was working within the CRT's specs.



Let's say 4186 Hz.

C8 is just the pianos highest note. Nothing special about that and most
people can easily hear it. It won't sound much like a piano note though
unless you include at least the third harmonic. There is something
seriously wrong with your hearing if you cannot hear 4kHz.

I set my Theremin up to do 50Hz-10kHz which covers the range most useful
for its ethereal style weird music. Linearising hand movement for
logarithmic frequency control was a nightmare. The Dr Who theme is
harder to play than it sounds as is Good Vibrations.

People may not hear higher frequencies distinctly, but that doesn't
prevent other parts of the ear detecting the sharper rise time. You can
squeeze intelligible speach over a very limited bandwidth, but it
actually takes skill to get broadcast quality high fidelity audio right.
UK DAB radio has failed in this respect at least for classical music.

Regards,
Martin Brown
 
F

F. Bertolazzi

Martin Brown:
C8 is just the pianos highest note. Nothing special about that and most
people can easily hear it. It won't sound much like a piano note though
unless you include at least the third harmonic. There is something
seriously wrong with your hearing if you cannot hear 4kHz.

Exactly. What is the frequency of the third armonic of C8?
16744 Hz, that, according to you, lies outside the range of most adults and
is anyway rather near the Nyquist frequency of a CD.
 
S

Spehro Pefhany

Hello all,

What is the simplest VCO that can be done with off-the-shelf components?
It doesn't have to be very fast. Audio range is fine.

Cheers,
Cem

http://www.national.com/ds/LM/LM124.pdf

Page 13. You can use a faster single supply dual op-amp if you like.

With minor changes you can do this with 5 parts and it will cost less
than 25 cents in moderate quantity:

1 dual op-amp
2 4- resistor networks (use two resistors in parallel for R/2)
1 2N7002 or similar
1 capacitor

If it's not obvious, the reference is the (single) power supply
voltage.


Best regards,
Spehro Pefhany
 
F

F. Bertolazzi

Jeroen Belleman:
They're upset because the government is increasing the legal
retirement age by two years. Quite understandable, in my opinion.

Is your opinion based on data you have about the number of people getting
benefits and the number of people paying for it, and does this data takes
in account that baby-boomers are about to retire?
Widespread strikes upset the distribution of goods, especially
fuel, around the country. The situation seems to be gradually
returning to normal now.

Now that their President passed the law despite this senseless strike? :D
 
M

Martin Brown

Martin Brown:


Exactly. What is the frequency of the third armonic of C8?
16744 Hz, that, according to you, lies outside the range of most adults and
is anyway rather near the Nyquist frequency of a CD.

Could be a linguistic thing here but in English the second harmonic is
2f and the third is 3f or around 12k5Hz which is borderline for many
adults and probably why the piano keyboard stops where it does.

According to you the alias from 16744Hz sampled at 44k01 for CD at
5376Hz is still above the range of human hearing. This is obvious
nonsense unless you were a roadie for loud heavy metal rock bands or
work in a boiler making shop.

Regards,
Martin Brown
 
F

F. Bertolazzi

Martin Brown:
Could be a linguistic thing here but in English the second harmonic is
2f and the third is 3f or around 12k5Hz which is borderline for many
adults and probably why the piano keyboard stops where it does.

Right, I said "harmonic" and calculated the octave.

The point is that Cem would like to build a Moog-style synthesizer, and
there is little reason to complicate the VCO in order to produce notes that
are outside a piano keyboard. All the further shaping of the fundamental
note he's going to produce is very likely to be useless, at such high
frequiencies.
According to you the alias from 16744Hz sampled at 44k01 for CD at
5376Hz is still above the range of human hearing.

I'm not sure I understood what you mean.
 
F

F. Bertolazzi

Jan Panteltje:
One point of view on this is that if you payed taxes all your life for a guaranteed gov pension at say age X,
and the gov than decides that it will only pay at X+n and you have to work n more years,
that sounds like a breach of contract to me.

If a contract cannot be honoured because of "act of God", then the contract
is void. The "act of God", in this case, is the doubling or tripling or
even more of the life expectancy while retired.
After the devaluation of the US dollar, the subsequent decrease of exports to the US, more unrest will come.

Most definitely, but not (only) because of a weak dollar.
This is actually what the US wants, the destabilisation of Europe.
So they can then sell more weapons.

Right. While Europeans are actively destabilizing Africa for selling their
weapons.

It's a sad and miserable world the one in which paranoid live.
Of course US will also destabilise in the process, already the deficit is so big that it cannot
be payed back, traders are buying bonds at 105%, betting on an interest raise...
Gold is way up...
War is coming.

Probably, but not because some Goldfinger decided it.

It's an inevitable outcome of keeping the unemployment rate at artificially
low levels. Our politicians (pushed by us voters) did it, and now we have
to pay it back. Or else.
 
P

PeterD

They're upset because the government is increasing the legal
retirement age by two years. Quite understandable, in my opinion.
Widespread strikes upset the distribution of goods, especially
fuel, around the country. The situation seems to be gradually
returning to normal now.

Jeroen Belleman

Funny, when they did the exact same thing in the US, no one said a
word of protest... Sad, isn't it!
 
Top