Display Vdd


Closed Thread
Results 1 to 8 of 8

Thread: Display Vdd

Hybrid View

  1. #1
    Join Date
    Feb 2010
    Posts
    6


    Did you find this post helpful? Yes | No

    Default Vdd display

    Thanks Joe.

    Yes of course you are right. The rectified voltage will be 1.414 times the AC voltage. And it measures accordingly. That's why I have a voltage divider built in and probably a zener after that to cover any cases where the AC goes over 30 volts.

    Any suggestions on how to do display Vdd/Vref ? Dave.

  2. #2
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,624


    Did you find this post helpful? Yes | No

    Default

    I may still be missing the point but if you want to measure and display Vdd, ie the PICs supply voltage, you MUST use an external, stable, source for Vref that does NOT "move" with Vdd, otherwise you will simply get the same reading all the time.

    Let's say your Vdd is 4.85V and therefor your Vref is 4.85V. A voltage of 4.85V on the analog inputs will now give you a full scale result (1023) from the ADC because 4.85V is what Vref is set to. Whatever you set Vref to is what will give you a full scale reading so as long as Vref=Vdd you can not measure and display Vdd with the ADC.

    /Henrik.

  3. #3
    Join Date
    Feb 2010
    Posts
    6


    Did you find this post helpful? Yes | No

    Default

    Thjanks again.

    All received and well understood. But the original question remains : "how do you physically display the current value of Vdd on an LCD?"

  4. #4
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,624


    Did you find this post helpful? Yes | No

    Default

    Hi,
    But the original question remains
    And has been answered IMO.....
    You use some kind of voltage reference chip that produces a stable reference voltage over the whole operating range of your batteries. Let's say that voltage is 2.048V. You connect this reference voltage to the Vref pin on the PIC and set the ADC up to use that pin as Vref+ instead of Vdd.

    Now you create a resistor network between Vdd and Vss and choose the resisitor values so that the voltage over the lower resistor is as close to 2.048V as possible when the batteries are fully charged. You connect this "signal" to the analog input of your choise.

    Now the ADC will give you a reading of 2mV/count.

    There is no way to internally "connect" Vdd to an analog input - except to the Vref+ pin. And there is no way to do measure Vdd without using an external reference voltage.

    /Henrik.

Similar Threads

  1. Hdsp 21xx display
    By Original in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 7th June 2012, 21:07
  2. Replies: 2
    Last Post: - 14th July 2008, 23:11
  3. DS1820 display with 7-seg 4 digits
    By chai98a in forum Code Examples
    Replies: 12
    Last Post: - 10th April 2008, 14:12
  4. need help on display problem
    By sixty9sandals in forum mel PIC BASIC Pro
    Replies: 19
    Last Post: - 30th March 2007, 04:57
  5. graphics display
    By adlinsystems in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 12th June 2004, 13:53

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

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