Transparent UART Network

From InCircuit
Jump to: navigation, search

To divide the radio-network into multiple consecutive parts, the transparent UART application first uses a ID for each logical network. To radios communicating to each other must have the same NETID.

Contents

device IDs

Within one logical network, each radio has a own ID (MYID) and a default destination ID (DESTID).

The MYID is the the device ID, the module is using as its own. It will accept only packets to this specific ID and mark all outgoing packets to be from this ID.

The DESTID is the ID the module will send it's data to. It is possible to send data to other nodes using the PacketTXMode.

As a radio can't here it's own data, it is possible to have a device with the same MYID and DESTID. Having to such devices will create a bidirection configuration-less communication-channel between them. Using more than two devices in this configuration will work, but the transmission of each packet is verified against one destination only. There is no way to detect a packet loss on just part of the receivers.


PacketRXMode

If the first bit of the MYID is set (meaning any ID above 0x8000), the module will enter the PacketRXMode. In this mode each packet received over the air will be formatted before being transmitted over the serial line. The packets will look like this:

 s1111 d2222 #33 lqi44 rssi022 len008 [ 00 11 22 33 44 55 66 77 88]
  • s1111 marks the sending MYID
  • d1111 marks the destition ID of the packet; usually the modules MYID
  • #11 is a sequencing number. This will be incremented for each packet and is displayed as a hex value.
  • lqi44 shows the packet's LQI in decimal; a indicator for the link quality
  • rssi022 the packets RSSI in decimal. This is a indicator for the packets transmission strength.
  • len008 the number of payload-bytes (decimal)
  • [ ... ] each byte of the payload is rendered as it's hexadecimal representation

Broadcast

Sending a packet to the destination ID 0xFFFF, will transmit this to every radio within this network; performing a network broadcast, effectively.

Network configuration

to change the configuration of a modul, the connected control first has to send the character 0x12 (^R). This will change into the network configuration mode and provide a interactive menu.

 Enter Configmode? <y> y
 Reset EEPROM
 CHANNEL :11 -> 11
 NETID   :0x1111 -> 0x1111
 MYID    :0x0011 -> 0x0011
 DSTID   :0x0010 -> 0x0010
 Max Retries  :0xFF -> FF
 
 ICradio-Uart-Bridge v1.3
 CHANNEL=11
 NETID  =0x1111
 MYID   =0x0011
 DSTID  =0x0010
 
 radio init...done

First a security question, wether the configuration should be changed must by answered by sending a 'y'-character. Any other character will leave the configuration immediatly. Afterwards the radio-channel, the modul should be using, must be entered. Two networks with the same ID but on different channels can't communicate with each other. Afterwards the IDs described above must be entered.

Personal tools