Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
void interrupt ISR()
{
// High by default
}
void low_priority interrupt ISR()
{
// Low as required..
}
#include<xc.h>
volatile int x;
void interrupt low_priority ISRL()
{
x = 2;
INT1IF = 0; // cancel button 1 press
}
void interrupt ISRH()
{
x = 1;
INT2IF = 0; // cancel button 2 press
}
void main(void)
{
IPEN = 1; // Interrupt prority set,,,
ADCON1 = 0xF; // PORTB ADC off
INTCON3 = 0x98; // set interrupt priority to INT1 and INT2
INTCON = 0xC0; // GIEH and GIEL set
while(1)
{
}
}
Thank you!
I'll try it out in my code and will update