Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 6 of 6

Thread: Reliable way to measure 24 VDC and have reverse current protection

  1. #1

    Reliable way to measure 24 VDC and have reverse current protection

    All,

    I have a data logger that measures a batter voltage where the battery will start at 24 VDC but degrade to 21 VDC.

    In order to protect from accidental backward connection I have a simple diode to prevent reverse current (which would probably damage my precious Teensy). A voltage divider drops the input volts to a safe measurable amount fed into pin A0. Computing the supply voltage from A0 measurement is pretty easy--and works. Kinda. See attached circuit diagram.

    In testing the circuit, I noticed the voltage drop across the diode varies based on voltage. Hence why I'm never able to calibrate the unit across a large range of voltages. I'm using and RL207.

    Anyone know of a better way measure 24 VDC with reverse polarity protection?
    1. better diode
    2. some op amp circuit
    3. other?


    Click image for larger version. 

Name:	RPP.jpg 
Views:	26 
Size:	23.7 KB 
ID:	29939


    Thanks in advance.

  2. #2
    Senior Member
    Join Date
    Apr 2020
    Location
    DFW area in Texas
    Posts
    565
    Kris: If you put the diode after the voltage divider, will the fact that it will see less of a voltage fluctuation work in your favor ??

    Mark J Culross
    KD5RXT

  3. #3
    Senior Member
    Join Date
    Aug 2018
    Location
    Brisbane, Australia
    Posts
    159
    Hi kris

    Like you, I fought calibrating a simple voltage divider with a rectifier diode for ages and eventually gave up and bit the bullet and added one of these to my motorcycle instruments project. Its been rock solid and as a bonus I can read real-time current draw.

  4. #4
    Senior Member+ MichaelMeissner's Avatar
    Join Date
    Nov 2012
    Location
    Ayer Massachussetts
    Posts
    4,391
    Quote Originally Posted by thebigg View Post
    Hi kris

    Like you, I fought calibrating a simple voltage divider with a rectifier diode for ages and eventually gave up and bit the bullet and added one of these to my motorcycle instruments project. Its been rock solid and as a bonus I can read real-time current draw.
    I was going to mention something like an INA219 sensor. Adafruit sells 2 versions, one in a feather wing package, and one with separate through hole connections:


    Adafruit has said the INA219 sensors have been hard to get during the chip shortages, and those two boards will use either INA219A or INA219B chips (the INA219A is 1% accurate, and the INA219B is 0.5% accurate), depending on what they can get at the moment. I've built a little monitoring station using a Teensy 4.0 with a featherwing adapter, featherwing display, featherwing tripler prototype board, and featherwing INA219A

  5. #5
    Junior Member
    Join Date
    Oct 2018
    Posts
    9

    Does this measurement break Vdd + 0.5v

    Just this week I was looking at the same kind if circuit shown at the top of this thread. I read in other thread posts that a voltage applied to an analog pin cannot be higher than Vdd + 0.5v. If the Teensy power is off then any voltage above 0.5v applied to an analog pin, from the external supply, is going to cause smoke.

    What did I get wrong.

    Carl

  6. #6
    Senior Member BriComp's Avatar
    Join Date
    Apr 2014
    Location
    Cheltenham, UK
    Posts
    1,146
    Yes. Put a BAT54S on the input to the Teensy. Should solve that problem.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •