Page 2 of 2

Re: Not An Interrupt to be Seen

PostPosted: Wed Jun 11, 2014 10:50 pm
by Ian.M
I regard it as good practice to set everything up for a feature or peripheral before enabling it.

Therefore:
* setup peripherals and I/O,
* set up the interrupt sources,
* set up INTCON with the GIE bit clear,
* do whatever it takes to acknowledge and clear the interrupt flags for any enabled interrupts to avoid spurious interrupts from the peripheral initialisation or from pins that are still settling after powerup
* finally set (GIE with BSF INTCON,GIE) immediately before entering the main superloop.

Re: Not An Interrupt to be Seen

PostPosted: Mon Jun 23, 2014 6:22 pm
by SLTom992
I should have added that I took your advice.