beautypg.com

Zilog Z16C35 User Manual

Page 287

background image

Application Note

Technical Considerations When Implementing LocalTalk Link Access Protocol

14-7

1

The second routine decrements the receiver buffer
address by two to account for the two CRC bytes that are
read from the SCC before the special condition interrupt
occurs. Note that the SCC does not filter these CRC bytes,
nor does it filter the address byte. Everything received after
the leading flags and before the trailing flags appears in
the receive buffer.

One difficulty that arises in LLAP that was not addressed
here is that the receipt of a frame very often creates an
obligation to send a frame back to the sender within the

interframe gap, which is 200

µ

secs. This difficulty is even

greater than it might appear. The 200

µ

sec gap starts

when the frame is received; it ends when the leading flags
and destination address of the response are sent. Start
sending the response soon enough to allow sending two
leading flags (plus a possible leading flag fragment) and
the first data character, and to allow for the 3-bit delay in
the SCC shifter. Therefore, start sending early enough to
transmit 35 bits before the interframe gap expires, or about
70

µ

secs after you receive the frame.

CONCLUSIONS

The problems of sending the sync pulses, the timing of
transmission packets, and the problems associated with
the reception of packets as defined by LLAP are handled
by the Z80181 and its peripherals. It was demonstrated
that LLAP frames can be transmitted and received by
using the straight forward polling method and by using
interrupt routines. In a much busier environment where the
processor cannot strictly be an LLAP engine, other

methods such as using DMA in a fully interrupt driven
environment must be used. It was also demonstrated that
severe CPU overhead is used in setting up the sync
pulses, timing out delays, etc., before each LLAP frame. A
modified SCC that transmits and receives special LLAP
frames helps in off loading some of this overhead, hence
freeing the CPU to do other tasks.

Page 281 of 316

UM011002-0808