analog input with VCO?
FlyingFishFinger
Posts: 461
Hello!
I just thought of a simple way to input analog signals into the stamp: Use the analog voltage to change the frequency of a VCO (Voltage Controlled Oscillator) and then read the resulting pulses with the Stamp. Has anyone done this before? Maybe it's really stupid, just an idea of mine...would it work? I tried it with an audible 555 VCO and the pulses (read with COUNT) seemed pretty random. Should I clean them up with a Schmidt trigger ?
I just thought of a simple way to input analog signals into the stamp: Use the analog voltage to change the frequency of a VCO (Voltage Controlled Oscillator) and then read the resulting pulses with the Stamp. Has anyone done this before? Maybe it's really stupid, just an idea of mine...would it work? I tried it with an audible 555 VCO and the pulses (read with COUNT) seemed pretty random. Should I clean them up with a Schmidt trigger ?
Comments
This method is used often... instead of cleaning up your signal from the 555 with a schmidt trigger, why not base
your oscillator around a schmidt trigger to begin with?
Here is an interesting circuit that I have used before, that can multiplex two analog signals into one PWM signal
that the Stamp can read.
Use PULSIN with the "state" descriptor to get a reading from t1 or t2
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Beau Schwabe
IC Layout Engineer
Parallax, Inc.
Thanks for the moment anyway.
50% duty cycle on the output signal. The inputs "skew" the duty cycle in one direction or the other by about 20%, so your PWM
ranges from 30% to 70%. Feel free to experiment with other values to get more range out of this if you want.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Beau Schwabe
IC Layout Engineer
Parallax, Inc.
The circuit you suggested did not work for me (probably because of my insufficient knowledge of electronics), but I used my 555 scheme and it did work. This is no problem since I have enough breadboard space and I/O pins to spare. Thanks for your help, I consider the topic closed.