small question on comparator of pic12f629

Status
Not open for further replies.

bouvett

New Member
in the datasheet there is written that the TRISIO register has something to do with the inputs and outputs of the comparator... in fact it says that for the output at GP2 to be enabled TRISIO<2> must be set (page 38)...

now do i also have to swt the TRISIO bit for the analogue input as 1 so to enable the analogue input?

thanks a lot
regards
 
Hi,

For the comparator output on GPIO2, TRISIO2 should be set (input) as in the datasheet. As for the comparator inputs, TRISIO should be set too (beginning of sec 6.2, page 37).

For the information of which SFR that affects the module your're using, please refer to the very end of the topic for the module. For comparator, it's in Table 6-2, page 40.
 
ok
so to enable inputs and outputs of the comparator, the coefficient bits in the TRISIO should be set right?
thanks
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…