Hello World¶
Description¶
This Hello World application presents a basic usage of the SPARK Wireless Core. This is a good starting point for anyone wanting to design wireless links using the Wireless Core. This application creates a synchronized bidirectional link between 2 devices to exchange predetermined data.
Behavior¶
In this example, two devices are setup with the same behavior. Both devices transmit a packet to the other device. The payload consists of the string “Hello, World!”. Upon receiving the packet, the application prints the message with useful statistics on a serial interface.
To see the message, simply connect and configure a terminal emulator software to the device’s serial port on your PC.
The first device is set up as a “Coordinator” and the second as a “Node”. The Node device will synchronize its clock to the Coordinator device, ensuring that both devices are synchronized to the same time schedule.
The following diagram illustrates the general structure of the schedule used in this application.

Coordinator Device¶
LED0 toggles every time a packet is successfully transmitted to the Node (almost always on because of the high packet rate).
LED1 toggles every time a packet is successfully received from the Node (almost always on because of the high packet rate).
Interface |
Name |
Description |
---|---|---|
SW1 |
Reset Stats |
Reset the TX and RX statistics |
SW2 |
N/A |
N/A |
LED0 |
Transmission Success |
Toggle LED when a wireless transmission is successful. |
LED1 |
Reception Success |
Toggle LED when a wireless reception is successful. |
LED2 |
N/A |
N/A |
Node Device¶
LED0 toggles every time a packet is successfully transmitted to the Coordinator (almost always on because of the high packet rate).
LED1 toggles every time a packet is successfully received from the Coordinator (almost always on because of the high packet rate).
Interface |
Name |
Description |
---|---|---|
SW1 |
Reset Stats |
Reset the TX and RX statistics |
SW2 |
N/A |
N/A |
LED0 |
Transmission Success |
Toggle LED when a wireless transmission is successful. |
LED1 |
Reception Success |
Toggle LED when a wireless reception is successful. |
LED2 |
N/A |
N/A |
Configuration¶
Dual Radio¶
The Wireless Core supports a configuration called Dual Radio where a single board can make use of two physical transceivers of the same model (e.g. 2x SR1020) for increased RF coverage. By adding the global symbol “WPS_RADIO_COUNT 2” in the Hello-World Node build configuration, the Node can activate a section of the code that configures a second transceiver. This feature requires a custom board with two physical transceivers. The SPARK EVK board has only one transceiver, so it cannot be used to demonstrate this feature.
Important
Do not activate the dual radio feature if using a board, such as the SPARK EVK, that has only one physical transceiver or the code will not compile due to missing board support package functions.