View Full Version : Display Vref 16f877
tico
- 14th January 2007, 02:43
Is there any way to display what the vref is in a 16f877 I an using A3 as my vref
but seem to have an issue with the A/D conversion. I have used a meter to verify the vref is what I want but was wondering of vref value could be output using debug or some other means.
Thanks in advance
Dave
- 14th January 2007, 10:44
tico, There is no way to report the value of VREF as it is used as the full scale rereference for the actual A/D. If there was some kind of band gap reference internal to the PIC that could be switched into the reference circuit then it would be possible but no luck.
Dave Purola,
N8NTA
skimask
- 14th January 2007, 11:34
Is there any way to display what the vref is in a 16f877 I an using A3 as my vref
but seem to have an issue with the A/D conversion. I have used a meter to verify the vref is what I want but was wondering of vref value could be output using debug or some other means.
Thanks in advance
Set up 2nd A/D (not Vref) on a diode (.25 or .6v) or other calibrated voltage reference (one of those 4.096v chips), and reference your Vref to that.
In other words, if you're 2nd A/D is a .6v diode (and it actually reads .6v, just an example here), and you're reading $80 on a 10 bit A/D, you're full scale ($400) will be 4.8v ($400 / $80 = 8 ; 8 * .6 = 4.8v).
Powered by vBulletin® Version 4.1.7 Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.