Part Number Hot Search : 
14923F SR2812 0815002 123ML Y7C680 A1208 N5265 15DW1T1
Product Description
Full Text Search
 

To Download SC68C94C1N Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quart) 1 1995 may 1 853-1601 15179 description the 68c94 quad universal asynchronous receiver/transmitter (quar t) combines four enhanced philips semiconductors industry-standard uar t s with an innovative interrupt scheme that can vastly minimize host processor overhead. it is implemented using philips semiconductors' high-speed cmos process that combines small die size and cost with low power consumption. the operating speed of each receiver and transmitter can be selected independently at one of eighteen fixed baud rates, a 16x clock derived from a programmable counter/timer , or an external 1x or 16x clock. the baud rate generator and counter/timer can operate directly from a crystal or from external clock inputs. the ability to independently program the operating speed of the receiver and transmitter make the quar t particularly attractive for dual-speed channel applications such as clustered terminal systems. each receiver is buf fered with eight character fifos (first-in-first-out memories) and one shift register to minimize the potential for receiver overrun and to reduce interrupt overhead in interrupt driven systems. in addition, a handshaking capability is provided to disable a remote uar t transmitter when the receiver buf fer is full. (r ts control) the 68c94 provides a power-down mode in which the oscillator is stopped and the register contents are stored. this results in reduced power consumption on the order of several magnitudes. the quar t is fully ttl compatible and operates from a single +5v power supply . features ? new low overhead interrupt control ? four philips semiconductors industry-standard uar ts ? eight byte receive fifo and eight byte transmit fifo for each uart ? programmable data format: 5 to 8 data bits plus parity odd, even, no parity or force parity 1, 1.5 or 2 stop bits programmable in 1/16-bit increments ? baud rate for the receiver and transmitter selectable from: 23 fixed rates: 50 to 230.4k baud non-standard rates to 1.0m baud user-defined rates from the programmable counter/timer associated with each of two blocks external 1x or 16x clock ? parity , framing, and overrun error detection ? false start bit detection ? line break detection and generation pin configura tions v cc a5:0 cen rdn wrn iackn reset x1/clk x2 rda-d v ss d7-0 dackn rqn i/o0ad i/o1ad i/o2ad i/o3ad tda-d sd00178 ? programmable channel mode normal (full-duplex), automatic echo, local loop back, remote loopback ? programmable interrupt priorities ? identification of highest priority interrupt ? global interrupt register set provides data from interrupting channel ? v ectored interrupts with programmable vector format ? iackn and dt ackn signals ? built-in baud rate generator with choice of 18 rates ? four i/o pins per uar t for modem controls, clocks, etc. ? power down mode ? high-speed cmos technology ? 52-pin plcc and 48-pin dip ? commercial and industrial temperature ranges available ? on-chip crystal oscillator ? ttl compatible ? single +5v power supply with low power mode ? t wo multifunction programmable 16-bit counter/timers ? 1mhz 16x mode operation ? 30ns data bus release time ? aw atch dogo timer for each receiver ordering information packages commercial industrial dwg # packages v cc = +5v + 10%, t a = 0 o c to +70 o c v cc = +5v + 10%, t a = 40 o c to +85 o c dwg # 48-pin plastic dual in-line package (dip) SC68C94C1N sc68c94a1n sot240-1 52-pin plastic leaded chip carrier (plcc) sc68c94c1a sc68c94a1a sot238-3
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 2 pin configura tions 46 45 44 48 47 46 45 44 43 42 41 40 39 38 37 36 35 34 33 32 31 30 29 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 28 27 26 25 21 22 23 24 x1/clk txdd rxdd irqn a5 a4 a3 a2 a1 a0 wrn cen rdn dackn iackn txdb rxdb d7 d6 d5 d4 d3 d1 d0 rxda txda i/o2b i/o1b i/o0b i/o2a i/o1a i/o0a i/o0c i/o1c i/o2c i/o0d i/o1d i/o2d rxdc txdc reset x2 v ss v cc d2 v ss v ss cen rdn dackn iackn txdb rxdb d7 d6 d5 d4 i/o3b d1 d0 rxda txda i/o2b i/o1b i/o0b i/o3a i/o2a d2 v ss d3 i/o1a a1 a2 a3 a4 a5 irqn rxdd txdd x1/clk x2 txdc rxdc i/o2d i/o1d i/o0d i/o3c i/o2c i/o1c i/o0c reset i/o3d i/o0a v ss wrn a0 48-pin dual-in-line package 52-pin plcc package 1 2 3 4 5 6 7 8 9 10 11 18 19 20 21 22 23 24 31 32 33 34 35 36 37 50 51 52 38 39 40 41 42 43 25 26 27 28 29 30 12 13 14 15 16 17 47 48 49 v ss v cc v ss v ss sd00179 absolute maximum ra tings 1, 2 symbol parameter rating unit t a operating ambient temperature range 3 note 4 o c t stg storage temperature range 65 to +150 o c v cc v oltage from v dd to gnd 4 0.5 to +7.0 v v s v oltage from any pin to ground 4 0.5 to v cc +0.5 v p d power dissipation 1 w notes: 1. stresses above those listed under absolute maximum ratings may cause permanent damage to the device. this is a stress rating only and functional operation of the device at these or any other condition above those indicated in the operation section of this specification is not implied. 2. for operating at elevated temperatures, the device must be derated based on +150 c maximum junction temperature. 3. this product includes circuitry specifically designed for the protection of its internal devices from damaging ef fects of excessive static charge. nonetheless, it is suggested that conventional precautions be taken to avoid applying any voltages larger than the rated maxima. 4. parameters are valid over specified temperature range. see ordering information table for applicable temperature range and operating supply range.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 3 block diagram 8 d0d7 rdn wrn cen a0a5 reset x1/clk x2 6 bus buffer opera tion control address decode r/w control timing channel a mr 0, 1, 2 cr sr input port output port opcr csr rx csr tx crystal oscillator power up-down logic same as duart ab 8 byte transmit fifo transmit shift register 8 byte receive fifo receive shift register change-of- state detect ors (4) ipcr acr function select logic channel b (as above) timing clock selectors counter/ timer acr ctur ctlr interrupt control imr isr internal da ta bus txda rxda txdb rxdb 1:0 4 timing control dackn duart cd txdc txdd rxdc rxdd i/o[3:0]c i/o[3:0]d 1:0 i/o[3:0]b i/o[3:0]a ? v cc ? v ss1 ? v ss2 ? v ss3 ? v ss4 baud rate generator duart ab logic global registers irqn iackn interrupt arbitra tion 8 duart common ab 18 4 4 4 2 sd00180
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 4 pin description mnemonic type name and function cen i chip select: active low input that, in conjunction with rdn or wrn, indicates that the host mpu is trying to access a quar t register . cen must be inactive when iackn is asserted. a5:0 i address lines: these inputs select a 68c94 register to be read or written by the host mpu. d7:0 i/o 8-bit bidirectional data bus: used by the host mpu to read and write 68c94 registers. rdn i read strobe: active low input. when this line is asserted simultaneously with cen, the 68c94 places the contents of the register selected by a5:0 on the d7:0 lines. wrn i w rite strobe: active low input. when this line is asserted simultaneously with cen, the 68c94 writes the data on d7:0 into the register selected by a5:0. dackn o data acknowledge: active low , open-drain output to the host mpu, which is asserted subsequent to a read or write operation. for a read operation, assertion of dackn indicates that register data is valid on d7:0. for a write operation, it indicates that the data on d7:0 has been captured into the indicated register . this signal corresponds to readyn on 80x86 processors and dt ackn on 680x0 processors. irqn o interrupt request: this active low open-drain output to the host mpu indicating that one or more of the enabled uar t interrupt sources has reached an interrupt value which exceeds that pre-programmed by host software. the irqn can be used directly as a 680x0 processor input; it must be inverted for use as an 80x86 interrupt input. this signal requires an external pull-up resistor . iackn i interrupt acknowledge: active low input indicates host mpu is acknowledging an interrupt requested. the 68c94 responds by placing an interrupt vector or interrupt vector modified on d7-d0 and asserting dackn. this signal updates the cir register in the interrupt logic. cen must be high during this cycle. tda-d o t ransmit data: serial outputs from the four uar ts. rda-d i receive data: serial inputs to the four uar ts/ i/o0a-d i/o input/output 0: a multi-use input or output signal for each uar t . these pins can be used as general purpose inputs, clear to send inputs, 1x or 16x t ransmit clock outputs or general purpose outputs. change-of-state detection is provided for these pins. i/o1a-d i/o input/output 1: a multi-use input or output signal for each uar t . these pins can be used as general purpose or 1x or 16x transmit clock inputs, or general purpose 1x or 16x receive clock outputs. change-of-state detection is provided for these pins. in addition, i/o1a and i/o1c can be used as counter/t imer inputs and i/o1b and i/o1d can be used as counter/t imer outputs. i/o2a-d i/o input/output 2: a multi-use input or output signal for each uar t . these pins can be used as general purpose inputs, 1x or 16x receive clock inputs, general purpose outputs, r ts output or 1x or 16x receive clock outputs. i/o3a-d i/o input/output 3: a multi-use input or output signal for each uar t . these pins can be used as general purpose inputs, 1x or 16x transmit clock inputs, general purpose outputs, or 1x or 16x transmit clock outputs. reset i master reset: active high reset for the 68c94 logic. must be asserted at power-up, may be asserted at other times that the system is to be reset and restarted. osc set to divide by 1, mr pointer set to 1, dackn enabled, i/o pins to input. registers reset: opr, cir. irqn, dt ackn, ivr interrupt v ector , power down, t est registers, fifo pointers, baud rate generator , error status, w atch dog t imers, change of state detectors, counter/timer to timer, t ransmitter and receiver controllers and all interrupt bits. if reset pin is not used, then first chip access should be to celar `power-down' mode. x1/clk i crystal 1 or communication clock: this pin is normally connected to one side of a 3.6864mhz or a 7.3728mhz crystal, or can be connected to an external clock up to 8mhz. x2 o crystal 2: if a crystal is used, this pin should be connected to its other terminal. if an external clock is applied to x1, this pin should be left unconnected. v cc , v ss power and grounds: respectively . counter/timer i/o port control uarts a/b interrupt control block b uarts c/d i/o control i/o port control a0-a5 d (7:0) dtackn iackn baud rate generator bus interface block a sd00161 figure 1. channel architecture
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 5 table 1. quart registers 1 a5:0 read (rdn = low) write (wrn = low) 000000 mode register a (mr0a, mr1a, mr2a) mode register a (mr0a, mr1a, mr2a) 000001 status register a (sra) clock select register a (csra) 000010 reserved command register a (cra) 000011 receive holding register a (rxfifoa) t ransmit holding register a (txfifoa) 000100 input port change reg ab (ipcrab) auxiliary control reg ab (acrab) 000101 interrupt status reg ab (israb) interrupt mask reg ab (imrab) 000110 counter/t imer upper ab (ctuab) counter/t imer upper reg ab (cturab) 000111 counter/t imer lower ab (ctlab) counter/t imer lower reg ab (ctlrab) 001000 mode register b (mr0b, mr1b, mr2b) mode register b (mr0b, mr1b, mr2b) 001001 status register b (srb) clock select register b (csrb) 001010 reserved command register b (crb) 001011 receive holding register b (rxfifob) t ransmit holding register b (txfifob) 001100 output port register ab (oprab) output port register ab (oprab) 001101 input port register ab (iprab) i/opcra (i/o port control reg a) 001110 start counter ab i/opcrb (i/o port control reg b) 001111 stop counter ab reserved 010000 mode register c (mr0c, mr1c, mr2c) mode register c (mr0c, mr1c, mr2c) 010001 status register c (src) clock select register c (csrc) 010010 reserved command register c (crc) 010011 receive holding register c (rxfifoc) t ransmit holding register c (txfifoc) 010100 input port change reg cd (ipcrcd) auxiliary control reg cd (acrcd) 010101 interrupt status reg cd (isrcd) interrupt mask reg cd (imrcd) 010110 counter/t imer upper cd (ctucd) counter/t imer upper reg cd (cturcd) 010111 counter/t imer lower cd (ctlcd) counter/t imer lower reg cd (ctlrcd) 011000 mode register d (mr0d, mr1d, mr2d) mode register d (mr0d, mr1d, mr2d) 011001 status register d (srd) clock select register d (csrd) 011010 reserved command register d (crd) 011011 receive holding register d (rxfifod) t ransmit holding register d (txfifod) 011100 output port register cd (oprcd) output port register cd (oprcd) 011101 input port register cd (iprcd) i/opcrc (i/o port control reg c) 011110 start counter cd i/opcrd (i/o port control reg d) 011111 stop counter cd reserved 100000 bidding control register a (bcra) bidding control register a (bcra) 100001 bidding control register b (bcrb) bidding control register b (bcrb) 100010 bidding control register c (bcrc) bidding control register c (bcrc) 100011 bidding control register d (bcrd) bidding control register d (bcrd) 100100 reserved power down 100101 reserved power up 100110 reserved disable dackn 100111 reserved enable dackn 101000 current interrupt register (cir) reserved 101001 global interrupting channel reg (gicr) interrupt v ector register (ivr) 101010 global int byte count reg (gibcr) update cir 101011 global receive holding reg (grxfifo) global t ransmit holding reg (gtxfifo) 101100 interrupt control register (icr) interrupt control register (icr) 101101 reserved brg rate. 00 = low; 01 = high 101110 reserved set x1/clk divide by two 2 101111 reserved set x1/clk normal 2 110000111000 reserved reserved 111001 t est mode t est mode 111010111111 reserved reserved notes: 1. registers not explicitly reset by hardware reset power up randomly . 2. in x1/clk divide by 2 all circuits receive the divided clock except the brg and change-of-state detectors.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 6 functional blocks the quar t is composed of four philips semiconductors industrystandard uar t s, each having a separate transmit and receive channel. the basic uar t cells in the quar t are configured with 8-byte receive fifos and 8-byte t ransmit fifos. hardware supports interrupt priority arbitration based on the number of bytes available in the transmit and receive fifos, counter/timers, change of state detectors, break detect or receiver error . attempts to push a full fifo or pop an empty fifo do not af fect the count. baud rate generator the baud rate generator used in the quar t is the same as that used in other philips semiconductors industry standard uar ts. it provides 18 basic baud rates from 50 baud to 38,400 baud. it has been enhanced to provide to provide other baud rates up to 230,400 baud based on a 3.6364mhz clock; with an 8.0mhz clock rates to 500k baud. other rates are available by setting the brg rate to high at address 2d hex or setting t est 1 on at address 39 hex. see t able 3. these two modes are controlled by writing 00 or 01 to the addresses above. they are both set to 00 on reset. external rx and tx clocks yield rates to 1mhz in the 16x mode. block diagram as shown in the block diagram, the quar t consists of: data bus buffer , interrupt control, operation control, timing, and four receiver and transmitter channels. the four channels are divided into two dif ferent blocks, each block independent of the other . channel blocks there are two blocks (block diagram), each containing two sets of receiver/transmitters. in the following discussion, the description applies to block a which contains channels a and b. however , the same information applies to all channel blocks. data bus buffer the data bus buf fer provides the interface between the external and internal data buses. it is controlled by the operation control block to allow read and write operations to take place between the controlling cpu and the quar t. operation control the operation control logic receives operation commands from the cpu and generates appropriate signals to internal sections to control device operation. it contains address decoding and read and write circuits to permit communications with the microprocessor via the data bus buf fer . the functions performed by the cpu read and write operations are shown in t able 1. mode registers (mr) 0, 1 and 2 are accessed via an address counter . this counter is set to one (1) by reset or a command 1x to the command register for compatibility with other philips semiconductors software. it is set to 0 via a command bx to the command register (cr). the address counter is incremented with each access to the mr until it reaches 2 at which time it remains at 2. all subsequent accesses to the mr will be to mr2 until the mr counter is changed by a reset or an mr counter command. the mode registers control the basic configuration of the uar t channels. there is one for each uar t. (t ransmitter/receiver pair) timing circuits the timing block consists of a crystal oscillator , a baud rate generator , power up/down logic and a divide by 2 selector . closely associated with the timing block are two 16-bit counter/timers; one for each duar t. oscillator the crystal oscillator operates directly from a 3.6864mhz crystal connected across the x1/ clk and x2 inputs with a minimum of external components. if an external clock of the appropriate frequency is available, it may be connected to x1/clk. if an external clock is used instead of a crystal, x1 must be driven and x2 left floating as shown in figure 10. the clock serves as the basic timing reference for the baud rate generator (brg), the counter/timer , and other internal circuits. a clock frequency , within the limits specified in the electrical specifications, must be supplied even if the internal brg is not used. the x1 pin always supplies the clock for the baud rate generator . the x1 pin also has a feature such that it may be divided by 2. the divide by two mode must always be used whenever the x1 pin is above 4mhz. the baud rate generator supplies the standard rates when x1 is at 3.6864mhz. in the divide by 2 mode, all circuits receive the divide by two clock except baud rate generator and i/o pin change-of-state detectors. 7.3738mhz clock doubles standard baud rates. baud rate generator the baud rate generator operates from the oscillator or external clock input and is capable of generating 18 commonly used data communications baud rates ranging from 50 to 38.4k baud. the eighteen brg rates are grouped in two groups. eight of the 18 are common to each group. the group selection is controlled by acr[7]. see the baud rate t able 3. the clock outputs from the brg are at 16x the actual baud rate. the counter/timer can be used as a timer to produce a 16x clock for any other baud rate by counting down the crystal clock or an external clock. the clock selectors allow the independent selection, by the receiver and transmitter , of any of these baud rates or an external timing signal. counter/timer the counter timer is a 16-bit programmable divider that operates in one of three modes: counter , timer , time out. in the timer mode it generates a square wave. in the counter mode it generates a time delay . in the time out mode it monitors the time between received characters. the c/t uses the numbers loaded into the counter/t imer lower register (ctlr) and the counter/t imer upper register (ctur) as its divisor . there are two counter/timers in the quar t ; one for each block. the counter/timer clock source and mode of operation (counter or timer) is selected by the auxiliary control register bits 6 to 4 (acr[6:4]). the output of the counter/timer may be used for a baud rate and/or may be output to the i/o pins for some external function that may be totally unrelated to data transmission. the counter/timer also sets the counter/timer ready bit in the interrupt status register (isr) when its output transitions from 1 to 0. a register read address (see t able 1) is reserved to issue a start counter/timer command and a second register read address is reserved to issue a stop command. the value of d(7:0) is ignored. the st ar t command always loads the contents of ctur, ctlr to the counting registers. the st op command always resets the isr(3) bit in the interrupt status register . t imer mode in the timer mode a symmetrical square wave is generated whose half period is equal in time to division of the selected counter/timer clock frequency by the 16-bit number loaded in the ctlr ctur. thus, the frequency of the counter/timer output will be equal to the counter/timer clock frequency divided by twice the value of the ctur ctlr. while in the timer mode the isr bit 3 (isr[3]) will be
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 7 set each time the counter/timer transitions from 1 to 0. (high to low) this continues regardless of issuance of the stop counter command. isr[3] is reset by the stop counter command. note: reading of the ctu and ctl registers in the timer mode is not meaningful. when the c/t is used to generate a baud rate and the c/t is selected through the csr then the receivers and/or transmitter will be operating in the 16x mode. calculation for the number `n' to program the counter timer upper and lower registers is shown below . n=2 x 16 x baud rate desired/(c/t clock frequency often this division will result in a non-integer number; 26.3 for example. one can only program integer numbers to a digital divider . therefore 26 would be chosen. this gives a baud rate error of 0.3/26.3 which is 1.14%; well within the ability of the asynchronous mode of operation. counter mode in the counter mode the counter/timer counts the value of the ctlr ctur down to zero and then sets the isr[3] bit and sets the counter/timer output from 1 to 0. it then rolls over to 65,365 and continues counting with no further observable ef fect. reading the c/t in the counter mode outputs the present state of the c/t . if the c/t is not stopped, a read of the c/t may result in changing data on the data bus. t imeout mode the timeout mode uses the received data stream to control the counter .the time-out mode forces the c/t into the timer mode. each time a received character is transferred from the shift register to the rxfifo, the counter is restarted. if a new character is not received before the counter reaches zero count, the counter ready bit is set, and an interrupt can be generated. this mode can be used to indicate when data has been left in the rx fifo for more than the programmed time limit. if the receiver has been programmed to interrupt the cpu when the receive fifo is full, and the message ends before the fifo is full, the cpu will not be interrupted for the remaining characters in the rxfifo. by programming the c/t such that it would time out in just over one character time, the above situation could be avoided. the processor would be interrupted any time the data stream had stopped for more than one character time. note: this is very similar to the watch dog time of mr0. the dif ference is in the programmability of the delay time and that the watchdog timer is restarted by either a receiver load to the rxfifo or a system read from it. this mode is enabled by writing the appropriate command to the command register . w riting an `ax' to cra or crb will invoke the timeout mode for that channel. w riting a `cx' to cra or crb will disable the timeout mode. only one receiver should use this mode at a time. however , if both are on, the timeout occurs after both receivers have been inactive for the timeout period. the start of the c/t will be on the logical or of the two receivers. the timeout mode disables the regular st art/st op counter commands and puts the c/t into counter mode under the control of the received data stream. each time a received character is transferred from the shift register to the rxfifo, the c/t is stopped after one c/t clock, reloaded with the value in ctur and ctlr and then restarted on the next c/t clock. if the c/t is allowed to end the count before a new character has been received, the counter ready bit, isr[3], will be set. if imr[3] is set, this will generate an interrupt. since receiving a character restarts the c/t , the receipt of a character after the c/t has timed out will clear the counter ready bit, isr[3], and the interrupt. invoking the `set t imeout mode on' command, crx=`ax', will also clear the counter ready bit and stop the counter until the next character is received. the counter timer is controlled with six commands: start/stop c/t , read/w rite counter/t imer lower register and read/w rite counter/t imer upper register . these commands have slight dif ferences depending on the mode of operation. please see the detail of the commands under the ctlr ctur register descriptions. time out mode caution when operating in the special time out mode, it is possible to generate what appears to be a afalse interrupto, i.e., an interrupt without a cause. this may result when a time-out interrupt occurs and then, before the interrupt is serviced, another character is received, i.e., the data stream has started again. (the interrupt latency is longer than the pause in the data strea.) in this case, when a new character has been receiver , the counter/timer will be restarted by the receiver , thereby withdrawing its interrupt. if, at this time, the interrupt service begins for the previously seen interrupt, a read of the isr will show the acounter readyo bit not set. if nothing else is interrupting, this read of the isr will return a x'00 character . receiver and transmitter the quar t has four full-duplex asynchronous receiver/transmitters. the operating frequency for the receiver and transmitter can be selected independently from the baud rate generator , the counter/timer , or from an external input. registers associated with the communications channel are the mode registers (mr0, mr1 and mr2) clock select register (csr), command register (cr), status register (sr), t ransmit fifo (txfifo), and the receive fifo (rxfifo). the transmit and receive fifos are each eight characters deep. the receive fifo also stores three status bits with each character . transmitter the transmitter accepts parallel data from the cpu and converts it to a serial bit stream on the txd output pin. it automatically sends a start bit followed by the programmed number of data bits, an optional parity bit, and the programmed number of stop bits. the least significant bit is sent first. following the transmission of the stop bits, if a new character is not available in the txfifo, the txd output remains high and the txemt bit in the sr will be set to 1. t ransmission resumes and the txemt bit is cleared when the cpu loads a new character in the txfifo. in the 16x clock mode, this also re-synchronizes the internal 1x transmitter clock so that transmission of the new character begins with minimum delay . if the transmitter is disabled it continues operating until the character currently being transmitted and any characters in the txfifo, including parity and stop bits, have been transmitted. new data cannot be loaded to the txfifo when the transmitter is disabled. the transmitter can be forced to send a break (a continuous low condition) by issuing a st ar t break command via the cr register . the break is terminated by a st op break command or a transmitter reset.. txfifo the txfifo empty positions are encoded as a three bit number for presentation to the bidding logic. the coding will equal the number of bytes that remain to be filled. that is, a binary number of 101 will mean five bytes may be loaded; 1 1 1 means 7, etc. eight positions will be indicated by a binary 1 11 and the fifo empty bit will be set. receiver the receiver accepts serial data on the rxd pin, converts the serial input to parallel format, checks for start bit, stop bit, parity bit (if any),
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 8 or break condition, and presents the assembled character to the cpu via the receiver fifo. the receiver operates in two modes: the 1x and 16x. the 16x mode is the more robust of the two. it allows the receiver to establish a phase relation to the remote transmitter clock within 1/16 of a bit time and also allows validation of the start bit. the 1x mode does not validate the start bit and assumes that the receiver clock rising edge is centered in the data bit cell. the use of the 1x mode implies that the transmitter clock is available to the receiver . when operating in the 16x mode and after the receiver has been enabled the receiver state machine will look for a high to low transition on the rxd input. the detection of this transition will cause the divider being driven by the 16x clock to be reset to zero and continue counting. when the counter reaches 7 the rxd input is sampled again and if still low a valid st ar t bit will be detected. if the rxd input is high at count 7 then an invalid start bit will have been sensed and the receiver will then look for another high to low transition and begin validating again. when a valid start bit is detected the receiver state machine allows the 16x divider circuit to continue counting 0 to 15. each time the receiver passes count 7 (the theoretical center of the bit time) another data bit is clocked into the receiver shift register until the proper number of bits have been received including the parity bit, if used, and 1/2 stop bit. after the st op bit is detected the receiver state machine will wait until the next falling edge of the 1x clock and then clock the assembled character and its status bits into the receiver fifo on the next rising edge of the 1x clock. the delay from the detection of the st op bit to the loading of the character to the rxfifo will be from one half to one and one half x1 clock periods, or twice that if x1/2 is used. receiver status register bits for fifo ready , fifo full, parity error , framing error , break detect will also set at this time. the most significant bits for data characters less than eight bits will be set to zero. after the stop bit is detected, the receiver will immediately look for the next start bit. however , if a non-zero character was received without a stop bit (i.e. framing error) and rxd remains low for one-half of the bit period after the stop bit was sampled, then the receiver operates as if a new start bit transition had been detected at that point (one-half bit time after the stop bit was sampled). the parity error , framing error and overrun error (if any) are strobed into the sr at the received character boundary , before the rxrdy status bit is set. if a break condition is detected (rxd is low for the entire character including the stop bit), only one character consisting of all zeros will be loaded in the fifo and the received break bit in the sr is set to 1. the achange of breako bit in the isr at position 2 or 6 is also set at this time. note that the achange of breako bit will set again when the break condition terminates. the rxd input must return to high for two (2) clock edges of the x1 crystal clock for the receiver to recognize the end of the break condition and begin the search for a start bit. this will usually require a high time of one x1 clock period or 3 x1 edges since the clock of the controller is not synchronous to the x1 clock. note: if the rxd input is low when the receiver is enabled and remains low for at least 9/16 of a bit time a valid start bit will be seen and data (probably random) will be clocked into the receiver fifo. if the line remains low for a full character time plus a stop bit then a break will be detected. each receiver is equipped with a watchdog timer . this timer is enabled by mr0[7] and counts 64 rxc1x clocks. its purpose is to alert the controlling cpu that data is in the fifo which has not been read. this situation may occur at the end of a message when the last group of characters was not long enough to cause an interrupt. receiver fifo the rxfifo consists of a first-in-first-out (fifo) with a capacity of eight characters. data is loaded from the receive shift register into the top-most empty position of the fifo. the rxrdy bit in the status register (sr) is set whenever one or more characters are available to be read; a ffull status bit is set if all eight stack positions are filled with data. the number of filled positions is encoded into a 3-bit value. this value is sent to the interrupt bidding logic where it is used to generate an interrupt. a read of the rxfifo, outputs the data at the top of the fifo. after the read cycle, the data fifo and its associated status bits are `popped' thus emptying a fifo position for new data. note: the number of filled positions in the rxfifo is coded as actual number filled positions. seven filled will be coded as 7. eight filled positions will be coded as 7 and the rxfifo full status bit will be set. in addition to the data word, three status bits (parity error , framing error , and received break) are appended to each data character in the fifo. status can be provided in two ways, as programmed by the error mode control bit in the mode register . in the `character ' mode, status is provided on a character-by-character basis: the status applies only to the character at the top of the fifo. in the `block' mode, the status provided in the sr for these three bits is the logical or of the status for all characters coming to the top of the fifo since the last reset error command was issued. in either mode, reading the sr does not af fect the fifo. the fifo is `popped' only when the rxfifo is read. therefore, the sr should be read prior to reading the corresponding data character . if the fifo is full when a new character is received, that character is held in the receive shift register until a fifo position is available. if an additional character is received while this state exists, the contents of the fifo are not af fected: the character previously in the shift register is lost and the overrun error status bit, sr[4], will be set upon receipt of the start bit of the new (overrunning) character . watchdog timer a awatchdogo timer is associated with each receiver . its interrupt is enabled by mr0[7]. the purpose of this timer is alerting the control processor that characters are in the rxfifo which have not been read and/or the datastream has stopped. this situation may occur at the end of a transmission when the last few characters received are not suf ficient to cause an interrupt. this counter times out after 64 bit times. it is reset each time a character is transferred from the receive shift register to the rxfifo or a read of the rxfifo is executed. wake-up mode (mul ti-drop or 9-bit) in addition to the normal transmitter and receiver operation described above, the quar t incorporates a special mode which provides automatic awakeupo of a receiver through address frame (or character) recognition for multi-processor or multi-station communications. this mode is selected by programming mr1[4:3] to `11'. in this mode of operation a `master ' station transmits an address character to the several `slave' stations on the line. the address character is identified by setting its parity bit to 1. the slave stations will usually have their receivers partially enabled as a result of setting mr1[4:3] to 1 1. when the receiver sees a one in the parity position, it considers it an address bit and loads that character to the rxfifo and set the rxrdy bit in the status register . the user would usually set the receiver interrupt to occur on rxrdy as well. (all characters whose parity bits are set to 0 will be ignored). the local processor at the slave station will read the `address' character just received. the local processor will test for an address match for
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 9 this station and if match occurs it will enable the local receiver and receive the following data characters. the master will normally follow an address character(s) with data characters. since the data characters transmitted by the master will have their parity bits set to zero, stations other than the addressed one(s) will ignore the data. note: the time between address and data fields must be enough for the local processor to test the address character and enable the receiver . at bit times approaching 10 m s this may begin to be a point of concern. the parity (address/data) bit should not be changed until the last stop bit of an address has been sent. similarly the a/d bit should not be changed to address until the last stop bit has been sent. either of these conditions will be indicated by an active txemt bit in the sr. the parity bit is not part of the txfifo. it is in the transmitter state machine. however , it could be controlled in the fifo if 5, 6 or 7 bit data was transmitted by using a 6, 7 or 8 bit character . the most significant bit would then be in the `parity' position and represent the a/d bit. the design of the uar t is based, however , on the a/d bit being controlled from the mr register . parity should be changed immediately before the data bytes will be loaded to the transmitter . a transmitted character consists of a start bit, the programmed number of data and stop bits and an aaddress/datao bit. the parity bit is used as the address or data indicator . the polarity of the a/d bit is selected by setting mr1[2] to zero or one; zero indicates that the current byte is data, while one indicates that the current byte is addressed. the desired polarity of the a/d bit (parity) should be programmed before the txfifo is loaded. the receiver should be enabled before the beginning of the first data bit. the time required is dependent on the interrupt latency of the slave receivers. the transmitter is able to start data immediately after the address byte has been sent. while in this mode, the receiver continuously looks at the received data stream, whether it is enabled or disabled. if disabled, it sets the rxrdy status bit and loads the character in the rxfifo if the received a/d bit is a one, but discards the received character if the received a/d bit is a zero. if enabled, all received characters are then transferred to the cpu via the rxfifo. in either case, the data bits are loaded in the data fifo while the a/d bit is loaded in the status fifo position normally used for parity error (sr[5]). framing error , overrun error , and break detect operate normally whether or not the receiver is enabled. input output (i/o) pins there are 16 multi-use pins; four for each uar t . these pins are accessed and controlled via the input port register (ipr), i/o port control register (i/opcr), input port change register (ipcr), and output port register (opr). they may be individually programmed to be inputs or outputs. see t able 5. i/o0x and i/o1x pins have change of state detectors. the change of state detectors sample the input ports every 26.04 m s (with the x1 clock at 3.686400mhz) and set the change bit in the ipcr if the pin has changed since it was last read. whether the pins are programmed as inputs or outputs the change detectors still operate and report changes accordingly . see the register descriptions of the i/o ports for the detailed use of these features. a read of the ipcr resets the i/o cos (change of state) detectors. interrupt priority system the interrupt control for the quar t has been designed to provide very low interrupt service overhead for the controlling processor while maintaining a high degree of flexibility in setting the importance of interrupts generated in dif ferent functional blocks of the device. this is accomplished by allowing each function of the quar t (18 total) which may cause an interrupt to generate a variable numeric code which contains the identity of the source, channel number and severity level. this code is compared (at the x1 clock rate or the x1 clock rate divided by 2) to an interrupt threshold. when the interrupt - ing source generates a code that is numerically greater than the interrupt threshold the irqn is asserted this is referred to as the bidding process. the winning bid contains, in dif ferent fields, all the characteristics of the winning bidder . this data may be used in several ways to steer the controlling processor to the proper type and amount of service required (usually the amount of service refers to the number of bytes written to the trans - mitter or read from the receiver). access to the winning bidder is provided via the cir (current interrupt register), interrupt vectors, modified interrupt vectors and global registers. note: irqn is essentially a level output. it will go active on an interrupt condition and stays active until all interrupting sources are serviced. irqn is designed to be an open drain active low level output. it will go low under the control of the arbitration system and remain low until the arbitration has determined that no more sources require service. when only one rx or tx is interrupting, it is possible to see the irqn assert more than once if, during an access to the fifo, the cen input is inactive for more than two cycles of the x1 clock or x1 divide by 2 if that feature is enabled. iackn may be thought of as a special read input. driving iackn low will update the cir and then read the interrupt v ector register or the interrupt v ector register modified by the cir. functional description of the interrupt arbitration for the purpose of this description, a `source' is any one of the 18 quar t circuits that may generate an interrupt. the quar t contains eighteen sources which may cause an interrupt: 1. four receiver data fifo filled functions. 2. four receiver break detect functions. 3. four transmitter fifo space available functions. 4. four achange of stateo detectors. 5. t wo counter/timers. the interrupt logic at each source produces a numeric code that identifies its interrupt priority condition currently pending. this code is compared to a programmable interrupt threshold via the arbitration logic which determines if the irqn should be asserted. the arbitration logic only judges those possible interrupt sources which have been allowed to bid via the imr (interrupt mask register). the arbitration logic produces a value which is the concatenation of the channel number , interrupt type, fifo fill level and user-defined fields. the channel number and interrupt type fields are hardwired. during the abid arbitrationo process all bids from enabled sources are presented, simultaneously , to an internal interrupt bus. the bidding system and formats are discussed in more detail in following sections. the interrupt arbitration logic insures that the interrupt with the numerically largest bid value will be the only source driving the interrupt bus at the end of the arbitration period. the arbitration
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 10 period follows the period of the x1 clock. the maximum speed is 4.0mhz. if a higher speed x1 clock is used then the x1 clock adivide by 2o feature must be used. the value of the winning bid determined during the arbitration cycle is compared to the ainterrupt thresholdo contained in the icr (interrupt control register). if the winning bid exceeds the value of the icr the irqn is asserted. priority arbitration and bidding each of the five atypeso of interrupts has slightly dif ferent abido value, as follows: receivers transmitters break detect change of state counter/timer # rcv'd rer 1 1 chan # 3 1 1 1 2 0 # avail 1 0 chan # 1 3 1 1 2 programmable 1 0 0 chan # 3 1 1 1 2 programmable 0 0 1 chan # 3 1 1 1 2 programmable 1 0 1 chan # 2 1 1 1 2 0 1 sd00162 bits shown above as `0' or `1' are hard-wired inputs to the arbitration logic. their presence allows determination of the interrupt type and they insure that no bid will have a value of all zeros (a condition that is indistinguishable from not bidding at all). they also serve to set a default priority among the non-receive/transmit types when the programmable fields are all zeros. the channel number always occupies the two lsbs. inclusion of the channel number insures that a bid value generated will be unique and that a single awinnero will drive the interrupt bus at the end of the arbitration interval. the channel number portion of each uart s bid is hard-wired with uar t a being channel number 0 and so forth. as can be seen above, bits 4:2 of the winning bid value can be used to identify the type of interrupt, including whether data was received correctly or not. like the channel number field, these bits are hard-wired for each interrupt source. the a# rcv'do and a# availo fields indicate the number of bytes present in the receiver fifo and the number of empty bytes in the transmitter fifo, respectively . note: when there are zero bytes in the receiver ' s fifo, it does not bid. similarly , a full transmitter fifo makes no bid. in the case where all bids have been disabled by the interrupt mask register or as a result of their byte counts, the active-low interrupt bus will return ffh. this value always indicates no interrupt source is active and irqn will be negated. the high order bit of the transmitter abido is always zero. an empty transmit fifo is, therefore, fixed at a lower interrupt priority than a 1/2 full receive fifo. bit 4 of a receiver bid is the receiver error bit (rer). the rer is the or of the parity , framing and overrun error conditions. the rer does little to modify the priority of receiver interrupts vs. transmitter interrupts. it is output to the interrupt bus to allow inclusion of good data vs. problem data information in the current interrupt register . the high order bits of bids for received break, cos (change of state) and counter/t imer events are all programmable. by programming ones in these fields, the associated interrupt source can be made more significant than most receiver and all transmitter interrupts. v alues near zero in these fields makes them lower priority classes of interrupt. the channel address for c/t ab will be encoded as channel b (01) the channel address for c/t cd will be encoded as channel d (1 1) as shown in figure 4, the bid arbitration process is controlled by the ev al/holdn signal derived from the oscillator clock. receipt of an iackn signal from the host mpu latches the latest awinning bido from the latched interrupt bus into the current interrupt register (cir). this logic is diagrammed in figure 5. if the iackn falling edge of figure 4 occurs during ev al time, the result from the last arbitration (captured by the interrupt bus latches) is stored in cir. otherwise, the next ev al pulse is inhibited and the value in the interrupt bus latches is stored in cir. clearing the interrupt activities which change the state of the isr will cause the irqn to assert or negate. in addition, the accessing of a global or local rxfifo or txfifo reduces the associated byte count for transmitter and receiver data interrupts. if the byte count falls below the threshold value, the interrupt request is withdrawn. other interrupt conditions are cleared when the interrupting source is cleared. once the interrupt is cleared, the programmable value lowered or its byte count value reduced by one of the methods listed above, a dif ferent bidder (or no bidder at all) will win the on-going arbitration. when the winning bid drops below the interrupt threshold register' s value, the irqn pin will negate. arbitration - aftermath at the end of the arbitration, i.e., the falling edge of ev al, the winning interrupt source is driving its channel number , number of bytes (if applicable) and interrupt type onto the interrupt bus. these values are captured into a latch by the trailing edge of ev al. the output of this latch is used by the interrupt threshold comparator; the winning value is captured into another set of latches called the current interrupt register (cir) at the time of an interrupt acknowledge cycle or execution of the aupdate ciro command. the current interrupt register and associated read logic is shown in figure 5. interrupting channel number and the three bit interrupt type code and fifo fill level are readable via the internal data bus. the contents of the appropriate receiver or transmitter byte acountero, as captured at the time of iackn assertion, make up bits 7:5 of the cir. if the interrupt type stored in the current interrupt register is not a receiver or transmitter data transfer type, the cir7:5 field will read as the programmable fields of their respective bid formats. the buf fers driving the cir to the dbus also provide the means of implementing the global interrupting channel and global byte count registers, described in a later section. the winning bid channel number and interrupt type fields can also be used to generate part of the interrupt v ector , as defined by the interrupt control register . interrupt context the channel number of the winning abido is used by the address decoders to provide data from the interrupting uar t channel via a set of global pseudo-registers. the interrupt global pseudo-registers are: 1. global interrupting byte count 2. global interrupting channel 3. global receive holding register
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 11 4. global t ransmit holding register the first two global aregisterso are provided by current interrupt register fields as shown in figure 5. the interrupting channel number latched in cir modifies address decoding so that the receive or t ransmit holding register for the interrupting channel is accessed during i/o involving the global receive and t ransmit holding registers. similarly , for data interrupts from the transmitter and receiver , the number of characters available for transfer to the cpu or the number of transmit fifo positions open is available by reading the global interrupt byte count register . for non-data interrupts, a read of the global interrupt byte count register yields a value equal to the highest programmable filed. in ef fect, once latched by an iack or the update cir command, the winning interrupt channel number determines the contents of the global registers. all global registers will provide data from the interrupting uar t channel. interrupt threshold calculation the state of irqn is determined by comparison of the winning abido value to the interrupt threshold field of the interrupt control register. the logic of the bidding circuit is such that when no interrupt source has a value greater than the interrupt threshold then the interrupt is not asserted and the cir (current interrupt register) is set to all ones. when one or more of the 18 interrupt sources which are enabled via the imr (interrupt mask register) exceed the threshold then the interrupt threshold is ef fectively disconnected from the bidding operation while the 18 sources now bid against each other . the final result is that the highest bidding source will disable all others and its value will be loaded to the cir and the irqn pin asserted low . this all occurs during each cycle of the x1, x2 crystal clock. table 2. receiver fifo interrupt fill level mr0[6] mr1[6] interrupt condition 0 0 1 1 0 1 0 1 1 or more bytes in fifo (rx rdy) default* 3 or more bytes in fifo 6 or more bytes in fifo 8 bytes in fifo (rx full) for the receiver these bits control the number of fifo positions empty when the receiver will attempt to interrupt. after the reset the receiver fifo is empty . the default setting of these bits cause the receiver to attempt to interrupt when it has one or more bytes in it. table 3. receiver fifo interrupt fill level mr0[5] mr0[4] interrupt condition 0 0 1 1 0 1 0 1 8 bytes empty (tx empty) default* 4 or more bytes empty 6 or more bytes empty 1 or more bytes empty (tx rdy) for the transmitter these bits control the number of fifo positions empty when the receiver will attempt to interrupt. after the reset the transmit fifo has 8 bytes empty . it will then attempt to interrupt as soon as the transmitter is enabled. the default setting of the mr0 bits (00) condition the transmitter to attempt to interrupt only when it is competely empty . as soon as one byte is loaded, it is no longer empty and hence will withdraw its interrupt request. interrupt note on 68c94: for the receivers and transmitters, the bidding of any particular unit may be held off unless one of four fifo fill levels is attained. this is done by setting the rxint and txint bits in mr0 and mr1 to non-zero values. this may be used to prevent a receiver or transmitter from generating an interrupt even though it is filed above the bid threshold. although this is not in agreement with the idea that each enabled interrupt source bid with equal authority , it does allow the flexibility of giving particular receiver or transmitters more interrupt importance than others. this may be used when the interrupt threshold is set at or above 100000. note than in this case the transmitter cannot generate an interrupt. if the interrupt threshold msbs were set to 011 and the `receiver interrupt bits' on the mr registers set to a value other than 00 then the rxfifo could not generate and interrupt until it had 4, 6 or 8 bytes. this in effect partially defeats the hardwired characteristic that the receiver interrupts should have more importance than the transmitter . this characteristic has been implemented by setting the msb of the transmitter bid to zero. vectored interrupts the quar t responds to an interrupt acknowledge (iack) initiated by the host by providing an interrupt acknowledge v ector on d7:0. the interrupt acknowledge cycle is terminated with a dackn pulse. the vector provided by the quar t can have one of the three forms under control of the ivc control field (bits 1:0 of the interrupt control register): w ith ivc = 00 (ivr only) ivr7:0 8 w ith ivc = 01 (channel number) ivr7:2 6 chan # 2 w ith ivc = 10 (type & channel number) ivr7:5 3 chan # 2 type 3 sd00163 a code of 1 1 in the interrupt v ector control field of the icr results in no interrupt vector being generated. the external data bus is driven to a high impedance throughout the iack cycle. a dackn will be generated normally for the iack cycle, however . note: if iackn is not being used then the command aupda te ciro must be issued for the global and interrupt registers to be updated. programming uart control registers the operation of the quar t is programmed by writing control words into the appropriate registers. operational feedback is provided via status registers which can be read by the cpu. addressing of the registers is described in t able 1. the bit formats of the quar t registers are depicted in t able 2.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 12 table 4. register bit formats, duart ab. [duplicated for duart cd] bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 bit 0 mr0 (mode register 0) rx watchdog timer rxint2 bit txint control these bits not implemented. they should be considered reserved. 0 = off 1 = on these bits should normally be set to 0 x x x x mr1 (mode register 1) rxrts control rxint1 select error mode * parity mode parity type bits per character 0 = no 1 = yes normally set to 0 0 = char 1 = block 00 = with parity 01 = force parity 10 = no parity 11 = w ake-up mode 0 = even 1 = odd 00 = 5 01 = 6 10 = 7 11 = 8 note: *in block error mode, block error conditions must be cleared by using the error reset command (command 4x) or a receiver reset. mr2 (mode register 2) channel mode txrts control cts  
 stop bit length* 00 = normal 01 = auto-echo 10 = local loop 1 1 = remote loop 0 = no 1 = yes 0 = no 1 = yes 0 = 0.563 4 = 0.813 8 = 1.563 c = 1.813 1 = 0.625 5 = 0.875 9 = 1.625 c = 1.875 2 = 0.688 6 = 0.938 a = 1.688 e = 1.938 3 = 0.750 7 = 1.000 b = 1.750 f = 2.000 note: add 0.5 to values shown above for 07, if channel is programmed for 5 bits/char . in block error mode, block error conditions must be cleared by using the error reset command (command 4x) or a receiver reset. csr (clock select register) receiver clock select t ransmitter clock select see text see text cr (command register) miscellaneous commands disable tx enable tx disable rx enable rx see text 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes note: issuing commands contained in the upper four bits of the acommand registero should be separated in time by at least three (3) x1 clock edges. allow four (4) edges if the ax1 clock divide by 2o mode is used. a disabled transmitter cannot be loaded. sr (status register) rec'd. break framing error parity error overrun error txemt txrdy rxfull rxrdy 0 = no 1 = yes * 0 = no 1 = yes * 0 = no 1 = yes * 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes note: these status bits are appended to the corresponding data character in the receive fifo. a read of the status register provides these bits [7:5] from the top of the fifo together with bits [4:0]. these bits are cleared by a reset error status command. unless reset with the `error reset' (cr command 40) or receiver reset, these bits will remain active in the status register after the rxfifo is empty . acr (auxiliary control register) brg set select counter/timer mode and source delta  delta  delta  delta  0 = set 1 1 = set 2 see text 0 = off 1 = on 0 = off 1 = on 0 = off 1 = on 0 = off 1 = on
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 13 table 4. register bit formats, duart ab. [duplicated for duart cd] (continued) bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 bit 0 isr (interrupt status register) i/o port change delta breakb rxrdy/ ffullb txrdyb counter ready delta breaka rxrdy/ ffulla txrdya 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes imr (interrupt mask register) i/o port change int delta breakb int rxrdy/ ffullb int txrdyb int counter ready int delta breaka int rxrdy/ ffulla int txrdya int 0 = off 1 = on 0 = off 1 = on 0 = off 1 = on 0 = off 1 = on 0 = off 1 = on 0 = off 1 = on 0 = off 1 = on 0 = off 1 = on ctur (counter/t imer upper register) c/t[15] c/t[14] c/t[13] c/t[12] c/t[11] c/t[10] c/t[9] c/t[8] ctur (counter/t imer lower register) c/t[7] c/t[6] c/t[5] c/t[4] c/t[3] c/t[2] c/t[1] c/t[0] ipr (input port register) i/o3b i/o2b i/o3a i/o2a i/o1b i/o0b i/o1a i/o0a 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high mode registers 0, 1 and 2 the addressing of the mode registers is controlled by the mr register pointer . on any access to the mode registers this pointer is always incremented. upon reaching a value of 2 it remains at 2 until changed by a cr command or a hardware reset. mr0 mode register 0 mode register 0 (mr0) is part of the uar t configuration registers. it controls the watch dog timer and the encoding of the number of characters received in the rxfifo. the lower four bits of this register are not implemented in the hardware of the chip. mr0 is normally set to either 80h or 00h . a read of this register will return 111 1 (fh) in the lower four bits. the mr0 register is accessed by setting the mr pointer to zero (0) via the command register command 101 1 (bh). mr0[7]: this bit enables or disables the rxfifo watch dog timer . mr0[7] = 1 enable timer mr0[7] = 0 disable timer mr0[6:4]: these bits are normally set to 0 except as noted in the ainterrupt threshold calculationo description mr0[3:0]: these bits are not implemented in the chip. these bits should be be considered areserved.o mr1 mode register 1 mr1 is accessed when the mr pointer points to mr1. the pointer is set to mr1 by reset , a set pointer command applied via the cr or after an access to mr0. after reading or writing mr1, the pointers are set at mr2. mr1[7] receiver request-to-send flow control this bit controls the deactivation of the r tsn output (i/o2x) by the receiver . this output is manually asserted and negated by commands applied via the command register . mr1[7] = 1 causes r tsn to be automatically negated upon receipt of a valid start bit if the receiver fifo is full. r tsn is re-asserted when an empty fifo position is available. this feature can be used to prevent overrun in the receiver by using the r tsn output signal to control the cts input (the quar t i/o0 pin) of the transmitting device. use of this feature requires the i/o2 pin to be programmed as output via the i/opcr and to be driving a 0 via the opr. when the rxfifo is full and the start bit of the ninth character is sensed the receiver logic will drive the i/o2 pin high. this pin will return low when another rxfifo position is vacant. mr1[6] receiver interrupt select 1 this bit is normally set to 0 except as noted in the ainterrupt threshold calculationo description. mr1[6] operates with mr0[6] to prevent the receiver from bidding until a particular fill level is attained. for software compatibility this bit is designed to emulate the rxfifo interrupt function of previous philips semiconductors uarts. mr1[5] error mode select this bit selects the operating mode of the three fifoed status bits (received break, fe, pe). in the character mode, status is provided on a character-by-character basis; the status applies only to the character at the top of the fifo. in the block mode, the status provided in the sr for these bits is the accumulation (logical-or) of the status for all characters coming to the top of the fifo since the last reset error command was issued.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 14 in the ablock erroro mode the oring of the error status bits and the presentation of them to the status register takes place as the bytes enter the rxfifo. this allows an indication of problem data when the error occurs after the leading bytes have been received. in the character mode the error bits are presented to the status register when the corresponding byte is at the top of the fifo. mr1[4:3] parity mode select if awith parityo or aforce parityo is selected, a parity bit is added to the transmitted character and the receiver performs a parity check on incoming data. mr1[4:3] = 1 1 selects the channel to operate in the special wake-up mode (see `w ake-up mode'). mr1[2] parity t ype select this bit selects the parity type (odd or even) if the awith parityo mode is programmed by mr1[4:3], and the polarity of the forced parity bit if the aforce parityo mode is programmed. it has no ef fect if the ano parityo mode is programmed. in the special awake-upo mode, it selects the polarity of the transmitted a/d bit. mr1[1:0] bits per character select this field selects the number of data bits per character to be transmitted and received. the character length does not include the start, parity , and stop bits. mr2 mode register 2 mr2 is accessed when the channel mr pointer points to mr2, which occurs after any access to mr1. accesses to mr2 do not change the pointer . mr2[7:6] mode select the quar t can operate in one of four modes. mr2[7:6] = 00 is the normal mode, with the transmitter and receiver operating independently . mr2[7:6] = 01 places the channel in the automatic echo mode, which automatically retransmits the received data. the following conditions are true while in automatic echo mode: 1. received data is re-clocked and retransmitted on the txd output. 2. the receive clock is used for the transmitter . 3. the receiver must be enabled, but the transmitter need not be enabled. 4. the txrdy and txemt status bits are inactive. 5. the received parity is checked, but is not regenerated for transmission, i.e., transmitted parity bit is as received. t wo diagnostic modes can also be selected. mr2[7:6] = 10 selects local loopback mode. in this mode: 1. the transmitter output is internally connected to the receiver input. 2. the transmit clock is used for the receiver . 3. the txd output is held high. 4. the rxd input is ignored. 5. the transmitter must be enabled, but the receiver need not be enabled. 6. cpu to transmitter and receiver communications continue normally. the second diagnostic mode is the remote loopback mode, selected by mr2[7:6] = 1 1. in this mode: 1. received data is re-clocked and retransmitted on the txd output. 2. the receive clock is used for the transmitter . 3. received data is not sent to the local cpu, and the error status conditions are inactive. 4. the received parity is not checked and is not regenerated for transmission, i.e., the transmitted parity bit is as received. 5. the receiver must be enabled, but the transmitter need not be enabled. 6. character framing is not checked, and the stop bits are retransmitted as received. 7. a received break is echoed as received until the next valid start bit is detected. the user must exercise care when switching into and out of the various modes. the selected mode will be activated immediately upon mode selection, even if this occurs in the middle of a received or transmitted character . likewise, if a mode is deselected, the device will switch out of the mode immediately . an exception to this is switching out of autoecho or remote loopback modes; if the deselection occurs just after the receiver has sampled the stop bit (indicated in autoecho by assertion of rxrdy), and the transmitter is enabled, the transmitter will remain in autoecho mode until the entire stop bit has been retransmitted. mr2[5] t ransmitter request-to-send control note: when the transmitter controls the i/o2 pin (usually used for the rtsn signal) the meaning of the pin is not rtsn at all! rather it signals that the transmitter has finished transmission. (i.e., end of block). this bit controls the deactivation of the r tsn output (i/o2) by the transmitter . this output is manually asserted and negated by appropriate commands issued via the command register . mr2[5] = 1 causes r tsn to be reset automatically one bit time after the characters in the transmit shift register and in the txfifo (if any) are completely transmitted (includes the programmed number of stop bits if the transmitter is not enabled). this feature can be used to automatically terminate the transmission as follows: 1. program auto-reset mode: mr2[5] = 1. 2. enable transmitter . 3. assert r tsn via command. 4. send message. 5. disable the transmitter after the last byte of the message is loaded to the txfifo. at the time the disable command is issued, be sure that the transmitter ready bit is on and the transmitter empty bit is of f. if the transmitter empty bit is on (the indication of transmitter underrun) when the disable is issued, the last byte(s) will not be sent. 6. the last character will be transmitted and r tsn will be reset one bit time after the last stop bit. mr2[4] t ransmitter clear-to-send flow control the sate of this bit determines if the ctsn input (i/o0) controls the operation of the transmitter . if this bit is 0, ctsn has no ef fect on the transmitter . if this bit is a 1, the transmitter checks the sate of ctsn each time it is ready to send a character . if it is asserted (low), the character is transmitted. if it is negated (high), the txd output remains in the marking state and the transmission is delayed until ctsn goes low . changes in ctsn, while a character is being transmitted do not af fect the transmission of that character . this feature can be used to prevent overrun of a remote receiver . mr2[3:0] stop bit length select this field programs the length of the stop bit appended to the transmitted character . stop bit lengths of 9/16 to 1 and 19/16 to 2 bits, in increments of 1/16 bit, can be programmed for character lengths of 6, 7, and 8 bits. for a character length of 5 bits, 11/16 to 2 stop bits can be programmed in increments of 1/16 bit. if an external 1x clock is used for the transmitter , mr2[3] = 0 selects one stop bit and mr2[3] = 1 selects two stop bits to be transmitted. receiver note: in all cases, the receiver only checks for a amarko condition at the center of the stop bit (1/2 to 9/16 bit time into the stop bit position). at this time the receiver has
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 15 finished processing the present character and is ready to search for the start bit of the next character . table 5. bit rate generator characteristics crystal or clock = 3.6864mhz normal rate (baud) actual 16x clock (khz) error (%) 50 75 110 134.5 150 200 300 600 1050 1200 1800 2000 2400 4800 7200 9600 19.2k 38.4k 0.8 1.2 1.759 2.153 2.4 3.2 4.8 9.6 16.756 19.2 28.8 32.056 38.4 76.8 115.2 153.6 307.2 614.4 0 0 -0.069 0.059 0 0 0 0 -0.260 0 0 0.175 0 0 0 0 0 0 note: duty cycle of 16x clock is 50% 1%. cr command register cr is used to write commands to the quar t. cr[7:4] miscellaneous commands issuing commands contained in the upper four bits of the acommand registero should be separated in time by at least three (3) x1 clock edges. allow four (4) edges if the ax1 clock divide by 2o mode is used. the encoded value of this field can be used to specify a single command as follows: 0000 no command. 0001 reset mr pointer . causes the mr pointer to point to mr1. 0010 reset receiver . resets the receiver as if a hardware reset had been applied. the receiver is disabled and the fifo pointer is reset to the first location. 0011 reset transmitter . resets the transmitter as if a hardware reset had been applied. 0100 reset error status. clears the received break, parity error , framing error , and overrun error bits in the status register (sr[7:4]}. used in character mode to clear oe status (although rb, pe, and fe bits will also be cleared), and in block mode to clear all error status after a block of data has been received. 0101 reset break change interrupt. causes the break detect change bit in the interrupt status register (isr[2 or 6]) to be cleared to zero. 0110 start break. forces the txd output low (spacing). if the transmitter is empty , the start of the break condition will be delayed up to two bit times. if the transmitter is active, the break begins when transmission of the character is completed. if a character is in the txfifo, the start of break is delayed until that character or any others loaded after it have been transmitted (txemt must be true before break begins). the transmitter must be enabled to start a break 0111 stop break. the txd line will go high (marking) within two bit times. txd will remain high for one bit time before the next character , if any , is transmitted. 1000 assert r tsn. causes the r tsn output to be asserted (low). 1001 negate r tsn. causes the r tsn output to be negated (high). 1010 set t imeout mode on. the register in this channel will restart the c/t as each receive character is transferred from the shift register to the rxfifo. the c/t is placed in the counter mode, the st art/st op counter commands are disabled, the counter is stopped, and the counter ready bit, isr[3], is reset. only one receiver should use this mode at a time. however , if both are on, the timeout occurs after both receivers have been inactive for the timeout. the start of the c/t will be on the logical `or' of the two receivers. 1011 set mr pointer to 0. 1100 disable t imeout mode. this command returns control of the c/t to the regular st art/st op counter commands. it does not stop the counter , or clear any pending interrupts. after disabling the timeout mode, a `stop counter ' command should be issued. 1101 reserved. 111x reserved for testing. csr clock select register csr[7:4] receiver clock select when using a 3.6864mhz crystal or external clock input, this field selects the baud rate clock for the receiver as shown in t able 3. the receiver clock is always a 16x clock, except for csr[7:4] = 111 1. i/o2x is external input. csr[3:0] t ransmitter clock select this field selects the baud rate clock for the transmitter . the field definition is as shown in t able 3, except as follows: csr[3:0] acr[7] = 0 acr[7] = 1 1 1 1 0 i/o3x 16x i/o3x 16x 1 1 1 1 i/o3x 1x i/o3x 1x cr[3] disable t ransmitter this command terminates transmitter operation and resets the txrdy and txemt status bits. however , if a character is being transmitted or if a character is in the txfifo when the transmitter is disabled, the transmission of the character(s) is completed before assuming the inactive state. while the transmitter is disabled (or a disable is pending), the txfifo may not be loaded. cr[2] enable t ransmitter enables operation of the transmitter . the txrdy and txemt status bits will be asserted. cr[1] disable receiver this command terminates operation of the receiver immediately a character being received will be lost. however any unread characters in the rxfifo area are still available. disable is not the same as a areceiver reseto. with a receiver reset any characters not read are lost. the command has no ef fect on the receiver status bits or any other control registers. if the special wakeup mode is programmed, the receiver operates even if it is disabled (see w ake-up mode). cr[0] enable receiver enables operation of the receiver . if not in the special wake-up mode, this also forces the receiver into the search for start bit state.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 16 table 6. baud rate brg rate = low brg rate = high test 1 = 1 csr[7:4] acr[7] = 0 acr[7] = 1 acr[7] = 0 acr[7] = 1 acr[7] = 0 acr[7] = 1 0 0 0 0 0 0 0 1 0 0 1 0 0 0 1 1 0 1 0 0 0 1 0 1 0 1 1 0 0 1 1 1 1 0 0 0 1 0 0 1 1 0 1 0 1 0 1 1 1 1 0 0 1 1 0 1 1 1 1 0 1 1 1 1 50 110 134.5 200 300 600 1,200 1,050 2,400 4,800 7,200 9,600 38.4k timer i/o2 16x i/o2 1x 75 110 38.4k 150 300 600 1,200 2,000 2,400 4,800 1,800 9,600 19.2k timer i/o2 16x i/o2 1x 300 110 134.5 1200 1800 3,600 7,200 1,050 14.4k 28.8k 7,200 57.6k 230.4k timer i/o2 16x i/o2 1x 450 110 134.5 900 1,800 3,600 7,200 2,000 14.4k 28.8k 1,800 57.6k 115.2k timer i/o2 16x i/o2 1x 4,800 880 1,076 19.2k 28.8k 57.6k 115.2k 1,050 57.6k 4,800 57.6k 9,600 38.4k timer i/o2 16x i/o2 1x 7,200 880 1,076 14.4k 28.8k 57.6k 115.2k 2,000 57.6k 4,800 14.4k 9,600 19.2k timer i/o2 16x i/o2 1x sr channel status register sr[7] received break this bit indicates that an all zero character of the programmed length has been received without a stop bit. only a single fifo position is occupied when a break is received; further entries to the fifo are inhibited until the rxda line returns to the marking state for at least one-half bit time two successive edges of the internal or external 1x clock. this will usually require a high time of one x1 clock period or 3 x1 edges since the clock of the controller is not synchronous to the x1 clock. when this bit is set, the change in break bit in the isr (isr[6 or 2]) is set. isr[6 or 2] is also set when the end of the break condition, as defined above, is detected. the break detect circuitry is capable of detecting breaks that originate in the middle of a received character . however , if a break begins in the middle of a character , it must last until the end of the next character in order for it to be detected. sr[6] framing error (fe) this bit, when set, indicates that a stop bit was not detected when the corresponding data character in the fifo was received. the stop bit check is made in the middle of the first stop bit position. sr[5] parity error (pe) this bit is set when the `with parity' or `force parity' mode is programmed and the corresponding character in the fifo was received with incorrect parity . in `wake-up mode', the parity error bit stores the received a/d (address/data) bit. in the wake-up mode this bit follows the polarity of the a/d parity bit as it is received. a parity of 1 would normally mean address and therefore, the end of a data block. sr[4] overrun error (oe) this bit, when set, indicates that one or more characters in the received data stream have been lost. it is set upon receipt of a new character when the fifo is full and a character is already in the receive shift register waiting for an empty fifo position. when this occurs, the character in the receive shift register (and its break detect, parity error and framing error status, if any) is lost. this bit is cleared by a reset error status command. sra[3] channel a t ransmitter empty (txemt a) this bit will be set when the transmitter underruns, i.e., both the txemt and txrdy bits are set. this bit and txrdy are set when the transmitter is first enabled and at any time it is re-enabled after either (a) reset, or (b) the transmitter has assumed the disabled state. it is always set after transmission of the last stop bit of a character if no character is in the thr awaiting transmission. it is reset when the thr is loaded by the cpu, a pending transmitter disable is executed, the transmitter is reset, or the transmitter is disabled while in the underrun condition. sr[2] t ransmitter ready (txrdy) this bit, when set, indicates that the txfifo has at least one empty location that may be loaded by the cpu. it sets when the transmitter is first enabled. it is cleared when the txfifo is full (eight bytes); the transmitter is reset; a pending transmitter disable is executed; the transmitter is disabled when it is in the underrun condition. when this bit is not set characters written to the txfifo will not be loaded or transmitted; they are lost. sr[1] rxfifo full (ffull) this bit is set when a character is transferred from the receive shift register to the receive fifo and the transfer causes the fifo to become full, i.e., all eight fifo positions are occupied. it is reset when the cpu reads the fifo and there is no character in the receive shift register . if a character is waiting in the receive shift register because the fifo is full, ffull is not reset after reading the fifo once. sr[0] rxfifo ready (rxrdy) this bit indicates that a character has been received and is waiting in the fifo to be read by the cpu. it is set when the character is transferred from the receive shift register to the fifo and reset when the cpu reads the rxfifo, and no more characters are in the fifo. acr auxiliary control register acr[7] baud rate generator set select this bit selects between two sets of baud rates that are available within each baud rate group generated by the brg. see t able 3. set 1: 50, 1 10, 134.5, 200, 300, 600, 1.05k, 1.2k, 2.4k, 4.8k, 7.2k, 9.6k, and 38.4k baud. set 2: 75, 1 10, 150, 300, 600, 1.2k, 1.8k, 2.0k, 2.4k, 4.8k, 9.6k, 19.2k, and 38.4k baud.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 17 the selected set of rates is available for use by the receiver and transmitter. acr[6:4] counter/t imer mode and clock source select this field selects the operating mode of the counter/timer and its clock source (see t able 4). the i/o pins available for counter/timer clock source is i/o1a and i/o1c. the counter/timer clock selection is connected to the i/o1 pin and will accept the signal on this pin regardless of how it is programmed by the i/opcr. table 7. acr[6:4] c/t clock and mode select [6:4] mode clock source 0 0 0 counter i/o1 pin 0 0 1 counter i/o1 pin divided by 16 0 1 0 counter txc1xa clock of the transmitter 0 1 1 counter txc1xb clock of the transmitter 1 0 0 timer i/o1 pin 1 0 1 timer i/o1 pin divided by 16 1 1 0 timer crystal or external clock (x1/clk) 1 1 1 timer crystal or external clock (x1/clk) divided by 16 the timer mode generates a squarewave acr[3:0] i/o1b, i/o0b, i/o1a, i/o0a change-of-state interrupt enable this field selects which bits of the input port change register (ipcr) cause the input change bit in the interrupt status register , isr[7], to be set and thus allow the change of state detectors to enter the bidding process. if a bit is in the `on' state, the setting of the corresponding bit in the ipcr will also result in the setting of isr[7], which may result in the generation of an interrupt output if imr[7] = 1. if a bit is in the `of f ' state, the setting of that bit in the ipcr has no ef fect on isr[7]. ipcr input port change register ipcr[7:4] i/o1b, i/o0b, i/o1a, i/o0a change-of-state detectors these bits are set when a change of state, as defined in the input port section of this data sheet, occurs at the respective pins. they are cleared when the ipcr is read by the cpu. a read of the ipcr also clears isr[7], the input change bit in the interrupt status register . the setting of these bits can be programmed to generate an interrupt to the cpu. ipcr[3:0] i/o1b, i/o0b, i/o1a, i/o0a state of i/o pins these bits provide the current state of the respective inputs. the information is unlatched and reflects the state of the input pins during the time the ipcr is read. the ipr is an unlatched register . data can change during a read. isr interrupt status register important: the setting of these bits and those of the imr are essential to the interrupt bidding process. this register provides the status of all potential interrupt sources. the contents of this register are masked by the interrupt mask register (imr). if a bit in the isr is a `1' and the corresponding bit in the imr is also a `1', then the interrupt source represented by this bit is allowed to enter the interrupt arbitration process. it will generate an interrupt (the assertion of intrn low) only if its bid exceeds the interrupt threshold value. if the corresponding bit in the imr is a zero, the state of the bit in the isr has no ef fect on the intrn output. note that the imr does not mask the reading of the isr; the complete status is provided regardless of the contents of the imr. isr[7] i/o change-of-state this bit is set when a change-of-state occurs at the i/o1b, i/o0b, i/o1a, i/o0a input pins. it is reset when the cpu reads the ipcr. isr[6] channel b change in break this bit, when set, indicates that the receiver has detected the beginning or the end of a received break. it is reset when the cpu issues a reset break change interrupt command. isr[5] receiver ready or fifo full channel b normally the isr[5] bit being set to one indicates the rxfifo is filled with one or more bytes and/or the receiver watch dog timer (when enabled) has timed out. the meaning of isr[5] is controlled by the mr0[6] and mr1[6] bits which are normally set to 00. the isr[5] bit setting to one allows the receiver to present its bid to the arbitration logic. this function is explained in the ainterrupt note on 68c94o and under the areceiver interrupt fill levelo. isr[5], if set, will reset when the rxfifo is read. if the reading of the fifo does not reduce the fill level below that determined by the mr bits, then isr[5] sets again within two x1 clock times. further , if the mr fill level is set at 8 bytes and there is a byte in the receiver shift register waiting for an empty fifo location, then a read of the rxfifo will cause isr[5] to reset. it will immediately set again upon the transfer of the character in the shift register to the fifo. note: the setting of isr[5] means that the receiver has entered the bidding process. it is necessary for this bit to set for the receiver to generate an interrupt. it does not mean it is generating an interrupt. isr[4] t ransmitter ready channel b the function of this bit is programmed by mr0[5:4] (normally set to 00). this bit is set when ever the number of empty txfifo positions exceeds or equals the level programmed in the mr0 register . this condition will almost always exist when the transmitter is first enabled. it will reset when the empty txfifo positions are reduced to a level less than that programmed in mr0[5:4] or the transmitter is disabled or reset. the isr[4] bit will reset with each write to the txfifo. if the write to the fifo does not bring the fifo above the fill level determined by the mr bits, the isr[4] bit will set again within two x1 clock times. note: the setting of isr[4] means that the transmitter has entered the bidding process. it is necessary for this bit to set for the transmitter to generate an interrupt. it does not mean it is generating an interrupt. isr[3] counter ready in the counter mode of operation, this bit is set when the counter reaches terminal count and is reset when the counter is stopped by a stop counter command. it is initialized to `0' when the chip is reset. in the timer mode, this bit is set once each cycle of the generated square wave (every other time the c/t reaches zero count). the bit is reset by a stop counter command. the command, however , does not stop the c/t . isr[2] channel a change in break this bit, when set, indicates that the receiver has detected the beginning or the end of a received break. it is reset when the cpu issues a reset break change interrupt command.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 18 isr[1] receiver ready or fifo full channel a see the description of isr[5]. the channel `a' receiver operation is the same as channel `b'. isr[0] t ransmitter ready channel a see the description of isr[4]. channel aao transmitter operates in the same manner as channel ab.o imr interrupt mask register the programming of this register selects which interrupt sources will be allowed to enter the interrupt arbitration process. this register is logically anded with the interrupt status register . its function is to allow the interrupt source it represents to join the bidding process if the corresponding imr and isr bits are both 1. it has no ef fect on the value in the isr. it does not mask the reading of the isr. ctur and ctlr counter/t imer registers the ctur and ctlr hold the eight msbs and eight lsbs, respectively , of the value to be used by the counter/timer in either the counter or timer modes of operation. the minimum value which may be loaded into the ctur/ctlr registers is h`0002'. note that these registers are write-only and cannot be read by the cpu. in the timer (programmable divider) mode, the c/t generates a square wave with a period of twice the value (in clock periods) of the ctur and ctlr. if the value in ctur or ctlr is changed, the current half-period will not be af fected, but subsequent half-periods will be. the c/t will not be running until it receives an initial `start counter ' command (read address at a5a0 0eh for c/t ab or read address 1eh for c/t cd ). after this, while in timer mode, the c/t will run continuously . receipt of a subsequent start counter command causes the c/t to terminate the current timing cycle and to begin a new cycle using the values in the ctur and ctlr. the counter ready status bit (isr[3]) is set once each cycle of the square wave. the bit is reset by a astop countero command (read address at a5a0 0fh for c/t ab or read address 1fh for c/t cd). the command, however , does not stop the c/t . it only resets the isr[3] bit; the c/t continues to run. the isr[3] bit will set again as the counter passes through 0. the generated square wave is output on an i/o pin if it is programmed to be the c/t output. in the counter mode, the c/t counts down the number of pulses loaded in ctur and ctlr by the cpu. counting begins upon receipt of a start counter command. upon reaching the terminal count h`0000', the counter ready interrupt bit (isr[3]) is set. the counter rolls over to 65535 and continues counting until stopped by the cpu. if i/o is programmed to be the output of the c/t , the output remains high until the terminal count is reached, at which time it goes low . the output returns to the high state and isr[3] is cleared when the counter is stopped by a stop counter command. the cpu may change the values of ctur and ctlr at any time, but the new count becomes ef fective only on the next start counter command. if new values have not been loaded, the previous values are preserved and used for the next count cycle. in the counter mode, the current value of the upper and lower eight bits of the counter (ctu, ctl) may be read by the cpu. it is recommended that the counter be stopped when reading to prevent potential problems which may occur if a carry from the lower eight bits to the upper eight bits occurs between the times that both halves of the counter is read. however , note that a subsequent start counter command will cause the counter to begin a new count cycle using the values in ctur and ctlr. i/o logic the quar t has four i/o pins for each channel. these pins may be individually programmed as an input or output under control of the i/opcr (i/o port control register). functions which may use the i/o pins as inputs (rx or tx external clock, for example) are always sensitive to the signal on the i/o pin regardless of it being programmed as an input or an output. for example if i/o1a was programmed to output the rxc1x clock and the counter/t imer was programmed to use i/o pin as its clock input the result would be the counter/t imer being clocked by the rxc1x clock. the 16 i/o ports are accessed and/or controlled by five (5) registers: ipr, acr, i/opcr, ipcr, opr. they are shown in t able 8 of this document. each uar t has four pins. t wo of these pins have achange of state detectorso (cos). these detectors set whenever the pin to which they are attached changes state. (1 to 0 or 0 to 1) the achange of state detectorso are enabled via the acr. when enabled the cos devices may generate interrupts via the imr and ipcr registers. note that when the cos interrupt is enabled that any one or more of the four cos bits in the ipcr will enable the cos bidding. each of the channel' s four i/o lines are configured as inputs on reset. the change of state detectors sample the i/o pins at the rate of the 38.4khz clock. a change on the pin will be required to be stable for at least 26.04 m s and as much as 52.08 m s for the cos detectors to confirm a change. note that changes in the x1/clock frequency will ef fect this stability requirement. cos detectors are reset by a read of the ipcr.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 19 table 8. register bit formats, i/o section bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 bit 0 ipcr (input port change register ab) the lower four bits replicate the lower four bits of the ipr. the upper four bits reads state of change detectors. change detectors are enabled in acr[3:0]. (duart ab) deltai/o1b delta i/o0b delta i/o1a delta i/o0a i/o1b i/o0b i/o1a i/o0a 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high ipcr (input port change register cd) the lower four bits replicate the lower four bits of the ipr. the upper four bits reads state of change detectors. change detectors are enabled in acr[3:0]. (duart cd) delta i/o1d delta i/o0d delta i/o1c delta i/o0c i/o1d i/o0d i/o1c i/o0c 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = no 1 = yes 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high i/opcr (i/o port configuration register) one register for each uart . i/o3x control i/o2x control i/o1x control i/o0x control t wo bits for each i/o pin. this register controls the configuration of the i/o ports. it defines them as inputs or outputs and controls what sources will drive them in the case of outputs or which functions they will drive when used as an input. each pin has four functions and hence two bits to control it. each uar t has one eight bit register to control its four i/o ports. opr (output port register cd) for duart cd i/o3d i/o2d i/o3c i/o2c i/o1d i/o0d i/o1c i/o0c one bit for each pin. when i/o pins are configured as ageneral purpose outputso the pins will be driven to the complement value of its associated opr bit. opr (output port register ab) for duart ab i/o3b i/o2b i/o3a i/o2a i/o1b i/o0b i/o1a i/o0a one bit for each pin. when i/o pins are configured as ageneral purpose outputso the pins will be driven to the complement value of its associated opr bit. this register contains the data for the i/o ports when they are used as 'general purpose outputs' . the bits of the register are controlled by writing to the hex addresses at 0c and 1c. ones written to the opr drive the pins to 0; zeros drive the pins to 1. (the pins drive the value of the complement data written to the opr) ipr (input port register cd) reads i/o pins for duart cd i/o3d i/o2d i/o3c i/o2c i/o1d i/o0d i/o1c i/o0c 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high ipr (input port register ab) reads i/o pins for duart ab i/o3b i/o2b i/o3a i/o2a i/o1b i/o0b i/o1a i/o0a 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high 0 = low 1 = high this register reads the state of the 'i/o ports'. the state of the i/o ports is read regardless of being programmed as inputs or outputs. the ipr can be thought of a just another 8 bit parallel port to the system data bus. the lower four bits of this register are replicated in the lower four bits of the ipcr register . i/o port control channel a (iopcra) iopcr[xx] pin control bits iopcra[7:6] iopcra[5:4] iopcra[3:2] iopcra[1:0] iopcr[xx] pin control bits i/o3a i/o2a i/o1a i/o0a 00 = input ipr(5), txc in ipr(4), rxc in ipr(1), c/t ab clk in no tag txc in ipr(0), ctsn 01 = output oprab(5) oprab(4) rtsn no tag if iopcr[5:4] = 01 oprab(1) rtsn no tag if iopcr[5:4] 01 oprab(0)
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 20 10 = output txc 16x rxc 1x rxc 16x txc 1x 1 1 = output txc 1x rxc 16x rxc 1x txc 16x i/o port control channel b (iopcrb) iopcr[xx] pin control bits iopcrb[7:6] iopcrb[5:4] iopcrb[3:2] iopcrb[1:0] iopcr[xx] pin control bits i/o3b i/o2b i/o1b i/o0b 00 = input ipr(7), txc in ipr(6), rxc in ipr(3), txc in ipr(2), ctsn 01 = output oprab(7) oprab(6) rtsn no tag if iopcr[5:4] = 01 oprab(3) rtsn no tag if iopcr[5:4] 01 oprab(2) 10 = output txc 16x rxc 1x c/t ab out txc 1x 1 1 = output txc 1x rxc 16x rxc 1x txc 16x i/o port control channel c (iopcrc) iopcr[xx] pin control bits iopcrc[7:6] iopcrc[5:4] iopcrc[3:2] iopcrc[1:0] iopcr[xx] pin control bits i/o3c i/o2c i/o1c i/o0c 00 = input ipr(5), txc in ipr(4), rxc in ipr(1), c/t cd clk in no tag txc in ipr(0), ctsn 01 = output oprcd(5) oprcd(4) rtsn no tag if iopcr[5:4] = 01 oprab(1) rtsn no tag if iopcr[5:4] 01 oprcd(0) 10 = output txc 16x rxc 1x rxc 16x txc 1x 1 1 = output txc 1x rxc 16x rxc 1x txc 16x i/o port control channel d (iopcrd) iopcr[xx] pin control bits iopcrd[7:6] iopcrd[5:4] iopcrd[3:2] iopcrd[1:0] iopcr[xx] pin control bits i/o3d i/o2d i/o1d i/o0d 00 = input ipr(7), txc in ipr(6), rxc in ipr(3), txc in ipr(2), ctsn 01 = output oprcd(7) oprcd(6) rtsn no tag if iopcr[5:4] = 01 oprcd(3) rtsn no tag if iopcr[5:4] 01 oprcd(2) 10 = output txc 16x rxc 1x c/t cd out txc 1x 1 1 = output txc 1x rxc 16x rxc 1x txc 16x the input part of the i/o pins is always active. the programming of the iopcr bits to 00 merely turns off the out drivers and places the pin at high impedance. a read of the ipr register returns the value of the ipr bits as shown above. ipr(5) is at bit position 5 of the data bus. note that the ipr bit positions do not follow the 0, 1, 2, 3 order of the i/o ports. during a read of the ipr the i/o ports are not latched. therefore, it is possible to see changing data during the read. port pins that have clocks on them may not yield valid data during the read. since the input circuits of the i/o ports are always active it is possible to direct the port signal back into the port. for example: i/o1 will output the r ts signal. setting the counter/t imer (c/t) to be clocked by the i/o1 port will result in the counter counting the number of times r ts goes active. the change of state detectors on i/o0 and i/o1 will, when programmed, always be sensitive to the signal on the port regardless of the source of that port' s signal. notes: 1. normal configurations place r tsn output on i/o1 and place tx external clock input on i/o3. for the 48 pin dual in-line package, i/o3 is not available. the following options allow flexible i/o programming with the 48 pin package: when iopcr(7:6), the i/o3 control, 00, then i/o1 becomes available to the transmitter as an external clock. when iopcr(5:4), the i/o2 control, = 01, then i/o2 may be the r tsn signal if mr1(7) = 1 and opr(4) = 1. 2. i/o1 becomes r tsn when iopcr(3:2) = 01 and mr1(7) = 1 and opr(1) = 1. (opr(3) for channel b) registers of the interrupt system the cir, and aglobalo registers are updated with the iackn signal or from the aupdate ciro command at hex address 2a. these registers are not updated when irqn is asserted since there could be a long time between the assertion of irqn and the start of the interrupt service routine. (see notes following this section). current interrupt register (cir) # bytes type chan # 3 3 2
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 21 the channel # field indicates which of the four uar ts has the highest priority interrupt currently outstanding, while the t ype field indicates its source within the uar t. the t ype field is encoded as follows: 000 no interrupt 001 change of state x10 t ransmit available 011 receive available, no error 100 receiver break change 101 counter/timer 111 receive available, w/errors with t ype = x1 1, the # bytes field indicates the count of received bytes available for reading, while with t ype = x10 it indicates the number of bytes that can be written to the transmit fifo. the cir is read only at address 28h. global interrupt byte count (gibc) 00000 # bytes 5 3 the gibc is not an actual register but simply outputs the interrupting uart' s transmit or receive byte counter value. the count, accurate at the time iackn asserts, is captured in the cir. the high order 5 bits are read as `0'. the gibc is read only at address 2ah. global rxfifo (grxfifo) received data 8 like the gibc, no physical register implementation exists. the correct receiver ' s fifo is popped based on the value of the interrupting channel field of the current interrupt register . if a receiver is not the cause of the current interrupt, a read of the global rxfifo will yield a byte containing all ones and none of the uar t channels' receive fifos will be popped. (impor tant) the grxfifo is read only at address 2bh. global txfifo (gtxfifo) data to be sent 8 similar to the grxfifo, no physical register implementation exists. the byte is pushed into the correct transmitter ' s fifo based on the interrupting channel field of the current interrupt register . if a transmitter is not the cause of the current interrupt, a write to the global txfifo has no ef fect. the gtxfifo is w rite only at address 2bh. global interrupting channel (gicr) 000000 chan # 6 2 like the other global pseudo-registers no hardware register exists. the channel number field of the current interrupt register padded with leading zeros is output as the gicr. the gicr is read only at address 29h. c/t ab indicated by channel code b 01 c/t cd indicated by channel code d 1 1 interrupt control (icr) threshold ivc 6 2 the threshold field is used by the interrupt comparator to determine if a winning interrupt abido should result in interrupting the host mpu. the threshold field resets to 00. the ivc field controls what kind of vector the quar t returns to the host mpu during an interrupt acknowledge cycle: 00 output contents of interrupt v ector register 01 output 6 msbs of ivr and channel number as 2 lsbs 10 output 3 msbs of ivr, interrupt t ype and channel number 11 disable generation of vector during iack cycle. returns hex'ff during an iackn cycle. the ivc field reset to 00. the icr is read/write at address 2ch. bidding control registers (bcrs) received break state change c/t 3 3 2 this register is a transparent latch. it must be set to ensure the expected operation of the arbitration system. the 3 msbs determine the priority of received break interrupts; they are reset to 000. bits 4:2 determine the priority of change of input state interrupts, and are reset to 00. there is one bcr per uar t channel; they can be read or written at addresses 20-23h. bcr counter/t imer bits reset to 00. interrupt v ector (ivr) the 8 bits of the interrupt vector interrupt v ector (ivr-modified) always used with ivc = 0x w/ivc = 01 or 10 3 3 2 holds the constant bits of the interrupt acknowledge vector . as shown, the three msbs are always used, while the less significant bits can be replaced by the interrupt type code and/or channel code bits contained in the cir. the ivr is write only at address 29h.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 22 dc electrical characteristics 5, 6, 7 symbol parameter test conditions limits unit symbol parameter test conditions min typ max unit v il input low voltage 0.8 v v ih input high voltage (except x1/clk) 0 to +70 c 2.0 v v ih input high voltage (except x1/clk) 40 to +85 c 2.2 v v ih input high voltage (x1/clk) 0.8v cc v v ol v oh output low voltage output high voltage (except od outputs) i ol = 4.0ma i oh = 400 m a i oh = 100 m a 0.8v cc 0.9v cc 0.4 v v v i il i ih input current low , i/o ports input current high, i/o ports v in = 0 v in = v cc 10 10 m a m a i i input leakage current v in = 0 to v cc 1 1 m a i ilx1 i ihx1 x1/clk input low current x1/clk input high current v in = gnd, x2 = open v in = v cc , x2 = open 100 100 m a m a i ozh i ozl output of f current high, 3state data bus output of f current low , 3state data bus v in = v cc v in = 0 1 10 1 m a i odl i odh opendrain output low current in of f state: irqn opendrain output low current in of f state: irqn v in = 0 v in = v cc 1 1 m a i cc power supply current operating mode ttl input levels 25 c with x1 = 4mhz 50 ma power down mode* 5 ma * see uar t application note for power down currents less than 5 m a.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 23 ac electrical characteristics 5, 6, 7, 8 symbol figure parameter limits unit symbol figure parameter min typ max unit reset timing t res 8 reset pulse width 200 ns i/o port timing t ps 9 i/o input setup time before rdn low 0 ns t ph 9 i/o input hold time after rdn high 0 ns t pd 9 i/o output valid from wrn high rdn low 110 110 ns ns interrupt timing t ir 10 irqn negated or i/o output high from: read rhr (rxrdy/ffull interrupt) w rite thr (txrdy interrupt) reset command (break change interrupt) reset command (i/o change interrupt) stop c/t command (counter interrupt) w rite imr (clear of interrupt mask bit) with respect to a 3.6864mhz clock on pin x1/clk 100 100 100 100 100 100 ns ns ns ns ns ns clock timing t clk 11 x1/clk low/high time 125/100 ns t clk 11 x1/clk low/high time (above 4mhz; x1/clk 2 active) 56/56 ns t clk 11 x1/clk frequency 0 9 3.6864 8.0 mhz t ctc 11 counter/timer clock high or low time 60 ns f ctc 11 counter/timer clock frequency 0 9 8 mhz t rx 11 rxc high or low time 30 ns f rx 11 rxc frequency (16x) rxc frequency (1x) 0 9 0 9 16 1.0 mhz mhz t tx 11 txc high or low time 30 ns f tx 11 txc frequency (16x) txc frequency (1x) 0 9 0 9 16 1.0 mhz mhz t ransmitter timing t txd 12 txd output delay from txc low 120 ns t tcs 12 txc output delay from txd output data 20 +20 ns receiver timing t rxs 13 rxd data setup time to rxc high 100 ns t rxh 13 rxd data hold time from rxc high 100 ns notes: 1. stress above these listed under absolute maximum ratings may cause permanent damage to the device. this is a stress rating only . functional operation of the device at these or any other condition above those indicated in the operation section of the specification is not implied. 2. for operating at elevated temperatures, the device must be derated based on +150 o c maximum junction temperature. 3. this product includes circuitry specifically designed for the protection of its internal devices from damaging ef fects of excessive static charge. nonetheless, it is suggested that conventional precautions be taken to avoid applying any voltages larger than the rated maxima. 4. parameters are valid over specified temperature range. see ordering information table for applicable temperature range and operating supply range. 5. all voltage measurements are referenced to ground (gnd). for testing, all inputs swing between 0.4v and 2.4v with a transition time of 20ns maximum. for x1/clk this swing is between 0.4v and 4.4v . all time measurements are referenced at input voltages of v il and v ih , as appropriate. 6. t ypical values are at +25 o c, typical supply voltages, and typical processing parameters. 7. t est condition for interrupt and i/o outputs: c l = 50pf, r l = 2.7k w to v cc . t est conditions for rest of outputs: c l = 150pf . 8. t iming is illustrated and referenced to the wrn and rdn inputs. the device may also be operated with cen as the `strobing' input. cen and rdn (also cen and wrn) are anded internally . as a consequence, the signal asserted last initiates the cycle and the signal negated first terminates the cycle. 9. this value is not tested, but is guaranteed by design. for t clk minimum test rate is 2.0mhz.
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 24 ac electrical characteristics 4 t a = 25 c; v cc = 5v 10%, unless otherwise specified. limits shown as nn/nn refer to commercial/industrial temperature range. single numbers apply to both ranges. no. figure characteristic limits unit no. figure characteristic min typ max unit 1 2 setup: a[5:0] valid to cen low 10 ns 2 2 hold: a[5:0] valid after cen low 6 45 ns 3 2 access: later of cen low and rdn low , to dnn valid (read) 110/115 ns 4 2 later of cen low and (rdn or wrn as applicable) low , to dackn low ns normal operation: 10 + 2 x1 edges 5 90/122 + 3 x1 edges 5 from power down: 150 5 2 earlier of cen high or rdn high, to dnn released (read) 1 0 30 ns 6 2 earlier of cen high or (rdn or wrn as applicable) high, to dackn released 0 30 ns 7 2 earlier of cen high or (rdn or wrn as applicable) high, in one cycle, to later of cen low and (rdn or wrn as applicable) low , for the next cycle 50 ns 8 2 setup, dnn valid (write) to later of cen low and wrn low 2 30 ns 9 2 later of cen low and wrn low , to earlier of cen high or wrn high 110/115 ns 10 2 hold: dnn valid (write) after dackn low , cen high or wrn high 3 0 ns notes: 1. the minimum time indicates that read data will remain valid until the bus master drives cen and/or rdn to high. 2. the fact that this parameter is negative means that the dnn line may actually become valid after cen and wrn are both low . 3. in a w rite operation, the bus master must hold the write data valid either until drives cen and/or wrn to high, or until the quar t drives dackn to low , whichever comes first. 4. t est condition for interrupt and i/o outputs: c l = 50pf , forced current for v ol = 5.3ma; forced current for v oh = 400 m a, rl = 2.7k w to v cc . t est condition for rest of outputs: c l = 150pf 5. consecutive write operations to the upper four bits of the command register (cr) require at least three x1/clk edges; four x1/clk edges in the `x1/clk divide by 2 edges' according to register 2e or 2f setting. 6. address is latched at leading edge of a read or write cycle. a[5:0] cen rdn wrn d[7:0] 1 2 1 2 read cycle write cycle dackn 4 4 3 3 7 7 9 9 7 7 9 9 5 5 6 6 8 8 4 4 10 10 10 6 6 sd00181 figure 2. a read cycle followed by a w rite cycle with dackn
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 25 ac electrical characteristics t a = 25 c; v cc = 5v 10%, unless otherwise specified. limits shown as nn/nn refer to commercial/industrial temperature range. single numbers apply to both ranges. no. figure characteristic limits unit no. figure characteristic min typ max unit 1 3 d[7:0] v alid after iackn low 110/115 ns 2 3 dackn low after iackn low 10 + 2 x1 edges 1 90/122 + 3 x1 edges 1 ns 3 3 d[7:0] floating after iackn high 0 30 ns 4 3 dackn high after iackn high 0 30 ns 5 3 iackn high after iackn low 110/115 ns note: 1. consecutive write operations to the upper four bits of the command register (cr) require at least three x1/clk edges; four x1/clk edges in the `x1/clk divide by 2 edges' according to register 2e or 2f setting. irqn iackn d[7:0] dackn 1 5 2 3 4 sd00165 note: rise time of irqn is dependent on external circuit. figure 3. interrupt knowledge (iackn) t iming osc/n eval/hold iackn cir v alue for this interrupt sd00182 figure 4. interrupt bid arbitration t iming
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 26 hold en intbusn7:0 inverting la tches byte counter transmitter offset correction logic iack byte count interrupt type channel current interrupt register read gibc read cicr d7 d6 d5 d4 d3 d2 d1 d0 read cir updcir ? ? ? ? ? ? sd00167 figure 5. current interrupt register logic 2.7k +5v 60pf 150pf 6k 1.6k +5v intranintrdn, i/o0ai/o3d d0d7, txdatxdh, i/o0ai/o3d sd00168 figure 6. t est conditions on outputs
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 27 reset t res sd00169 figure 7. reset t iming rdn cen i/o as output i/o as input t ps t ph t pd t pd wrn old data new da ta i/o pins must be st able for non-changing bus da t a during the read. note: i/o pin data is not latched sd00170 figure 8. i/o port timing wrn interrupt 1 output rdn interrupt 1 output v m t ir t ir v ol +0.5v v ol +0.5v v ol v ol notes: 1. includes i/o when used as txrdy or rxdy/ffull outputs as well as irqn. 2. the test for open drain outputs is intended t o guarantee switching of the output transist or. measurement of this response is referenced from the midpoint of the switching signal, v m , to a point 0.5v above v ol . this point represents noise margin tha t as- sures true switching has occurred. beyond this level, the effects of external circuitr y and test environment are pronounced and can grea tl y affect the resul t ant measurement . sd00171 figure 9. interrupt t iming
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 28 c1 and c2 should be chosen according to the crystal manufacturer' s specification. c1 and c2 values will include any parasitic capacitance of the wiring. x1/clk ctclk rxc txc t clk t ctc t rx t tx t clk t ctc t rx t tx +5v 1k required for ttl gate. x1 x2 c1 = c2 = 24pf for c l = 20pf x1 x2 3.6864mhz 3pf 4pf 50 kohms to 150 kohms 26c94 notes: c1 and c2 should be based on manufacturer ' s specification. x1 and x2 parasitic capacitance is 1-2pf and 3-5pf , respectively . gain: at 4mhz 8 to 14db; at 8mhz 2 to 6db phase: at 4mhz 272 to 276 ; at 8mhz 272 to 276 typical cr yst al specifica tion frequency: 2 4mhz load cap acit ance (c l ): 12 32pf type of opera tion: p arallel resonant , fundament al mode nc c1 c2 mux to remainder of circuit 2 38.4khz clock brg to i/o change-of-sta te detect ors 22 standard baud rates sd00172 figure 10. clock t iming txc (input) txd txc (1x output) 1 bit time (1 or 16 clocks t tcs t txd sd00173 figure 11. t ransit clock t imng
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 29 rxc (1x input) rxd t rxs t rxh sd00174 figure 12. receive clock t iming txd d1 d2 d3 break d4 d6 trans- mitter enabled txrdy (sr2) wrn ctsn 1 (i/o0) (i/o1) rtsn 2 d1 d2 d3 start break d4 stop break d5 will not be transmitted d6 cr[7:4] = 1010 cr[7:4] = 1010 notes: 1. timing shown for mr2[4] = 1. 2. timing shown for mr2[5] = 1. mr0(5:4) = 00 sd00175 figure 13. t ransmitter data t iming
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 30 d1 d2 d9 d10 d11 d12 d13 d3 rxd receiver enabled rxrdy (sr0) ffull (sr1) rxrdy/ rdn overrun (sr4) rts 1 i/o1 notes; 1. timing shown for mr1[7] = 1. 2. default: i/o1 is rts and iopcr(5:4) 01 ffull isr(1) i/o1 = 1 or (cr[7:4] = 1010) reset by command d10 will be lost s d s d s d s d d2 d3 d10 d1 s = status d = data d2 d10 will be overwritten by d11, 12, etc sd00176 figure 14. receiver data t iming master station txd transmitter enabled txrdy (sr2) cen (write] peripheral st ation rxd receiver enabled rxrdy (sr0) rdn/wrn add#1 1 d0 0 add#2 1 bit 9 bit 9 bit 9 bit 9 bit 9 bit 9 bit 9 bit 9 mr1 [4:3] = 11 mr1 [2] = 1 add#1 mr1 [2] = 0 d0 mr1 [2] = 1 add#2 0 add#1 1 d0 0 add#2 1 0 mr1 [4:3] = 11 add#1 d0 s d s = status d = data s d add#2 note: timing shown for fifo power-up def ault sd00177 figure 15. w ake-up mode
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 31 interrupt notes the following is a brief description of the new quar t abiddingo interrupt system, interrupt vector and the use of the global registers. the new features of the quar t s have been developed to greatly reduce the microprocessor time required to service uart interrupts. bus cycle times have also been enhanced. by use of the new current interrupt register (cir) the speed of a polled system is also improved. for example programming the scc2692 to interrupt on txrdy and rxful would generate four interrupts for every six characters processed along with at least two additional accesses to the chip for each interrupt. this amounts to two nondata chip accesses per character . in the 68c94 this has been reduced to 0.25 non data accesses per character; an eight fold improvement. in certain conditions use of the global registers will yield a greater improvement. the quar t has 18 possible sources which can be programmed to generate an interrupt: ? 4 receiver channels ? 4 t ransmitter channels ? 4 received obreako conditions ? 4 change of state detectors (a total of 8 ports) ? 2 counter/t imers these sources are encoded in such a way that they generate a unique value. this value is defined by chip hardwire programming, user programming, and the source' s present condition. the values the sources generate are compared (at the x1 clock rate) to a user defined interrupt threshold value contained in the icr (interrupt control register). when the source' s value exceeds the threshold the interrupt is generated. it is the source' s value which is captured in the cir. the heart of the interrupt speed enhancement is attained by allowing the interrupting source to encode its channel, interrupt type and, if appropriate, the number of fifo bytes requiring service. this information is coded and transferred the cir (current interrupt register) at the time iackn is asserted or the command 'update cir' is executed. upon an interrupt the processor may read this register and in one access determine the owho, what and how mucho. this cir value is used to drive the interrupt vector modification (when used) and the new oglobalo registers. aglobalo registers the oglobal registerso are ef fectively pointers which use the contents of the cir to direct a read or write operation to rx or tx or other source which is currently interrupting. there are four global registers defined in the register map: 1. global interrupting byte count 2. global interrupting channel 3. global receive fifo register 4. global t ransmit fifo register the global receive and transmit registers operate as an indirect address. the data read from the global receive register will be that of the currently interrupting receiver; the data written to the global transmit register will go to the currently interrupting transmitter . the interesting point here is that under certain circumstances an interrupt can be serviced without an interrogation of the chip. for completeness it should be noted that the global registers are not physical devices. reads of the global byte and channel registers give the byte count or channel number , respectively , (right justified) of the interrupting channel. the cir data is mapped to these oregisterso. in these identifiers the receivers are biased to have highest priority . the identifier bits and the channel number bits are hardwired on the chip. normally the nondata interrupts would be programmed to a low value. the programmable fields can, in some cases, make these sources higher than a full receiver . it would seem that a 1 1 programmed in the upper counter/timer bits, for example, would cause it to interrupt nearly all the time. this is not true . a counter/timer that has not timed out will not bid. in a similar fashion a receiver fifo that is empty or a transmitter fifo that is full will not bid in general terms the threshold value programmed in the icr (interrupt control register) will reflect some fill level of the eight character transmit and receive fifos that allow processor service without underrun or overrun occurring. table 9. abidding formato bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 bit 0 function rx byte count error 1 1 1 channel no. receiver bid with error rx byte count no error 0 1 1 channel no. receiver bid no error 0 tx byte count 1 0 channel no. t ransmit bid programmable 1 0 0 channel no. receive break programmable 0 0 1 channel no. change of state programmable 0 1 0 1 channel no. counter/timer notes: 1. the ones and zeros above represent the hardwired positions. 2. note the format of bits 4:2. they represent the identity of the interrupting source. 3. bids with the highest number of contiguous msbs win the bid. 1 1 1 receiver with error 0 1 1 receiver without error x 1 0 transmitter 1 0 0 receiver break detect 0 0 1 change of state 1 0 1 counter/timer 0 0 0 no interrupt
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 32 note that interrupt threshold value in the icr is 6 bits long. this value is aligned with the bid arbitration logic such that it bids only through the most significant 6 bits. the result of this is that the channel value does not 'bid'. however the logic is such that other parts of the bid being equal the condition of the highest channel will be captured in cir. the increasing order of the channels is a, b, c, d. thus channel d is the ostrongesto of the four . it could be that the giving the highest strength to channel d may , from time to time, not be what would be most desired. further it may be desired to alter the authority of a channel' s bid. this may be done by setting the rx and/or tx interrupt bits in mr0 and mr1 to values dif ferent than zero. this will have the ef fect of not allowing the associated receiver or transmitter to bid until its fifo reaches a particular fill level. although this compromises the idea of the bidding interrupt scheme, it is entirely safe to use. in fact it is setting of mr0 and mr1 interrupt bits to zero that causes the receiver to stop bidding when it is empty and causes the transmitter to stop bidding when it is full. altering the mr0 and mr1 interrupt bits only changes the level at which the rx & tx bidding is stopped. see the ainterrupt note on 68c94o which refers to the use of the mr registers in controlling the rx and tx bidding. in normal operation the character of an interrupt will be controlled by the above registers in conjunction with the imr (interrupt mask register (one for each duar t)) . the function of the imr will be to enable bidding of any particular source. recall that the quar t has 18 functions which may generate an interrupt. the format of the interrupt vector is controlled by the icr[1:0] bits. the formats are shown in t able 7. the purpose of the vector modification is to allow the interrupting source (either channel or type and channel) to direct the processor to appropriate service routine. w e have found that some users wish to use extremely tight loops for the service routines and find the addition of several tests of status bytes to be very 'expensive' in processor time. table 10. configuration of interrupt vector for the quart bit 7 bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 bit 0 interrupt vector for icr[1:0]=00 interrupt vect or forma ts (controlled by icr[1:0]) icr[1:0]=00 ivr[7:0] full interrupt vector interrupt vector for icr[1:0]=01 icr[1:0]=01 ivr[7:2] icr[1:0] interrupt vector 6 msbs channel number interrupt vector for icr[1:0]=10 icr[1:0]=10 ivr[7:5] icr[4:2] icr[1:0] interrupt vector 3 msbs interrupt type channel number interrupt vector for icr[1:0]=1 1 (inhibit) icr[1:0]=1 1 (inhibit) inhibit vector output. (set bus to ffh) current interrupt register forma t cir[7:0] rx or tx byte count interrupt type: r/tx ct cos brk channel number interrupt control register forma t icr[0:7] interrupt threshold icr[7:2] interrupt vector format icr[1:0] note on quart interf ace to its controlling processor the quart , has been designed to interface in either the synchronous interrupt environment (without dackn) or the asynchronous interrupt environment (with dackn). the 80xxx devices of intel design are usually operated in a synchronous interrupt mode while those of motorola design, 68xxx devices, operate in an asynchronous interrupt mode. note: synchronous and asynchronous interrupt modes are not in any way associated with synchronous or asynchronous data transmission. the quar t has been designed with the pins required to service either interface. in general then it is probable that in any application some of the interface pins will not be used. this note discusses what is required for the otext booko connections of the two methods. it should be noted that features of either method are not mutually exclusive. the interface pins are all active low . (at v ss or ground) the pins used for normal reading and writing to the quar t (the generation of a bus cycle) are cen (chip enable), rdn (read enable), wrn (w rite enable). the pins used in the interrupt service are irqn (interrupt request), iackn (interrupt acknowledge). the pin used for data transfer is dackn (data acknowledge). irqn and dackn are open drain outputs. dackn signaling can be enabled or disabled via writing to address 27h or 26h respectively . note that if dackn is enabled that writing to the quar t will occur on the falling edge of dackn. the use of hardware reset (required at power up) enables dackn. the asynchronous interface those familiar with 68xxx i/o will note the use of the two pins rdn and wrn to be in conflict with 68xxx devices use of the one r/wn pin. the r/wn must be inverted such that the r/wn may drive the wrn input while the inversion of r/wn drives the rdn input. it is good practice to condition the inversion of r/wn such that rdn will not become active on the termination of a write to the quar t while cen is still asserted. these short periods of read could upset fifo pointers in the chip. during a read of the quar t dackn signals that valid data is on the data bus. during a write to the quar t dackn signals that data placed on the bus by the control processor has been written to the
philips semiconductors product specification sc68c94 quad universal asynchronous receiver/transmitter (quar t) 1995 may 1 33 addressed register . the generation of dackn begins with the start of a bus cycle (read, w rite or interrupt acknowledge) and then requires two edges of the x1 clock plus typically 70ns for its assertion. in this mode the writing of data to the quar t registers occurs on the falling edge of dackn or the rising edge of the combination of cen and wrn which ever occurs first. this requires that the data to be written to the quar t registers be valid with respect to the leading edge of the combination of cen and wrn. (in the synchronous mode it is the trailing edge) iackn updates the cir (current interrupt register) and places the interrupt v ector or modified interrupt v ector on the bus if the interrupt v ector is used. the synchronous interface in this mode the dackn and iackn are usually not used. here data is written to the quar t on the trailing edge of the combination of cen and wrn. the placing of data on the bus during a read cycle begins with the leading edge of the combination of cen and rdn. the read cycle will terminate with the rise of cen or rdn which ever one occurs first. in this mode bus cycles are usually setup to be the minimum time required by the quar t and hence will be faster than bus cycles that are defined by the dackn signal. dackn should be turned of f in this mode. when iackn is not used or is not available the command at 2ah should be used to update the cir (current interrupt register). this register is normally updated by iackn in response to the irqn. note that the cir is not updated by irqn since there could be a long time between the assertion of irqn and the start of the interrupt service routine. during this time it is quite possible that another interrupt with a higher priority occurs. it is the cir that contains the information that describes the interrupt source and its priority . it is therefor recommended that the first operation upon entering the interrupt service routine is the updating of the cir. (recall that the contents of the global registers reflect the content of the cir) summary in the asynchronous mode all of the interface pins are usually used. the synchronous mode usually will not use the iackn and dackn. however there is no conflict in the quart if both modes are used in the same application. (i.e. more than one device may control the quar t) the principles to keep in mind are: 1. when iackn is not used the cir should be updated via command. 2. if dackn is not used it should be disabled. 3. when in the asynchronous mode be sure dackn is enabled. 4. with 68xxx type controllers the rdn signal must be generated.


▲Up To Search▲   

 
Price & Availability of SC68C94C1N

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X