2014-05-02 10:35 PM
hi, i'm using a stm32f4 board. and i want to write a program with ecos embeded system that when i push user button, an interrupt will trigerd and do something.
i find the function cyg_interrupt_create(), but i need a interrupt vector. in the file /cyg/hal/var_intr.h , there are lots of CYGNUM_HAL_INTERRUPT_xxx, how can i know which one i should use? thanks in advanced! #ecos2014-05-04 01:10 AM
CYGNUM_HAL_INTERRUPT_EXTI0
Isn't the USER button PA0? Then use EXTI0 and configure the pin and exti.2014-05-04 07:03 AM
thanks for the reply. I have tried exti0, but it doesn't work. i thought it might be that i had to configured something with ecos configtool, but i don't have idea how to
2014-05-04 07:11 AM
but i don't have idea how to
Me neither, and I don't see much ecos traffic here, perhaps there is a better forum? You could review the STM32F4-DISCO firmware library, or that of the F4 DSP library, there should be button/exti examples in there.2014-05-04 09:23 PM
It's trully EXTI0, and it don't need to configure something. it turned out it's my program faults.
Thanks you anain!