User Manual

Page 30 of 39
6.1.3 RF Messaging
Overview
The FreeStar module provides a versatile command set for communications
between modules. Depending on the application’s requirements, either short
or long address modes can be used. Short addressing mode uses a two
byte transceiver address, while long addressing mode uses eight byte
transceiver addresses. It is also possible to communicate between
transceivers using mixed addressing modes, hence a message can be sent
from a transceiver with a short address to another transceiver with a long
address or vice versa.
There is a single host message that is used to send data from one
transceiver to another and two host messages that are generated when a
message is received. When in the receive all mode of operation and a
message is received by a transceiver, host message type 0xA9 is generated
and sent out the serial port to the host. In the default mode of operation
(receive all mode disabled) host message type 0x95 is generated and sent
out the serial port to the host.
RF host messages consist of a standard header (start, length and type), RF
message header, payload, and a standard trailer (checksum and stop). The
RF message header contains a Packet ID, a Target/Sender identifier, an
Address Mode byte, and the Transceiver Addresses. The Packet ID is used
to identify each message and should be incremented for each new packet
when sending a message. The Target/Sender byte indicates where the
message originated from and is being sent to. Messages either are
originated from or sent to either the host or the application. The application
is the user application code that is running on the FreeStar module (currently
not supported). The host is the host application. The Address Mode byte
describes the type of addressing for the particular message. The upper
nibble indicates the addressing mode used for the destination of the
message, while the lower nibble indicates the mode for the source of the
message. A 0 is used to represent a short address, while a 1 represents a
long address. Following the Addressing Mode is the destination address and
then the source address (for received messages only – types 0x95 and
0xA9).
Short Addressing
In order to use short addressing it is required that the transceiver address be
set between 0 and 65,533 (0xFFFD). Setting the short address to 65,534
causes the transceiver module to use the eight byte long address.
Long Addressing
Long addressing mode is configured by setting the short address to 65,534
and then selecting a long address in the range of 0 to
18,446,744,073,709,551,614 (0xFFFFFFFFFFFFFFFE).
Broadcasts
It is possible to broadcast a message to all transceivers configured to the
same RF channel and PAN ID. Messages are broadcast by sending the
message to the short destination transceiver address 65,535 (0xFFFF).