Fred, easiest way is use 1% tolerance resistor divider with 5,1 v ziner diode connected to ground to protect pic. on top of ziner add ceramic and electrolytic cap. this means when your battery is 14,4 v pic will get 5 v or you can set to any voltage. more expensive way is to use leaner opto-coupler this is good for noise etc. Andre Abelian fred jones wrote: > > Hi all, > I'm sure this is an easy question for many of you so I hope I don't > get flamed. I searched but can't find the answer in the archives > although I'm sure it must be there somewhere. This is not my strong > point so I thought I'd ask for help. > > I am building a device that will run off of a 12V gel cell battery. > It will use a 16F877 PIC powered with a 7805 regulator. I'd like to > be able to read the voltage of the gel cell and display it on the 2X16 > LCD display. I'm sure I can't connect the 12V batter into the A2D of > the PIC but I'm not sure what the proper method would be. Any help is > appreciated. > Thanks for your time, > FJ > > -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist