delay/hanging while exiting ISR with PIC16f877A

General discussion on mikroC PRO for PIC.
Post Reply
Author
Message
oriabure
Posts: 1
Joined: 22 Jul 2022 01:21

delay/hanging while exiting ISR with PIC16f877A

#1 Post by oriabure » 22 Jul 2022 01:59

Hi guys, I am currently working on a project title "traffic controller with emergency override"
my while loop works well, but i encounter problem whenever the ISR is been called. The problems are as follows:
1) the last line of code in the ISR takes a longer time to execute than the time i allot to it
2) when it finally exit the ISR, it does not return to the exact line of code from which the ISR was called. Rather, it goes a step further (i.e. if the code was previously in line 12, on returning, it starts execution from line 13 even when the time allotted to line 12 is yet to be exhausted before the ISR was called.
i used the PORTB.RB0 external interrupt.
I will appreciate if anyone can proffer a solution to my dilemma.
Thanks in anticipation

Post Reply

Return to “mikroC PRO for PIC General”