Thanks so much for the helpful info. But allow me to get this straight. Any way I can clear the interrupt flag so I do not jump directly into the ISR again ? I think in my case every time the ISR will be executed first then judge which I/O (pin0_4 - P0_7) is in low-level stage. If P0_4 or P0_5 ( both connect to buttons) detected low, then the code need to do some routine. If P0_6 or P0_7 ( both for LEDs) detected low , then the code will execute nothing then leave the ISR. Is my understanding correct ?
Please help me again.
Thanks a lot,
Raymond