I am on a newbie to microcontrollers but I am new to GCB.
I have a simple issue with interrupts on a 16F1825.
I want to use the RA3 (the MCLRE) as my input. I am just trying to fire the interrupt. I have studied the datasheet and tried lots of options but nothing.
Please help.
Anobium
#chip 16F1825, 4
#config Osc = XT, MCLRE_OFF
'Set the input pin direction
#define SwitchIn1 PORTa.3
Dir SwitchIn1 In
DIR PORTC.0 OUT
DIR PORTC.1 OUT
DIR PORTC.2 OUT
DIR PORTC.3 OUT
'Setup the intertupt - see page 89 of the 16F1825 datasheet
On Interrupt PORTBChange Call Setir
main:
goto main
sub Setir
IntOff
portc = 15
wait 100 ms
portc = 0
IntOn
end sub
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am on a newbie to microcontrollers but I am new to GCB.
I have a simple issue with interrupts on a 16F1825.
I want to use the RA3 (the MCLRE) as my input. I am just trying to fire the interrupt. I have studied the datasheet and tried lots of options but nothing.
Please help.
Anobium