Atmel website | ARM Community | AVR freaks | Technical Support
Banner
 FAQ •  Search •  Register •  Login 

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: each intrrupt occured one time
PostPosted: Thu Jan 12, 2012 11:16 am 
Offline

Joined: Thu Jan 12, 2012 10:51 am
Posts: 1
hi every one....
i have some problem in (PIT/PIO) intrrupts .
each intrrupt occured just one time and then go to the PENDDIND mode ....
would u help me pls !!!???!!! :(
Code:
void PIT_initialize (void)
{
unsigned int MCLK_F = 48;
unsigned int Disr_F = 100000; // usec

PMC_EnablePeripheral(AT91C_ID_SYS); 
IRQ_ConfigureIT(AT91C_ID_SYS, (0x07 << 1 )| AT91C_AIC_SRCTYPE_POSITIVE_EDGE , (void (*)(void))ISR_PIT);    
IRQ_EnableIT(AT91C_ID_SYS);

PIT_Init(Disr_F, MCLK_F); 
PIT_EnableIT();
PIT_Enable();
 
}
void ISR_PIT (void)
{

unsigned int dummy;
unsigned int status;     

if (PIT_GetStatus() & AT91C_PITC_PITS)  status = PIT_GetPIVR();

jj = ~jj;
kk++;
if(jj) PIO_Set(&GPIO_porta2);   
else   PIO_Clear(&GPIO_porta2);


//AT91C_BASE_AIC->AIC_ICCR = 0x01 << AT91C_ID_SYS;   
//AT91C_BASE_AIC->AIC_EOICR = AT91C_BASE_AIC->AIC_IVR;

}


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: Bing [Bot] and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: