• Announcements

    • bluehash

      Forum Upgrade   03/11/2017

      Hello Everyone, Thanks for being patient while the forums were being fixed and upgraded. Please see details and report issues in this thread. Thanks!
Sign in to follow this  
Followers 0
Taggsladder

Voltage divider with zener protection problems

8 posts in this topic

Hello

 

I want to measure the battery voltage (ballpark measurement) in a car so I thought I do that with a voltage divider connected to a msp430 ADC pin, but I wanted to add overvoltage protection with a zener as in the schematics in the link below. I am using 100k / 10k in the voltage divider and a BZX79C2V7 zener. If I leave the zener disconnected I get the divider to work as expected in a linear fashion, but when I connect the zener I get the correct reading when the input voltage is 10V but if for example I double the input voltage to 20V I get a lower reading compared to when the zener is disconnected and the voltage divider is no longer linear.

 

Measurements without zener:

 

10V in, 0.9V to mcu pin

15V in, 1.35V to mcu pin

20V in, 1.78V to mcu pin

 

 

Measurements with zener:

10V in, 0.9V to mcu pin

15V in, 1.25V to mcu pin

20V in, 1.46V to mcu pin

 

 

Why is this so? B)

 

 

http://www.re-innovation.co.uk/web12/index.php/en/information/electronics-information/accurate-voltage-measurement

 

 

Thanks :)

 

Kind regards

Andreas

Share this post


Link to post
Share on other sites

Because the reverse current of a zener is not exactly zero, so there's a tiny current leaking through the zener causing it to act as a non-linear resistor in parallel with your second resistor.

I don't think you can solve this problem using just passives. You could maybe use an opamp as an analog buffer, powering it from the same source as your controller will effectively clip your output voltage from the opamp to the maximum voltage allowed by your controller.

Taggsladder likes this

Share this post


Link to post
Share on other sites

Thanks for the reply! TBT, just the word opamp scares me a little, hehe.

 

How comes the zener is used in the link and the title is "Accurate Voltage Measurement". Is there a way to calculate this offset in software or would it be to messy? I am not looking for a accurate reading, +- 0.5V in a 10-25V span would do fine.

 

Best regards

Share this post


Link to post
Share on other sites

Either try to define the behaviour of the zener and compensate for that in software, or - much simpler - make a table with a range of actual voltages and make a table that maps the ADC readout to voltages :D

Share this post


Link to post
Share on other sites

I was thinking about some sort of lookup table as you say :)

 

Thanks for the help, much appreciated.

 

Have a nice day!

 

Sent from my SM-G900F using Tapatalk

Share this post


Link to post
Share on other sites

Reducing the resistor values is also a possibility (if low current consumption is not important), say by a factor of ten - this will reduce the impact of the leakage current.

Share this post


Link to post
Share on other sites

Reducing the resistor values is also a possibility (if low current consumption is not important), say by a factor of ten - this will reduce the impact of the leakage current.

 

I played around with that too but since the device will power from the cars battery I want as low consumption as possible.

Share this post


Link to post
Share on other sites

To reduce current consumption, you could add a high side switch to the voltage divider which is controlled using a digital i/o pin and switch it on just before taking a sample.

 

Search for high side p-channel mosfet switch to find example circuits. There are also specialst one-stop-shop ic's for ths job, like the ITS4141N that uses logic control levels and works down to about 9V.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0