cancel
Showing results for 
Search instead for 
Did you mean: 

ST10276Z5Q3 Interrupt service problem

zzp6252005
Associate II
Posted on February 20, 2008 at 22:51

ST10276Z5Q3 Interrupt service problem

2 REPLIES 2
zzp6252005
Associate II
Posted on February 20, 2008 at 04:17

Hello!

In my ST10F276 application,the CAPCOM12 interrupt routine defined as following:

void KeyPressed (void) interrupt CC12INT=0x1C

{

//do some thing ...

}

In system initial routine ,the following code are added:

sbit CCMOD12_0 = CCM3^0;

sbit CCMOD12_1 = CCM3^1;

sbit CCMOD12_2 = CCM3^2;

CC12IC = 0x1E; //0111 10 ILVL=7, GLVL=2 _nop_();_nop_();_nop_();

CCMOD12_0 = 0;

_nop_();_nop_();_nop_();

CCMOD12_1 = 1;

_nop_();_nop_();_nop_();

CCMOD12_2 = 0;

_nop_();_nop_();_nop_();

CC12IE = 1;

_nop_();_nop_();_nop_();

IEN = 1;

_nop_();_nop_();_nop_();

But the interrupt service routine never execute when I change CC12IO level from 0V to 5V or from 5V to 0V.

Can anyone help?

thanks!

zzp6252005
Associate II
Posted on February 20, 2008 at 22:51

Add the folowing code:

CC12IR = 1;