Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Forums > Electronic Projects Design/Ideas/Reviews


Electronic Projects Design/Ideas/Reviews Are you building an electronic project or want to? Maybe you need some assistance? Come and submit your electronic questions here and let our experienced members find a solution.

Reply
 
Thread Tools Display Modes
Old 15th December 2007, 06:18 PM   (permalink)
New Member
Markley02 is on a distinguished road
Default How to turn 0-5 volts to 5-0 volts

I have a sensor that puts out 0-5 volts. When it is putting out 5 volts though, I need 0 volts. When it is putting out 0 volts I need 5 volts. When it is putting out 4 volts I need 2 volt.

How many volts I have : How many I need

0 : 5
1 : 4
2 : 3
3 : 2
4 : 1
5 : 0

I think you guys get the point. How can I do this?
Markley02 is offline   Reply With Quote
Old 15th December 2007, 06:39 PM   (permalink)
Experienced Member
 
ericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud of
Default

Quote:
Originally Posted by Markley02
I have a sensor that puts out 0-5 volts. When it is putting out 5 volts though, I need 0 volts. When it is putting out 0 volts I need 5 volts. When it is putting out 4 volts I need 2 volt.

How many volts I have : How many I need

0 : 5
1 : 4
2 : 3
3 : 2
4 : 1
5 : 0

I think you guys get the point. How can I do this?
hi,
This circuit will get the job done.
Attached Files
File Type: pdf OPAOFFSE.pdf (8.2 KB, 68 views)
__________________
Eric
"Good enough is Perfect"

PIC tutorials:
Gramo's: www.digital-diy.net/
Bill's: www.blueroomelectronics.com/

Last edited by ericgibbs; 7th July 2008 at 11:22 AM.
ericgibbs is offline   Reply With Quote
Old 15th December 2007, 08:41 PM   (permalink)
Experienced Member
 
Roff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to behold
Default

Eric, maybe the supply voltage should be 7V or more. The LM358 datasheet says VOH is Vcc-1.5, and the part does have a Darlington emitter follower for the pullup stage. I don't have any hands-on experience with these parts, but I believe it's a good idea to go with the datasheet.
__________________
Ron

Roff is online now   Reply With Quote
Old 16th December 2007, 09:01 AM   (permalink)
Experienced Member
 
ericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud of
Default

Quote:
Originally Posted by Roff
Eric, maybe the supply voltage should be 7V or more. The LM358 datasheet says VOH is Vcc-1.5, and the part does have a Darlington emitter follower for the pullup stage. I don't have any hands-on experience with these parts, but I believe it's a good idea to go with the datasheet.
hi Ron,
On my earlier drawings of this circuit I used to state +8V as a supply voltage, to give that 'overhead' for +5V out.
However from the results/tests I find that the +6V will just allow a +5V limit or close to.
Also by using about +6V, the user cannot overdrive the PIC's ADCinp from a low impedance source.

Some of the earlier OPs stated they hadnt got the +8/+9v available on their projects, so I checked it out for +6V...
personally I would choose a +9V supply, as you say, these devices do vary.

Thanks for the feedback..[ if you will pardon the pun!.. ]

EDIT: the other reason for this choice of LM358, is it accepts input voltages down to 0Vin
__________________
Eric
"Good enough is Perfect"

PIC tutorials:
Gramo's: www.digital-diy.net/
Bill's: www.blueroomelectronics.com/

Last edited by ericgibbs; 16th December 2007 at 09:04 AM.
ericgibbs is offline   Reply With Quote
Old 16th December 2007, 03:12 PM   (permalink)
Experienced Member
 
audioguru is a splendid one to beholdaudioguru is a splendid one to beholdaudioguru is a splendid one to beholdaudioguru is a splendid one to beholdaudioguru is a splendid one to beholdaudioguru is a splendid one to beholdaudioguru is a splendid one to behold
Default

The circuit is inverting so the input of the opamp never goes anywhere near ground.
The LM358 was chosen because its output can go down to near ground, and a load resistor will drive it closer to ground.

Its class-A pullup current is 50uA so its minimum output voltage is +0.05V with a 1k load resistor to ground.
__________________
Uncle $crooge
audioguru is online now   Reply With Quote
Old 16th December 2007, 05:07 PM   (permalink)
New Member
Markley02 is on a distinguished road
Default

You guys are so awesome! I cannot thank everyone enough. It actually should only need to go down to about +0.3V anyway so the +0.05V will give some room to spare.

So, I should still try +6V for the supply voltage first right?
Markley02 is offline   Reply With Quote
Old 16th December 2007, 05:16 PM   (permalink)
Experienced Member
 
Roff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to beholdRoff is a splendid one to behold
Default

Quote:
Originally Posted by Markley02
You guys are so awesome! I cannot thank everyone enough. It actually should only need to go down to about +0.3V anyway so the +0.05V will give some room to spare.

So, I should still try +6V for the supply voltage first right?
If you already have a 5V supply, you can use an op amp with rail-to-rail output and get within 50mV or less to +5V and GND if your op amp output is lightly loaded. However, you probably won't find one at Radio Schlock.
__________________
Ron

Roff is online now   Reply With Quote
Old 16th December 2007, 05:21 PM   (permalink)
Experienced Member
 
audioguru is a splendid one to beholdaudioguru is a splendid one to beholdaudioguru is a splendid one to beholdaudioguru is a splendid one to beholdaudioguru is a splendid one to beholdaudioguru is a splendid one to beholdaudioguru is a splendid one to behold
Default

Quote:
Originally Posted by Markley02
So, I should still try +6V for the supply voltage first right?
The datasheet for the LM358 shows its typical output high voltage with a very low load current is about 1.2V less than its supply voltage. So with a 6V supply its max output could be +4.8V or a little more or a little less.
__________________
Uncle $crooge
audioguru is online now   Reply With Quote
Old 17th December 2007, 01:14 AM   (permalink)
Experienced Member
dipmicro is on a distinguished road
Default

Quote:
I have a sensor that puts out 0-5 volts. When it is putting out 5 volts though, I need 0 volts. When it is putting out 0 volts I need 5 volts.
How about reverting the sensor and connecting it to the 5V instead of common. No circuitry required.
__________________
www.dipmicro.com
dipmicro is offline   Reply With Quote
Old 17th December 2007, 02:34 AM   (permalink)
Experienced Member
john1 is a jewel in the roughjohn1 is a jewel in the rough
Default

just what i was thinking.
Cross it over.
Still, some sensors have a common connection on the casing,
but i'm sure it could be done easily
if we could see the circuit.

John
__________________
************************************************** *****************
john1 is offline   Reply With Quote
Old 17th December 2007, 08:31 AM   (permalink)
Experienced Member
 
ericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud of
Default

hi Markley,
If the sensor cannot be reversed, consider using a Texas OP365, rail to rail opa with a +5V supply rail, thats if you really need the end limits of the 0/+5V.

Price wise, the OP365 in the UK is about £2GBP compared to a LM358 about £0.5GBP.

If you have +9V on the project board, power the LM358 with that.
__________________
Eric
"Good enough is Perfect"

PIC tutorials:
Gramo's: www.digital-diy.net/
Bill's: www.blueroomelectronics.com/
ericgibbs is offline   Reply With Quote
Old 17th December 2007, 03:08 PM   (permalink)
New Member
Markley02 is on a distinguished road
Default

http://dutch.northwestmr2.com/Toyota...Inspection.pdf

That is the sensor's circuit.
Markley02 is offline   Reply With Quote
Old 17th December 2007, 03:32 PM   (permalink)
Experienced Member
 
ericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud of
Default

Quote:
Originally Posted by Markley02
hi,
Looked thru your pdf.
It looks as though its not possible to switch the sensor 'over'.

Where did you get the values of 0V and +5V out from the sensor bridge, did you measure it? or was it from a datasheet?.
As it appears to be a bridge sensor, I would expect a mid range voltage on the output?
__________________
Eric
"Good enough is Perfect"

PIC tutorials:
Gramo's: www.digital-diy.net/
Bill's: www.blueroomelectronics.com/
ericgibbs is offline   Reply With Quote
Old 17th December 2007, 04:05 PM   (permalink)
New Member
Markley02 is on a distinguished road
Default

It has a 12 volt supply. From many sources on the web it says 0V to +5V. It is possible that it could go up to +6V. If I get close to maxing it out anyway I will just increase the diameter of the pipe and that will cause a lower reading.
Markley02 is offline   Reply With Quote
Old 17th December 2007, 05:31 PM   (permalink)
Experienced Member
 
ericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud ofericgibbs has much to be proud of
Default

Quote:
Originally Posted by Markley02
It has a 12 volt supply. From many sources on the web it says 0V to +5V. It is possible that it could go up to +6V. If I get close to maxing it out anyway I will just increase the diameter of the pipe and that will cause a lower reading.
hi,
In that case do as I suggested in my 09:13 post of today.

That is, a OP365 with a +5V supply or the LM358 with a +8V supply, using the pdf circuit I posted previously.

Does that help?
__________________
Eric
"Good enough is Perfect"

PIC tutorials:
Gramo's: www.digital-diy.net/
Bill's: www.blueroomelectronics.com/
ericgibbs is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Latest
Line Detection Robot using PIC16F877 helmyshahryl Micro Controllers 0 28th August 2007 01:53 AM
Reduce 5 volts to 3 volts, suggestions? prprog Electronic Projects Design/Ideas/Reviews 19 21st December 2006 06:02 PM
12 volts from two 9 volt batteries sandmantoy Electronic Projects Design/Ideas/Reviews 9 22nd April 2006 01:02 PM
Turn on and off air valves thup Electronic Projects Design/Ideas/Reviews 16 27th December 2003 03:19 AM
brake light/ turn signal andrew8485 Electronic Projects Design/Ideas/Reviews 13 11th November 2003 12:48 AM



All times are GMT. The time now is 09:53 PM.


Electronic Circuits  |  Radio Controlled
Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.