[aprssig] Setting of the C bit in the AX.25

John Langner WB2OSZ wb2osz at comcast.net
Sat Oct 24 14:08:13 EDT 2015


Short answer:

For the source and destination, set the MSB of the SSID byte to 1.  It is
not used for APRS and can be ignored on receive.

For the digipeater addresses, the MSB is set to 0 initially and gets changed
as the packet gets retransmitted by digipeaters.

The LSB of the SSID byte indicates the end of the address part of the frame.


More details:

This is copied from the comments in
https://github.com/wb2osz/direwolf/blob/master/ax25_pad.c 



 An APRS UI frame starts with 2-10 addressses (14-70 octets):

 * Destination Address
 * Source Address
 * 0-8 Digipeater Addresses  (Could there ever be more as a result of
                                digipeaters inserting their own call
                                and decrementing the remaining count in
                                WIDEn-n, TRACEn-n, etc.?
                                NO.  The limit is 8 when transmitting AX.25
over the radio
                                However, communication with an IGate server
could have
                                a longer VIA path but that is only in text
form, not 
                                in an AX.25 frame.

 Each address is composed of:

 * 6 upper case letters or digits, blank padded.
        These are shifted left one bit, leaving the LSB always 0.
 * a 7th octet containing the SSID and flags.
        The LSB is always 0 except for the last octet of the address field.

 The final octet of the Destination has the form:

        C R R SSID 0, where,

                C = command/response = 1
                R R = Reserved = 1 1
                SSID = substation ID
                0 = zero

 The final octet of the Source has the form:

        C R R SSID 0, where,

                C = command/response = 1
                R R = Reserved = 1 1
                SSID = substation ID
                0 = zero (or 1 if no repeaters)

 The final octet of each repeater has the form:

        H R R SSID 0, where,

                H = has-been-repeated = 0 initially.
                        Set to 1 after this address has been used.
                R R = Reserved = 1 1
                SSID = substation ID
                0 = zero (or 1 if last repeater in list)

        A digipeater would repeat this frame if it finds its address
        with the "H" bit set to 0 and all earlier repeater addresses
        have the "H" bit set to 1.
        The "H" bit would be set to 1 in the repeated frame.

 In standard monitoring format, an asterisk is displayed after the last
digipeater with
 the "H" bit set.  No asterisk means the source is being heard directly.

 Example, if we can hear all stations involved,

        SRC>DST,RPT1,RPT2,RPT3:         -- we heard SRC
        SRC>DST,RPT1*,RPT2,RPT3:        -- we heard RPT1
        SRC>DST,RPT1,RPT2*,RPT3:        -- we heard RPT2
        SRC>DST,RPT1,RPT2,RPT3*:        -- we heard RPT3


 Next we have:

 * One byte Control Field       - APRS uses 3 for UI frame
                                   The more general AX.25 frame can have
two.

 * One byte Protocol ID                 - APRS uses 0xf0 for no layer 3

 Finally the Information Field of 1-256 bytes.

 And, of course, the 2 byte CRC.




More information about the aprssig mailing list