Re: 16F877A and LCD HD44780
_WDT_ON try change to _WDT_OFF it could be your reset
I am NOT overly familiar with the analog stuff. What I THINK I SEE, is ADCON1 is set to use VDD & VSS as voltage reference, you can change this to an external vref for your A/D conversion in the ADCON1 register, see sect. 11.2 of the data sheet, and you can supply that vREF on AN3, also you lose about .7 volt across those diodes, you could use schottkey or germanium which switch at lower voltage.
Last edited by Archangel; - 25th October 2013 at 09:12.
If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
.
Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
.
There simply is no "Happy Spam" If you do it you will disappear from this forum.
Bookmarks