English
Language : 

CD1865 Datasheet, PDF (92/150 Pages) Intel Corporation – Intelligent Eight-Channel Communications Controller
CD1865 — Intelligent Eight-Channel Communications Controller
interrupt
return;
}
// Signal to the CD1865 that the current
// Service is concluded.
Transmit Interrupt Service
Service_Tx(unsigned char chan)
{
unsigned char
channel, vector,c;
int i;
vector= Read_Byte(0x85);
// Perform hardware acknowledge
channel = Read_Byte(GSCR1) >> 2;
if (channel==chan){
// Make sure correct channel
for (i=1; i<= 8 && !quit_tx ; i++){
Set_Byte(TDR, txm_str[tx_ptr[chan]++] );
if (tx_ptr[chan] >= strlen(txm_str) ){
tx_ptr[chan] = 0; // Reset the pointer back to the
quit_tx = 1;
}
}//for
}//if
else
Tx_chan_err = 1;
// Wrong transmitting channel.
Set_Byte(EOSRR, 0x00);
// Set Transmit End of Int Reg.
// The Transmit End of Interrupt Register must
// Be written to by the corresponding host
// Interrupt service routine to signal to the
// CD1865 that the current interrupt service
// Is concluded.
return;
}
Modem Interrupt Service
Service_Mdm()
{
unsigned char channel, vector;
vector = Read_Byte(MRAR);
//vector = Read_Byte(0x81);
// hardware acknowledge.
// Software acknowledge using MRAR
// Comment out the previous line, if using
channel = Read_Byte(GSCR1) >> 2;
switch(Read_Byte(MCR)&0xe0)
{
case 32:
// case of CTS change interrupt
{
printf(" CTR has a changed state. \n");
break;
}
case 64:
// case of CD change interrupt
{
printf(" CD has a changed state.\n");
break;
92
Datasheet