`
`2.3.5.3 Reject
`
`(REJ) Recovery
`
`REJ is used to request a retransmission of I frames following the
`detection of a MS) sequence error. Only one outstanding "sent REJ" condition
`is allowed at a time. This condition is cleared when the requested I frame
`has been received.
`I
`
`A DXE receiving the REJ command will clear the condition by re-
`sending all outstanding I frames (up to the window size), starting with the
`one indicated in MR) of of the REJ command frame.
`
`2.3.5.4 Time—out Error Recovery
`
`2.3.5.4.1 [T1 Timer Recovery
`
`If a DXE, due to a transmission error, does not receive (or
`receives and discards) a single I frame or the last I frame in a sequence of I
`frames,
`it will not detect a send-sequence-number error,
`and therefore will
`not
`transmit a REJ.
`The DXE which transmitted the unacknowledged I frame(s)
`shall,
`following the completion of time-out period Tl,
`take appropriate
`recovery action to determine when I frame retransmission should begin as
`described in 2.4.4.9, below. This condition is clearedhy the reception of an
`acknowledgement for the sent frame(s), or" by the link being reset.
`See 2.4.6.
`
`2.3.5.4.2 Timer T3 Recovery!
`
`Timer T3 is used to assure the link is still functional during
`periods of
`low information transfer. Whenever T1
`is not
`running (no
`outstanding I frames), T3 Is used to periodically poll the other DXE of a
`link. When T3 times out, a RP. or RNR frame is transmitted as a command and
`with the P bit set.
`The waiting acknowledgement procedure (2.4.4.9, below) is
`then executed.
`]
`
`2.3.5.5 Invalid Frame or FCS Error
`
`If an invalid frame is received, or a frame is received with an FCS
`error, that frame will be discarded with no action taken.
`
`2 .3 . 5 .6
`
`Frame Reject ion Cond it ion
`
`A frame rejection condition occurs when an otherwise error-free frame
`[
`has been received with one of
`the conditions listed in 2.3.4.3.3 above.
`]
`
`Once a rejection error occurs, no more I frames are accepted (except
`for the examination of the P/F bit) until the error is resolved. The error
`condition is reported to the other DXE by sending a FRMR response frame.
`See
`204I5I
`
`19
`
`
`
`Page 000037
`
`
`
`AX.25 Amateur Packet-Radio Link-Layer Protocol
`
`2.4 Description of AX.25 Procedures
`The following describes the procedures used to setup, use, and disconnect
`a balanced link between two DXE stations.
`
`2.4.1 Address Field Operation
`
`2.4.1.1 Address Information
`All
`transmitted frames shall have address fields conforming to
`2.2.13, above. All frames shall have both the destination device and the
`source device addresses in the address field, with the destination address
`coming first. This allows many links to share the same RF channel.
`The
`destination address is always the address of the station(s) to receive the
`frame, while the source address contains the address of the device that sent
`the frame.
`The destination address can be a group name or club call sign if
`point-to-multipoint operation is allowed. Operation with destination
`addresses other than actual amateur call signs is a subject for further
`study.
`
`2.4.1.2 [Command/Response Procedure
`AX.25 Version 2.0 has implemented the commandlresponse information in
`the address field.
`In order to maintain compatibility with previous versions
`of AX.25,
`the command/response information is conveyed using two bits.
`An upward-compatible AX.25 DXE can determine whether it is
`communicating with a DXE using an older version of this protocol by testing
`the commandlresponse bit information located in bit 7 of the SSID octets of
`both the destination and source address subfields.
`If both C bits are set to
`zero,
`the device is using the older protocol.
`The newer version of the
`protocol always has one of these two bits set to one and the other set to
`zero, depending on whether the frame is a command or a response.
`The command/response information is encoded into the address field as
`shown in Fig. 10.
`
`*
`
`_..__.....___...—.__—._.__—..__.____—_-——_..——_-._.._—..__._—__—_—__.._—..._.—.___..._
`I Frame Type
`I Dest. SSID C-Bit
`I Source SSID C-Bit
`I
`I ------------------------------------------------------------I
`IPrevious versions
`I
`0
`I
`0
`I
`Icomand (V.2.0)
`I
`1
`I
`0
`I
`lResponse (V.2.0)
`I
`0
`-I
`l
`I
`IPrevious versions
`I
`1
`I
`1
`I
`
`Fig. 10 -- Comand/Response encoding
`
` *
`
`20
`
`Page 000038
`
`
`
`AX.25 Amateur Packet-Radio Link-Layer Protocol
`
`Since all frames are considered either commands or responses, a
`device shall always have one of the bits set to one, and the other bit set to
`zero.
`,
`
`The use of the command/response information in AX.25 allows S frames
`to be either commands or responses. This aids maintainance of proper control
`over the link during the information transfer state.
`
`2.4.2 P/F Bit Procedures
`
`The next response frame returned by the DXE to a SABM or DISC command
`with the P bit set to 1 will be a UA or DM response with the F bit set to 1.
`
`The next response frame returned to an I frame with the P bit set to 1,
`received during the information transfer state, will be a RR, RNR, or REJ
`response with the F bit set to 1.
`’
`
`The next response frame returned to a supervisory command frame with
`the P bit set to 1, received during the information transfer state, will be a
`RR, RNR, or REJ response frame with the F bit set to 1.
`
`The next response frame returned to a S or I command frame with the P
`bit set to 1, received in the disconnected state, will be a DM response frame
`with the F bit set to 1.
`‘
`The P bit
`is used in conjunction with the time-out recovery condition
`discussed in 2.3.5.4, above.
`
`When not used,
`
`the PI’ bit is set to zero.
`
`]
`
`2.4.3 Procedures For Link Set-Up and Disconnection
`
`2.4.3.1 LAPB Link Connection Establishment
`
`When one DXE wishes to connect to another DXE, it will send a SABM
`command frame to that device and start timer (T1).
`If the other DXE is there
`and able to connect,
`it will respond with a UA response frame, and reset both
`of its internal state variables (V(S) and V(R)). The reception of the UA
`response frame at
`the other end will cause the DXE requesting the connection
`to cancel the T1 timer and set its internal state variables to 0.
`
`the device
`If the other DXE doesn't respond before Tl times out,
`[
`requesting the connection will re-send the SABM frame,
`and start T1 running
`again. The DXE should continue to try to establish a connection until it has
`tried unsuccessfully N2 times. N2 is defined in 2.4.7.2, below.
`
`the DXE decides that it cannot
`If, upon reception of a SABM command,
`enter the indicated state, it should send a DM frame.
`
`the DXE sending the SABM should cancel
`When receiving a DM response,
`its Tl timer, and not enter the information-transfer state.
`
`21
`
`«———————_____———----I-I-Ill-IIIIIII-I-IIIII
`
`Page 000039
`
`
`
`AX.25 Amateur Packet-Radio Link-Layer Protocol
`
`The DXE sending a SABM command will ignore and discard any frames
`except SABM, DISC, UA, and DM frames from the other DXE.
`
`Frames other than UA and DM in response to a received SABM will be
`sent only after the link is set up and if no outstanding SABM exists.
`
`2 .4.3 . 2
`
`Informat ion-Transfer Phase
`
`the
`the DXE will enter
`After establishing a link connection,
`information—transfer state.
`In this state, the DXE will accept and transmit I
`and S frames according to the procedure outlined in 2.4.4, below.
`
`state,
`
`When receiving a SABM command while in the information-transfer
`the DXE will follow the resetting procedure outlined in 2.4.6 below.
`1
`
`2 .4 . 3 .3 Link Disconnection
`
`2.4.3.3.l While in the information-transfer state, either DXE may indicate a
`request to disconnect the link by transmitting a DISC command frame and
`starting timer T1 (see 2.4.7).
`
`A DXE, upon receiving a valid DISC command, shall send a UA
`2.4.3.3.2
`response frame and enter the disconnected state.
`A DXE, upon receiving a UA
`or DM response to a sent DISC command, shall cancel timer T1, and enter the
`disconnected state.
`
`2.4.3.3.3 [If a UA or DM response is not correctly received before Tl times
`out,
`the DISC frame should be sent again and T1 restarted.
`If this happens N2
`times,
`the DXE should enter the disconnected state.
`
`2.4 .3 .4 Disconnected State
`
`2.4.3.4.1 [A DXE in the disconnected state shall monitor received commands and
`react upon the reception of a SABM as described in 2.4.3.1 above and will
`transmit a D11 frame in response to a DISC command.
`I
`
`In the disconnected state, a DXE may initiate a link set-up as
`2.4.3.4.2
`outlined in connection establishment above (2.4.3.l).
`It may also respond to
`the reception of a SABM and establish a connection, or it may ignore the SABM
`and send a D14 instead.
`
`2.4.3.4.3 [Any DXE receiving a command frame other than a SABM or UI frame
`with the P bit set to one should respond with a DM frame with the F bit set to‘
`one.
`The offending frame should be ignored.
`
`22
`
`I-’—
`
`Page 000040
`
`
`
`AX.25 Amateur Packet-Radio Link-Layer Protocol
`
`2Jn3A»4 When the DXE enters the disconnected state after an error condition
`or if an internal error has resulted in the DXE being in the disconnected
`state,
`the DXE should indicate this by sending a DM response rather than a
`DISC frame and follow the link disconnection procedure outlined in ZJLSJLB,
`above. The DXE may then try to re-establish the link using the link set-up
`procedure outlined in 2.4.3.1, above.
`1
`
`2.4.3.5 Collision Recovery
`
`?..4.3.5.1 Collisions in a Half-Duplex Environment
`
`Collisions of frames in a half-duplex environment are taken care of
`by the retry nature of the T1 timer and retransmission count variable. No
`other special action needs to be taken.
`
`2.4.3.5.2 Collisions of Unnumbered Commands
`
`If sent and received SABM or DISC command frames are the same, both
`[
`DXEs should send a UA response at
`the earliest opportunity, and both devices
`should enter the indicated state.
`
`If sent and received SABM or DISC commands are different, both DXEs
`should enter the disconnected state and transmit a D14
`frame at
`the earliest
`opportunity.
`‘
`]
`1
`
`2.4.3.5.3 Collision of a D14 with a SABM or DISC
`
`a" collision between
`When an unsolicited DH response frame is sent,
`it and a SAM! or DISC may (cent.
`In order to prevent this BM‘ from being
`misinterpreted, all unsolicited DH frames should be transmitted with the F bit
`set to zero. All SABM and DISC frames should be sent with the 1’ bit set to
`one. This will prevent any confusion when a ‘D14 frame is received.
`
`2 .4 .3 .6 Connectionless Operat ion
`
`is
`type of operation that
`there is an additional
`In Amateur Radio,
`not feasable using level 2 connections. This operation is the round table,
`where several amateurs may be engaged in one conversation. This type of
`operation cannot be accommodated by»AX.25 link-layer connections.
`The way round-table activity is implemented is technically outside
`the AX.25 connection, but still using the A.X.25 frame structure.
`
`23
`
`$
`
`Page 000041
`
`
`
`AX.25 Amateur Packet-Radio Link—Layer Protocol
`
`AX.25 uses a special frame for this operation, called the Unnumbered
`Information (U1) frame. When this type of operation is used,
`the destination
`address should have a code word installed in it to prevent
`the users of
`that
`particular round table from seeing all frames going through the shared RF
`medium. An example of this is if a group of amateurs are in a round-table
`discussion about packet radio,
`they could put PACKET in the destination
`address, so they would receive frames only from others in the same discussion.
`An added advantage of the use of AX.25 in this manner is that the source of
`each frame is in the source address subfield,
`so software could be written to
`automatically display who is making what comments.
`
`Since this mode is connectionless, there will be no requests for
`retransmissions of bad frames. Collisions will also occur, with the potential
`of losing the frames that collided.
`‘
`
`2.4.4 Procedures for Information Transfer
`
`Once a connection has been established, as outlined above, both devices
`are able to accept I,S, and U frames.
`
`2.4.4.1 Sending I Frames
`
`Whenever a fikE has an I frame to transmit, it will send the I frame
`[
`with N(S) of the control field equal
`to its current send state variable V(SL
`Once the I frame is sent, the send state variable is incremented by one.
`If
`timer T1 is not running, it should be started.
`If timer T1 is running, it
`should be restarted.
`1
`
`The DXE should not transmit any more I frames if its send state
`variable equals the last received N€R)
`from the other side of the link plus
`seven.
`If it were to send-more I frames, the flow control window would be
`exceeded, and errors could result.
`
`If a DXE is in a busy condition, it may still send I frames as long
`as the other device is not also busy.
`
`If a DXE is in the frame-rejection mode, it will stop sending I
`
`frames.
`
`2.4.4.2 Receiving I Frames
`
`2.4.4.2.l If a DXE receives a valid I frame (one with a correct FCS and whose
`send sequence number equals the receiver's receive state variable) and is not‘
`in the busy condition, it will accept the received I frame, increment its
`receive state variable, and act in one of the following manners:
`
`24
`
`$
`
`Page 000042
`
`
`
`AX.25 Amateur Packet-Radio Link—Layer Protocol
`
`1.
`
`2.
`
`[
`
`that I frame may be sent with the
`If it has an I frame to send,
`transmitted N(R) equal to its receive state variable V(R) (thus
`acknowledging the received frame). Alternately, the device may
`send a RR frame with MR) equal to V(R), and then send the I frame.
`
`the receiving devicetwill
`If there are no outstanding I frames,
`send a RR frame with MR) equal to V(R).
`The receiving DXE may
`wait a small period of time before sending the RR frame to be sure
`additional I frames are not being transmitted.
`]
`
`2.4.4.2.2 If the DXE is in a busy condition, it may ignore any received I
`frames without reporting this condition other than repeating the indication of
`the busy condition.
`
`If a busy condition exists, the DXE receiving the busy condition
`»
`indication should poll
`the sender of
`the busy indication periodically until
`the busy condition disappears.
`
`A DXE may poll the busy DXE periodically with RR or RNR frames with
`'
`[
`the P bit set
`to one.
`]
`
`The reception of I frames that contain zero-length information
`fields shall be reported to the next level but no information field will be
`transferred.
`‘
`
`2.4.4.3 Reception of Out of Sequence Frames
`
`When an I frame is received with a correct FCS, but its send sequence
`number, N(S), does not match the current receiver's receive state variable,
`the frame should be discarded.
`‘A REJ frame shall be sent with a receive
`sequence number equalto one higher (modulo 8)
`than the last correctly
`received I frame if an uncleared NCS) sequence error condition has not been
`previously established.
`The received state variable and poll bit of the
`discarded frame should be checked and acted upon,
`if necessary, before
`discarding the frame.
`
`2.4.4.4 Reception of Incorrect Frames
`
`When a DXE receives a frame with an incorrect FCS, an invalid frame,
`or a frame with an improper address,
`that frame shall be discarded.
`
`2.4.4.5 Receiving Acknowledgement
`
`Whenever an I or S frame is correctly received, even in a busy
`condition,
`the N01) of the received frame should be checked» to see if it
`includes an acknowldegment of outstanding sent I frames.
`The T1 timer should
`be cancelled if the received frame actually acknowledges previously
`unacknowledged frames.
`If the T1 timer is cancelled and there are still some
`frames that have been sent that are not acknowledged, T1 should be started
`again.
`If the T1 timer runs out before an acknowledgement is received, the
`device should proceed to the retransmission procedure in 2.4.4.9.
`
`'
`
`25
`
`Page 000043
`
`
`
`AX.25 Amateur Packet-Radio Link-Layer Protocol
`
`I
`
`2.4.4.6 Receiving Reject
`Upon receiving a REJ frame, the transmitting DXE will set its send
`state variable to the same value as the REJ frame's received sequence number
`in the control field.
`The DXE will then retransmit any I frame(s) outstanding
`at the next available opportunity conforming to the following:
`1.
`If the DXE is not transmitting at the time, and the channel is open,
`the device may commence to retransmit the I frame(s) immediately.
`If the DXE is operating on a full-duplex channel transmitting a U1 or
`8 frame when it receives a REJ frame,
`it may finish sending the UI or
`S frame and then retransmit the I frame(s).
`1
`If the DXE is operating in a full-duplex channel transmitting another
`1 frame when it receives a REJ frame, it may abort the I frame it was
`sending and start retransmission of the requested I frames
`immediately.
`4. The DXE may send just the one I frame outstanding, or it may send
`more than the one indicated if more I frames followed the first one
`not acknowledged, provided the total to be sent does not exceed the
`flow-control window (7 frames).
`If the DXE recives a REJ frame with the poll bit set, it should
`respond with either a RR or RNR frame with the final bit set before
`retransmitting the outstanding I frame(sL
`
`[
`
`2.
`
`3.
`
`2.4.4.7 Receiving a RNR Frame
`it shall stop transmission of I
`[
`Whenever a DXE receives a RNR frame,
`frames until the busy condition has been cleared.
`If timer Tl runs out after
`the RNR was received,
`the waiting acknowledgement procedure listed in 2.4.4.9,
`below, should be performed. The poll bit may be used in conjunction with 5
`frames to test for a change in the condition of the busied—out DXE.
`1
`2.4.4.8 Sending a Busy Indication
`Whenever a DXE enters a busy condition, it will indicate this by
`sending a RNR response at the next opportunity. While the DXE is in the busy
`condition,
`it may receive and process S frames, and if a received S frame has
`the P bit set to one, the DXE should send a RNR frame with the F bit set to
`one at the next possible opportunity.
`To clear the busy condition, the DXE
`should send either a RR or REJ
`frame with the received sequence number equal
`to the current receive state variable, depending on whether the last received
`I frame was properly received or not.
`
`26
`
`I""""""""""""'-"IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII
`
`Page 000044
`
`
`
`AX.25 Amateur Packet-Radio Link—Layer Protocol
`
`2.4.4.9 Waiting Acknowledgement
`
`from the other DXE
`If timer Tl runs out waiting the acknowledgement
`I
`for an I frame transmitted, the DXE will restart timer T1 and tramsmit an
`appropriate supervisory command frame (RR or RNR) with the P bit set.
`If the
`DXE receives correctly a supervisory response frame with the F bit set and
`with an N(R) within the range from the last N(R) received to the last N(S)
`sent plus one,
`the DXE will restart timer T1 and will set its send state
`variable V(S)
`to the received N(R).
`It may then resume with I
`frame
`transmission or retransmission, as appropriate. If, on the other hand, the
`DXE receives correctly a supervisory response frame with the F bit not set, or
`an I frame or supervisory command frame, and with an M11) within the range
`from the last N(R) received to the last N(S) sent plus one, the DTE will not
`restart timer T1, but will use the received N(R) as an indication of
`acknowledgement of transmitted I frames up to and including I frame numbered
`N(R)-1.
`
`If timer Tl runs out before a supervisory response frame with the F
`bit set is received,
`the DXE will retransmit an, appropriate supervisory
`command frame (RR or RNR) with the P bit set. After N2 attempts to get a
`supervisory response frame with the F bit set from the other DXE,
`the DXE will
`initiate a link resetting procedure as described in 2.4.6, below.
`]
`
`2.4.5 Frame Rejection Conditions
`1
`
`A DXE shall initiate the frame.-reset procedure when a frame is received
`[
`with the correct FCS and address field during the information-transfer state
`with one or more of the conditions in 2.3.4.3.3, above.
`Ior
`-‘
`‘
`
`the DXE will ask the other DXE to reset the
`Under these conditions,
`link by transmitting a FRMR response as outlined in 2.4.6.3, below.
`1
`
`After sending the FRHR frame, the sending DXE will enter the frame
`reject condition. This condition is cleared when the DH: that sent
`the FRMR
`frame receives a SABM or DISC command, or a DM response frame. Any other
`command received while the DXE is in the frame reject state will cause another
`FRMR to be sent out with the same information field as originally sent.
`
`In the frame rejection condition, additional I frames will not be
`[
`transmitted, and received I frames and S frames will be discarded by the DXE.]
`
`The DXE that sent the FRMR frame shall start the T1 timer when the
`F-RMR is sent.
`If no SABM or DISC frame is received before the timer runs out,
`the FRI-IR frame shall be retransmitted, and the T1 timer restarted as described
`in the waiting acknowledgement section (2.4.4.9) above.
`If the FRMR is sent
`N2 times without success,
`the link shall ‘be reset.
`
`2 .4 . 6 Resett ing Procedure
`
`The resetting procedure is used to initialize both directions of data
`2.4.6.1
`flow after a nonrecoverable error has occured. This resetting procedure is
`used in the information-transfer state of an AX.25 link only.
`
`
`
`I é
`
`27
`
`Page 000045