| Electronic Components Datasheet Search |
|
SCD1284 Datasheet(PDF) 95 Page - Intel Corporation |
|
|
|||||||||||||||||||||||||||||
SCD1284 Datasheet(HTML) 95 Page - Intel Corporation |
|
95 / 176 page ![]() IEEE 1284-Compatible Parallel Interface Controller — CD1284 Datasheet 95 switch (status) { case 1: /* all values that include a receive request */ case 3: case 5: case 7: case 0xF: rx_stat = service_rec( ); return(rx_stat); break; case 2: /* all values that include transmit but not receive */ case 6: case 0xA: case 0xE: tx_stat = service_txm( ); return(tx_stat); break; case 4: /* modem service request */ case 0xC: md_stat = service_mdm( ); return(md_stat); break; case: 8: /* parallel port service request */ par_stat = service_par(); return(par_stat); break; default: /* can’t happen */ break; } } } Once the code above locates an active request posted in the SVRR, it calls the appropriate subroutine to service the request. The service routines follow. 6.3.1.2 Serial Receive Service /* The receive service acknowledge cycle begins by reading the RIR. This register contains the necessary information to switch the CD1284 into the correct service acknowledge context. The RIR is saved for use at the end of the routine and then copied into the CAR. The act of copying the RIR into the CAR forces the context switch. The channel number requesting service is extracted from the RIR. The RIVR register indicates whether the request is for good data or exception data and is used to correctly handle the request. At the end of the service, the upper two bits in the RIR are cleared causing the switch out of the service acknowledge context. */ service_rec( ) { char serv_type, save_rir, save_car, channel, status, char; int char_count, i; save_rir = inportb(RIR); /* retrieve and save receive interrupt value */ channel = save_rir & 0x03; /* extract channel number from the RIR*/ save_car = inportb(CAR); /* save CAR for restore */ outportb(CAR, save_rir); /* switch CD1284 to service ack. context */ serv_type = inportb(RIVR) & 0x07; /* read vector register; get type (good/ exception)*/ switch (serv_type) { case 3: /* good data service */ char_count = inportb(RDCR); /* get number of characters in FIFO */ for ( i = 1; i <= char_count; i++) {/* - read that number of chars */ char = inportb(RDSR); /* read char from FIFO */ |
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |