I am working on a home project which I would like to use a 16F873A to control a TIP120 Darlington to drive a relay coil. I first check a PortC pin for high or low. If high, I need to read an encoder to select a time delay before triggering the relay.
I would like to Check for high or low on PortC, read the two bit encoder which will have some value continuously on PortA, display time delay value on PortB, and drive the TIP120 on PortC. As I read about PortA I have some concerns using PortA as digital inputs. Question; using PBP should I set ADCON1= %00000111, TRISA=%11111111. There is a note in the mid range manual that says I may have a high current on pins on PortA as I read the value of the port. Do I have a problem using PortA as digital input?
TRISB=%00000000
TRISC=%11110000
Will PBP handle my concerns?
Comments will be appreciated.
Bookmarks