This version (21 Jan 2020 12:48) was approved by Pranit Jadhav.

RapidNet IP DeviceServer Userguide


                       RapidNet IP gateway bloack diagram

RapidNet IP allows gateway applications to communicate with the network through the deviceServer.

Starting the deviceServer

Required files - deviceServer executable and deviceServer_config.ini

  • Windows- The required files can be found in \RapidNet-IP-Rel1.1.2\Tools\RapidNet-IP-Demo_App\config
  • Linux (Raspberry Pi) - The required files can be found in \RapidNet-IP-Rel1.1.2\Manager\deviceServer\RaspberryPi


  1. Create a folder named “config” in the same directory as the deviceServer executable
  2. Place deviceServer_config.ini in the “config” folder
  3. Run the deviceServer executable via command prompt/terminal
Instructions to run the deviceServer-


  1. Open a command prompt in the same directory as deviceServer.exe
  2. Type “deviceServer.exe” in the commandline and press the Enter key.


  1. Open a terminal window in the same directory as deviceServer
  2. Type the following commands and press the Enter key after each-
    • sudo chmod 555 deviceServer
    • sudo ./deviceServer –v

Configuring the deviceServer/LBR

The deviceServer_config.ini file defines the runtime configuration for the deviceServer/LBR, such as-

  • LBR communication parameters such as COM port, baud rate
  • RapidNet network parameters such as PAN ID, ISM band, datarate
  • Debug preferences

Message queues

The gateway application is required to send and receive packets via message queues provided by the host operating system. The message queue names used by the deviceServer are defined in deviceServer_config.ini –

  • ds_rxq_name=/rfm_host_app_rxq #Message queue used by deviceServer to receive messages from app.
  • ds_txq_name=/rfm_host_app_txq #Message queue used by deviceServer to transmit messages to app.
Ensure that message queuing is enabled in the operating system being used
  • It may be enabled by default for linux systems
  • It is disabled by default for windows systems. Please find instructions on how to enable it on page 6 of the Sensor integration guide (available in the path \RapidNet-IP-Rel1.1.2\Docs)

Gateway application

Gateway application flow

deviceServer APIs

The RapidNet API guide provides a list of APIs to be used by gateway applications by exchanging request/response packets with the deviceServer. Some important APIs are-

  • DS_UPDATE_LN_DATA_REQ – send data to one or multiple nodes in the network.
  • DS_ADD_LN_PREFERRED_PARENT_REQ – set the preferred parent node for one or more nodes in the network.
  • DS_GET_REGISTERED_LN_LIST_REQ - get the list of registered Motes
  • DS_LBR_NWK_READY_IND – indication given by the deviceServer when the network has been started successfully
  • DS_LN_REG_IND – indication given by the deviceServer when a node registers with the network
  • DS_LN_APP_DATA_IND – indication given by the deviceServer when application data is received from a node

Packet format


  • MID – request/confirmation message ID
  • ML – message length in bytes (including ML and MID)
  • Message data – message data based on MID

The full list of APIs with details of MID, message data and expected response can be found in the RapidNet API guide.

Example - Requesting current state of a node from the deviceServer
  1. The DS_GET_LN_STATE_REQ API is used to request the current state of a node.
  2. Send a DS_GET_LN_STATE_REQ to the deviceServer by writing the packet from below figure into the RX message queue of the deviceServer (ds_rxq_name)
  3. After performing necessary operations, the deviceServer responds with a DS_GET_LN_STATE_CONF which should be read from the TX message queue of the deviceServer (ds_txq_name)

                                            Example DS_GET_LN_STATE_REQ packet

                                            Example DS_GET_LN_STATE_CONF packet

Example applications

Example applications are provided for the linux operating system in the RapidNet software package, they can be found in the path- \RapidNet-IP-Rel1.1.2\Manager\application\appsOnLinux\


Example application uses the DS_ADD_LN_LIST_REQ, DS_ADD_AP_LIST_REQ and DS_ADD_LN_PREFERRED_PARENT_REQ commands to add a list of LNs, APs and set the preferred parents for the list of LNs. It then uses the DS_UPDATE_LN_DATA_REQ command to send data to the list of nodes periodically.


Example application uses the DS_OTA_FU_FOR_LN_REQ API to update the firmware for a hardcoded list of end nodes.


Example application provides code snippets to test various APIs such as-

resources/eval/user-guides/rapidnet-ip/deviceserver-userguide.txt · Last modified: 21 Jan 2020 12:25 by Aditya S