Hi,
I'm using the CCP1 Compare, in a program, which goes HIGH at compare.
I've tried all of these to reset it LOW, but none work (for me!)
--------------------------
LATC.2 = 0
PORTC.2 = 0
PIR1 = 0
PIE1 = 0
PIR1.CCP1IF = 0 'clear interrupt flag
CCP1CON = %00001000 'Compare mode; initialize CCPx pin low; ON COMPARE MATCH-force CCPx pin high (CCPxIF bit is set)
CCP1CON = %00001001 'Compare mode; initialize CCPx pin high; on compare match, force CCPx pin low (CCPxIF bit is set)
---------------------------
Any ideas please?
Camerart
I'm using the CCP1 Compare, in a program, which goes HIGH at compare.
I've tried all of these to reset it LOW, but none work (for me!)
--------------------------
LATC.2 = 0
PORTC.2 = 0
PIR1 = 0
PIE1 = 0
PIR1.CCP1IF = 0 'clear interrupt flag
CCP1CON = %00001000 'Compare mode; initialize CCPx pin low; ON COMPARE MATCH-force CCPx pin high (CCPxIF bit is set)
CCP1CON = %00001001 'Compare mode; initialize CCPx pin high; on compare match, force CCPx pin low (CCPxIF bit is set)
---------------------------
Any ideas please?
Camerart