intdo
83C152 HARDWARE DESCRIPTION
WhenBKOFFequalsthe slot assignment(as definedin
MYSLOT),the signal“BKOFF = MYSLOT’in Fig-
ure 3.5is asserted for one slot time, during which the
GSCcan restart its transmission.
WhileBKOFF is countingdown,if any activityis de-
tectedat the GRXD pin,the countdownis frozenuntil
the activityends,a line idle conditionis detected,and
an IFS transpires. Then the countdownresumesfrom
whereit left off.
If a collision is detected at the GRXD pin while
BKOFFiscountingdown,the collisionresolutionalgo-
rithm is restarted fromthe beginning.
In effeckthe GSC“owns”its assignedslotnumber,but
with one exception. Nobody owns slot number O.
Thereforeif the GSC is assignedslot number O,then
when BKOFF = O,this station and any other station
that has somethingto say at this time will have an
equalchanceto take the line.
3.2.7 HARDWARE BASED ACKNOWLEDGE
Hardware BasedAcknowledge(HBA) is a data link
packet acknowledgingscheme that the user software
can enablewith CSMA/CD protocol.It is not an op-
tion with SDLCprotocolhowever.
In general HBA can give improvedsystem response
time ad increasedeffectivetransmissionrates overac-
knowledgeschemesimplementedin higherlayersofthe
networkarchitecture.Anotherbenefitis the possibility
of early release of the transmit bufferas soon as the
acknowledgeis received.
The acknowledgeconsistsofa preamblefollowedby an
idle condition.A receivingstation with HABEN en-
abled will send an acknowledgeonly if the incoming
address is unique
to the receivingstation and if the
frame is determinedto be correct with no errors. For
the acknowledgeto be scnLTEN must be set. For the
transmitting station to recognize the acknowledge
GREN must be set. A zero as the LSBof the address
indicatesthat the addreasis uniqueand not a groupor
broadcast address. Errors ean be causedby collisions,
incorrect CRC, misalignment,or FIFO overflow.The
receiver sends the acknowledgeas soon as the line is
sensedtobe idle.Theusermustprogramthe interhme
space and the preamblelengthsuch that the acknowl-
edgeis completedbeforeIFS expirea.This is normally
doneby programmingIFS largerthan the preamble.
A transmittingstation with HABEN enabledexpects
an acknowledge.It must receiveonepriorto the endof
the interframe space, or else an error is assumed and
the NOACKbit is set. Settingof the TDN bit is also
delayeduntilthe endofthe interframespace.Collisions
detected during the interframe space will also cause
NOACKto be set.
If the usersoftwarehas enabledDMAseMcing of the
GSC,an interrupt is generatedwhenTDN is set. TDN
willbe set at the end of the interframespaceifa hard-
warebasedacknowledgeis requiredandreceived.If the
GSCisservicedby the CPU,the usermusttime out the
interfkamespaceand then checkTDN beforedisabling
the transmitter or transmit error interrupts. NOACK
willgeneratea transmi
t error interruptif the transmit-
ter and interrupts are enabled during the interframe
space.
3.3
SDLCOperation
3.3.1 SDLC OVERVIEW
SDLCis a communicationprotocoldevelopedby IBM
and widelyusedin industry. It is baaedon a primary/
secondaryarchitecture and requiresthat each second-
ary station have a uniqueaddress. The secondarysta-
tionscanonlycommunicateto the primarystation, and
then, onlywhenthe primary station allowscommuni-
cationto take place. This eliminatesthe possibilityof
contentionon the serial line causedby the
Secon-
station’stryingto transmit simultaneously.
In the C152,SDLCcanbe configuredtoworkin either
Ml or halfduplex,Whenadheringto strict SDLCpro-
tocol, full duplex is required. Full duplexis selected
whenevera 16-bitCRCis selected.At theendofa valid
reset the id-bit CRC is selected.To selecthalf duplex
with a 16-bitCRC,the receivermust be turned offby
user software before transmission. The receiver is
turned
Off by chrin g the GREN bit (RSTAT.1).The
receiverneedsto be turned offbecausethe address that
is transmittedis the address of the secondarystation’s
receiver.If not turned off, the receivercould mistake
the outgoingmessageas beingintendedforitaelf.When
32-bitCRCSare used, half duplexis the only method
availablefor transmission.
7-27