This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

exception handler problem.

hello,
first sorry for my bad english.

I want to light up 4 leds on stm32f4 discovery board.
I am able to do that without using interrupt in 4-5 lines.
But when i try to do that inside exception handler it is not working.
code is:

#include <stm32f407xx.h>
#include <system_stm32f4xx.h>

#define portDout *((uint16_t*)(0x40020c14))
#define portAin *((uint16_t*)(0x40020010))
#define portDmod *((uint32_t*)(0x40020c00))
#define RCCreg *((uint32_t*)(0x40023830))

int main(void){ SystemCoreClockUpdate(); __set_MSP(0x20020000); SysTick_Config(SystemCoreClock/100); NVIC_SetPriority(SysTick_IRQn,1); NVIC_EnableIRQ(SysTick_IRQn); while(1); return 0;
}

void SysTick_Handler(void){ RCCreg=RCCreg|0xFF; portDmod=0x55000000; portDout=0XF000;
}

greetings from croatia.
Andjelko.

0