Functional Description
2.8.5.2 Additional General Considerations when Using the Auto Mode
a) Switching from auto mode to non-auto mode.
As mentioned in the introduction the auto mode is only applicable in the states 7 and 8 of
the LAPD. Therefore whenever these states have to be left (which is indicated by a
"Mode:NAM" text) there are several actions to be taken that could not all be detailed in the
SDL-diagrams:
a.1) write non-auto mode and TMD = 0 into the mode register.
a.2) write the timer register with an arbitrary value to stop it. The timer T200 as specified
in the LAPD-protocol is implemented in the hardware only in the states 7 and 8; in all
other states this or any other timer-procedure has to be done by the software with the
possible use of the timer in external timer mode.
a.3) read the WFA bit of the STAR2 register and store it in a software variable. The
information in this bit may be necessary for later decisions. When switching from auto
mode to non-auto mode XPR interrupts may be lost.
a.4) In the non-auto mode the software has to decode I, U and S-frames because I and S
frames are only handled autonomously in the auto mode.
a.5) The RSC and PCE interrupts, the contents of the STAR2 register and the RRNR bit
in the STAR register are only meaningful within the auto mode.
a.6) leave some time before RHR or XRES is written to reset the counters, as a currently
sent frame may not be finished yet.
b) What has to be written to the XFIFO?
In the legend description when the software has to write contents of a frame to the XFIFO
only "XFIFO" is shown in the corresponding box. We shall give here a general rule of what
has to be written to the XFIFO:
a) For sending an I-frame with CMDR:XIF, only the information field content, i.e. no SAPI,
TEI, Control field should be written to the XFIFO.
b) For sending an U-frame or any other frame with CMDR:XTF, the SAPI, TEI and the
control field has to be written to the XFIFO.
c) The interrupts XPR and XMR.
The occurence of an XPR interrupt in auto mode after an XIF command indicates that the
I-frame sent was acknowledged and the next I frame can be sent, if STAR2:TREC
indicates state 7 and STAR:RRNR indicates Peer Rec not busy. If Peer Rec is busy after
an XPR, the software should wait for the next RSC interrupt before sending the next I-
frame. If the XPR happens to be in the timer recovery state, the software has to poll the
STAR2 register until the state multiple frame established is reached or a TIN interrupt is
issued which requires auto mode to be left (One of these two conditions will occur before
the time T200*N200). In non-auto mode or after an XTF command the XPR just indicates,
that the frame was sent successfully.
Semiconductor Group
121