fhjkghk hkcgk

Interrupt don't work

Discussion created by fhjkghk hkcgk on Jun 11, 2008
Latest reply on Jun 20, 2008 by fhjkghk hkcgk
Hi all,
I'm novice and i want to make an interrupt but this don't work...
In main.c
Code:
/* * main implementation: use this sample to create your own application * */#define __interrupt__   __declspec(interrupt)#include "support_common.h" /* include peripheral declarations and more */#include "MCF52235_GPIO.h"#if (CONSOLE_IO_SUPPORT || ENABLE_UART_SUPPORT) /* Standard IO is only possible if Console or UART support is enabled. */#include <stdio.h>#endifextern __interrupt__ void timer_handler(void);__interrupt__void timer_handler(void){ MCF_GPIO_PORTUB=0; MCF_GPIO_PORTUB^=0x01; MCF_PIT0_PCSR=0x109; MCF_PIT0_PCNTR=0x1F4;}int main(void){  mcf5xxx_irq_enable();  MCF_GPIO_PORTUB=0; MCF_GPIO_DDRUB=0x06;  while(1) {  MCF_GPIO_PORTUB^=0x02;  }}

 
In mcf52235_vector.s

Code:
...#define _timer_handler  timer_handler... .extern _timer_handler...vector77: .long _timer_handler...

 The timer_handler function isn't execute by processeur :smileysad:
Thank a bunch
Sorry for my bad english and my hopelessness :smileyhappy:



Message Edited by kedja on 2008-06-11 10:20 AM

Outcomes