Yahoo Groups archive

Lpc2000

Index last updated: 2026-04-28 23:31 UTC

Message

IRQ problem

2006-03-19 by Hossam Alzomor

Hi


When trying to compile this code on keil I get the errore next to it
This part of code related to interupts

"
void init_micro()
{
	IODIR1=0x02000000;//P1.25 is output and used for RGB out
	PINSEL0=0x0000A05A;//P0.2 & P0.3 are used as SCL and SDA
			   //P0.1 used as EINT0
			   //P0.7 used as EINT2

	VICIntSelect= 0x00004000;//EINT0 used as FIQ	
	VICIntEnable= 0x00014000;//enable interrupt EINT0 & EINT2
	
	VICVectCntl0= 0x00000030;//EINT2 has periority 0 within the 
IRQ
	VICVectAddr0=  (unsigned long)IRQ_Handler;
}
void FIQ_Handler (void)	__fiq 
{
   if(!first_time)   
      first_time=1;
   else
   {
       first_time=0;
       LineCount++;
   }
  EXTINT = 0x00000001;      // Clear the peripheral interrupt flag
}
void IRQ_Handler (void)  __irq
{
	LineCount=1;
  	EXTINT = 0x00000004;   // Clear the peripheral interrupt flag
}
"
and here's the errors

TEST_INT.C(41): error C67: 'IRQ_Handler': undefined identifier
TEST_INT.C(58): error C53: redefinition of 'IRQ_Handler': different 
function attributes
TEST_INT.C(58): error C53: redefinition of 'IRQ_Handler': 
different '__irq/__fiq' attribute value
TEST_INT.C(59): error C53: redefinition of 'IRQ_Handler': different 
return types

Do you have any suggetions

Salam
Hossam Alzomor
www.i-g.org

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.