void interrupt irq_service()
{
new_int_state=inportb(wBase+7)&0x0f; /* read all interrupt state */
int_c=new_int_state^now_int_state; /* compare which interrupt */
/* signal be change */
if ((int_c&0x1)!=0) /* INT_CHAN_0 is active */
{
if ((new_int_state&0x01)!=0) /* now P2C0 change to high */
{
CNT_H1++;
}
else /* now P2C0 change to low */
{
CNT_L1++;
}
invert=invert^1; /* to generate a high pulse */
}
if ((int_c&0x2)!=0)
{
if ((new_int_state&0x02)!=0) /* now P5C0 change to high */
{
CNT_H2++;
}
else /* now P5C0 change to low */
{
CNT_L2++;
{
invert=invert^2; /* to generate a high pulse */
}
if ((int_c&0x4)!=0)
{
If ((new_int_state&0x04)!=0) /* now P8C0 change to high */
{
CNT_H3++;
}
else /* now P8C0 change to low */
{
CNT_L3++;
}
invert=invert^4; /* to generate a high pulse */
}
if ((int_c&0x8)!=0)
{
if ((new_int_state&0x08)!=0) /* now P11C0 change to high */
{
CNT_H4++;
_L4++;
=invert^8; /* to generate a high pulse */
t_state=new_int_state;
0x20);
{
else /* now P11C0 change to low */
{
CNT
}
invert
}
now_in
outportb(wBase+0x2a,invert);
if (wIrq>=8) outportb(A2_8259,
outportb(A1_8259,0x20);
}
OME-PIO-D96 User Manual (Ver.1.1, Mar/2003) ---- 15