Set GPIO to digital I/O for PIC12F609

Status
Not open for further replies.

guesslsc85

Newbie level 5
Joined
Aug 11, 2009
Messages
9
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,349
Could anyone help on settings of PIC12F609 in order to make all GPIO to digital I/O?
PIC12F609 has CMCON0 and CMCON1 register, how to set GPIO 0, 1, 2 output to digital I/O?

*If using PIC12F629, it is equivalent to setting CMCON=0x07.

Thanks for replying.
 

Hi,


Try this :

CMCON0 = 0 // turn off comparators
ANSEL = 0b11110100 // turn off analog inputs
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…