Maker Pro
Maker Pro

voltage to freq converter

P

PDRUNEN

Jan 1, 1970
0
Hi All,

I want to take an analog voltage, 0-5 volts and convert over to a PWM signal
with fixed period. The on time of the PWM would be based on the input voltage.

This PWM signal will travel over a opto device for isolation and then be
converted back to a analog voltage.

I have been reviewing the net and see Analog Devices has a really good handle
on this type of thing, but they are out of the budget for my application.

Any one have a good "cost effective" solution to such a requirement?
 
R

Rene Tschaggelar

Jan 1, 1970
0
PDRUNEN said:
Hi All,

I want to take an analog voltage, 0-5 volts and convert over to a PWM signal
with fixed period. The on time of the PWM would be based on the input voltage.

This PWM signal will travel over a opto device for isolation and then be
converted back to a analog voltage.

I have been reviewing the net and see Analog Devices has a really good handle
on this type of thing, but they are out of the budget for my application.

Any one have a good "cost effective" solution to such a requirement?

Apparently you are not seeking a voltage to frequency converter,
but just a PWM. This can be achieved with a constant current source
loading a cap and a fet unloading the cap at fixed intervalls.
Some do that with a 555. Then a comparator, such as a LM339.

Rene
 
M

martin griffith

Jan 1, 1970
0
Apparently you are not seeking a voltage to frequency converter,
but just a PWM. This can be achieved with a constant current source
loading a cap and a fet unloading the cap at fixed intervalls.
Some do that with a 555. Then a comparator, such as a LM339.

Rene
something like this?
http://www.solorb.com/elect/solarcirc/pwm2/index.html



martin

Serious error.
All shortcuts have disappeared.
Screen. Mind. Both are blank.
 
C

Christian Rausch

Jan 1, 1970
0
PDRUNEN,

an old classic is the 3524 (SG3524, LM3524, UC3524, ...) and this is
probably what you want. As far as I know, it sells for less than 50 (euro or
US) cents.
Have a look at National's application note AN292 for application examples.

Christian
 
J

Joerg

Jan 1, 1970
0
Hi PDRUNEN,

The LM331 from National is a nice V/F converter chip.

Regards, Joerg
 
N

Nicholas O. Lindan

Jan 1, 1970
0
PDRUNEN said:
I want to take an analog voltage, 0-5 volts and convert over to a PWM signal
with fixed period. The on time of the PWM would be based on the input
voltage.

V/F's don't work that way. The pulse width is fixed and frequency changes with
voltage.
I have been reviewing the net and see Analog Devices has a really good handle
on this type of thing

I don't know your bandwidth and accuracy requirements, but an AD654 works very
well to about 14bits with a 100mSec count integration period.
they are out of the budget for my application.

Seventy five cents? With a bit of a song-and-dance AD will send a sample for
free.

What's the application, a Mattel toy (where major projects
are initiated to shave off $0.03)?

$0.03 x 1,000,000 = $30,000.00
 
J

Joerg

Jan 1, 1970
0
Hi Nicholas,
Seventy five cents? With a bit of a song-and-dance AD will send a sample for
free.
The only way to make it happen at that cost and with fixed frequency
would be an oscillator and a current ramp into a cap that starts fresh
every rising clock edge. Then a comparator would switch when Vin equals
Vramp and, bingo. Kind of a poor man's slope conversion.

Or run it into a uC per dual slope conversion and send in any code, PWM,
whatever. But I guess that would have to be one of those Chinese 4Bit
chips then.
What's the application, a Mattel toy (where major projects
are initiated to shave off $0.03)?

$0.03 x 1,000,000 = $30,000.00
It's not only Mattel. Same for diposable med stuff. We sometimes
calculate in "Milli-Dollars".

Regards, Joerg
 
S

Spehro Pefhany

Jan 1, 1970
0
Hi All,

I want to take an analog voltage, 0-5 volts and convert over to a PWM signal
with fixed period. The on time of the PWM would be based on the input voltage.

This PWM signal will travel over a opto device for isolation and then be
converted back to a analog voltage.

I have been reviewing the net and see Analog Devices has a really good handle
on this type of thing, but they are out of the budget for my application.

Any one have a good "cost effective" solution to such a requirement?

One of the most straightforward methods is to use a 5V microcontroller
with (for example) a 10-bit ADC on it. Convert to digital and either
generate your pulse or send the data as serial data over the barrier.
The accuracy will be limited by the ADC (not by much) and the accuracy
of the 5V supply on the remote processor. From Microchip's line, the
PIC12F683 is one possibility (about 1.50 in 100 in SOIC-8). Very low
parts count and it has both a 10-bit ADC and hardware 10-bit PWM.

If you want to avoid microcontrollers, what you need to to is to
generate either a 0-5V sawtooth or a 0-5V triangle wave and compare
that to the unknown voltage. If you want to avoid rail-to-rail
op-amps, you may prefer to have something like a 100mV to 3V ramp, so
that would be your input range. The accuracy will be limited mostly by
how stable and accurate the switching points of the triangle wave are.



Best regards,
Spehro Pefhany
 
N

Nicholas O. Lindan

Jan 1, 1970
0
Joerg said:
Seventy five cents? With a bit of a song-and-dance AD will send a sample for
free.
The only way to make it happen at that cost [lots of parts]
Or run it into a uC per dual slope conversion and send in any code, PWM,
whatever.

That may be the cheapest way: There's lots of 75c micros out there with
at least a comparator input - add an R and a C and a bit of software and
away you go.

Something sticks in my head about AVR/Atmel having a cheapy
with a 4-channel 10-bit A/D.
But I guess that would have to be one of those Chinese 4Bit
chips then.

Oh, horrors.
It's not only Mattel. Same for disposable med stuff. We sometimes
calculate in "Milli-Dollars".

Gee, and here most folks thought that 'med stuff' was calculated in
Milli(on)-Dollars.

There was an ad in EDN et. al. with the picture of a car's C-Pillar and
the line: "The boss ordered you to take 75c out of the design to pay for
the opera windows". It was the 70's. The tasteless era: pale green
leisure suits, 100% polyester drip-dry shirts, white belt and shoes:
wearing all that at one time was called 'A full Cleveland'.

I worked a little on a disposable irrigation gun (think medical power squirt-
gun, 'To clean you out after they cut you up'). The nurses would fight over
the disposed units so as to crack them apart and remove the 4 D-Duracells
in each one. Client wanted to take 50c out of the product. Removable/
replaceable batteries (save $2) were right out.

Med-Stuff is a funny business. Kafka is on the board of directors.
 
J

Joerg

Jan 1, 1970
0
Hi Nicholas,
That may be the cheapest way: There's lots of 75c micros out there with
at least a comparator input - add an R and a C and a bit of software and
away you go.
Plus a crystal. But in this case it can be almost any frequency. I like
the MSP chips that only need a 32KHz watch crystal because those
crystals are between a dime and a nickel. The higher frequency is made
internally via a frequency control loop, something like a poor man's
PLL. Pretty smart, works nicely.
Oh, horrors.
Where the documentation is not necessarily available in English, of
course....
Gee, and here most folks thought that 'med stuff' was calculated in
Milli(on)-Dollars.
Not anymore, at least not since everyone has to fight for that coveted
Medicare 'reimbursement number', HMO endorsements and so on. When it
comes to disposables like your squirt gun every penny counts nowadays.
50 Cents would be a huge amount of money in that field.
There was an ad in EDN et. al. with the picture of a car's C-Pillar and
the line: "The boss ordered you to take 75c out of the design to pay for
the opera windows". It was the 70's. The tasteless era: pale green
leisure suits, 100% polyester drip-dry shirts, white belt and shoes:
wearing all that at one time was called 'A full Cleveland'.
I lived in Europe back then but it was similar. Ugly sideburns, clashing
colors, disgusting pop music. I mean, I really liked the Stones but much
of the other stuff, yuck. Also, I doggedly stuck to cotton shirts,
mostly the lumberjack style, listened to country music and Wolfman Jack,
and avoided "modern" plastic stuff like the plague. It's still the same
except that Wolfman Jack ain't around anymore.

Regards, Joerg
 
K

Ken Smith

Jan 1, 1970
0
Hi Nicholas,

Plus a crystal. But in this case it can be almost any frequency. I like

Many of the micros on the market today can get by without a crystal unless
you want a very accurate frequency.
 
N

Nicholas O. Lindan

Jan 1, 1970
0
Joerg said:
Plus a crystal.
Or an R and a C. If it is PWM instead of V/F then all the timing is
relative.
I lived in Europe back then but it was similar. Ugly sideburns, clashing
colors,

Dark brown and burnt orange plastic for restaurant interiors ...
disgusting pop music. I mean, I really liked the Stones but much
of the other stuff, yuck. Also, I doggedly stuck to cotton shirts,
mostly the lumberjack style, listened to country music and Wolfman Jack,
and avoided "modern" plastic stuff like the plague. It's still the same
except that Wolfman Jack ain't around anymore.

"I'm a lumberjack and I'm OK,
I sleep all night and I work all day ..."
 
N

Nicholas O. Lindan

Jan 1, 1970
0
Ken Smith said:
Many of the micros on the market today can get by without a crystal unless
you want a very accurate frequency.

Good solution.

Most cheap-o-processor applications aren't very time dependant. If available
I use the AC line as a timebase when an accurate one is needed.

Using the AC line as a timebase keeps integrated measurements - say from a
V/F - synchronized with the power line hum - you can get 70db transverse
power line noise rejection, for free!
 
J

Joerg

Jan 1, 1970
0
Hi Ken,
Many of the micros on the market today can get by without a crystal unless
you want a very accurate frequency.
Then a resonator can be used, or R and C as Nicholas suggested. It'll
still be an additional 5 Cents or so. Just nitpicking ;-)

Regards, Joerg
 
K

Ken Smith

Jan 1, 1970
0
Nicholas O. Lindan said:
Using the AC line as a timebase keeps integrated measurements - say from a
V/F - synchronized with the power line hum - you can get 70db transverse
power line noise rejection, for free!

... and get the clock to read 24.000 hours in a day without a crystal
 
K

Ken Smith

Jan 1, 1970
0
Hi Ken,

Then a resonator can be used, or R and C as Nicholas suggested. It'll
still be an additional 5 Cents or so. Just nitpicking ;-)

If you use the Cygnal one or, I think, some of the PICs, no external parts
are needed at all.
 
J

Joerg

Jan 1, 1970
0
Hi Ken,
.. and get the clock to read 24.000 hours in a day without a crystal
Depends on where you live. We had times here in California where the day
had only 18 hours according to the 60Hz cycle count. The other six hours
were candle light and battery time.

Regards, Joerg
 
K

Ken Smith

Jan 1, 1970
0
.. and get the clock to read 24.000 hours in a day without a crystal
Depends on where you live. We had times here in California where the day
had only 18 hours according to the 60Hz cycle count. The other six hours
were candle light and battery time.[/QUOTE]

Yes, I too am in California. They problem of keeping clocks on time when
the power fails can be real trouble. I have about 8 I need to reset and
each has a different procedure for doing it.

One idea:

Let the chip always run on the internal oscillator. Use software to work
out the average period, in terms of machine cycles, of the mains.
Calibrate the fractional divider from the machine cycles based on that.
If the temperature doesn't change too much during the outage, this would
hold the clock quite well.
 
Top