PDA

View Full Version : Problem with RC3 and RC6 on 16F685



NL2TTL
- 9th February 2007, 08:55
I have this simple code:

@ DEVICE PIC16F685, WDT_ON, INTRC_OSC_NOCLKOUT

TRISC = 0
ADCON1 = 0

Main:
High PORTC.3
Pause 1000
High PORTC.6
Pause 1000
High PORTC.7
Pause 1000
High PORTB.7
Pause 1000
LOW PORTC.3
Pause 1000
LOW PORTC.6
Pause 1000
LOW PORTC.7
Pause 1000
LOW PORTB.7
Pause 1000

Goto Main

But when RC6 gets high, RC3 will automaticly goes low.
CMCON doesn't work. Anybody have a solution?

mister_e
- 9th February 2007, 14:58
'
' Disable ALL analog stuff
' ========================
ANSELH=0
ANSEL=0
CM1CON0=0
CM2CON0=0

NL2TTL
- 11th February 2007, 21:03
Thank you it's working.