We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi; I have been working on a simple project a couple of week now. It has two task which work simultaneously, and an interrupt handler in order to catch user button input.the board i use is stm32l152-discovery board.
the problem is that whenever i push the button to create an interrupt , system hangs on hardware fault exception handler.There is no problem with tasks. code I wrote is below.
When i push the button, it comes to irq handler but never goes to buttoncallBack task insted of this , it hangs on harware fault handler.
Please take a look .Thanks...
__irq void EXTI0_IRQHandler(void) { os_evt_set (0x0001, id_buttoncallBack); EXTI_ClearITPendingBit(EXTI_Line0); } __task void buttoncallBack (void) { while (1) { os_evt_wait_or (0x0001, 0xffff); /* wait for an event flag 0x0001 */ ;stuff to do... } }
Thanks bighead; It works as I expected.
It works as I told you it would work. I will not waste any more time with this.