This is the multi-page printable view of this section. Click here to print...

Return to the regular view of this page

As of 2025-07-24

TWELITE APPS

Ready-made software for signal transmission and serial communication, ready to use without software development.
TWELITE APPS - Twilight Apps are ready-made software for TWELITE that can be used as is without software development.

What is Interactive Mode

Interactive mode is the mode to perform detailed settings of TWELITE APPS.

You can make necessary settings when you want to communicate with multiple groups or reduce communication errors.

Connection with PC

For TWELITEFor MONOSTICK
Attach the TWELITE R series to the 7P interface prepared on the parent board and connect to the PC using a USB cable.Connect the MONOSTICK to the PC’s USB port. TWELITE R series is not required.
Connection between TWELITE (SMD) and PC

Connection between TWELITE (SMD) and PC

Connection between MONOSTICK and PC

Connection between MONOSTICK and PC

For TWELITE DIP (BLUE/RED)For Others
Attach to TWELITE R series and connect to the PC using a USB cable.For TWELITE series with 7P interface, attach TWELITE R series and connect to the PC using a USB cable.
Connection between TWELITE DIP (BLUE/RED) and PC

Connection between TWELITE DIP (BLUE/RED) and PC

Connection between other TWELITE series and PC

Connection between other TWELITE series and PC

Switching to Interactive Mode

When Using TWELITE STAGE

TWELITE STAGE APP is an integrated development tool that includes firmware writing and configuration of TWELITE, as well as a function to display received data.

  1. Launch TWELITE STAGE APP
Main menu of TWELITE STAGE APP

Main menu of TWELITE STAGE APP

  1. Select “Interactive Mode” from the menu of TWELITE STAGE APP

When Using Terminal Software

You can also use general terminal software.

  1. Launch terminal software on the PC (communication settings: 115200bps/8-N-1)
  2. Reset TWELITE.
  3. Slowly press the + key on the PC keyboard three times (interval 0.2 to 1 second). If it does not work well, keep entering + repeatedly.

To exit interactive mode, press + three times again.

Operation of Interactive Mode

Interactive mode displays a screen like the following.

--- CONFIG/TWELITE APP V1-00-2/SID=0x81000038/LID=0x78 ---
 a: set Application ID (0x67720102)
 i: set Device ID (--)
 c: set Channels (18)
 t: set mode4 sleep dur (1000ms)
 y: set mode7 sleep dur (10s)
 f: set mode3 fps (32)
---
 S: save Configuration
 R: reset to Defaults

The displayed content varies depending on the firmware type and version.

Steps

  1. Select value: press the first letter alphabet
  2. Specify value: input the value
  3. Confirm value: press Enter
  4. Save value: press S (uppercase)
  5. Apply value: restart TWELITE

Values in parentheses indicate the current setting.

Pressing R (uppercase) resets to default values (apply with S).

Example of Operation

To set the Application ID to 0xBEEFCAFE, input as follows:

Input Application ID (HEX:32bit): BEEFCAFE

Common Settings for TWELITE APPS

Frequency channel, application ID, device ID, retry count, and transmission output settings are common to TWELITE APPS.

Application ID and Frequency Channel

Image of Grouping

Image of Grouping

Devices must have the same application ID and frequency channel to communicate.

a: Application ID

Setting the same value to all devices communicating allows logical network separation.

TWELITE discards packets received from devices with different application IDs. Therefore, multiple groups can be established within the same frequency channel.

c: Frequency Channel

Setting the same value to all devices communicating allows physical network separation.

TWELITE conforms to the IEEE802.15.4 standard and divides the 2.4GHz band into 16 channels.

List of Frequency Channels

List of Frequency Channels

To change the frequency channel, press c (lowercase).

Default Values for Each TWELITE APP

TWELITE APPSApplication IDFrequency Channel
Super Simple! Standard App (App_Twelite)0x6772010218
Remote Control App (App_IO)0x6772010716
Serial Communication App (App_Uart)0x6772010318
Wireless Tag App (App_Tag)0x6772630515
Pulse App (App_PAL)0x6772630515
Queue App (App_CUE)0x6772010218
Aria App (App_ARIA)0x6772010218
Parent/Relay App (App_Wings)0x6772010218

i: Logical Device ID

The logical device ID is used to identify each device. You can assign logical IDs to each device.

Image of Assigning Logical Device ID

Image of Assigning Logical Device ID

When using multiple child devices for one parent device, assign different IDs (1 to 100) to each child device.

x: Transmission Output and Retry Count

You can weaken the transmission output to narrow the effective radio transmission range. However, power consumption does not change, so normally use the maximum output.

Retry count refers to the number of additional transmissions per one transmission request. Setting retry count may improve data arrival rate in poor communication environments. However, communication time and power consumption increase accordingly.

In interactive mode, input a two-digit number.

  • Tens place: retry count
    • 1 to 9 times
    • 0 is the default value for each app
    • F disables retry
  • Ones place: transmission output
    • 3 is the strongest
    • 2/1/0 each step down reduces output by -11.5dB

Examples

  • 32 → Retry 3 times, output one level weaker
  • 93 → Retry 9 times, maximum output

Resetting Settings

Some settings may interfere with operation (such as baud rate changes).

You can reset settings by the following steps.

  1. Rewrite to another app
  2. Switch to interactive mode
    • Reset with R
    • Save with S
  3. Write back to the original app

App-specific Settings for Each TWELITE APP

For settings that differ between apps, please see the following pages.

1 - TWELITE APPS (Unified) Manual

Unified firmware that consolidates all TWELITE APPS
Mainly for the TWELITE GOLD series, this firmware integrates TWELITE APPS such as the Extremely Simple! Standard App App_Twelite, allowing functionality to be switched without rewriting.

1.1 - TWELITE APPS (Unified) Manual

Latest Edition
TWELITE_Apps is a firmware that integrates TWELITE APPS such as the Extremely Simple! Standard App App_Twelite, allowing users to switch functionalities without rewriting. It’s like an assortment pack of TWELITE APPS.

Overview

The unified firmware bundles the following TWELITE APPS:

Switching involves a reset, but it can be performed from software without rewriting the firmware.

How to Switch

1. Open Interactive Mode

Access the Interactive Mode of TWELITE APPS and enter : (AppSel).

[CONFIG MENU/App_Wings:PARENT:0/v1-03-2/SID=8300051A]
a: (0x67720102) Application ID [HEX:32bit]
c: (18        ) Channel(s)
x: (      0x03) RF Power/Retransmissions [HEX:8bit]
b: (115200,8N1) UART Baud Alt. [XXXXX]
o: (0x00000000) Option bits [HEX:32bit]
t: (0xA5A5A5A5) Encryption key [HEX: 32bits]

[ESC]:Exit [!]:Reset System [*]:Extr Menu [:]:AppSel

2. Open the TWELITE APPS List

A menu like the following will display a list of TWELITE APPS:

[TWELITE AppSel/v0-02-1/SID=8300051A/SAVE=04-12-01]
M: AppSel           App selector (this screen)
R: Revert to DEFAULT(*DEF)
A: App_Twelite      Standar app. (App_Twelite)
B: App_IO           App for remote. (App_IO)
C: App_UART         App for SERIAL comm. (App_Uart)
D: App_Wings        Parent/Repeater (App_Wings)(*DEF)
E: App_OTA          OTA Apps for ARIA/CUE.

[!]:Reset [R]:Revert [$]:LANG=English

3. Select a TWELITE APP

Just like in Interactive Mode, you can switch to a TWELITE APP by entering the command ID letter.

For example, in the above example, entering C switches to App_Uart.

[App_UART / App for SERIAL comm. (App_Uart)]
Designed for UART (Serial) communications. UART is commonly used on MCUs.

=== Please select from the list below. Save the startup application. ===
1: Normal
2: for TWELITE UART

[BS]:Back

Initialize TWELITE APP

On the TWELITE APP list screen, entering R will revert to the default TWELITE APP.

! Clear Save Data? The next key will perform:
S: Clear App Selection.
!: Clear ALL SAVE DATA.

[BS]:Back

2 - Extremely Simple! Standard App Manual

Transmission of digital and analog signals
The input/output states of parent and child devices are synchronized. An all-in-one package supporting 4 digital ports, 4 analog ports, serial, and I2C. Simplified with versatile features, but does not focus on processing speed, responsiveness, or power saving.

2.1 - Extremely Simple! Standard App Manual

Latest Edition

Download

To install the Extremely Simple! Standard App (App_Twelite), install the TWELITE STAGE SDK and rewrite using the TWELITE STAGE App.

2.1.1 - Pin Assignments of Extremely Simple! Standard App

Functions of pins used by the Extremely Simple! Standard App
Functions and arrangements of pins used by the Extremely Simple! Standard App (App_Twelite)

Pin Assignments

Pin Assignment Table

Pin Assignment Table

Pin NameFunction
VCC GNDPower Input
DIx AIxDigital/Analog Input
DOx PWMxDigital/Analog Output
TX RXUART
SCL SDAI2C
Mx BPSConfiguration Input
RSTReset Input

Power Input

Connect a 3.3V (2.3-3.6V) power supply to VCC/GND.

Digital and Analog Input/Output

DIx/DOx, AIx/PWMx pins transmit signals synchronously with matching pin numbers.

DigitalAnalog
Input on DIx → Output on DOxInput on AIx → Output on PWMx

Serial Communication

UART

TX/RX are used for UART transmission and reception. Specifically, they are used in the following cases:

I2C

SCL/SDA pins are used to connect I2C target devices.

Configuration Input

By leaving the Mx pins unconnected or connecting them to GND, you can switch operation modes such as parent, child, and repeater (Operation Modes).

By leaving the BPS pin unconnected or connecting it to GND, you can change the UART baud rate from 115200bps to other values (Alternative Baudrate).

Reset Input

By connecting a push button between the reset input pin RST and GND, you can implement a reset button. RST is internally pulled up.

2.1.2 - Operating Modes of Extremely Simple! Standard App

Explanation of each operating mode
The Extremely Simple! Standard App (App_Twelite) has seven operating modes.

List of Operating Modes

Each mode is set by leaving the Mx pin unconnected or connecting it to GND.

M3M2M1ModeFunctionPowerSavingInitialLID
OOOChild: ContinuousSends input status to parent, and always waits for received data to reflect on output120
OOGParent: ContinuousSends input status to child, and always waits for received data to reflect on output0
OGORepeater: ContinuousAlways waits for received data and relays it122
OGGChild: Continuous 0.03sFrequently sends input status to parent, and always waits for received data to reflect on output123
GOOChild: Intermittent 1sSends input status to parent every 1 second, and disables reception to always enter power-saving mode124
GOGChild: Intermittent Reception 1sSends input status to parent every 1 second, and simultaneously performs reception, always entering power-saving mode125
GGO-Unused--
GGGChild: Intermittent 10sSends input status to parent every 10 seconds, and disables reception to always enter power-saving mode127

O: Not connected (OPEN), G: Connected to GND

Initial state is Child: Continuous mode.

The initial Logical Device ID (LID) used to identify the device varies depending on the mode.

Parent Device

Continuous Mode

Parent: Continuous Mode

When input signals change or every 1 second, data is sent to all child devices.

It always waits for data sent from child devices, providing good responsiveness but continuously consuming power.

  • Reception: Always waiting
  • Transmission: On input change / every 1 second

Child Device

Continuous Mode

Child: Continuous Mode

When input signals change or every 1 second, data is sent to all parent devices.

It always waits for data sent from parent devices, providing good responsiveness but continuously consuming power.

Communication image with parent device

Communication image with parent device

  • Reception: Always waiting
  • Transmission: On input change / every 1 second

Child: Continuous 0.03s Mode

This mode shortens the periodic transmission interval of Child: Continuous Mode from 1 second to 0.03 seconds.

Although it always waits for data sent from the parent, the communication from child to parent occupies the bandwidth, making the parent’s input response slower. It continuously consumes power.

Communication image with parent device

Communication image with parent device

  • Reception: Always waiting
  • Transmission: On input change / every 0.03 seconds

Intermittent Mode

Child: Intermittent 1s Mode

When input signals change or every 1 second, power-saving mode is canceled and data is sent to all parent devices.

Reception is disabled, so control from the parent device is not possible. This mode has excellent power-saving performance.

Communication image with parent device

Communication image with parent device

  • Reception: Disabled
  • Transmission: On input change / every 1 second

Child: Intermittent 10s Mode

When input signals change or every 10 seconds, power-saving mode is canceled and data is sent to all parent devices.

Reception is disabled, so control from the parent device is not possible. This mode has excellent power-saving performance.

Communication image with parent device

Communication image with parent device

  • Reception: Disabled
  • Transmission: On input change / every 10 seconds

Child: Intermittent Reception 1s Mode

When input signals change or every 1 second, power-saving mode is canceled and data is sent to all parent devices.

Reception is also performed every 1 second. It has excellent power-saving performance but is inferior to Child: Intermittent 1s Mode.

Communication image with parent device

Communication image with parent device

  • Reception: Every 1 second
  • Transmission: On input change / every 1 second

Repeater

Continuous Mode

Repeater: Continuous Mode

The repeater forwards received packets.

Up to three repeaters can be installed between parent and child devices, but increasing repeaters increases the number of packets, which may cause interference.

Image of relaying

Image of relaying

  • Reception: Always waiting
  • Transmission: On reception

2.1.3 - Alternative Baud Rate Setting for Extremely Simple! Standard App

Changing the baud rate used for UART communication
The Extremely Simple! Standard App (App_Twelite) uses 115200 bps as the default baud rate for UART communication, but this can be changed.

Enabling Alternative Baud Rate Setting

You can enable the alternative baud rate setting by connecting the BPS pin to GND.

BPSDescriptionBaud RateRemarks
ODefault115200bps
GOverride Setting38400bpsCan be changed via Interactive Mode

O: Not connected (OPEN), G: Connected to GND

2.1.4 - UART Function of Extremely Simple! Standard App

Data format used in UART function
This explains the data format used in the UART function of the Extremely Simple! Standard App (App_Twelite).

Digital and Analog Input/Output

0x81: Status Notification from Remote Device

Outputs the state of the received input signals.

Data Format

#DataContentNote
charHeader: only
0uint8Source Logical Device ID
1uint8Command Number0x81 only
2uint8Packet IdentifierGenerated from Application ID
3uint8Protocol Version0x01 only
4uint8LQI0-255
5uint32Source Serial ID0x8???????
9uint8Destination Logical Device ID
10uint16Timestamp64 counts per second
12uint8Relay Count
13uint16Power Supply VoltageUnit is mV
15int8-(Unused)
16uint8Digital SignalsCorresponds to DIx from LSB, 0 is High
MSB 1 means periodic transmission
17uint8Digital Signal MaskCorresponds to DIx from LSB, 1 is valid
18uint8Conversion Value of AI1See Calculation of Analog Signals, 0xFF means unused
19uint8Conversion Value of AI2See Calculation of Analog Signals, 0xFF means unused
20uint8Conversion Value of AI3See Calculation of Analog Signals, 0xFF means unused
21uint8Conversion Value of AI4See Calculation of Analog Signals, 0xFF means unused
22uint8Correction Value of AIxCorresponds to AIx in 2-bit units from LSB
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Calculation of Analog Signals

The input voltage \(V\) of AIx can be expressed using the received conversion value \(e_{r}\) and correction value \(e_{fr}\) as follows:

$$\begin{align*} V &= e+e_f \\ \text{where} \\ e &= 16e_r \\ e_f &= 4e_{fr} \\ \end{align*}$$

Unit: mV

Example Output Data

:78811501C98201015A000391000C2E00810301FFFFFFFFFB

0x80: Remote Device Output Change

Controls the output signals of the remote device.

Data Format

#DataContentNote
charHeader: only
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command Number0x80 only
2uint8Format Version0x01 only
3uint8Digital SignalsCorresponds to DOx from LSB, 0 is High
4uint8Digital Signal MaskCorresponds to DOx from LSB, 1 is valid
5uint16PWM1 Signal0-1024, 0xFFFF means disabled
7uint16PWM2 Signal0-1024, 0xFFFF means disabled
9uint16PWM3 Signal0-1024, 0xFFFF means disabled
11uint16PWM4 Signal0-1024, 0xFFFF means disabled
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

UART Input/Output

0x01: Transmission of Arbitrary Data

Data Format

#DataContentNote
charHeader: only
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command Number0x01 only
2[uint8]Arbitrary DataByte sequence of length \(N\) (recommended \(N\leqq80\))
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0x01: Reception of Arbitrary Data

Data Format

#DataContentNote
charHeader: only
0uint8Source Logical Device IDParent 0x00, Child 0x01-0x64, Unset Child 0x78
1uint8Command Number0x01 only
2[uint8]Arbitrary DataByte sequence of length \(N\)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

I2C Input/Output

0x88: I2C Input

Data Format

#DataContentNote
charHeader: only
0uint8Destination Logical Device IDParent 0x00, Child 0-0x7F, All Children 0x78, Self 0xDB
1uint8Packet Identifier0x88 only
2uint8Response NumberNumber output to response message
3uint8Command NumberWrite 0x1, Read 0x2, Read/Write 0x4
4uint8I2C Address7-bit
5uint8I2C CommandFirst command byte
6uint8Data Size0 means none
7[uint8]DataByte sequence of length \(N\)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0x89: I2C Output

Data Format

#DataContentNote
charHeader: only
0uint8Source Logical Device IDParent 0x00, Child 0-0x7F, All Children 0x78, Self 0xDB
1uint8Packet Identifier0x89 only
2uint8Response NumberNumber output to response message
3uint8Command NumberWrite 0x1, Read 0x2, Read/Write 0x4
4uint8ResultFailure 0, Success 1
5uint8Data Size0 means none
6[uint8]DataByte sequence of length \(N\)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

2.1.5 - Interactive Mode (Extremely Simple! Standard App)

Detailed configuration changes via Interactive Mode
You can perform detailed configuration of the app via Interactive Mode.

This section explains functions specific to the Extremely Simple! Standard App (App_Twelite). For common features, please refer to the TWELITE APPS manual top page.

Display Example

The following screen is displayed.

--- CONFIG/TWELITE APP V1-08-2/SID=0x8201001f/LID=0x78 ---
 a: set Application ID (0x67720102)
 i: set Device ID (--)
 c: set Channels (18)
 x: set Tx Power (03)
 t: set mode4 sleep dur (1000ms)
 y: set mode7 sleep dur (10s)
 f: set mode3 fps (32)
 z: set PWM HZ (1000,1000,1000,1000)
 o: set Option Bits (0x00000000)
 b: set UART baud (38400)
 p: set UART parity (N)
---
 S: save Configuration
 R: reset to Defaults

Commands

Command ItemDefaultRemarks
aApplication ID0x6772010232bit
iLogical Device IDAutoChild 1-100, Parent 121, Relay 122
cFrequency Channel1811-26
xTransmission Output and Retry Count03
Retry Count01-9 times, 0 means default 2 times, F disables
Transmission Output30-3
tChild Intermittent 1-second Mode Interval1000100-10000 ms
yChild Intermittent 10-second Mode Interval102-10000 s
fChild Continuous 0.03-second Mode Cycle324/8/16/32 times per second
zPWMx Frequency10001-64000 Hz, individually set by comma separation
oOption Bits0x00000000Other detailed settings
bUART Alternative Baud Rate38400Enabled by BPS pin
pUART ParityN8-( N/O/E )-1

Details of each command are shown below.

a: Application ID

All devices communicating must share the same value. It logically separates networks.

i: Logical Device ID

Set when it is necessary to identify multiple child devices.

Set any value from 1 to 100 for child devices, 121 for parent devices, and 122 for relay devices.

c: Frequency Channel

All devices communicating must share the same value. It physically separates networks.

x: Transmission Output and Retry Count

Specify the radio transmission output and the number of additional packet transmissions.

t: Child Intermittent 1-second Mode Interval

Overrides the intermittent interval of the child intermittent 1-second mode from 1 second to another value. Unit is milliseconds.

Setting 0 disables periodic wakeup by timer. In this case, wakeup occurs on falling edge of DIx but not on rising edge.

y: Child Intermittent 10-second Mode Interval

Overrides the intermittent interval of the child intermittent 10-second mode from 10 seconds to another value. Unit is seconds.

Setting 0 disables periodic wakeup by timer. In this case, wakeup occurs on falling edge of DIx but not on rising edge.

f: Child Continuous 0.03-second Mode Cycle

Overrides the number of transmission requests per second from 32 times to 4/8/16 times. Retry count is not included.

z: PWMx Frequency

If one value is specified, it overrides the frequency of all PWM ports. If specified by comma separation, individual values for PWM1 to PWM4 can be overridden.

o: Option Bits

Specify a 32bit number. Enables settings linked to each bit.

Target BitSetting ItemInitialTransmissionReceptionContinuousIntermittent
0x00000001Low Latency Mode0️⃣
0x00000002Disable Periodic Transmission0️⃣
0x00000004Disable Periodic Transmission and UART Output0️⃣
0x00000010Disable Transmission on AIx Change0️⃣
0x00000020Disable AIx Value0️⃣
0x00000040Change PWMx Calculation Formula0️⃣
0x00000100Transmit Only When Button Pressed0️⃣
0x00000800Disable Internal Pull-up of DIx0️⃣
0x00008000Add Relay Function to Child0️⃣
0x00001000Set Max Relay Steps to 2 for Child Relay0️⃣
0x00002000Set Max Relay Steps to 3 for Child Relay0️⃣
0x00010000Invert PWMx Waveform0️⃣
0x00020000Turn Off PWMx After Startup0️⃣
0x00080000Alternative Port Assignment0️⃣
0x00100000Turn Off DOx for 2 Seconds After Startup0️⃣
0x00400000Invert DOx Output0️⃣
0x00800000Disable Internal Pull-up of DOx0️⃣

b: UART Alternative Baud Rate

Overrides the alternative baud rate selected when the BPS pin is connected to GND at startup from 38400bps.

Values can be selected from 9600/19200/38400/57600/115200/230400. Specifying other values may cause errors.

p: UART Parity

N means no parity, O means odd parity, and E means even parity.

Data bits are fixed to 8, stop bits to 1. Hardware flow control cannot be set.

Details of Option Bits

Explanation of settings linked to each bit of the Option Bits value.

00000001: Low Latency Mode

Low Latency Mode shortens the delay on the receiver side by quickly transmitting after detecting changes in DIx.

00000002: Disable Periodic Transmission

Disables periodic transmission every 1 second in continuous mode for child devices.

00000004: Disable Periodic Transmission and UART Output

For child devices: disables periodic transmission every 1 second in continuous mode and stops UART output of received data.

00000010: Disable Transmission on AIx Change

For child devices: disables transmission when AIx input changes in continuous mode.

Since released AIx ports report undefined values, connect them to VCC when analog input is not used. This option allows omission of connection to VCC.

00000020: Disable AIx Value

Sends packets treating unused ports as 0xFFFF without using ADC measurement values.

00000040: Change PWMx Calculation Formula

By default, adjusted output for volume control is applied to PWMx.

This option disables that and outputs full scale for inputs below 1.8V.

00000100: Transmit Only When Button Pressed

Continuously transmits packets when DIx input is Low.

For example, used to remotely control a motor. The motor runs while the remote button is pressed and stops when the radio signal is lost.

00000800: Disable Internal Pull-up of DIx

Disables all internal pull-ups (about 50kΩ) of DIx.

00008000: Add Relay Function to Child

Adds relay function to child devices in continuous mode. Maximum relay steps is 1.

00001000: Set Max Relay Steps to 2 for Child Relay

Changes maximum relay steps to 2 when 00008000: Add Relay Function to Child is set.

00002000: Set Max Relay Steps to 3 for Child Relay

Changes maximum relay steps to 3 when 00008000: Add Relay Function to Child is set.

00010000: Invert PWMx Waveform

Inverts the output waveform of PWMx.

When maximum value is input to AIx, PWMx becomes Low.

00020000: Turn Off PWMx After Startup

Sets PWMx output to Low state after startup or reset.

00080000: Alternative Port Assignment

Enables alternative port assignment.

Connecting transistors etc. to PWM2/PWM3 may cause unstable operation (Details). Use this option in such cases.

00100000: Turn Off DOx for 2 Seconds After Startup

Sets DOx to Low state for 2 seconds after startup or reset.

You can light LEDs connected to DOx at startup.

00400000: Invert DOx Output

Inverts DOx output.

Unlike the initial state, when one DI is Low level, the other DO is High level.

00800000: Disable Internal Pull-up of DOx

Disables all internal pull-ups (about 50kΩ) of DOx.

3 - Parent and Repeater App Manual

For data aggregation and communication range extension.
This app receives and relays packets from TWELITE APPS such as Extremely Simple! Standard App and Pal App, as well as act.

3.1 - Parent and Repeater App Manual

v1.3.2 GOLD Latest version
Acts as parent or repeater for child devices of TWELITE APPS and act.

Features

Can process all data packets of TWELITE APPS and act, and can be used as common parent or repeater.

  • Collect data from multiple TWELITE APPS and act such as Extremely Simple! Standard App and Pal App with one MONOSTICK.
  • Can operate multiple systems separately on 16 channels.
  • By setting application ID, multiple systems can coexist on the same channel.
  • Communication range extension with repeater function.

3.1.1 - Operating Modes of Parent and Repeater App

Operating modes of Parent and Repeater App

There are two modes: Parent mode and Repeater mode.

3.1.1.1 - Parent Mode of Parent and Repeater App

Receives data from child devices and sends data to child devices

Receives data sent from child devices and outputs it via the serial port. Also sends commands input from the serial port to child devices.

3.1.1.1.1 - Messages of Parent and Repeater Apps

Output when data is received from child devices

Receives data sent from child devices and outputs it from the serial port in a predefined format.

3.1.1.1.1.1 - Output from the Extremely Simple! Standard App (Parent and Repeater App)

Output format when receiving data from the Extremely Simple! Standard App

0x81: Status Notification from the Peer Device

Outputs the status of the received input signals.

Data Format

#DataDescriptionNotes
charHeaderOnly :
0uint8Logical Device ID of Sender
1uint8Command NumberOnly 0x81
2uint8Packet IdentifierGenerated from Application ID
3uint8Protocol VersionOnly 0x01
4uint8LQI0-255
5uint32Serial ID of Sender0x8???????
9uint8Logical Device ID of Receiver
10uint16Timestamp64 counts per second
12uint8Number of Relays
13uint16Power Supply VoltageUnit: mV
15int8-(Unused)
16uint8Digital SignalsCorresponds to DIx from LSB upwards, 0 means High
If MSB is 1, periodic transmission
17uint8Digital Signal MaskCorresponds to DIx from LSB upwards, 1 means valid
18uint8Converted Value of AI1See Calculation of Analog Signals, 0xFF means unused
19uint8Converted Value of AI2See Calculation of Analog Signals, 0xFF means unused
20uint8Converted Value of AI3See Calculation of Analog Signals, 0xFF means unused
21uint8Converted Value of AI4See Calculation of Analog Signals, 0xFF means unused
22uint8Correction Value of AIxCorresponds to AIx in 2-bit increments from LSB upwards
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Calculation of Analog Signals

The input voltage \(V\) of AIx can be expressed by the received converted value \(e_{r}\) and the correction value \(e_{fr}\) as follows:

$$\begin{align*} V &= e+e_f \\ \text{where} \\ e &= 16e_r \\ e_f &= 4e_{fr} \\ \end{align*}$$

The unit is mV

Example of Output Data

:78811501C98201015A000391000C2E00810301FFFFFFFFFB
#DataDescriptionValue
:charHeader:
780uint8Logical Device ID of Sender0x78
811uint8Command Number0x81
152uint8Packet Identifier0x15
013uint8Protocol Version0x01
C94uint8LQI201/255
8201015A5uint32Serial ID of Sender0x201015A
009uint8Logical Device ID of Receiver0x00
039110uint16TimestampApprox. 14.27 seconds
0012uint8Number of Relays0
0C2E13uint16Power Supply Voltage3118 mV
0015int8-
8116uint8Digital SignalsDI1 L DI2 H
DI3 H DI4 H
(Periodic transmission)
0317uint8Digital Signal MaskDI1 DI2
0118uint8Converted Value of AI116 mV
FF19uint8Converted Value of AI2Unused
FF20uint8Converted Value of AI3Unused
FF21uint8Converted Value of AI4Unused
FF22uint8Correction Value of AIxAI1 0x03
FBuint8Checksum0xFB
charFooter\r
charFooter\n

Data Identification Conditions

The parent and relay apps can receive data from various types of child devices.

To confirm whether the output data is from the Extremely Simple! Standard App, refer to the following:

#DataItemCondition
1uint8Command NumberMust be 0x81
3uint8Protocol VersionMust be 0x01
5uint32Serial ID of SenderMSB must be 1 (i.e., 0x8???????)
--Payload SizeMust be 23 bytes (between : and checksum)

Parser Implementation Examples

0x01: Reception of Arbitrary Data

Data Format

#DataDescriptionNotes
charHeaderOnly :
0uint8Logical Device ID of SenderParent 0x00, Child 0x01-0x64, Unset Child 0x78
1uint8Command NumberOnly 0x01
2[uint8]Arbitrary DataByte array of length \(N\)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

3.1.1.1.1.2 - Output from Remote Control App (Parent and Repeater App)

Output format when data is received from the Remote Control App

0x81: Status Notification from Remote Device

Outputs the state of the received input signal.

Data Format

#DataDescriptionRemarks
charHeader: only
0uint8Source Logical Device ID
1uint8Command NumberOnly 0x81
2uint8Packet IdentifierOnly 0x0F
3uint8Protocol VersionOnly 0x01
4uint8LQI0-255
5uint32Source Serial ID0x8???????
9uint8Destination Logical Device ID
10uint16Timestamp64 counts per second, MSB is internal flag
12uint8Relay Count
13uint16Digital SignalCorresponds to Ix from LSB, 0 is High
15uint16Digital Signal MaskCorresponds to Ix from LSB, 1 means enabled
17uint16Digital Signal FlagCorresponds to Ix from LSB, 1 means interrupt triggered
19uint8UnusedInternal management
uint8ChecksumLRC8
charFooterCR (0x0D/\r)
charFooterLF (0x0A/\n)

Example of Output Data

:01810F01DB8630000200645F000040004F00400049
#DataDescriptionValue
:charHeader:
010uint8Source Logical Device ID0x78
811uint8Command Number0x81
0F2uint8Packet Identifier0x15
013uint8Protocol Version0x01
DB4uint8LQI219/255
863000025uint32Source Serial ID0x6300002
009uint8Destination Logical Device ID0x00
645F10uint16TimestampAbout 401 seconds
0012uint8Relay Count0
004013uint16Digital SignalI7 is Low
004F15uint16Digital Signal MaskI7, I1-I4 are enabled
004017uint16Digital Signal FlagI7 has changed due to interrupt
0019uint8Unused
49uint8Checksum0x49
charFooter\r
charFooter\n

Data Identification Conditions

Parent and Repeater App can receive data from various types of child devices.

To confirm that the output data is from the Remote Control App, refer to the following conditions.

#DataItemCondition
1uint8Command NumberMust be 0x81
3uint8Protocol VersionMust be 0x02
5uint32Source Serial IDMSB must be 1 (0x8???????)
--Payload SizeMust be 20 bytes (between : and checksum)

Example Parser Implementations

3.1.1.1.1.3 - Output from Serial Communication App (Parent and Repeater App)

Output format when receiving data from the serial communication app

Format Mode: Simple Format

Data Format

#DataDescriptionNotes
charHeaderOnly :
0uint8Logical device ID of senderParent 0x00, child 0x01-0x64, unassigned child 0x78
1uint8Command numberValue less than 0x80 specified by sender
2[uint8]Arbitrary dataByte array of length (N)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example of Output Data

:780100112233AABBCCDD13
#DataDescriptionValue
:charHeader:
780uint8Logical device ID of senderUnassigned child ID
011uint8Command number0x01
00112233AABBCCDD2[uint8]Arbitrary dataAs is
13uint8Checksum0x13
charFooter\r
charFooter\n

Conditions to Identify Data

The Parent and Repeater App can receive data from various types of child devices.

To verify whether the output data is from the serial communication app (format mode: simple format), refer to the following:

#DataItemCondition
0uint8Logical device ID of senderMust be less than or equal to 0x64 or equal to 0x78
1uint8Command numberMust be less than 0x80
--Payload sizeMust be between 3 and 82 bytes

Example Implementation of Parser

Format Mode: Extended Format

Data Format

#DataDescriptionNotes
charHeaderOnly :
0uint8Logical device ID of senderParent 0x00, child 0x01-0x64, unassigned child 0x78
1uint8Command numberOnly 0xA0
2uint8Response IDValue specified by sender
3uint32Extended address of senderValue with 0x8 added at the start of serial ID
7uint32Extended address of receiver0xFFFFFFFF when logical device ID is used
11uint8LQIRadio communication quality at reception
12uint16Length of following byte arrayNumber of bytes (M)
14[uint8]Arbitrary dataByte array of length (M)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example of Output Data

:78A0028201015AFFFFFFFFA8000700112233AABBCCC6
#DataDescriptionNotes
:charHeader:
780uint8Logical device ID of senderUnassigned child ID
A01uint8Command number0xA0
022uint8Response ID0x02
8201015A3uint32Extended address of sender0x201015A
FFFFFFFF7uint32Extended address of receiverLogical device ID specified
A811uint8LQI168/255
000712uint16Length of following byte array7 bytes
00112233AABBCC14[uint8]Arbitrary dataAs is
C6uint8Checksum0xC6
charFooter
charFooter

Conditions to Identify Data

The Parent and Repeater App can receive data from various types of child devices.

To verify whether the output data is from the serial communication app (format mode: extended format), refer to the following:

#DataItemCondition
0uint8Logical device ID of senderMust be less than or equal to 0x64 or equal to 0x78
1uint8Command numberMust be 0xA0
2uint8Response IDMust be less than 0x80
3uint32Extended address of senderMSB must be 1 (i.e., 0x8???????)
12uint16Length of following byte arrayMust be payload size - 14 bytes

Example Implementation of Parser

3.1.1.1.1.4 - Output from Pal/Cue/Aria Apps (Parent and Repeater App)

Output format when data is received from Pal, Cue, and Aria apps

3.1.1.1.1.4.1 - Output from PAL App (Parent and Repeater App)

Output format when data is received from the PAL App

General

Data received from the PAL App is represented as a series of sensor data consisting of sensor type and its value.

Below are specific examples according to the product type.

Open/Close Sensor PAL

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x81
14uint8Number of sensor dataOnly 3
Sensor data 1
15uint8Info bitsOnly 0x11
16uint8Data sourceOnly 0x30
17uint8Extended byteOnly 0x08
18uint8Data lengthOnly 2
19uint16DataPower supply voltage (mV)
Sensor data 2
21uint8Info bitsOnly 0x11
22uint8Data sourceOnly 0x30
23uint8Extended byteOnly 0x01
24uint8Data lengthOnly 2
25uint16DataADC1 voltage (mV)
Sensor data 3
27uint8Info bitsOnly 0x00
28uint8Data sourceOnly 0x00
29uint8Extended byteOnly 0x00
30uint8Data lengthOnly 1
31uint8DataMagnetic data
End of sensor data
32uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

:80000000A8001C82012B1E01808103113008020D0C1130010203E40000000101EC6E
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
A84uint8LQI168/255
001C5uint16Sequence number28
82012B1E7uint32Serial ID of sender0x2012B1E
0111uint8Logical device ID of sender0x01
8012uint8Sensor type
8113uint8PAL board version and PAL board IDOpen/Close PAL V1
0314uint8Number of sensor data3
Sensor data 1
1115uint8Info bitsWith extended byte uint16
3016uint8Data sourceVoltage
0817uint8Extended bytePower supply
0218uint8Data length2 bytes
0D0C19uint16Data3340mV
Sensor data 2
1121uint8Info bitsWith extended byte uint16
3022uint8Data sourceVoltage
0123uint8Extended byteADC1
0224uint8Data length2 bytes
03E425uint16Data996mV
Sensor data 3
0027uint8Info bitsNo extended byte uint8
0028uint8Data sourceMagnetic
0029uint8Extended byteNone
0130uint8Data length1 byte
0131uint8DataN pole approached
End of sensor data
EC32uint8Checksum 10xEC
6Euint8Checksum 20x6E
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the PAL App (Open/Close Sensor PAL), refer to the following points.

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and IDMust be 0x81
--Payload size33 bytes

Example Parser Implementations

Environmental Sensor PAL

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x82
14uint8Number of sensor dataOnly 5
Sensor data 1
15uint8Info bitsOnly 0x11
16uint8Data sourceOnly 0x30
17uint8Extended byteOnly 0x08
18uint8Data lengthOnly 2
19uint16DataPower supply voltage (mV)
Sensor data 2
21uint8Info bitsOnly 0x11
22uint8Data sourceOnly 0x30
23uint8Extended byteOnly 0x01
24uint8Data lengthOnly 2
25uint16DataADC1 voltage (mV)
Sensor data 3
27uint8Info bitsOnly 0x05
28uint8Data sourceOnly 0x01
29uint8Extended byteOnly 0x00
30uint8Data lengthOnly 2
31int16DataTemperature data
Sensor data 4
33uint8Info bitsOnly 0x01
34uint8Data sourceOnly 0x02
35uint8Extended byteOnly 0x00
36uint8Data lengthOnly 2
37uint16DataHumidity data
Sensor data 5
39uint8Info bitsOnly 0x02
40uint8Data sourceOnly 0x03
41uint8Extended byteOnly 0x00
42uint8Data lengthOnly 4
43uint32DataIlluminance data
End of sensor data
47uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

​:8000000084811F810EFF6D04808205113008020AEB11300102035A0501000209E3010200020E3A02030004000001BE6C00
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
844uint8LQI132/255
811F5uint16Sequence number33055
810EFF6D7uint32Serial ID of sender0x10EFF6D
0411uint8Logical device ID of sender0x04
8012uint8Sensor type
8213uint8PAL board version and PAL board IDEnvironmental Sensor PAL V1
0514uint8Number of sensor data5
Sensor data 1
1115uint8Info bitsWith extended byte uint16
3016uint8Data sourceVoltage
0817uint8Extended bytePower supply
0218uint8Data length2 bytes
0AEB19uint16Data2795mV
Sensor data 2
1121uint8Info bitsWith extended byte uint16
3022uint8Data sourceVoltage
0123uint8Extended byteADC1
0224uint8Data length2 bytes
035A25uint16Data858mV
Sensor data 3
0527uint8Info bitsNo extended byte int16
0128uint8Data sourceTemperature
0029uint8Extended byteNone
0230uint8Data length2 bytes
09E331int16Data25.31°C
Sensor data 4
0133uint8Info bitsNo extended byte uint16
0234uint8Data sourceHumidity
0035uint8Extended byteNone
0236uint8Data length2 bytes
0E3A37uint16Data36.42%
Sensor data 5
0239uint8Info bitsNo extended byte uint32
0340uint8Data sourceIlluminance
0041uint8Extended byteNone
0442uint8Data length4 bytes
000001BE43uint32Data446lx
End of sensor data
6C47uint8Checksum 10x6C
00uint8Checksum 20x00
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the PAL App (Environmental Sensor PAL), refer to the following points.

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and IDMust be 0x82
--Payload size48 bytes

Example Parser Implementations

Motion Sensor PAL

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x83
14uint8Number of Sensor DataOnly 18
Sensor Data 1
15uint8Info bitsOnly 0x11
16uint8Data sourceOnly 0x30
17uint8Extended byteOnly 0x08
18uint8Data lengthOnly 2
19uint16DataPower supply voltage (mV)
Sensor Data 2
21uint8Info bitsOnly 0x11
22uint8Data sourceOnly 0x30
23uint8Extended byteOnly 0x01
24uint8Data lengthOnly 2
25uint16DataADC1 voltage (mV)
Sensor Data 3
27uint8Info bitsOnly 0x15
28uint8Data sourceOnly 0x04
29uint8Extended byte0x?0 Frequency and sample number
30uint8Data lengthOnly 6
31int16DataAcceleration data
Sensor Data 4
37uint8Info bitsOnly 0x15
38uint8Data sourceOnly 0x04
39uint8Extended byte0x?1 Frequency and sample number
40uint8Data lengthOnly 6
41int16DataAcceleration data
Sensor Data 5
(Omitted)
Sensor Data 18
177uint8Info bitsOnly 0x15
178uint8Data sourceOnly 0x04
179uint8Extended byte0x?F Frequency and sample number
180uint8Data lengthOnly 6
181int16DataAcceleration data
End of sensor data
187uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

:80000000BA002382011CEF01808312113008020D0211300102055C1504400600100010045015044106000800100430150442060000001004381504430600080018043015044406000000180458150445060000002004381504460600080018042815044706FFE80010042015044806FFF00010043815044906FFE80018043015044A06FFF80018044015044B06FFF80018041815044C0600000010042015044D0600000028045015044E0600000008043815044F0600000018043828A5
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
BA4uint8LQI186/255
00235uint16Sequence number35
82011CEF7uint32Serial ID of sender0x2011CEF
0111uint8Logical device ID of sender0x01
8012uint8Sensor type
8313uint8PAL board version and PAL board IDMotion PAL V1
1214uint8Number of Sensor Data18 items
Sensor Data 1
1115uint8Info bitsWith extended byte uint16
3016uint8Data sourceVoltage
0817uint8Extended bytePower supply
0218uint8Data length2 bytes
0D0219uint16Data3330mV
Sensor Data 2
1121uint8Info bitsWith extended byte uint16
3022uint8Data sourceVoltage
0123uint8Extended byteADC1
0224uint8Data length2 bytes
055C25uint16Data1372mV
Sensor Data 3
1527uint8Info bitsWith extended byte int16
0428uint8Data sourceAcceleration
4029uint8Extended byte100Hz, sample 0
0630uint8Data length6 bytes
00100010045031int16DataX16mG/Y16mG/Z1104mG
Sensor Data 4
1537uint8Info bitsWith extended byte int16
0438uint8Data sourceAcceleration
4139uint8Extended byte100Hz, sample 1
0640uint8Data length6 bytes
00080010043041uint16DataX8mG/Y16mG/Z1072mG
Sensor Data 5
(Omitted)
Sensor Data 15
15177uint8Info bitsWith extended byte int16
04178uint8Data sourceAcceleration
4F179uint8Extended byte100Hz, sample 15
06180uint8Data length6 bytes
000000180438181uint32DataX0mG/Y24mG/Z1080mG
End of sensor data
28187uint8Checksum 10x28
A5uint8Checksum 20xA5
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the PAL App (Motion Sensor PAL), refer to the following points.

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and IDMust be 0x83
--Payload size188 bytes

Example Parser Implementations

Notification PAL

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x84
14uint8Number of Sensor DataOnly 3
Sensor Data 1
15uint8Info bitsOnly 0x11
16uint8Data sourceOnly 0x30
17uint8Extended byteOnly 0x08
18uint8Data lengthOnly 2
19uint16DataPower supply voltage (mV)
Sensor Data 2
21uint8Info bitsOnly 0x11
22uint8Data sourceOnly 0x30
23uint8Extended byteOnly 0x01
24uint8Data lengthOnly 2
25uint16DataADC1 voltage (mV)
Sensor Data 3
27uint8Info bitsOnly 0x12
28uint8Data sourceOnly 0x05
29uint8Extended byteOnly 0x04
30uint8Data lengthOnly 4
31uint8DataAcceleration event data
32[uint8]Unused
End of sensor data
35uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

:80000000C9BBC082014C3501808403 113008020D0C 1130010203F9 1205040410000000 97C6
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
C94uint8LQI201/255
BBC05uint16Sequence number48064
82014C357uint32Serial ID of sender0x2014C35
0111uint8Logical device ID of sender0x01
8012uint8Sensor type
8413uint8PAL board version and PAL board IDNotification PAL V1
0314uint8Number of Sensor Data3 items
Sensor Data 1
1115uint8Info bitsWith extended byte uint16
3016uint8Data sourceVoltage
0817uint8Extended bytePower supply
0218uint8Data length2 bytes
0D0C19uint16Data3340mV
Sensor Data 2
1121uint8Info bitsWith extended byte uint16
3022uint8Data sourceVoltage
0123uint8Extended byteADC1
0224uint8Data length2 bytes
03F925uint16Data1017mV
Sensor Data 3
1227uint8Info bitsWith extended byte uint32
0528uint8Data sourceEvent
0429uint8Extended byteAcceleration event
0430uint8Data length4 bytes
1031uint8DataMove
00000032[uint8]
End of sensor data
9735uint8Checksum 10x97
C6uint8Checksum 20xC6
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the PAL App (Notification PAL), refer to the following points.

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and IDMust be 0x84
--Payload size36 bytes

3.1.1.1.1.4.2 - Output from CUE App (Parent and Repeater App)

Output format when receiving data from the CUE App

TWELITE CUE Mode

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x05
14uint8Number of sensor dataOnly 15
Sensor Data 1
15uint8Info bitsOnly 0x00
16uint8Data sourceOnly 0x34
17uint8Extended byteOnly 0x00
18uint8Data lengthOnly 3
19[uint8]DataPacket property data
Sensor Data 2
22uint8Info bitsOnly 0x12
23uint8Data sourceOnly 0x05
24uint8Extended byte0x35, 0x04, or 0x00
25uint8Data lengthOnly 4
26uint32DataEvent data
Sensor Data 3
30uint8Info bitsOnly 0x11
31uint8Data sourceOnly 0x30
32uint8Extended byteOnly 0x08
33uint8Data lengthOnly 2
34uint16DataPower supply voltage (mV)
Sensor Data 4
36uint8Info bitsOnly 0x11
37uint8Data sourceOnly 0x30
38uint8Extended byteOnly 0x01
39uint8Data lengthOnly 2
40uint16DataVoltage of ADC1 (mV)
Sensor Data 5
42uint8Info bitsOnly 0x00
43uint8Data sourceOnly 0x00
44uint8Extended byteOnly 0x00
45uint8Data lengthOnly 1
46uint8DataMagnetic data
Sensor Data 6
47uint8Info bitsOnly 0x15
48uint8Data sourceOnly 0x04
49uint8Extended byte0x?0 Frequency and sample number
50uint8Data lengthOnly 6
51[int16]DataAcceleration data
Sensor Data 7
57uint8Info bitsOnly 0x15
58uint8Data sourceOnly 0x04
59uint8Extended byte0x?1 Frequency and sample number
60uint8Data lengthOnly 6
61[int16]DataAcceleration data
Sensor Data 8
(Omitted)
Sensor Data 15
137uint8Info bitsOnly 0x15
138uint8Data sourceOnly 0x04
139uint8Extended byte0x?9 Frequency and sample number
140uint8Data lengthOnly 6
141int16DataAcceleration data
End of sensor data
147uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to Checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Output Data Example

:80000000CF7F7382019E3B0180050F003400038135001205040406000000113008020B8611300102042E000000018015044006FFF00010FC1815044106FFF00018FC1815044206FFF00010FC0015044306FFF80000FC1015044406FFF00010FC1815044506FFE00018FBF815044606FFE80000FC0015044706FFE80010FBF815044806FFE80010FC0815044906FFE80010FC080C0E
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
CF4uint8LQI207/255
7F735uint16Sequence number32627
82019E3B7uint32Serial ID of sender0x2019E3B
0111uint8Logical device ID of sender0x01
8012uint8Sensor type
0513uint8PAL board version and PAL board IDTWELITE CUE
0F14uint8Number of sensor data15 items
Sensor Data 1
0015uint8Info bitsNo extended byte uint8
3416uint8Data sourcePacket property
0017uint8Extended byteNone
0318uint8Data length3 bytes
81350019[uint8]DataID 129, timer event occurred
Sensor Data 2
1222uint8Info bitsExtended byte present uint32
0523uint8Data sourceEvent
0424uint8Extended byteAcceleration event
0425uint8Data length4 bytes
0600000026uint32DataDice: 6
Sensor Data 3
1130uint8Info bitsExtended byte present uint16
3031uint8Data sourceVoltage
0832uint8Extended bytePower supply voltage
0233uint8Data length2 bytes
0B8634uint16Data2950 mV
Sensor Data 4
1136uint8Info bitsExtended byte present uint16
3037uint8Data sourceVoltage
0138uint8Extended byteVoltage of ADC1
0239uint8Data length2 bytes
042E40uint16Data1070 mV
Sensor Data 5
0042uint8Info bitsNo extended byte uint8
0043uint8Data sourceMagnetic
0044uint8Extended byteNone
0145uint8Data length1 byte
8046uint8DataNo magnet (periodic transmit)
Sensor Data 6
1547uint8Info bitsExtended byte present int16
0448uint8Data sourceAcceleration data
4049uint8Extended byte100Hz, sample 0
0650uint8Data length6 bytes
FFF00010FC1851[int16]DataX-16mG/Y16mG/Z-1000mG
Sensor Data 7
1557uint8Info bitsExtended byte present int16
0458uint8Data sourceAcceleration data
4159uint8Extended byte100Hz, sample 1
0660uint8Data length6 bytes
FFF00018FC1861[int16]DataX-16mG/Y24mG/Z-1000mG
Sensor Data 8
(Omitted)
Sensor Data 15
15137uint8Info bitsExtended byte present int16
04138uint8Data sourceAcceleration data
49139uint8Extended byte100Hz, sample 9
06140uint8Data length6 bytes
FFE80010FC08141int16DataX-24mG/Y16mG/Z-1016mG
End of sensor data
0C147uint8Checksum 10x0C
0Euint8Checksum 20x0E
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the CUE App (TWELITE CUE mode), refer to the following points:

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and PAL board IDMust be 0x05
--Payload sizeMust be 148 bytes

Example Parser Implementations

Magnet Sensor PAL Mode

Motion Sensor PAL Mode (Acceleration Measurement Mode)

Motion Sensor PAL Mode (Move / Dice Mode)

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x03
14uint8Number of sensor dataOnly 04
Sensor Data 1
15uint8Info bitsOnly 0x00
16uint8Data sourceOnly 0x34
17uint8Extended byteOnly 0x00
18uint8Data lengthOnly 3
19[uint8]DataPacket property data
Sensor Data 2
22uint8Info bitsOnly 0x12
23uint8Data sourceOnly 0x05
24uint8Extended byteOnly 0x04
25uint8Data lengthOnly 4
26uint32DataEvent data
Sensor Data 3
30uint8Info bitsOnly 0x11
31uint8Data sourceOnly 0x30
32uint8Extended byteOnly 0x08
33uint8Data lengthOnly 2
34uint16DataPower supply voltage (mV)
Sensor Data 4
36uint8Info bitsOnly 0x11
37uint8Data sourceOnly 0x30
38uint8Extended byteOnly 0x01
39uint8Data lengthOnly 2
40uint16DataVoltage of ADC1 (mV)
End of sensor data
42uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to Checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Output Data Example

Below is an example for Dice Mode. For Move Mode, the event in Sensor Data 2 will differ.

:80000000B400048106664801800304003400038035001205040403000000113008020D2011300102052C59B7
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
B14uint8LQI177/255
00085uint16Sequence number8
810666487uint32Serial ID of sender0x2019E3B
0111uint8Logical device ID of sender0x1066648
8012uint8Sensor type
0313uint8PAL board version and PAL board IDTWELITE CUE Dice / Move
0414uint8Number of sensor data4 items
Sensor Data 1
0015uint8Info bitsNo extended byte uint8
3416uint8Data sourcePacket property
0017uint8Extended byteNone
0318uint8Data length3 bytes
80350019[uint8]DataID 128, event occurred (only ADC1 and power supply)
Sensor Data 2
1222uint8Info bitsExtended byte present uint32
0523uint8Data sourceEvent
0424uint8Extended byteAcceleration event
0425uint8Data length4 bytes
0300000026uint32DataDice Mode, die: 3
Sensor Data 3
1130uint8Info bitsExtended byte present uint16
3031uint8Data sourceVoltage
0832uint8Extended bytePower supply voltage
0233uint8Data length2 bytes
0D2034uint16Data3360 mV
Sensor Data 4
1136uint8Info bitsExtended byte present uint16
3037uint8Data sourceVoltage
0138uint8Extended byteVoltage of ADC1
0239uint8Data length2 bytes
052C40uint16Data1324 mV
End of sensor data
5942uint8Checksum 10x0C
B7uint8Checksum 20x0E
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the CUE App (Move or Dice Mode of Motion Sensor PAL Mode), refer to the following points:

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and PAL board IDMust be 0x03
--Payload sizeMust be 43 bytes

Example Parser Implementations

3.1.1.1.1.4.3 - Output from Aria App (Parent and Repeater App)

Output format when data is received from the Aria app

TWELITE ARIA Mode

Data Format

#DataContentRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0 to 255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x06
14uint8Number of sensor dataOnly 7
Sensor data 1
15uint8Info bitsOnly 0x00
16uint8Data sourceOnly 0x34
17uint8Extension byteOnly 0x00
18uint8Data lengthOnly 3
19[uint8]DataPacket property data
Sensor data 2
22uint8Info bitsOnly 0x12
23uint8Data sourceOnly 0x05
24uint8Extension byte0x35 or 0x00
25uint8Data lengthOnly 4
26uint32DataEvent data
Sensor data 3
30uint8Info bitsOnly 0x11
31uint8Data sourceOnly 0x30
32uint8Extension byteOnly 0x08
33uint8Data lengthOnly 2
34uint16DataPower supply voltage (mV)
Sensor data 4
36uint8Info bitsOnly 0x11
37uint8Data sourceOnly 0x30
38uint8Extension byteOnly 0x01
39uint8Data lengthOnly 2
40uint16DataADC1 voltage (mV)
Sensor data 5
42uint8Info bitsOnly 0x00
43uint8Data sourceOnly 0x00
44uint8Extension byteOnly 0x00
45uint8Data lengthOnly 1
46uint8DataMagnetic data
Sensor data 6
47uint8Info bitsOnly 0x05
48uint8Data sourceOnly 0x01
49uint8Extension byteOnly 0x00
50uint8Data lengthOnly 2
51int16DataTemperature data
Sensor data 7
53uint8Info bitsOnly 0x01
54uint8Data sourceOnly 0x02
55uint8Extension byteOnly 0x00
56uint8Data lengthOnly 2
57uint16DataHumidity data
End of sensor data
59uint8Checksum 1CRC8 up to previous byte
uint8Checksum 2LRC8 up to Checksum 1
charFooterCR (0x0D/\r)
charFooterLF (0x0A/\n)

Data Identification Conditions

Parent and Repeater App can receive data from various types of child devices.

To confirm that the output data is from the Aria App (TWELITE ARIA Mode), refer to the following:

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor type0x80
13uint8PAL board version and PAL board ID0x06
--Payload sizeMust be 60 bytes

Parser Implementation Examples

Open/Close Sensor Pal Mode

3.1.1.1.1.4.4 - Details of Output from Pal, Cue, and Aria Apps (Parent and Repeater App)

Details of the common output format for Pal, Cue, and Aria apps
Data received from child devices of Pal, Cue, and Aria apps are output according to a common format. This section details that format. For specific output examples of each app, see the app pages.

Overall

Data Format

#DataDescriptionNotes
charHeader: only
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDe.g. 0x81
14uint8Number of sensor data
15[uint8]List of sensor dataByte array of length (N)
15+(N)uint8Checksum 1CRC8 up to previous byte
uint8Checksum 2LRC8 up to Checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

:80000000A8001C82012B1E01808103113008020D0C1130010203E40000000101EC6E
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
A84uint8LQI168/255
001C5uint16Sequence number28
82012B1E7uint32Serial ID of sender0x2012B1E
0111uint8Logical device ID of sender0x01
8012uint8Sensor type-
8113uint8PAL board version and PAL board ID0x81
0314uint8Number of sensor data3
1130...010115[uint8]List of sensor dataByte array of length 17
EC15+17uint8Checksum 10xEC
6Euint8Checksum 20x6E
charFooter'\r'
charFooter'\n'

Sensor Data

Data Format

#DataDescriptionNotes
0uint8Info bitsData type and presence of extension byte
1uint8Data sourceType of sensor value
2uint8Extension byteAdditional info for sensor value
3uint8Data lengthLength of sensor value
4[uint8]DataSensor value

Example Output Data

113008020D0C
#DataDescriptionValue
110uint8Info bitsExtension byte present, uint16
301uint8Data sourceVoltage
082uint8Extension bytePower supply voltage
023uint8Data length2 bytes
0D0C4[uint8]Data3340 mV

Info Bits

Indicates the data type of the sensor value, presence of extension byte, and read error status.

bit76543210
FunctionERR--EXT-TYP:2TYP:1TYP:0

Each function indicates the following:

FunctionDescriptionValueMeaning
ERRRead error presence0Normal
1Error present
EXTExtension byte presence0No extension byte
1Extension byte present
TYPData type000uint8
001uint16
010uint32
011N/A
100int8
101int16
110int32
111[uint8]

Data Source

Indicates the type of sensor value.

ValueDescription
0x00Magnetic
0x01Temperature
0x02Humidity
0x03Illuminance
0x04Acceleration
0x05Event
0x30Voltage
0x34Packet properties

Extension Byte

Indicates additional information such as index for continuous data.

For data sources Magnetic / Temperature / Humidity / Illuminance / Packet Properties

None

For data source Acceleration

Indicates attributes of acceleration sample data.

bit76543210
FunctionSFQ:2SFQ:1SFQ:0SNM:4SNM:3SNM:2SNM:1SNM:0

Each function indicates the following:

FunctionDescriptionValueMeaning
SFQSampling frequency000 (`0x00SNM`)
001 (`0x20SNM`)
010 (`0x40SNM`)
011 (`0x60SNM`)
100 or higherUndefined
SNMSample number0-31Oldest first

For data source Event

Indicates cause of event occurrence.

ValueDescription
0x00Magnetic
0x01Temperature
0x02Humidity
0x03Illuminance
0x04Acceleration
0x31Digital input
0x35Timer

For data source Voltage

Indicates target.

ValueDescription
0x01ADC1
0x02ADC2
0x03ADC3
0x04ADC4
0x08Power supply

Data Length

Indicates the number of bytes of the following data.

Data

Represents the sensor value.

For data source Magnetic

Data type is uint8.

ValueDescription
0x00No magnet
0x01North pole approached
0x02South pole approached
0x80No magnet (periodic send)
0x81North pole nearby (periodic send)
0x82South pole nearby (periodic send)

For data source Temperature

Data type is int16.

Represents temperature in Celsius multiplied by 100.

For data source Humidity

Data type is uint16.

Represents relative humidity multiplied by 100.

For data source Illuminance

Data type is uint32.

Represents illuminance in lux.

For data source Acceleration

Three int16 values follow.

X, Y, Z axis values (mG) total 6 bytes.

byte012345
ContentX:15-8X:7-0Y:15-8Y:7-0Z:15-8Z:7-0

For data source Event

Four uint8 values follow.

The first data indicates the event content, the rest are unused.

byte0123
ContentUsedUnusedUnusedUnused
Extension byte for Magnetic
First valueDescription
0x00No magnet
0x01North pole nearby
0x02South pole nearby
Extension byte for Acceleration
First valueDescription
0x00Stationary (Move mode)
0x01Dice: 1
0x02Dice: 2
0x03Dice: 3
0x04Dice: 4
0x05Dice: 5
0x06Dice: 6
0x08Shake
0x10Move
Extension byte for Timer
First valueDescription
0x01Woken by timer

For data source Voltage

Data type is uint16.

Represents voltage in mV.

For data source Packet Properties

Three uint8 values follow.

byte012
DataPacket IDRoot cause of wake-upCondition of wake-up

Each data indicates the following:

DataValueDescription
Packet ID0No event, only ADC1 and power voltage
1-127No event, other data present
128Event present, only ADC1 and power voltage
129-255Event present, other data present
Root cause of wake-up0x00Magnetic
0x01Temperature
0x02Humidity
0x03Illuminance
0x04Acceleration
0x31Digital input
0x35Timer
Condition of wake-up0x00Event occurred
0x01Value changed
0x02Value exceeded threshold
0x03Value fell below threshold
0x04Value met range

3.1.1.1.1.5 - Output from act (Parent and Repeater App)

Output format when data is received from act

Data Received from act

Data Format

#DataContentRemarks
charHeader: only
0uint8Source Logical Device ID
1uint8Command Typeonly 0xAA
2uint8Response ID0x00-0x7F
3uint32Source Serial ID
7uint32Destination Serial ID00000000 when specifying logical device ID
11uint8LQI0-255
12uint16Number of data bytes
14[uint8]Arbitrary dataLength (N) bytes
uint8ChecksumLRC8
charFooterCR (0x0D/\r)
charFooterLF (0x0A/\n)

Example of Output Data

:FEAA008201015A00000000B7000F424154310F0CEE000B03FF03FF03FF92
#DataContentValue
:charHeader:
FE0uint8Source Logical Device ID0xFE
AA1uint8Command Type0xAA
002uint8Response ID0x00
8201015A3uint32Source Serial ID0x201015A
000000007uint32Destination Serial IDLogical Device ID specified
B711uint8LQI183/255
000F12uint16Number of data bytes15 bytes
424154310F0CEE000B03FF03FF03FF14[uint8]Arbitrary dataAs is
92uint8Checksum0x92
charFooter\r
charFooter\n

3.1.1.1.1.6 - Output from Wireless Tag App (Parent and Repeater App)

Output format when data is received from the Wireless Tag App
This section describes the output when connecting main sensors to the child device.

Analog Sensor

Data Format

#DataDescriptionNotes
charHeader: only
0uint32Relay device serial ID80000000 if no relay
4uint8LQI0-255
5uint16Sequence number
7uint32Source serial ID
11uint8Source logical device ID
12uint8Sensor type
13uint8Power supply voltage (mV)See Power Supply Voltage Calculation
14uint16ADC1 voltage
16uint16ADC2 voltage
18uint32Unused
22uint8Checksum

Example Output Data

:80000000B700628201015A0010DF08FD09A300000000E9
#DataDescriptionValue
:charHeader:
800000000uint32Relay device serial IDNo relay
B74uint8LQI183/255
00625uint16Sequence number98
8201015A7uint32Source serial ID0x201015A
0011uint8Source logical device ID0x00
1012uint8Sensor typeAnalog sensor
DF13uint8Power supply voltage (mV)3330mV
08FD14uint16ADC1 voltage2301mV
09A316uint16ADC2 voltage2467mV
0000000018uint32Unused
E922uint8Checksum0xE9
charFooter\r
charFooter\n

Accelerometer (ADXL34x / TWELITE 2525A)

Data Format

#DataDescriptionNotes
charHeader: only
0uint32Relay device serial ID80000000 if no relay
4uint8LQI0-255
5uint16Sequence number
7uint32Source serial ID
11uint8Source logical device ID
12uint8Sensor type
13uint8Power supply voltage (mV)See Power Supply Voltage Calculation
14uint16ADC1 voltage
16uint16ADC2 voltage
18uint8Sensor mode number
19int16X-axis accelerationUnit: mG*10
21int16Y-axis accelerationUnit: mG*10
23int16Z-axis accelerationUnit: mG*10
25uint8Checksum

Example Output Data

:8000000063001781013C850035DF057702F2000000FF96FFF0BB
#DataDescriptionValue
:charHeader:
800000000uint32Relay device serial IDNo relay
634uint8LQI99/255
00175uint16Sequence number23
81013C857uint32Source serial ID0x1013C85
0011uint8Source logical device ID0x00
3512uint8Sensor typeAccelerometer (ADXL34x)
DF13uint8Power supply voltage (mV)3330mV
057714uint16ADC1 voltage1399mV
02F216uint16ADC2 voltage754mV
0018uint8Sensor mode numberNormal
000019int16X-axis acceleration0mG
FF9621int16Y-axis acceleration-1060mG
FFF023int16Z-axis acceleration-160mG
BB25uint8Checksum0xBB
charFooter\r
charFooter\n

Switch

Data Format

#DataDescriptionNotes
charHeader: only
0uint32Relay device serial ID80000000 if no relay
4uint8LQI0-255
5uint16Sequence number
7uint32Source serial ID
11uint8Source logical device ID
12uint8Sensor type
13uint8Power supply voltage (mV)See Power Supply Voltage Calculation
14uint16ADC1 voltage
16uint16ADC2 voltage
18uint8Sensor mode number0 is Hi→Lo, 1 is Lo→Hi
19uint8DI1 state1 is Lo
20uint8Unused
21uint8Checksum

Example Output Data

:800000009C00118201015A00FEDF000709A300010064
#DataDescriptionValue
:charHeader
800000000uint32Relay device serial IDNo relay
9C4uint8LQI156/255
00625uint16Sequence number98
8201015A7uint32Source serial ID0x201015A
0011uint8Source logical device ID0x00
FE12uint8Sensor typeSwitch
DF13uint8Power supply voltage (mV)3330mV
000714uint16ADC1 voltage7mV
09A316uint16ADC2 voltage2467mV
0018uint8Sensor mode numberHi→Lo
0119uint8DI1 stateLo
0020uint8Unused
6421uint8Checksum0x64
charFooter\r
charFooter\n

Power Supply Voltage Calculation

The power supply voltage \(V_{cc}\) can be expressed using the received value \(e_{cc}\) as follows:

$$\begin{cases} V_{cc} = 1950+5e_{cc} & (e_{cc} <= 170) \\ V_{cc} = 2800+10(e_{cc}-170) & (e_{cc} > 170) \end{cases}$$

Unit is mV

3.1.1.1.2 - Transmit Command of Parent and Repeater App

Input for sending data to the child

Commands entered from the serial port in the specified format are sent to the child.

3.1.1.1.2.1 - Input to the Extremely Simple! Standard App (Parent and Repeater App)

Commands to control the output of the Extremely Simple! Standard App
You can control the output of the Extremely Simple! Standard App.

Digital and Analog Input/Output

0x80: Change Output of the Target Device

Controls the output signals of the target device.

Data Format

#DataDescriptionNotes
charHeader: only
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command Number0x80 only
2uint8Format Version0x01 only
3uint8Digital SignalCorresponds to DOx from LSB, 0 means High
4uint8Digital Signal MaskCorresponds to DOx from LSB, 1 means Enabled
5uint16PWM1 Signal0-1024, 0xFFFF means Disabled
7uint16PWM2 Signal0-1024, 0xFFFF means Disabled
9uint16PWM3 Signal0-1024, 0xFFFF means Disabled
11uint16PWM4 Signal0-1024, 0xFFFF means Disabled
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

3.1.1.1.2.2 - Input to the Serial Communication App (Parent and Repeater App)

Commands to send data to the serial communication app
You can send data to the child device of the serial communication app (format mode, simple format).

UART

Format Mode: ASCII Simple Format

App_Wings v1.3 and later support the simple format of format mode (A).

Data Format

#DataDescriptionNotes
charHeaderOnly :
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command NumberAny value less than 0x80
2[uint8]Arbitrary DataByte sequence of length \(N\) (recommended \(N\leqq80\))
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

3.1.1.1.2.3 - Input to the PAL App (Notification PAL) (Parent and Repeater App)

Commands to control the LED of the Notification PAL
You can control the LED of the Notification PAL.
:0190010004000169[CR][LF]
 ^1^2^3^^^^^^^4^5
No.BytesMeaningExample DataNotes
11Destination Logical Device ID01

Specify the logical device ID of the destination TWELITE PAL.
Valid values range from 0x01 to 0x64.

21Command Type90
31Number of Command Parameters01Specify the number of command parameters. For example, set to 1 if specifying one command parameter, or 2 if specifying two.
4Number of Commands x 4Command Parameters00040001

Specify parameters such as events and LED colors.
See the command parameters section for details.

51Checksum69

Calculate the sum of bytes 1 to 4 within 8 bits and take the two’s complement. In other words, the sum of all data bytes plus the checksum byte equals zero within 8 bits.
The checksum byte is represented by two ASCII characters.
For example, in 00A01301FF123456, the sum 0x00 + 0xA0 + … + 0x56 = 0x4F, and its two’s complement is 0xB1 (i.e., 0x4F + 0xB1 = 0).
The checksum can be omitted by using ‘X’ as the checksum.

62Footer[CR][LF]Specify [CR] (0x0D) [LF] (0x0A). However, if the checksum is omitted with ‘X’, the footer can also be omitted.

Command Parameters

Combine 4-byte command parameters to specify commands.

0x00: Send Event ID

The TWELITE PAL has predefined behaviors for each received event ID. This parameter sends an event ID to the destination TWELITE PAL to trigger the configured behavior.

No.BytesContentNotes
11Command Parameter ID0x00
21Destination PAL ID

Specify the destination PAL ID.
0x04: Notification PAL
0xFF: All TWELITE PALs

31UnusedFixed at 0x00
41Event IDSpecify event ID from 0 to 16

0x01: Send LED Color, Blinking Pattern, and Brightness

Send the LED color, blinking pattern, and brightness to the destination Notification PAL.

No.BytesContentNotes
11Command Parameter ID0x01
21Color

0: Red
1: Green
2: Blue
3: Yellow
4: Purple
5: Cyan
6: White
7: Warm White

31Blinking Pattern

0: Always on
1-3: Blinking patterns (higher value means faster blinking)

41Brightness

0: Off
0x01–0x0F: Brightness (higher value means brighter)

0x02: Send Lighting Duration

Send the lighting duration of the Notification PAL’s LED.

No.BytesContentNotes
11Command Parameter ID0x02
21UnusedFixed at 0xFF
31UnusedFixed at 0x00
41Lighting DurationSpecified in seconds (0 means always on)

0x03: Specify LED Color in RGBW

Send the LED lighting color of the Notification PAL in RGBW.

No.BytesContentNotes
11Command Parameter ID0x03
21UnusedFixed at 0xFF
32LED Lighting Color

Specify 4 bits each for RGBW in order from LSB.

Higher value means brighter.

0x04: Specify Blinking Parameters

Send the blinking cycle and duty of the Notification PAL’s LED.

No.BytesContentNotes
11Command Parameter ID0x04
21UnusedFixed at 0xFF
31Blinking Time Ratio

Specify from 0x00 to 0xFF.

Higher value means longer ON time per cycle.

0x7F means ON for half of the cycle.

41Blinking Cycle

Specify from 0x00 to 0xFF.

Each increment increases the blinking cycle by about 0.04s.

0x17 corresponds to a 1-second cycle.

Command Examples

Example 1: Send Event

Command example to send event 1 to the NOTICE PAL with logical device ID 1.

:0190010004000169
 ^1^2^3^4^5^6^7^8
No.BytesMeaningExample DataExplanation of Example DataNotes
11Destination Logical Device ID01Logical device ID of the destination is 0x01
21Command Type900x90 commandFixed at 90
31Number of Commands01One command
41Command ID00Command 00
51Destination PAL ID04Sent to Notification PAL
61Unused00
71Event ID01Event 10x00 to 0x10
81Checksum69

Example 2: Send LED Lighting Color to Notification PAL

Command to send LED lighting color with brightness 8 and slow blinking white to the NOTICE PAL with logical device ID 1.

:019001010601085E
 ^1^2^3^4^5^6^7^8
No.BytesMeaningExample DataExplanation of Example DataNotes
11Destination Logical Device ID01Logical device ID of the destination is 0x01
21Command Type900x90 commandFixed at 90
31Number of Commands01One command
41Command Parameter ID01Command parameter ID 0x01
51Color06White
61Blinking Pattern01Blinking
71Brightness08Brightness 8Range 0x00 to 0x0F
81Checksum5E

Example 3: Send LED Lighting Color and Lighting Duration to Notification PAL

Command to light up purple and turn off after 1 second for the NOTICE PAL with logical device ID 1.

:0190020104000802FF00015E
 ^1^2^3^4^5^6^7^8^9^a^b^c
No.BytesMeaningExample DataExplanation of Example DataNotes
11Destination Logical Device ID01Logical device ID of the destination is 0x01
21Command Type900x90 commandFixed at 90
31Number of Commands02Two commands
41Command Parameter ID01Command parameter ID 0x01
51Color04Purple
61Blinking Pattern00Always on
71Brightness08Brightness 8Range 0x00 to 0x0F
81Command Parameter ID02Command parameter ID 0x02
91UnusedFF
a1Unused00
b1Lighting Duration01Turns off after 1 second
c1Checksum5E

Example 4: Send Detailed Lighting Color to Notification PAL

Command to light up purple for the NOTICE PAL with logical device ID 1.

:01900103FF0F0459
 ^1^2^3^4^5^^^6^7
No.BytesMeaningExample DataExplanation of Example DataNotes
11Destination Logical Device ID01Logical device ID of the destination is 0x01
21Command Type900x90 commandFixed at 90
31Number of Commands01One command
41Command Parameter ID03Command parameter ID 0x03
51UnusedFF
62LED Lighting Color0F04Lights blue at 15 and red at 4 brightness

Specify 4 bits each for RGBW in order from LSB (0–15).

Higher value means brighter.

71Checksum59

Example 5: Send LED Lighting Color and Lighting Duration to Notification PAL

Command to light up purple and turn off after 1 second for the NOTICE PAL with logical device ID 1.

:0190020104000802FF00015E
 ^1^2^3^4^5^6^7^8^9^a^b^c
No.BytesMeaningExample DataExplanation of Example DataNotes
11Destination Logical Device ID01Logical device ID of the destination is 0x01
21Command Type900x90 commandFixed at 90
31Number of Commands02Two commands
41Command Parameter ID01Command parameter ID 0x01
51Color04Purple
61Blinking Pattern00Always on
71Brightness08Brightness 8Range 0x00 to 0x0F
81Command Parameter ID02Command parameter ID 0x02
91UnusedFF
a1Unused00
b1Lighting Duration01Turns off after 1 second
c1Checksum5E

3.1.1.2 - Repeater Mode of Parent and Repeater App

Retransmit data received from Child or Parent
In repeater mode, retransmitting received packets can extend the communication range between Child and Parent.

Example Settings

To use as a repeater, set the Operating Mode in interactive mode to 1 or higher.

Relay Methods

TWELITE NET provides two major relay methods for wireless packet delivery, as shown in the table below, which differ depending on the application. This app can identify and relay packets of the applications shown in the table below.

Relay MethodSupported Applications
Simple NetExtremely Simple! Standard App, Remote Control App, Serial Communication App, ACT
Relay NetWireless Tag App, PAL App, CUE App

Relay Using Simple Net

When relaying applications using Simple Net, setting the operating mode to 1 or higher allows up to three relays.

For example, in case 1., if there are up to 3 Repeaters between the Parent and Child, data will reach the Parent, but in case 2., if there are 4 or more Repeaters, data will not reach the Parent.

1. Child  --->  Repeater  --->  Repeater  --->  Repeater  --->  Parent
   → Parent can receive Child's data relayed 3 times.
2. Child  --->  Repeater  --->  Repeater  --->  Repeater  --->  Repeater  -x->  Parent
   → Stops relaying at the 4th relay.

Relaying with Simple Net basically uses broadcast communication and relays all received packets. The advantage is that communication to form and maintain the relay network is not necessary, but the disadvantage is that communication volume can explode as the number of Repeaters increases.

For details, please refer to here.

Relay Using Relay Net

For relaying data of applications using Relay Net with one stage of relay, set the operating mode value to 1.

When performing multiple relays, increase the operating mode setting value as the distance from the Parent increases. (It is acceptable if the setting values are in ascending order even if some values are skipped.)

The maximum number of relays for this method is up to 63 times.

Example 1: One relay\
Child ---> Repeater (Operating Mode: 1) ---> Parent

Example 2: Two relays\
Child  --->  Repeater (Operating Mode: 2) --->  Repeater (Operating Mode: **1**)  --->  Parent

Example 3: Three relays\
Child ---> Repeater (Operating Mode: 6) ---> Repeater (Operating Mode: 3) ---> Repeater (Operating Mode: 1) ---> Parent

Relay Net is a tree-type network designed to efficiently deliver upstream packets. Repeaters search for an upper layer (Parent or Repeater with a smaller operating mode setting) and relay to one discovered upper layer device.

Therefore, even if the number of Repeaters increases, the communication volume is less likely to become large compared to Simple Net, but communication occurs to discover and maintain the connection destination.

For details, please see here.

When Performing Static Routing (Directly Specifying Relay Destination)

When relaying with Relay Net, considering the layout as shown in the figure below, Repeater 2 automatically selects either the Parent or Repeater 1 as the connection destination.

Basically, fewer relays tend to have a higher delivery rate to the Parent, but if the Parent is selected as the connection destination for Repeater 2, communication quality may deteriorate due to obstacles between Parent and Repeater 2, resulting in a lower delivery rate to the Parent than when relaying through Repeater 1.

Therefore, this app has a function (static routing function) to specify the connection destination of Repeaters by TWELITE serial number.

Relay Net

When performing static routing, set the route from Repeater 2 to Repeater 1 statically, or set all routes statically.

Setting all routes increases the amount of configuration and does not support redundancy for situations such as Repeater failure or changes in radio conditions, but it eliminates the time to determine the upper communication destination and allows prompt relay operation.

To perform static routing, set the connection destination as shown in the table below: Repeater 1’s connection destination is the Parent’s SID, and Repeater 2’s connection destination is Repeater 1’s SID.

Example: Two-stage relay (Parent ← Repeater 1 ← Repeater 2 ← Child)

TWELITE SID ExampleConnection Destination (A: Access Point Address) Setting ExampleOperating Mode (l:Mode) Setting Example
Parent810F155E-0
Repeater 1810E18E8810F155E (Parent’s SID)※1
Repeater 2810F17FF810E18E8 (Repeater 1’s SID)2

※ If you only want to deal with effects caused by walls as shown in the figure, this setting is unnecessary.

3.1.2 - Interactive Mode (Parent and Repeater App)

Detailed configuration changes via Interactive Mode
You can configure advanced settings of the app in Interactive Mode.

This section describes functions specific to the Parent and Repeater App (App_Wings). For common functions, refer to the top page of the TWELITE APPS manual.

Display Example

A screen like the following will appear:

[CONFIG MENU/App_Wings:ROUTER:0/v1-03-2/SID=8300051A]
a: (0x67720102) Application ID [HEX:32bit]
c: (18        ) Channel(s)
x: (      0x03) RF Power/Retransmissions [HEX:8bit]
b: (115200,8N1) UART Baud Alt. [XXXXX]
o: (0x00000001) Option bits [HEX:32bit]
t: (0xA5A5A5A5) Encryption key [HEX: 32bits]
m: (         1) [1] default, [2-63] to specify the layer of the LayerNetwork.
A: (0x00000000) Relay destination [HEX:32bit]

 [ESC]:Exit [!]:Reset System [*]:Extr Menu [:]:AppSel

Note: m and A are for repeater mode only.

Commands

ItemDefault ValueNotes
aApplication ID0x6772010232bit
cFrequency Channel181126
xTx Power and Retry Count03
Retry Count019 times, 0 = initial value
Tx Power303
bAlternative UART Settings38400,8N1Enabled via option bit
oOption Bits0x00000000Other detailed settings
kEncryption Key0xA5A5A5A532bit
mOperation Mode0Repeater only. 1=normal, 163=layer
ARelay Destination0x00000000Repeater mode only

Details of each command are as follows:

a: Application ID

All devices that communicate must use the same value. This logically separates networks.

c: Frequency Channel

All devices that communicate must use the same value. This physically separates networks.

x: Tx Power and Retry Count

Specify the radio transmission power and the number of additional transmissions per packet.

b: Alternative UART Settings

Specify UART options when Enabling Alternative UART Settings is enabled in the Option Bits.

You can choose a baud rate from 9600 / 19200 / 38400 / 57600 / 115200 / 230400.

o: Option Bits

Specify a 32-bit value. Each bit enables a corresponding setting.

Bit FlagSetting DescriptionDefault
0x00000200Enabling Alternative UART Settings0️⃣
0x00000400Suppress Periodic Transmission Output0️⃣
0x00001000Enable Encrypted Communication0️⃣
0x00002000Enable Plaintext Reception in Encrypted Mode0️⃣
0x00010000Disable LED0️⃣
0x00020000Disable LED in Standby0️⃣

k: Encryption Key

Specify a 32-bit hexadecimal encryption key when Enable Encrypted Communication is set in the Option Bits.

m: Operation Mode

Set 0 for parent mode, and 1 for repeater mode.

When using multi-hop relaying in repeater mode, you can specify the relay layer with a value from 2 to 63.

A: Relay Destination

When performing static routing in repeater mode, specify the Serial ID (0x8???????) of the upstream device. If set to 0x00000000, it will search automatically.

Details of Option Bits

This section explains the settings associated with each bit in the Option Bits value.

00000200: Enabling Alternative UART Settings

Enables b: Alternative UART Settings.

00000400: Suppress Periodic Transmission Output

Suppresses the 1-second periodic transmission and continuous UART output of the Extremely Simple! Standard App and Remote App.

00001000: Enable Encrypted Communication

Enables encrypted communication. The other side must also have encryption enabled.

00002000: Enable Plaintext Reception in Encrypted Mode

Allows reception of unencrypted packets even when encrypted communication is enabled.

00010000: Disable LED

Disables the LED on TWELITE STICK and MONOSTICK.

00020000: Disable LED in Standby

Disables the LED on TWELITE STICK and MONOSTICK while in standby.

3.2 - Parent and Repeater App Manual

v1.2.1 BLUE/RED Stable version
Acts as parent or repeater for child devices of TWELITE APPS and act.

Features

Can process all data packets of TWELITE APPS and act, and can be used as common parent or repeater.

  • Collect data from multiple TWELITE APPS and act such as Extremely Simple! Standard App and Pal App with one MONOSTICK.
  • Can operate multiple systems separately on 16 channels.
  • By setting application ID, multiple systems can coexist on the same channel.
  • Communication range extension with repeater function.

3.2.1 - Operating Modes of Parent and Repeater App

Operating modes of Parent and Repeater App

There are two modes: Parent mode and Repeater mode.

3.2.1.1 - Parent Mode of Parent and Repeater App

Receives data from child devices and sends data to child devices

Receives data sent from child devices and outputs it via the serial port. Also sends commands input from the serial port to child devices.

3.2.1.1.1 - Messages of Parent and Repeater Apps

Output when data is received from child devices

Receives data sent from child devices and outputs it from the serial port in a predefined format.

3.2.1.1.1.1 - Output from the Extremely Simple! Standard App (Parent and Repeater App)

Output format when receiving data from the Extremely Simple! Standard App

0x81: Status Notification from the Peer Device

Outputs the status of the received input signals.

Data Format

#DataDescriptionNotes
charHeaderOnly :
0uint8Logical Device ID of Sender
1uint8Command NumberOnly 0x81
2uint8Packet IdentifierGenerated from Application ID
3uint8Protocol VersionOnly 0x01
4uint8LQI0-255
5uint32Serial ID of Sender0x8???????
9uint8Logical Device ID of Receiver
10uint16Timestamp64 counts per second
12uint8Number of Relays
13uint16Power Supply VoltageUnit: mV
15int8-(Unused)
16uint8Digital SignalsCorresponds to DIx from LSB upwards, 0 means High
If MSB is 1, periodic transmission
17uint8Digital Signal MaskCorresponds to DIx from LSB upwards, 1 means valid
18uint8Converted Value of AI1See Calculation of Analog Signals, 0xFF means unused
19uint8Converted Value of AI2See Calculation of Analog Signals, 0xFF means unused
20uint8Converted Value of AI3See Calculation of Analog Signals, 0xFF means unused
21uint8Converted Value of AI4See Calculation of Analog Signals, 0xFF means unused
22uint8Correction Value of AIxCorresponds to AIx in 2-bit increments from LSB upwards
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Calculation of Analog Signals

The input voltage \(V\) of AIx can be expressed by the received converted value \(e_{r}\) and the correction value \(e_{fr}\) as follows:

$$\begin{align*} V &= e+e_f \\ \text{where} \\ e &= 16e_r \\ e_f &= 4e_{fr} \\ \end{align*}$$

The unit is mV

Example of Output Data

:78811501C98201015A000391000C2E00810301FFFFFFFFFB
#DataDescriptionValue
:charHeader:
780uint8Logical Device ID of Sender0x78
811uint8Command Number0x81
152uint8Packet Identifier0x15
013uint8Protocol Version0x01
C94uint8LQI201/255
8201015A5uint32Serial ID of Sender0x201015A
009uint8Logical Device ID of Receiver0x00
039110uint16TimestampApprox. 14.27 seconds
0012uint8Number of Relays0
0C2E13uint16Power Supply Voltage3118 mV
0015int8-
8116uint8Digital SignalsDI1 L DI2 H
DI3 H DI4 H
(Periodic transmission)
0317uint8Digital Signal MaskDI1 DI2
0118uint8Converted Value of AI116 mV
FF19uint8Converted Value of AI2Unused
FF20uint8Converted Value of AI3Unused
FF21uint8Converted Value of AI4Unused
FF22uint8Correction Value of AIxAI1 0x03
FBuint8Checksum0xFB
charFooter\r
charFooter\n

Data Identification Conditions

The parent and relay apps can receive data from various types of child devices.

To confirm whether the output data is from the Extremely Simple! Standard App, refer to the following:

#DataItemCondition
1uint8Command NumberMust be 0x81
3uint8Protocol VersionMust be 0x01
5uint32Serial ID of SenderMSB must be 1 (i.e., 0x8???????)
--Payload SizeMust be 23 bytes (between : and checksum)

Parser Implementation Examples

0x01: Reception of Arbitrary Data

Data Format

#DataDescriptionNotes
charHeaderOnly :
0uint8Logical Device ID of SenderParent 0x00, Child 0x01-0x64, Unset Child 0x78
1uint8Command NumberOnly 0x01
2[uint8]Arbitrary DataByte array of length \(N\)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

3.2.1.1.1.2 - Output from Remote Control App (Parent and Repeater App)

Output format when data is received from the Remote Control App

0x81: Status Notification from Remote Device

Outputs the state of the received input signal.

Data Format

#DataDescriptionRemarks
charHeader: only
0uint8Source Logical Device ID
1uint8Command NumberOnly 0x81
2uint8Packet IdentifierOnly 0x0F
3uint8Protocol VersionOnly 0x01
4uint8LQI0-255
5uint32Source Serial ID0x8???????
9uint8Destination Logical Device ID
10uint16Timestamp64 counts per second, MSB is internal flag
12uint8Relay Count
13uint16Digital SignalCorresponds to Ix from LSB, 0 is High
15uint16Digital Signal MaskCorresponds to Ix from LSB, 1 means enabled
17uint16Digital Signal FlagCorresponds to Ix from LSB, 1 means interrupt triggered
19uint8UnusedInternal management
uint8ChecksumLRC8
charFooterCR (0x0D/\r)
charFooterLF (0x0A/\n)

Example of Output Data

:01810F01DB8630000200645F000040004F00400049
#DataDescriptionValue
:charHeader:
010uint8Source Logical Device ID0x78
811uint8Command Number0x81
0F2uint8Packet Identifier0x15
013uint8Protocol Version0x01
DB4uint8LQI219/255
863000025uint32Source Serial ID0x6300002
009uint8Destination Logical Device ID0x00
645F10uint16TimestampAbout 401 seconds
0012uint8Relay Count0
004013uint16Digital SignalI7 is Low
004F15uint16Digital Signal MaskI7, I1-I4 are enabled
004017uint16Digital Signal FlagI7 has changed due to interrupt
0019uint8Unused
49uint8Checksum0x49
charFooter\r
charFooter\n

Data Identification Conditions

Parent and Repeater App can receive data from various types of child devices.

To confirm that the output data is from the Remote Control App, refer to the following conditions.

#DataItemCondition
1uint8Command NumberMust be 0x81
3uint8Protocol VersionMust be 0x02
5uint32Source Serial IDMSB must be 1 (0x8???????)
--Payload SizeMust be 20 bytes (between : and checksum)

Example Parser Implementations

3.2.1.1.1.3 - Output from Serial Communication App (Parent and Repeater App)

Output format when receiving data from the serial communication app

Format Mode: Simple Format

Data Format

#DataDescriptionNotes
charHeaderOnly :
0uint8Logical device ID of senderParent 0x00, child 0x01-0x64, unassigned child 0x78
1uint8Command numberValue less than 0x80 specified by sender
2[uint8]Arbitrary dataByte array of length (N)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example of Output Data

:780100112233AABBCCDD13
#DataDescriptionValue
:charHeader:
780uint8Logical device ID of senderUnassigned child ID
011uint8Command number0x01
00112233AABBCCDD2[uint8]Arbitrary dataAs is
13uint8Checksum0x13
charFooter\r
charFooter\n

Conditions to Identify Data

The Parent and Repeater App can receive data from various types of child devices.

To verify whether the output data is from the serial communication app (format mode: simple format), refer to the following:

#DataItemCondition
0uint8Logical device ID of senderMust be less than or equal to 0x64 or equal to 0x78
1uint8Command numberMust be less than 0x80
--Payload sizeMust be between 3 and 82 bytes

Example Implementation of Parser

Format Mode: Extended Format

Data Format

#DataDescriptionNotes
charHeaderOnly :
0uint8Logical device ID of senderParent 0x00, child 0x01-0x64, unassigned child 0x78
1uint8Command numberOnly 0xA0
2uint8Response IDValue specified by sender
3uint32Extended address of senderValue with 0x8 added at the start of serial ID
7uint32Extended address of receiver0xFFFFFFFF when logical device ID is used
11uint8LQIRadio communication quality at reception
12uint16Length of following byte arrayNumber of bytes (M)
14[uint8]Arbitrary dataByte array of length (M)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example of Output Data

:78A0028201015AFFFFFFFFA8000700112233AABBCCC6
#DataDescriptionNotes
:charHeader:
780uint8Logical device ID of senderUnassigned child ID
A01uint8Command number0xA0
022uint8Response ID0x02
8201015A3uint32Extended address of sender0x201015A
FFFFFFFF7uint32Extended address of receiverLogical device ID specified
A811uint8LQI168/255
000712uint16Length of following byte array7 bytes
00112233AABBCC14[uint8]Arbitrary dataAs is
C6uint8Checksum0xC6
charFooter
charFooter

Conditions to Identify Data

The Parent and Repeater App can receive data from various types of child devices.

To verify whether the output data is from the serial communication app (format mode: extended format), refer to the following:

#DataItemCondition
0uint8Logical device ID of senderMust be less than or equal to 0x64 or equal to 0x78
1uint8Command numberMust be 0xA0
2uint8Response IDMust be less than 0x80
3uint32Extended address of senderMSB must be 1 (i.e., 0x8???????)
12uint16Length of following byte arrayMust be payload size - 14 bytes

Example Implementation of Parser

3.2.1.1.1.4 - Output from Pal/Cue/Aria Apps (Parent and Repeater App)

Output format when data is received from Pal, Cue, and Aria apps

3.2.1.1.1.4.1 - Output from PAL App (Parent and Repeater App)

Output format when data is received from the PAL App

General

Data received from the PAL App is represented as a series of sensor data consisting of sensor type and its value.

Below are specific examples according to the product type.

Open/Close Sensor PAL

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x81
14uint8Number of sensor dataOnly 3
Sensor data 1
15uint8Info bitsOnly 0x11
16uint8Data sourceOnly 0x30
17uint8Extended byteOnly 0x08
18uint8Data lengthOnly 2
19uint16DataPower supply voltage (mV)
Sensor data 2
21uint8Info bitsOnly 0x11
22uint8Data sourceOnly 0x30
23uint8Extended byteOnly 0x01
24uint8Data lengthOnly 2
25uint16DataADC1 voltage (mV)
Sensor data 3
27uint8Info bitsOnly 0x00
28uint8Data sourceOnly 0x00
29uint8Extended byteOnly 0x00
30uint8Data lengthOnly 1
31uint8DataMagnetic data
End of sensor data
32uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

:80000000A8001C82012B1E01808103113008020D0C1130010203E40000000101EC6E
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
A84uint8LQI168/255
001C5uint16Sequence number28
82012B1E7uint32Serial ID of sender0x2012B1E
0111uint8Logical device ID of sender0x01
8012uint8Sensor type
8113uint8PAL board version and PAL board IDOpen/Close PAL V1
0314uint8Number of sensor data3
Sensor data 1
1115uint8Info bitsWith extended byte uint16
3016uint8Data sourceVoltage
0817uint8Extended bytePower supply
0218uint8Data length2 bytes
0D0C19uint16Data3340mV
Sensor data 2
1121uint8Info bitsWith extended byte uint16
3022uint8Data sourceVoltage
0123uint8Extended byteADC1
0224uint8Data length2 bytes
03E425uint16Data996mV
Sensor data 3
0027uint8Info bitsNo extended byte uint8
0028uint8Data sourceMagnetic
0029uint8Extended byteNone
0130uint8Data length1 byte
0131uint8DataN pole approached
End of sensor data
EC32uint8Checksum 10xEC
6Euint8Checksum 20x6E
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the PAL App (Open/Close Sensor PAL), refer to the following points.

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and IDMust be 0x81
--Payload size33 bytes

Example Parser Implementations

Environmental Sensor PAL

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x82
14uint8Number of sensor dataOnly 5
Sensor data 1
15uint8Info bitsOnly 0x11
16uint8Data sourceOnly 0x30
17uint8Extended byteOnly 0x08
18uint8Data lengthOnly 2
19uint16DataPower supply voltage (mV)
Sensor data 2
21uint8Info bitsOnly 0x11
22uint8Data sourceOnly 0x30
23uint8Extended byteOnly 0x01
24uint8Data lengthOnly 2
25uint16DataADC1 voltage (mV)
Sensor data 3
27uint8Info bitsOnly 0x05
28uint8Data sourceOnly 0x01
29uint8Extended byteOnly 0x00
30uint8Data lengthOnly 2
31int16DataTemperature data
Sensor data 4
33uint8Info bitsOnly 0x01
34uint8Data sourceOnly 0x02
35uint8Extended byteOnly 0x00
36uint8Data lengthOnly 2
37uint16DataHumidity data
Sensor data 5
39uint8Info bitsOnly 0x02
40uint8Data sourceOnly 0x03
41uint8Extended byteOnly 0x00
42uint8Data lengthOnly 4
43uint32DataIlluminance data
End of sensor data
47uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

​:8000000084811F810EFF6D04808205113008020AEB11300102035A0501000209E3010200020E3A02030004000001BE6C00
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
844uint8LQI132/255
811F5uint16Sequence number33055
810EFF6D7uint32Serial ID of sender0x10EFF6D
0411uint8Logical device ID of sender0x04
8012uint8Sensor type
8213uint8PAL board version and PAL board IDEnvironmental Sensor PAL V1
0514uint8Number of sensor data5
Sensor data 1
1115uint8Info bitsWith extended byte uint16
3016uint8Data sourceVoltage
0817uint8Extended bytePower supply
0218uint8Data length2 bytes
0AEB19uint16Data2795mV
Sensor data 2
1121uint8Info bitsWith extended byte uint16
3022uint8Data sourceVoltage
0123uint8Extended byteADC1
0224uint8Data length2 bytes
035A25uint16Data858mV
Sensor data 3
0527uint8Info bitsNo extended byte int16
0128uint8Data sourceTemperature
0029uint8Extended byteNone
0230uint8Data length2 bytes
09E331int16Data25.31°C
Sensor data 4
0133uint8Info bitsNo extended byte uint16
0234uint8Data sourceHumidity
0035uint8Extended byteNone
0236uint8Data length2 bytes
0E3A37uint16Data36.42%
Sensor data 5
0239uint8Info bitsNo extended byte uint32
0340uint8Data sourceIlluminance
0041uint8Extended byteNone
0442uint8Data length4 bytes
000001BE43uint32Data446lx
End of sensor data
6C47uint8Checksum 10x6C
00uint8Checksum 20x00
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the PAL App (Environmental Sensor PAL), refer to the following points.

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and IDMust be 0x82
--Payload size48 bytes

Example Parser Implementations

Motion Sensor PAL

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x83
14uint8Number of Sensor DataOnly 18
Sensor Data 1
15uint8Info bitsOnly 0x11
16uint8Data sourceOnly 0x30
17uint8Extended byteOnly 0x08
18uint8Data lengthOnly 2
19uint16DataPower supply voltage (mV)
Sensor Data 2
21uint8Info bitsOnly 0x11
22uint8Data sourceOnly 0x30
23uint8Extended byteOnly 0x01
24uint8Data lengthOnly 2
25uint16DataADC1 voltage (mV)
Sensor Data 3
27uint8Info bitsOnly 0x15
28uint8Data sourceOnly 0x04
29uint8Extended byte0x?0 Frequency and sample number
30uint8Data lengthOnly 6
31int16DataAcceleration data
Sensor Data 4
37uint8Info bitsOnly 0x15
38uint8Data sourceOnly 0x04
39uint8Extended byte0x?1 Frequency and sample number
40uint8Data lengthOnly 6
41int16DataAcceleration data
Sensor Data 5
(Omitted)
Sensor Data 18
177uint8Info bitsOnly 0x15
178uint8Data sourceOnly 0x04
179uint8Extended byte0x?F Frequency and sample number
180uint8Data lengthOnly 6
181int16DataAcceleration data
End of sensor data
187uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

:80000000BA002382011CEF01808312113008020D0211300102055C1504400600100010045015044106000800100430150442060000001004381504430600080018043015044406000000180458150445060000002004381504460600080018042815044706FFE80010042015044806FFF00010043815044906FFE80018043015044A06FFF80018044015044B06FFF80018041815044C0600000010042015044D0600000028045015044E0600000008043815044F0600000018043828A5
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
BA4uint8LQI186/255
00235uint16Sequence number35
82011CEF7uint32Serial ID of sender0x2011CEF
0111uint8Logical device ID of sender0x01
8012uint8Sensor type
8313uint8PAL board version and PAL board IDMotion PAL V1
1214uint8Number of Sensor Data18 items
Sensor Data 1
1115uint8Info bitsWith extended byte uint16
3016uint8Data sourceVoltage
0817uint8Extended bytePower supply
0218uint8Data length2 bytes
0D0219uint16Data3330mV
Sensor Data 2
1121uint8Info bitsWith extended byte uint16
3022uint8Data sourceVoltage
0123uint8Extended byteADC1
0224uint8Data length2 bytes
055C25uint16Data1372mV
Sensor Data 3
1527uint8Info bitsWith extended byte int16
0428uint8Data sourceAcceleration
4029uint8Extended byte100Hz, sample 0
0630uint8Data length6 bytes
00100010045031int16DataX16mG/Y16mG/Z1104mG
Sensor Data 4
1537uint8Info bitsWith extended byte int16
0438uint8Data sourceAcceleration
4139uint8Extended byte100Hz, sample 1
0640uint8Data length6 bytes
00080010043041uint16DataX8mG/Y16mG/Z1072mG
Sensor Data 5
(Omitted)
Sensor Data 15
15177uint8Info bitsWith extended byte int16
04178uint8Data sourceAcceleration
4F179uint8Extended byte100Hz, sample 15
06180uint8Data length6 bytes
000000180438181uint32DataX0mG/Y24mG/Z1080mG
End of sensor data
28187uint8Checksum 10x28
A5uint8Checksum 20xA5
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the PAL App (Motion Sensor PAL), refer to the following points.

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and IDMust be 0x83
--Payload size188 bytes

Example Parser Implementations

Notification PAL

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x84
14uint8Number of Sensor DataOnly 3
Sensor Data 1
15uint8Info bitsOnly 0x11
16uint8Data sourceOnly 0x30
17uint8Extended byteOnly 0x08
18uint8Data lengthOnly 2
19uint16DataPower supply voltage (mV)
Sensor Data 2
21uint8Info bitsOnly 0x11
22uint8Data sourceOnly 0x30
23uint8Extended byteOnly 0x01
24uint8Data lengthOnly 2
25uint16DataADC1 voltage (mV)
Sensor Data 3
27uint8Info bitsOnly 0x12
28uint8Data sourceOnly 0x05
29uint8Extended byteOnly 0x04
30uint8Data lengthOnly 4
31uint8DataAcceleration event data
32[uint8]Unused
End of sensor data
35uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

:80000000C9BBC082014C3501808403 113008020D0C 1130010203F9 1205040410000000 97C6
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
C94uint8LQI201/255
BBC05uint16Sequence number48064
82014C357uint32Serial ID of sender0x2014C35
0111uint8Logical device ID of sender0x01
8012uint8Sensor type
8413uint8PAL board version and PAL board IDNotification PAL V1
0314uint8Number of Sensor Data3 items
Sensor Data 1
1115uint8Info bitsWith extended byte uint16
3016uint8Data sourceVoltage
0817uint8Extended bytePower supply
0218uint8Data length2 bytes
0D0C19uint16Data3340mV
Sensor Data 2
1121uint8Info bitsWith extended byte uint16
3022uint8Data sourceVoltage
0123uint8Extended byteADC1
0224uint8Data length2 bytes
03F925uint16Data1017mV
Sensor Data 3
1227uint8Info bitsWith extended byte uint32
0528uint8Data sourceEvent
0429uint8Extended byteAcceleration event
0430uint8Data length4 bytes
1031uint8DataMove
00000032[uint8]
End of sensor data
9735uint8Checksum 10x97
C6uint8Checksum 20xC6
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the PAL App (Notification PAL), refer to the following points.

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and IDMust be 0x84
--Payload size36 bytes

3.2.1.1.1.4.2 - Output from CUE App (Parent and Repeater App)

Output format when receiving data from the CUE App

TWELITE CUE Mode

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x05
14uint8Number of sensor dataOnly 15
Sensor Data 1
15uint8Info bitsOnly 0x00
16uint8Data sourceOnly 0x34
17uint8Extended byteOnly 0x00
18uint8Data lengthOnly 3
19[uint8]DataPacket property data
Sensor Data 2
22uint8Info bitsOnly 0x12
23uint8Data sourceOnly 0x05
24uint8Extended byte0x35, 0x04, or 0x00
25uint8Data lengthOnly 4
26uint32DataEvent data
Sensor Data 3
30uint8Info bitsOnly 0x11
31uint8Data sourceOnly 0x30
32uint8Extended byteOnly 0x08
33uint8Data lengthOnly 2
34uint16DataPower supply voltage (mV)
Sensor Data 4
36uint8Info bitsOnly 0x11
37uint8Data sourceOnly 0x30
38uint8Extended byteOnly 0x01
39uint8Data lengthOnly 2
40uint16DataVoltage of ADC1 (mV)
Sensor Data 5
42uint8Info bitsOnly 0x00
43uint8Data sourceOnly 0x00
44uint8Extended byteOnly 0x00
45uint8Data lengthOnly 1
46uint8DataMagnetic data
Sensor Data 6
47uint8Info bitsOnly 0x15
48uint8Data sourceOnly 0x04
49uint8Extended byte0x?0 Frequency and sample number
50uint8Data lengthOnly 6
51[int16]DataAcceleration data
Sensor Data 7
57uint8Info bitsOnly 0x15
58uint8Data sourceOnly 0x04
59uint8Extended byte0x?1 Frequency and sample number
60uint8Data lengthOnly 6
61[int16]DataAcceleration data
Sensor Data 8
(Omitted)
Sensor Data 15
137uint8Info bitsOnly 0x15
138uint8Data sourceOnly 0x04
139uint8Extended byte0x?9 Frequency and sample number
140uint8Data lengthOnly 6
141int16DataAcceleration data
End of sensor data
147uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to Checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Output Data Example

:80000000CF7F7382019E3B0180050F003400038135001205040406000000113008020B8611300102042E000000018015044006FFF00010FC1815044106FFF00018FC1815044206FFF00010FC0015044306FFF80000FC1015044406FFF00010FC1815044506FFE00018FBF815044606FFE80000FC0015044706FFE80010FBF815044806FFE80010FC0815044906FFE80010FC080C0E
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
CF4uint8LQI207/255
7F735uint16Sequence number32627
82019E3B7uint32Serial ID of sender0x2019E3B
0111uint8Logical device ID of sender0x01
8012uint8Sensor type
0513uint8PAL board version and PAL board IDTWELITE CUE
0F14uint8Number of sensor data15 items
Sensor Data 1
0015uint8Info bitsNo extended byte uint8
3416uint8Data sourcePacket property
0017uint8Extended byteNone
0318uint8Data length3 bytes
81350019[uint8]DataID 129, timer event occurred
Sensor Data 2
1222uint8Info bitsExtended byte present uint32
0523uint8Data sourceEvent
0424uint8Extended byteAcceleration event
0425uint8Data length4 bytes
0600000026uint32DataDice: 6
Sensor Data 3
1130uint8Info bitsExtended byte present uint16
3031uint8Data sourceVoltage
0832uint8Extended bytePower supply voltage
0233uint8Data length2 bytes
0B8634uint16Data2950 mV
Sensor Data 4
1136uint8Info bitsExtended byte present uint16
3037uint8Data sourceVoltage
0138uint8Extended byteVoltage of ADC1
0239uint8Data length2 bytes
042E40uint16Data1070 mV
Sensor Data 5
0042uint8Info bitsNo extended byte uint8
0043uint8Data sourceMagnetic
0044uint8Extended byteNone
0145uint8Data length1 byte
8046uint8DataNo magnet (periodic transmit)
Sensor Data 6
1547uint8Info bitsExtended byte present int16
0448uint8Data sourceAcceleration data
4049uint8Extended byte100Hz, sample 0
0650uint8Data length6 bytes
FFF00010FC1851[int16]DataX-16mG/Y16mG/Z-1000mG
Sensor Data 7
1557uint8Info bitsExtended byte present int16
0458uint8Data sourceAcceleration data
4159uint8Extended byte100Hz, sample 1
0660uint8Data length6 bytes
FFF00018FC1861[int16]DataX-16mG/Y24mG/Z-1000mG
Sensor Data 8
(Omitted)
Sensor Data 15
15137uint8Info bitsExtended byte present int16
04138uint8Data sourceAcceleration data
49139uint8Extended byte100Hz, sample 9
06140uint8Data length6 bytes
FFE80010FC08141int16DataX-24mG/Y16mG/Z-1016mG
End of sensor data
0C147uint8Checksum 10x0C
0Euint8Checksum 20x0E
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the CUE App (TWELITE CUE mode), refer to the following points:

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and PAL board IDMust be 0x05
--Payload sizeMust be 148 bytes

Example Parser Implementations

Magnet Sensor PAL Mode

Motion Sensor PAL Mode (Acceleration Measurement Mode)

Motion Sensor PAL Mode (Move / Dice Mode)

Data Format

#DataDescriptionRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x03
14uint8Number of sensor dataOnly 04
Sensor Data 1
15uint8Info bitsOnly 0x00
16uint8Data sourceOnly 0x34
17uint8Extended byteOnly 0x00
18uint8Data lengthOnly 3
19[uint8]DataPacket property data
Sensor Data 2
22uint8Info bitsOnly 0x12
23uint8Data sourceOnly 0x05
24uint8Extended byteOnly 0x04
25uint8Data lengthOnly 4
26uint32DataEvent data
Sensor Data 3
30uint8Info bitsOnly 0x11
31uint8Data sourceOnly 0x30
32uint8Extended byteOnly 0x08
33uint8Data lengthOnly 2
34uint16DataPower supply voltage (mV)
Sensor Data 4
36uint8Info bitsOnly 0x11
37uint8Data sourceOnly 0x30
38uint8Extended byteOnly 0x01
39uint8Data lengthOnly 2
40uint16DataVoltage of ADC1 (mV)
End of sensor data
42uint8Checksum 1CRC8 up to this point
uint8Checksum 2LRC8 up to Checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Output Data Example

Below is an example for Dice Mode. For Move Mode, the event in Sensor Data 2 will differ.

:80000000B400048106664801800304003400038035001205040403000000113008020D2011300102052C59B7
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
B14uint8LQI177/255
00085uint16Sequence number8
810666487uint32Serial ID of sender0x2019E3B
0111uint8Logical device ID of sender0x1066648
8012uint8Sensor type
0313uint8PAL board version and PAL board IDTWELITE CUE Dice / Move
0414uint8Number of sensor data4 items
Sensor Data 1
0015uint8Info bitsNo extended byte uint8
3416uint8Data sourcePacket property
0017uint8Extended byteNone
0318uint8Data length3 bytes
80350019[uint8]DataID 128, event occurred (only ADC1 and power supply)
Sensor Data 2
1222uint8Info bitsExtended byte present uint32
0523uint8Data sourceEvent
0424uint8Extended byteAcceleration event
0425uint8Data length4 bytes
0300000026uint32DataDice Mode, die: 3
Sensor Data 3
1130uint8Info bitsExtended byte present uint16
3031uint8Data sourceVoltage
0832uint8Extended bytePower supply voltage
0233uint8Data length2 bytes
0D2034uint16Data3360 mV
Sensor Data 4
1136uint8Info bitsExtended byte present uint16
3037uint8Data sourceVoltage
0138uint8Extended byteVoltage of ADC1
0239uint8Data length2 bytes
052C40uint16Data1324 mV
End of sensor data
5942uint8Checksum 10x0C
B7uint8Checksum 20x0E
charFooter'\r'
charFooter'\n'

Data Identification Criteria

The Parent and Repeater App can receive data from various types of child devices.

To check whether the output data is from the CUE App (Move or Dice Mode of Motion Sensor PAL Mode), refer to the following points:

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor typeMust be 0x80
13uint8PAL board version and PAL board IDMust be 0x03
--Payload sizeMust be 43 bytes

Example Parser Implementations

3.2.1.1.1.4.3 - Output from Aria App (Parent and Repeater App)

Output format when data is received from the Aria app

TWELITE ARIA Mode

Data Format

#DataContentRemarks
charHeaderOnly :
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0 to 255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDOnly 0x06
14uint8Number of sensor dataOnly 7
Sensor data 1
15uint8Info bitsOnly 0x00
16uint8Data sourceOnly 0x34
17uint8Extension byteOnly 0x00
18uint8Data lengthOnly 3
19[uint8]DataPacket property data
Sensor data 2
22uint8Info bitsOnly 0x12
23uint8Data sourceOnly 0x05
24uint8Extension byte0x35 or 0x00
25uint8Data lengthOnly 4
26uint32DataEvent data
Sensor data 3
30uint8Info bitsOnly 0x11
31uint8Data sourceOnly 0x30
32uint8Extension byteOnly 0x08
33uint8Data lengthOnly 2
34uint16DataPower supply voltage (mV)
Sensor data 4
36uint8Info bitsOnly 0x11
37uint8Data sourceOnly 0x30
38uint8Extension byteOnly 0x01
39uint8Data lengthOnly 2
40uint16DataADC1 voltage (mV)
Sensor data 5
42uint8Info bitsOnly 0x00
43uint8Data sourceOnly 0x00
44uint8Extension byteOnly 0x00
45uint8Data lengthOnly 1
46uint8DataMagnetic data
Sensor data 6
47uint8Info bitsOnly 0x05
48uint8Data sourceOnly 0x01
49uint8Extension byteOnly 0x00
50uint8Data lengthOnly 2
51int16DataTemperature data
Sensor data 7
53uint8Info bitsOnly 0x01
54uint8Data sourceOnly 0x02
55uint8Extension byteOnly 0x00
56uint8Data lengthOnly 2
57uint16DataHumidity data
End of sensor data
59uint8Checksum 1CRC8 up to previous byte
uint8Checksum 2LRC8 up to Checksum 1
charFooterCR (0x0D/\r)
charFooterLF (0x0A/\n)

Data Identification Conditions

Parent and Repeater App can receive data from various types of child devices.

To confirm that the output data is from the Aria App (TWELITE ARIA Mode), refer to the following:

#DataItemCondition
0uint32Serial ID of repeaterMSB is 1
7uint32Serial ID of senderMSB is 1
12uint8Sensor type0x80
13uint8PAL board version and PAL board ID0x06
--Payload sizeMust be 60 bytes

Parser Implementation Examples

Open/Close Sensor Pal Mode

3.2.1.1.1.4.4 - Details of Output from Pal, Cue, and Aria Apps (Parent and Repeater App)

Details of the common output format for Pal, Cue, and Aria apps
Data received from child devices of Pal, Cue, and Aria apps are output according to a common format. This section details that format. For specific output examples of each app, see the app pages.

Overall

Data Format

#DataDescriptionNotes
charHeader: only
0uint32Serial ID of repeater80000000 if no repeater
4uint8LQI0-255
5uint16Sequence number
7uint32Serial ID of sender0x8???????
11uint8Logical device ID of sender
12uint8Sensor typeOnly 0x80
13uint8PAL board version and PAL board IDe.g. 0x81
14uint8Number of sensor data
15[uint8]List of sensor dataByte array of length (N)
15+(N)uint8Checksum 1CRC8 up to previous byte
uint8Checksum 2LRC8 up to Checksum 1
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

:80000000A8001C82012B1E01808103113008020D0C1130010203E40000000101EC6E
#DataDescriptionValue
:charHeader:
800000000uint32Serial ID of repeaterNo repeater
A84uint8LQI168/255
001C5uint16Sequence number28
82012B1E7uint32Serial ID of sender0x2012B1E
0111uint8Logical device ID of sender0x01
8012uint8Sensor type-
8113uint8PAL board version and PAL board ID0x81
0314uint8Number of sensor data3
1130...010115[uint8]List of sensor dataByte array of length 17
EC15+17uint8Checksum 10xEC
6Euint8Checksum 20x6E
charFooter'\r'
charFooter'\n'

Sensor Data

Data Format

#DataDescriptionNotes
0uint8Info bitsData type and presence of extension byte
1uint8Data sourceType of sensor value
2uint8Extension byteAdditional info for sensor value
3uint8Data lengthLength of sensor value
4[uint8]DataSensor value

Example Output Data

113008020D0C
#DataDescriptionValue
110uint8Info bitsExtension byte present, uint16
301uint8Data sourceVoltage
082uint8Extension bytePower supply voltage
023uint8Data length2 bytes
0D0C4[uint8]Data3340 mV

Info Bits

Indicates the data type of the sensor value, presence of extension byte, and read error status.

bit76543210
FunctionERR--EXT-TYP:2TYP:1TYP:0

Each function indicates the following:

FunctionDescriptionValueMeaning
ERRRead error presence0Normal
1Error present
EXTExtension byte presence0No extension byte
1Extension byte present
TYPData type000uint8
001uint16
010uint32
011N/A
100int8
101int16
110int32
111[uint8]

Data Source

Indicates the type of sensor value.

ValueDescription
0x00Magnetic
0x01Temperature
0x02Humidity
0x03Illuminance
0x04Acceleration
0x05Event
0x30Voltage
0x34Packet properties

Extension Byte

Indicates additional information such as index for continuous data.

For data sources Magnetic / Temperature / Humidity / Illuminance / Packet Properties

None

For data source Acceleration

Indicates attributes of acceleration sample data.

bit76543210
FunctionSFQ:2SFQ:1SFQ:0SNM:4SNM:3SNM:2SNM:1SNM:0

Each function indicates the following:

FunctionDescriptionValueMeaning
SFQSampling frequency000 (`0x00SNM`)
001 (`0x20SNM`)
010 (`0x40SNM`)
011 (`0x60SNM`)
100 or higherUndefined
SNMSample number0-31Oldest first

For data source Event

Indicates cause of event occurrence.

ValueDescription
0x00Magnetic
0x01Temperature
0x02Humidity
0x03Illuminance
0x04Acceleration
0x31Digital input
0x35Timer

For data source Voltage

Indicates target.

ValueDescription
0x01ADC1
0x02ADC2
0x03ADC3
0x04ADC4
0x08Power supply

Data Length

Indicates the number of bytes of the following data.

Data

Represents the sensor value.

For data source Magnetic

Data type is uint8.

ValueDescription
0x00No magnet
0x01North pole approached
0x02South pole approached
0x80No magnet (periodic send)
0x81North pole nearby (periodic send)
0x82South pole nearby (periodic send)

For data source Temperature

Data type is int16.

Represents temperature in Celsius multiplied by 100.

For data source Humidity

Data type is uint16.

Represents relative humidity multiplied by 100.

For data source Illuminance

Data type is uint32.

Represents illuminance in lux.

For data source Acceleration

Three int16 values follow.

X, Y, Z axis values (mG) total 6 bytes.

byte012345
ContentX:15-8X:7-0Y:15-8Y:7-0Z:15-8Z:7-0

For data source Event

Four uint8 values follow.

The first data indicates the event content, the rest are unused.

byte0123
ContentUsedUnusedUnusedUnused
Extension byte for Magnetic
First valueDescription
0x00No magnet
0x01North pole nearby
0x02South pole nearby
Extension byte for Acceleration
First valueDescription
0x00Stationary (Move mode)
0x01Dice: 1
0x02Dice: 2
0x03Dice: 3
0x04Dice: 4
0x05Dice: 5
0x06Dice: 6
0x08Shake
0x10Move
Extension byte for Timer
First valueDescription
0x01Woken by timer

For data source Voltage

Data type is uint16.

Represents voltage in mV.

For data source Packet Properties

Three uint8 values follow.

byte012
DataPacket IDRoot cause of wake-upCondition of wake-up

Each data indicates the following:

DataValueDescription
Packet ID0No event, only ADC1 and power voltage
1-127No event, other data present
128Event present, only ADC1 and power voltage
129-255Event present, other data present
Root cause of wake-up0x00Magnetic
0x01Temperature
0x02Humidity
0x03Illuminance
0x04Acceleration
0x31Digital input
0x35Timer
Condition of wake-up0x00Event occurred
0x01Value changed
0x02Value exceeded threshold
0x03Value fell below threshold
0x04Value met range

3.2.1.1.1.5 - Output from act (Parent and Repeater App)

Output format when data is received from act

Data Received from act

Data Format

#DataContentRemarks
charHeader: only
0uint8Source Logical Device ID
1uint8Command Typeonly 0xAA
2uint8Response ID0x00-0x7F
3uint32Source Serial ID
7uint32Destination Serial ID00000000 when specifying logical device ID
11uint8LQI0-255
12uint16Number of data bytes
14[uint8]Arbitrary dataLength (N) bytes
uint8ChecksumLRC8
charFooterCR (0x0D/\r)
charFooterLF (0x0A/\n)

Example of Output Data

:FEAA008201015A00000000B7000F424154310F0CEE000B03FF03FF03FF92
#DataContentValue
:charHeader:
FE0uint8Source Logical Device ID0xFE
AA1uint8Command Type0xAA
002uint8Response ID0x00
8201015A3uint32Source Serial ID0x201015A
000000007uint32Destination Serial IDLogical Device ID specified
B711uint8LQI183/255
000F12uint16Number of data bytes15 bytes
424154310F0CEE000B03FF03FF03FF14[uint8]Arbitrary dataAs is
92uint8Checksum0x92
charFooter\r
charFooter\n

3.2.1.1.1.6 - Output from Wireless Tag App (Parent and Repeater App)

Output format when data is received from the Wireless Tag App
This section describes the output when connecting main sensors to the child device.

Analog Sensor

Data Format

#DataDescriptionNotes
charHeader: only
0uint32Relay device serial ID80000000 if no relay
4uint8LQI0-255
5uint16Sequence number
7uint32Source serial ID
11uint8Source logical device ID
12uint8Sensor type
13uint8Power supply voltage (mV)See Power Supply Voltage Calculation
14uint16ADC1 voltage
16uint16ADC2 voltage
18uint32Unused
22uint8Checksum

Example Output Data

:80000000B700628201015A0010DF08FD09A300000000E9
#DataDescriptionValue
:charHeader:
800000000uint32Relay device serial IDNo relay
B74uint8LQI183/255
00625uint16Sequence number98
8201015A7uint32Source serial ID0x201015A
0011uint8Source logical device ID0x00
1012uint8Sensor typeAnalog sensor
DF13uint8Power supply voltage (mV)3330mV
08FD14uint16ADC1 voltage2301mV
09A316uint16ADC2 voltage2467mV
0000000018uint32Unused
E922uint8Checksum0xE9
charFooter\r
charFooter\n

Accelerometer (ADXL34x / TWELITE 2525A)

Data Format

#DataDescriptionNotes
charHeader: only
0uint32Relay device serial ID80000000 if no relay
4uint8LQI0-255
5uint16Sequence number
7uint32Source serial ID
11uint8Source logical device ID
12uint8Sensor type
13uint8Power supply voltage (mV)See Power Supply Voltage Calculation
14uint16ADC1 voltage
16uint16ADC2 voltage
18uint8Sensor mode number
19int16X-axis accelerationUnit: mG*10
21int16Y-axis accelerationUnit: mG*10
23int16Z-axis accelerationUnit: mG*10
25uint8Checksum

Example Output Data

:8000000063001781013C850035DF057702F2000000FF96FFF0BB
#DataDescriptionValue
:charHeader:
800000000uint32Relay device serial IDNo relay
634uint8LQI99/255
00175uint16Sequence number23
81013C857uint32Source serial ID0x1013C85
0011uint8Source logical device ID0x00
3512uint8Sensor typeAccelerometer (ADXL34x)
DF13uint8Power supply voltage (mV)3330mV
057714uint16ADC1 voltage1399mV
02F216uint16ADC2 voltage754mV
0018uint8Sensor mode numberNormal
000019int16X-axis acceleration0mG
FF9621int16Y-axis acceleration-1060mG
FFF023int16Z-axis acceleration-160mG
BB25uint8Checksum0xBB
charFooter\r
charFooter\n

Switch

Data Format

#DataDescriptionNotes
charHeader: only
0uint32Relay device serial ID80000000 if no relay
4uint8LQI0-255
5uint16Sequence number
7uint32Source serial ID
11uint8Source logical device ID
12uint8Sensor type
13uint8Power supply voltage (mV)See Power Supply Voltage Calculation
14uint16ADC1 voltage
16uint16ADC2 voltage
18uint8Sensor mode number0 is Hi→Lo, 1 is Lo→Hi
19uint8DI1 state1 is Lo
20uint8Unused
21uint8Checksum

Example Output Data

:800000009C00118201015A00FEDF000709A300010064
#DataDescriptionValue
:charHeader
800000000uint32Relay device serial IDNo relay
9C4uint8LQI156/255
00625uint16Sequence number98
8201015A7uint32Source serial ID0x201015A
0011uint8Source logical device ID0x00
FE12uint8Sensor typeSwitch
DF13uint8Power supply voltage (mV)3330mV
000714uint16ADC1 voltage7mV
09A316uint16ADC2 voltage2467mV
0018uint8Sensor mode numberHi→Lo
0119uint8DI1 stateLo
0020uint8Unused
6421uint8Checksum0x64
charFooter\r
charFooter\n

Power Supply Voltage Calculation

The power supply voltage \(V_{cc}\) can be expressed using the received value \(e_{cc}\) as follows:

$$\begin{cases} V_{cc} = 1950+5e_{cc} & (e_{cc} <= 170) \\ V_{cc} = 2800+10(e_{cc}-170) & (e_{cc} > 170) \end{cases}$$

Unit is mV

3.2.1.1.2 - Transmit Command of Parent and Repeater App

Input for sending data to the child

Commands entered from the serial port in the specified format are sent to the child.

3.2.1.1.2.1 - Input to the Extremely Simple! Standard App (Parent and Repeater App)

Commands to control the output of the Extremely Simple! Standard App
You can control the output of the Extremely Simple! Standard App.

Digital and Analog Input/Output

0x80: Change Output of the Target Device

Controls the output signals of the target device.

Data Format

#DataDescriptionNotes
charHeader: only
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command Number0x80 only
2uint8Format Version0x01 only
3uint8Digital SignalCorresponds to DOx from LSB, 0 means High
4uint8Digital Signal MaskCorresponds to DOx from LSB, 1 means Enabled
5uint16PWM1 Signal0-1024, 0xFFFF means Disabled
7uint16PWM2 Signal0-1024, 0xFFFF means Disabled
9uint16PWM3 Signal0-1024, 0xFFFF means Disabled
11uint16PWM4 Signal0-1024, 0xFFFF means Disabled
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

3.2.1.1.2.2 - Input to the Serial Communication App (Parent and Repeater App)

Commands to send data to the serial communication app
You can send data to the child device of the serial communication app (format mode, simple format).

UART

Format Mode: ASCII Simple Format

App_Wings v1.3 and later support the simple format of format mode (A).

Data Format

#DataDescriptionNotes
charHeaderOnly :
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command NumberAny value less than 0x80
2[uint8]Arbitrary DataByte sequence of length \(N\) (recommended \(N\leqq80\))
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

3.2.1.1.2.3 - Input to the PAL App (Notification PAL) (Parent and Repeater App)

Commands to control the LED of the Notification PAL
You can control the LED of the Notification PAL.
:0190010004000169[CR][LF]
 ^1^2^3^^^^^^^4^5
No.BytesMeaningExample DataNotes
11Destination Logical Device ID01

Specify the logical device ID of the destination TWELITE PAL.
Valid values range from 0x01 to 0x64.

21Command Type90
31Number of Command Parameters01Specify the number of command parameters. For example, set to 1 if specifying one command parameter, or 2 if specifying two.
4Number of Commands x 4Command Parameters00040001

Specify parameters such as events and LED colors.
See the command parameters section for details.

51Checksum69

Calculate the sum of bytes 1 to 4 within 8 bits and take the two’s complement. In other words, the sum of all data bytes plus the checksum byte equals zero within 8 bits.
The checksum byte is represented by two ASCII characters.
For example, in 00A01301FF123456, the sum 0x00 + 0xA0 + … + 0x56 = 0x4F, and its two’s complement is 0xB1 (i.e., 0x4F + 0xB1 = 0).
The checksum can be omitted by using ‘X’ as the checksum.

62Footer[CR][LF]Specify [CR] (0x0D) [LF] (0x0A). However, if the checksum is omitted with ‘X’, the footer can also be omitted.

Command Parameters

Combine 4-byte command parameters to specify commands.

0x00: Send Event ID

The TWELITE PAL has predefined behaviors for each received event ID. This parameter sends an event ID to the destination TWELITE PAL to trigger the configured behavior.

No.BytesContentNotes
11Command Parameter ID0x00
21Destination PAL ID

Specify the destination PAL ID.
0x04: Notification PAL
0xFF: All TWELITE PALs

31UnusedFixed at 0x00
41Event IDSpecify event ID from 0 to 16

0x01: Send LED Color, Blinking Pattern, and Brightness

Send the LED color, blinking pattern, and brightness to the destination Notification PAL.

No.BytesContentNotes
11Command Parameter ID0x01
21Color

0: Red
1: Green
2: Blue
3: Yellow
4: Purple
5: Cyan
6: White
7: Warm White

31Blinking Pattern

0: Always on
1-3: Blinking patterns (higher value means faster blinking)

41Brightness

0: Off
0x01–0x0F: Brightness (higher value means brighter)

0x02: Send Lighting Duration

Send the lighting duration of the Notification PAL’s LED.

No.BytesContentNotes
11Command Parameter ID0x02
21UnusedFixed at 0xFF
31UnusedFixed at 0x00
41Lighting DurationSpecified in seconds (0 means always on)

0x03: Specify LED Color in RGBW

Send the LED lighting color of the Notification PAL in RGBW.

No.BytesContentNotes
11Command Parameter ID0x03
21UnusedFixed at 0xFF
32LED Lighting Color

Specify 4 bits each for RGBW in order from LSB.

Higher value means brighter.

0x04: Specify Blinking Parameters

Send the blinking cycle and duty of the Notification PAL’s LED.

No.BytesContentNotes
11Command Parameter ID0x04
21UnusedFixed at 0xFF
31Blinking Time Ratio

Specify from 0x00 to 0xFF.

Higher value means longer ON time per cycle.

0x7F means ON for half of the cycle.

41Blinking Cycle

Specify from 0x00 to 0xFF.

Each increment increases the blinking cycle by about 0.04s.

0x17 corresponds to a 1-second cycle.

Command Examples

Example 1: Send Event

Command example to send event 1 to the NOTICE PAL with logical device ID 1.

:0190010004000169
 ^1^2^3^4^5^6^7^8
No.BytesMeaningExample DataExplanation of Example DataNotes
11Destination Logical Device ID01Logical device ID of the destination is 0x01
21Command Type900x90 commandFixed at 90
31Number of Commands01One command
41Command ID00Command 00
51Destination PAL ID04Sent to Notification PAL
61Unused00
71Event ID01Event 10x00 to 0x10
81Checksum69

Example 2: Send LED Lighting Color to Notification PAL

Command to send LED lighting color with brightness 8 and slow blinking white to the NOTICE PAL with logical device ID 1.

:019001010601085E
 ^1^2^3^4^5^6^7^8
No.BytesMeaningExample DataExplanation of Example DataNotes
11Destination Logical Device ID01Logical device ID of the destination is 0x01
21Command Type900x90 commandFixed at 90
31Number of Commands01One command
41Command Parameter ID01Command parameter ID 0x01
51Color06White
61Blinking Pattern01Blinking
71Brightness08Brightness 8Range 0x00 to 0x0F
81Checksum5E

Example 3: Send LED Lighting Color and Lighting Duration to Notification PAL

Command to light up purple and turn off after 1 second for the NOTICE PAL with logical device ID 1.

:0190020104000802FF00015E
 ^1^2^3^4^5^6^7^8^9^a^b^c
No.BytesMeaningExample DataExplanation of Example DataNotes
11Destination Logical Device ID01Logical device ID of the destination is 0x01
21Command Type900x90 commandFixed at 90
31Number of Commands02Two commands
41Command Parameter ID01Command parameter ID 0x01
51Color04Purple
61Blinking Pattern00Always on
71Brightness08Brightness 8Range 0x00 to 0x0F
81Command Parameter ID02Command parameter ID 0x02
91UnusedFF
a1Unused00
b1Lighting Duration01Turns off after 1 second
c1Checksum5E

Example 4: Send Detailed Lighting Color to Notification PAL

Command to light up purple for the NOTICE PAL with logical device ID 1.

:01900103FF0F0459
 ^1^2^3^4^5^^^6^7
No.BytesMeaningExample DataExplanation of Example DataNotes
11Destination Logical Device ID01Logical device ID of the destination is 0x01
21Command Type900x90 commandFixed at 90
31Number of Commands01One command
41Command Parameter ID03Command parameter ID 0x03
51UnusedFF
62LED Lighting Color0F04Lights blue at 15 and red at 4 brightness

Specify 4 bits each for RGBW in order from LSB (0–15).

Higher value means brighter.

71Checksum59

Example 5: Send LED Lighting Color and Lighting Duration to Notification PAL

Command to light up purple and turn off after 1 second for the NOTICE PAL with logical device ID 1.

:0190020104000802FF00015E
 ^1^2^3^4^5^6^7^8^9^a^b^c
No.BytesMeaningExample DataExplanation of Example DataNotes
11Destination Logical Device ID01Logical device ID of the destination is 0x01
21Command Type900x90 commandFixed at 90
31Number of Commands02Two commands
41Command Parameter ID01Command parameter ID 0x01
51Color04Purple
61Blinking Pattern00Always on
71Brightness08Brightness 8Range 0x00 to 0x0F
81Command Parameter ID02Command parameter ID 0x02
91UnusedFF
a1Unused00
b1Lighting Duration01Turns off after 1 second
c1Checksum5E

3.2.1.2 - Repeater Mode of Parent and Repeater App

Retransmit data received from Child or Parent
In repeater mode, retransmitting received packets can extend the communication range between Child and Parent.

Example Settings

To use as a repeater, set the Operating Mode in interactive mode to 1 or higher.

Relay Methods

TWELITE NET provides two major relay methods for wireless packet delivery, as shown in the table below, which differ depending on the application. This app can identify and relay packets of the applications shown in the table below.

Relay MethodSupported Applications
Simple NetExtremely Simple! Standard App, Remote Control App, Serial Communication App, ACT
Relay NetWireless Tag App, PAL App, CUE App

Relay Using Simple Net

When relaying applications using Simple Net, setting the operating mode to 1 or higher allows up to three relays.

For example, in case 1., if there are up to 3 Repeaters between the Parent and Child, data will reach the Parent, but in case 2., if there are 4 or more Repeaters, data will not reach the Parent.

1. Child  --->  Repeater  --->  Repeater  --->  Repeater  --->  Parent
   → Parent can receive Child's data relayed 3 times.
2. Child  --->  Repeater  --->  Repeater  --->  Repeater  --->  Repeater  -x->  Parent
   → Stops relaying at the 4th relay.

Relaying with Simple Net basically uses broadcast communication and relays all received packets. The advantage is that communication to form and maintain the relay network is not necessary, but the disadvantage is that communication volume can explode as the number of Repeaters increases.

For details, please refer to here.

Relay Using Relay Net

For relaying data of applications using Relay Net with one stage of relay, set the operating mode value to 1.

When performing multiple relays, increase the operating mode setting value as the distance from the Parent increases. (It is acceptable if the setting values are in ascending order even if some values are skipped.)

The maximum number of relays for this method is up to 63 times.

Example 1: One relay\
Child ---> Repeater (Operating Mode: 1) ---> Parent

Example 2: Two relays\
Child  --->  Repeater (Operating Mode: 2) --->  Repeater (Operating Mode: **1**)  --->  Parent

Example 3: Three relays\
Child ---> Repeater (Operating Mode: 6) ---> Repeater (Operating Mode: 3) ---> Repeater (Operating Mode: 1) ---> Parent

Relay Net is a tree-type network designed to efficiently deliver upstream packets. Repeaters search for an upper layer (Parent or Repeater with a smaller operating mode setting) and relay to one discovered upper layer device.

Therefore, even if the number of Repeaters increases, the communication volume is less likely to become large compared to Simple Net, but communication occurs to discover and maintain the connection destination.

For details, please see here.

When Performing Static Routing (Directly Specifying Relay Destination)

When relaying with Relay Net, considering the layout as shown in the figure below, Repeater 2 automatically selects either the Parent or Repeater 1 as the connection destination.

Basically, fewer relays tend to have a higher delivery rate to the Parent, but if the Parent is selected as the connection destination for Repeater 2, communication quality may deteriorate due to obstacles between Parent and Repeater 2, resulting in a lower delivery rate to the Parent than when relaying through Repeater 1.

Therefore, this app has a function (static routing function) to specify the connection destination of Repeaters by TWELITE serial number.

Relay Net

When performing static routing, set the route from Repeater 2 to Repeater 1 statically, or set all routes statically.

Setting all routes increases the amount of configuration and does not support redundancy for situations such as Repeater failure or changes in radio conditions, but it eliminates the time to determine the upper communication destination and allows prompt relay operation.

To perform static routing, set the connection destination as shown in the table below: Repeater 1’s connection destination is the Parent’s SID, and Repeater 2’s connection destination is Repeater 1’s SID.

Example: Two-stage relay (Parent ← Repeater 1 ← Repeater 2 ← Child)

TWELITE SID ExampleConnection Destination (A: Access Point Address) Setting ExampleOperating Mode (l:Mode) Setting Example
Parent810F155E-0
Repeater 1810E18E8810F155E (Parent’s SID)※1
Repeater 2810F17FF810E18E8 (Repeater 1’s SID)2

※ If you only want to deal with effects caused by walls as shown in the figure, this setting is unnecessary.

3.2.2 - Interactive Mode (Parent and Repeater App)

Detailed setting changes using Interactive Mode
You can perform detailed app settings in Interactive Mode.

This section explains features specific to the Parent and Repeater App (App_Wings). For common features, please refer to the TWELITE APPS Manual Top Page.

Display Example

The screen shown below will be displayed.

[CONFIG MENU/App_Wings:0/v1-02-1/SID=820163B2]
a: (0x67720102) Application ID [HEX:32bit]
c: (18        ) Channels Set
x: (      0x03) RF Power/Retry [HEX:8bit]
b: (38400,8N1 ) UART Baud [9600-230400]
o: (0x00000000) Option Bits [HEX:32bit]
k: (0xA5A5A5A5) Encryption Key [HEX:32bit]
m: (         0) Mode (Parent or Router)
A: (0x00000000) Access point address [HEX:32bit]

 [ESC]:Back [!]:Reset System [M]:Extr Menu

Commands

ItemDefaultNotes
aApplication ID0x6772010232bit
cFrequency Channel1811-26
xRetry Count and Transmission Power03
Retry Count01-9 times, 0 means default 0 times
Transmission Power30-3
bUART Alternative Settings38400,8N1Enabled by option bit
oOption Bits0x00000000Other detailed settings
kEncryption Key0xA5A5A5A532bit
mOperating Mode0Parent 0, Repeater 1, Repeater Network 1-63
ARepeater Destination0x00000000Repeater mode only

Details of each command are shown below.

a: Application ID

All devices communicating must have the same value. It logically separates networks.

c: Frequency Channel

All devices communicating must have the same value. It physically separates networks.

x: Transmission Power and Retry Count

Specify the radio transmission power and the number of additional packet retransmissions.

b: UART Alternative Settings

Specify UART options when the option bit Enable UART Alternative Settings is set.

The value specifies baud rate and parity settings separated by a comma.

The baud rate can be selected from 9600/19200/38400/57600/115200/230400. Specifying other values may cause errors.

Parity can be set as N: None, O: Odd, E: Even. Hardware flow control cannot be set. Settings like 8N1, 7E2 can be specified, but settings other than 8N1 are unverified. Please confirm operation in advance.

o: Option Bits

Specify a 32bit numeric value. Settings linked to each bit can be enabled.

Bit MaskSettingDefault
0x00000200Enable UART Alternative Settings0️⃣
0x00000400Stop Periodic Packet Transmission Output0️⃣
0x00001000Enable Encrypted Communication0️⃣
0x00002000Enable Plain Reception During Encrypted Communication0️⃣

k: Encryption Key

Specify a 32bit hexadecimal encryption key when the option bit Enable Encrypted Communication is set.

m: Operating Mode

Set 0 for Parent mode, 1 for Repeater mode.

When performing multi-hop repeater in Repeater mode, setting 2-63 specifies the repeater layer.

A: Repeater Destination

Specify the serial ID (0x8???????) of the upper-level device connected when performing static routing in Repeater mode. When set to 0x00000000, automatic search is performed.

Details of Option Bits

Explanation of settings linked to each bit of the option bit value.

00000200: Enable UART Alternative Settings

Enables b: UART Alternative Settings.

00000400: Stop Periodic Packet Transmission Output

Stops the 1-second periodic transmission of the Extremely Simple! Standard App and Remote Control App and stops UART output during continuous mode.

00001000: Enable Encrypted Communication

Enables encrypted communication. The other party must also enable encrypted communication.

00002000: Enable Plain Reception During Encrypted Communication

When encrypted communication is enabled, allows reception of packets that are not encrypted.

4 - Remote Control App Manual

Transmission of digital signals
Firmware specialized in digital signal transmission. Offers rich features compared to the Extremely Simple! Standard App.

4.1 - Remote Control App Manual

Latest Edition

Installation

To install the Remote Control App (App_IO), install TWELITE STAGE SDK and rewrite the app using the TWELITE STAGE App. Select [App Rewrite] → [TWELITE APPS Build & Rewrite] → [App_IO].

Features

You can wirelessly transmit up to 12 switch or contact inputs.

Differences from Extremely Simple! Standard App (App_Twelite) are:

  • Increased number of ports, up to 12 ports available
  • Four types of input/output assignment (12:0, 8:4, 6:6, 0:12)
  • Frequency channel selectable externally from four types
  • Communication encryption available
  • Communication only possible with specified peers (automatic application ID setting)

4.1.1 - Pin Assignment of Remote Control App

Functions of pins used by the Remote Control App

TWELITE / TWELITE DIP

The functions of pins used by the Remote Control App are represented using the names from the diagram of Extremely Simple! Standard App Pins.

Super Simple! Standard App Pin Assignment Table

Super Simple! Standard App Pin Assignment Table

DIP #IOStandardRemote ControlFunction
1GNDGNDGNDPower Input
2DIO14SCLI9/O9Digital Input/Output
3DIO7RXRXSerial Input/Output
4DIO5PWMI11/O11Digital Input/Output
5DIO18DO1I5/O1Digital Input/Output
6DO0PWMLEDStatus LED Output
7DO1M3
8DIO19DO2I6/O2Digital Input/Output
9DIO4DO3I7/O3Digital Input/Output
10DIO6TXTXSerial Input/Output
11DIO8PWMI12/O12Digital Input/Output
12DIO9DO4I8/O4Digital Input/Output
13DIO10M1M1Mode Setting Input
14GNDGNDGNDPower Input
28VCCVCCVCCPower Input
27DIO3M3M3Mode Setting Input
26DIO2M2M2Mode Setting Input
25DIO1AI4C2Channel Setting Input
24ADC2AI3
23DIO0AI2C1Channel Setting Input
22ADC1AI1
21RESETNRSTRSTReset Input
22DIO17BPSBPSAlternative Baud Rate Setting Input
19DIO15SDAI10/O10Digital Input/Output
18DIO16DI4I4/O8Digital Input/Output
17DIO11DI3I3/O7Digital Input/Output
16DIO13DI2I2/O6Digital Input/Output
15DIO12DI1I1/O5Digital Input/Output

Power Input

Connect a 3.3V (2.0-3.6V) power supply to VCC/GND.

Digital Input/Output

Child: 12 inputs 0 outputs / Parent: 12 outputs 0 inputs

Default input/output assignments.

NameChildParentStandardDIP #
I1/O5I1O5DI115
I2/O6I2O6DI216
I3/O7I3O7DI317
I4/O8I4O8DI418
I5/O1I5O1DO15
I6/O2I6O2DO28
I7/O3I7O3DO39
I8/O4I8O4DO412
I9/O9I9O9SCL2
I10/O10I10O10SDA19
I11/O11I11O11PWM14
I12/O12I12O12PWM411

Child: 8 inputs 4 outputs / Parent: 8 outputs 4 inputs

Input/output assignments when the option bit: 0x00001000 setting is enabled.

NameChildParentStandardDIP #
I1/O5I1I1DI115
I2/O6I2I2DI216
I3/O7I3I3DI317
I4/O8I4I4DI418
I5/O1O1O1DO15
I6/O2O2O2DO28
I7/O3O3O3DO39
I8/O4O4O4DO412
I9/O9I5O5SCL2
I10/O10I6O6SDA19
I11/O11I7O7PWM14
I12/O12I8O8PWM411

Child: 6 inputs 6 outputs / Parent: 6 outputs 6 inputs

Input/output assignments when the option bit: 0x00002000 setting is enabled.

NameChildParentStandardDIP #
I1/O5I1I1DI115
I2/O6I2I2DI216
I3/O7I3I3DI317
I4/O8I4I4DI418
I5/O1O1O1DO15
I6/O2O2O2DO28
I7/O3O3O3DO39
I8/O4O4O4DO412
I9/O9O5I5SCL2
I10/O10O6I6SDA19
I11/O11I5O5PWM14
I12/O12I6O6PWM411

Child: 0 inputs 12 outputs / Parent: 0 outputs 12 inputs

Input/output assignments when the option bit: 0x00003000 setting is enabled.

NameChildParentStandardDIP #
I1/O5O5I1DI115
I2/O6O6I2DI216
I3/O7O7I3DI317
I4/O8O8I4DI418
I5/O1O1I5DO15
I6/O2O2I6DO28
I7/O3O3I7DO39
I8/O4O4I8DO412
I9/O9O9I9SCL2
I10/O10O10I10SDA19
I11/O11O11I11PWM14
I12/O12O12I12PWM411

Serial Input/Output

TX/RX are used for transmission and reception of the remote control (UART).

Status LED Output

Used when outputting status during automatic application ID setting.

Make the LED light up when the output is Low (sink type).

Setting Input

Mode Setting Input

By leaving the Mx pins unconnected or connecting them to GND, you can switch between operating modes such as parent, child, and repeater.

Alternative Baud Rate Setting Input

By leaving the BPS pin unconnected or connecting it to GND, you can change the UART baud rate (communication speed) to a value other than 115200bps.

Channel Setting Input

Temporarily overrides the frequency channel.

C2C1Frequency Channel
UnconnectedUnconnectedDefault (initial value is 16)
UnconnectedGND12
GNDUnconnected21
GNDGND25

Reset Input

By connecting a push button between RST and GND, you can implement a reset button. RST is internally pulled up.

4.1.2 - Remote Control App Operating Modes

Description of each operating mode
The Remote Control App (App_IO) has six operating modes.

List of Operating Modes

Each mode is set by connecting the Mx pins to either not connected (OPEN) or to GND.

M3M2M1ModeFunctionPowerSavingOperationInitialLID
OOOChild: ContinuousSends input states to the parent device and always waits for received data to reflect it on output120
OOGParent: ContinuousSends input states to child devices and always waits for received data to reflect it on output0
OGORepeater: ContinuousAlways waits for received data and relays it122
OGGChild: Continuous 0.03sSends input states to the parent device frequently and always waits for received data to reflect it on output123
GOOChild: Intermittent 1sSends input states to the parent device every second, disables reception, and always enters power saving mode124
GGO(Pairing Mode)Details
GGGChild: Intermittent 10sSends input states to the parent device every 10 seconds, disables reception, and always enters power saving mode127

O: Not connected (OPEN), G: Connected to GND

Initial mode is Child: Continuous mode.

The initial Logical Device ID (LID) used to identify the device differs depending on the mode.

Parent Device

Continuous Mode

Parent: Continuous Mode

When a change in signal input is detected, or every second, data is sent to all child devices.

It also always waits for data sent from child devices, so it responds quickly but continuously consumes power.

  • Reception: Always waiting
  • Transmission: On input change / every 1 second

Child Device

Continuous Mode

Child: Continuous Mode

When a change in signal input is detected, or every second, data is sent to all parent devices.

It also always waits for data sent from parent devices, so it responds quickly but continuously consumes power.

Image of communication with parent device

Image of communication with parent device

  • Reception: Always waiting
  • Transmission: On input change / every 1 second

Child: Continuous 0.03s Mode

This mode shortens the periodic transmission interval of Child: Continuous Mode from 1 second to 0.03 seconds.

Although it always waits for data sent from the parent device, it occupies the bandwidth of communication from child to parent, causing slower response to parent input. It continuously consumes power.

Image of communication with parent device

Image of communication with parent device

  • Reception: Always waiting
  • Transmission: On input change / every 0.03 seconds

Intermittent Mode

Child: Intermittent 1s Mode

When a change in signal input is detected, or every second, the power saving mode is disabled and data is sent to all parent devices.

Reception is disabled, so it cannot be controlled by the parent device. This mode has excellent power saving performance.

Image of communication with parent device

Image of communication with parent device

  • Reception: Disabled
  • Transmission: On input change / every 1 second

Child: Intermittent 10s Mode

When a change in signal input is detected, or every 10 seconds, the power saving mode is disabled and data is sent to all parent devices.

Reception is disabled, so it cannot be controlled by the parent device. This mode has excellent power saving performance.

Image of communication with parent device

Image of communication with parent device

  • Reception: Disabled
  • Transmission: On input change / every 10 seconds

Repeater Device

Continuous Mode

Repeater: Continuous Mode

The repeater transmits received packets.

You can install up to three repeaters between parent and child devices, but increasing repeaters increases the number of packets, which can cause interference.

Image of relay

Image of relay

  • Reception: Always waiting
  • Transmission: On reception

4.1.3 - Remote Control App Alternative Baud Rate Setting

Changing the baud rate used for UART communication
The Remote Control App (App_IO) uses 115200 bps as the default baud rate for UART communication, but this can be changed.

Enabling Alternative Baud Rate Setting

You can enable the alternative baud rate setting by connecting the BPS pin to GND.

BPSDescriptionBaud RateRemarks
ODefault115200bps
GOverride38400bpsChangeable via Interactive Mode

O: not connected (OPEN), G: connected to GND

4.1.4 - Remote Control App UART Function

Data format used for UART function.
Explanation of data format used in the UART function of Remote Control App (App_IO).

Digital Input and Output

0x81: Status Notification from the Remote Device

Outputs the state of the received input signal.

Data Format

#DataDescriptionRemarks
charHeader: only
0uint8Source Logical Device ID
1uint8Command Number0x81 only
2uint8Packet Identifier0x0F only
3uint8Protocol Version0x01 only
4uint8LQI0-255
5uint32Source Serial ID0x8???????
9uint8Destination Logical Device ID
10uint16Timestamp64 counts per second, MSB is internal flag
12uint8Relay Count
13uint16Digital SignalCorresponds to Ix from LSB, 0 is High
15uint16Digital Signal MaskCorresponds to Ix from LSB, 1 means valid
17uint16Digital Signal FlagCorresponds to Ix from LSB, 1 means interrupt
19uint8UnusedFor internal management
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Output Data

:01810F01DB8630000200645F000040004F00400049

0x80: Remote Device Output Change

Controls the output signals of the remote device.

Data Format

#DataDescriptionRemarks
charHeader: only
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command Number0x80 only
2uint8Format Version0x01 only
3uint16Digital SignalCorresponds to Ox from LSB, 0 is High
5uint16Digital Signal MaskCorresponds to Ox from LSB, 1 is valid
7uint16Unused0
9uint16Unused0
11uint16Unused0
13uint16Unused0
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

UART Input and Output

4.1.5 - Custom Default Feature of Remote Control App

Creating firmware with changed default settings
With the custom default feature, you can change the default parameters included in the firmware.

For example, if you create firmware that changes the baud rate from 115200bps to 9600bps, you can use it at 9600bps from the start.

Configuration Procedure

1. Apply the Settings

Change the settings in Interactive Mode, press S to save.

2. Download the Settings

Prepare software capable of downloading data using the xmodem protocol.

While still in Interactive Mode (before selecting items), request xmodem download.

If the download succeeds, it generates a 128-byte file (may be smaller depending on the xmodem implementation).

3. Creating Custom Binary

Concatenate the downloaded file to the end of the firmware binary file to create a custom binary.

Use command line tools or general file concatenation tools for concatenation.

Example

An example when the downloaded xmodem file is conf.bin, the original binary file is App_IO_BLUE_L1305_V1-3-X.bin, and the custom binary to be created is App_IO_custom_V1-3-X.bin.

【Windows】

copy App_IO_BLUE_L1305_V1-3-X.bin App_IO_custom_V1-3-X.bin
type conf.bin >> App_IO_custom_V1-3-X.bin

【macOS / Linux】


cat App_IO_BLUE_L1305_V1-3-X.bin conf.bin > App_IO_custom_V1-3-X.bin

4. Writing Custom Binary

Write the concatenated custom binary to TWELITE.

4.1.6 - Pairing Function of Remote Control App

Grouping parent and child devices by automatic application ID setting
The Remote Control App (App_IO) has a function to create groups of parent and child devices without using Interactive Mode.

Configuration Method

Create a group by generating an application ID based on the parent’s serial ID and feeding it to the child devices. Connect an LED to the LED pin to check if the configuration is successful.

Connection

Connection

  1. Connect an LED and a current limiting resistor (680Ω) to the LED pins of the parent and child devices (with correct polarity).
  2. Leave M1 open and connect M2 and M3 to GND.
  3. Power on the parent device and check that the LED blinks.
  4. Within 5 seconds, power on the child device near the parent and confirm that the LED turns off (if it stays lit, the configuration failed).

4.1.7 - Interactive Mode (Remote Control App)

Configuration changes via Interactive Mode
You can perform detailed settings of the app via Interactive Mode.

This section explains features specific to the Remote Control App (App_IO). For common features, please refer to the TWELITE APPS Manual Top Page.

Display Example

The screen below will be displayed.

--- CONFIG/APP_IO V1-03-2/SID=0x86300001/LID=0x00 ---
 a: set Application ID (0x67720107)
 i: set Device ID (--)
 c: set Channels (16)
 x: set Tx Power (3)
 t: set mode4 sleep dur (1000ms)
 y: set mode7 sleep dur (0s)
 f: set mode3 fps (16)
 d: set hold mask (000000000000)
 D: set hold dur (1000ms)
 o: set Option Bits (0x00000000)
 b: set UART baud (38400)
 p: set UART parity (N)
 C: set crypt mode (0)
 K: set crypt key []
---
 S: save Configuration
 R: reset to Defaults

Commands

CommandSetting ItemDefaultNotes
aApplication ID0x6772010732bit
iLogical Device ID120Parent 121, Child 1-100, ID-less Child 120, Unset 0
cFrequency Channel1611-26
xRetry Count and Transmission Output3
Retry Count01-9 times, 0 default: 2 times
Transmission Output30-3
tChild Device Intermittent 1-Second Mode Interval1000100-64000 ms
yChild Device Intermittent 10-Second Mode Interval02-10000 s, Disabled 0
fChild Device Continuous 0.03-Second Mode Cycle324/8/16/32 times per second
dHold/Long Press Mode Targets000000000000From right I1-I2, Enabled 1
DHold/Long Press Mode Duration100020-64000 ms
oOption Bits0x00000000Other detailed settings
bUART Alternative Baud Rate38400Enabled by BPS pin
pUART ParityNStop bit fixed to 1
CEncryption0Disabled 0, AES128bit 1
KEncryption Key-Up to 16 characters

Details for each command are as follows.

a: Application ID

All devices communicating should have the same value. This logically separates networks.

i: Logical Device ID

Set this when it is necessary to distinguish multiple child devices.

If distinction is not necessary or not possible, set to 120. If distinction is necessary, child devices should be any value from 1 to 100, and parent device should be 0 or 121.

c: Frequency Channel

All devices communicating should have the same value. This physically separates networks.

x: Transmission Output and Retry Count

Specify the radio transmission output and the number of additional packet transmissions in transparent mode and header-attached transparent mode.

t: Child Device Intermittent 1-Second Mode Interval

Overwrite the intermittent interval of the child device intermittent 1-second mode from 1 second to another value. Unit is milliseconds.

If 0 is set, periodic wake-up by timer is disabled. In this case, the device wakes up on the falling edge of Ix, but not on the rising edge.

y: Child Device Intermittent 10-Second Mode Interval

Overwrite the intermittent interval of the child device intermittent 10-second mode from 10 seconds to another value. Unit is seconds.

If 0 is set, periodic wake-up by timer is disabled. In this case, the device wakes up on the falling edge of Ix, but not on the rising edge.

f: Child Device Continuous 0.03-Second Mode Cycle

Overwrite the number of transmission requests per second from 32 times to 4/8/16 times. Retry count is not included.

d: Hold/Long Press Mode Targets

By default, select ports targeted by hold mode, and when Option Bit 0x00000100 is enabled, select ports targeted by remote control long press mode.

Specify the bitmask of Ix or Ox ports to target. The value consists of up to 12 characters of 0 or 1. From LSB, the order is I1 I2I12.

For example, specifying 000000001010 applies hold mode to I2 and I4. If any pin is targeted, ports not targeted output a 50ms pulse.

Hold Mode

In hold mode, targeted ports behave as follows:

Input (Transmission) side: Ix
  • After all inputs return from Lo to Hi, continuous transmission occurs for the configured duration (to release hold).
Output (Reception) side: Ox
  • For received inputs that are Lo, output holds Lo for the configured duration.
  • If during hold of any output, another Lo signal is received, the hold duration is extended.

Remote Control Long Press Mode

In remote control long press mode, targeted ports behave as follows:

Input (Transmission) side: Ix
  • Continuous transmission while any input is Lo.
  • After all inputs return from Lo to Hi, continuous transmission occurs for the configured duration.
Output (Reception) side: Ox
  • After packets with any input Lo are interrupted, outputs return Hi after the configured duration.

D: Hold/Long Press Mode Duration

By default, specify hold mode duration; when Option Bit 0x00000100 is enabled, specify hold duration or transmission interval for remote control long press mode.

Specify a value between 20 and 64000 ms.

Hold Mode

For hold mode, the configured duration applies as follows:

Input (Transmission) side: Ix

In continuous mode, the duration of continuous transmission after all inputs return from Lo to Hi.

In intermittent mode, the transmission interval while any input is Lo.

Output (Reception) side: Ox

The duration to maintain output.

Remote Control Long Press Mode

For remote control long press mode, the configured duration applies as follows:

Input (Transmission) side: Ix

The duration of continuous transmission after all inputs return from Lo to Hi.

Output (Reception) side: Ox

The time from interruption of packets with any input Lo until all outputs return to Hi.

o: Option Bits

Specify a 32bit number. Enable settings associated with each bit.

Bit MaskSetting ItemDefaultTransmitReceiveContinuousIntermittent
0x00000001Low Latency Mode0️⃣
0x00000002Low Latency Mode (Sleep Interrupt)0️⃣
0x00000010Enable Transmission with ACK0️⃣
0x00000020Disable Periodic Transmission0️⃣
0x00000100Enable Remote Control Long Press Mode0️⃣
0x00000200Disable C1/C2 Channel Switching0️⃣
0x00000400Invert Ix Input0️⃣
0x00000800Disable Internal Pull-up of Ix0️⃣
0x00001000Child: 8 Input 4 Output / Parent: 8 Output 4 Input0️⃣
0x00002000Child: 6 Input 6 Output / Parent: 6 Output 6 Input0️⃣
0x00003000Child: 0 Input 12 Output / Parent: 0 Output 12 Input0️⃣
0x00010000Force Enable Reception on Child0️⃣
0x00020000Stop UART Output on IO Change0️⃣
0x00040000Enable Watchdog Output on C20️⃣
0x00400000Invert Output on Ox0️⃣

b: UART Alternative Baud Rate

Overwrite the alternative baud rate selected when starting with the BPS pin connected to GND from 38400 bps.

Values can be selected from 9600/19200/38400/57600/115200/230400. Other values may cause errors.

p: UART Parity

Set to N (None), O (Odd), or E (Even). Stop bit is fixed to 1, hardware flow control is not supported.

C: Encryption

Specify whether encryption is enabled.

Set 1 to enable AES128bit encryption.

K: Encryption Key

Input the key used for encryption. Specify a 16-character text (binary sequences cannot be specified).

Details of Option Bits

Explanation of settings associated with each bit of the option bits value.

0x00000001: Low Latency Mode

Monitor input status and perform wireless transmission in low latency mode.

Shortens button monitoring time and minimizes transmission delay. In continuous mode, interrupts are used for input judgment but are more susceptible to chattering. In intermittent mode, reduces time to confirm input status.

Only valid for child devices.

0x00000002: Low Latency Mode (Sleep Interrupt)

When waking from sleep due to an interrupt from Ix going from Hi to Lo in intermittent mode, quickly send port information of the interrupt source.

Especially used in child device intermittent 10-second mode when periodic wake-up is disabled, combined with hold mode to detect button presses.

Only valid for child devices.

0x00000010: Enable Transmission with ACK

Enable ACK communication from child to parent. Transmission ends when parent returns ACK.

Not available for multiple parents or all repeaters, but provides efficient communication in stable environments.

In child device intermittent 10-second mode, the BPS pin is set as output pin, so baud rate override on child side is not possible.

0x00000020: Disable Periodic Transmission

Disable periodic transmission every 1 second in child continuous mode.

0x00000100: Enable Remote Control Long Press Mode

Apply remote control long press mode instead of hold mode.

0x00000200: Disable C1/C2 Channel Switching

Disable channel switching by C1/C2 pins.

0x00000400: Invert Ix Input

Send 1 when input is Hi, and 0 when Lo.

0x00000800: Disable Internal Pull-up of Ix

Disable all internal pull-ups (~50kΩ) on Ix.

0x00001000: Child: 8 Input 4 Output / Parent: 8 Output 4 Input

Change I/O port assignment from “Child: 12 Input 0 Output / Parent: 12 Output 0 Input”. Intermittent mode uses intermittent reception.

0x00002000: Child: 6 Input 6 Output / Parent: 6 Output 6 Input

Change I/O port assignment from “Child: 12 Input 0 Output / Parent: 12 Output 0 Input”. Intermittent mode uses intermittent reception.

0x00003000: Child: 0 Input 12 Output / Parent: 0 Output 12 Input

Change I/O port assignment from “Child: 12 Input 0 Output / Parent: 12 Output 0 Input”. Intermittent mode uses intermittent reception.

0x00010000: Force Enable Reception on Child

In continuous mode, force enable reception regardless of output ports.

Allows UART output of data received from other devices.

0x00020000: Stop UART Output on IO Change

Stop message output on input/output changes.

0x00040000: Enable Watchdog Output on C2

Output watchdog signal from C2 port.

Control IO in application loop and output approx. 32Hz square wave.

Used to connect external reset circuit for automatic recovery and force reset the module in case of hang-up.

0x00400000: Invert Output on Ox

Output Lo when received input port status is 0, and Hi when 1.

5 - Serial Communication App Manual

Wireless serial communication
Firmware specialized for wireless transmission of serial communication (UART). Offers more functions compared to Extremely Simple! Standard App.

5.1 - Serial Communication App Manual

v1.5.1 GOLD Latest version

Download

To install the Serial Communication App (App_Uart), install the TWELITE STAGE SDK and rewrite using the TWELITE STAGE App.

5.1.1 - Pin Assignments of Serial Communication App

Functions of pins used by the Serial Communication App

TWELITE / TWELITE DIP

The functions of pins used by the Serial Communication App are represented using the pin names from the Super Simple! Standard App Pins shown in the figure below.

Super Simple! Standard App Pin Assignment Table

Super Simple! Standard App Pin Assignment Table

Serial CommunicationSuper Simple! StandardFunction
VCC GNDVCC GNDPower Input
TX RXTX RXSerial Input and Output
TX_SUB RX_SUBSCL SDASerial Sub Input and Output
RTSPWM1Serial Input Permission
M1M1Parent/Child Selection
M2M2Adding Relay Function to Child
M3M3Sleep
EX1AI2Overwriting Operation Mode
BPSBPSEnabling Alternative Baud Rate Setting
RSTRSTReset Input
SETDI1Enter interactive mode

Power Input

Connect a 3.3V (2.0-3.6V) power supply to VCC/GND.

Serial Input and Output

TX/RX are used for transmitting and receiving serial communication (UART).

Serial Sub Input and Output

TX_SUB (SCL) / RX_SUB (SDA) can be used as sub-ports for serial input and output.

Serial Input Permission

When RTS (PWM1) is at Low level, it indicates that serial input to RX is being accepted.

Parent/Child Selection

Connecting M1 to GND sets the device as a parent, while leaving it open or connecting to VCC sets it as a child.

Adding Relay Function to Child

When M2 is connected to GND in child mode, relay functionality can be added.

Sleep

Connecting M3 to GND puts the device into sleep mode.

Overwriting Operation Mode

By connecting EX1 to GND at startup, the operation mode can be overwritten to format mode (binary).

Enabling Alternative Baud Rate Setting

Connecting BPS to GND enables the alternative baud rate setting specified in interactive mode.

Reset Input

By connecting a push button between RST and GND, a reset button can be implemented. RST has an internal pull-up resistor.

Enter interactive mode

By connection SET to GND on startup, the interactive mode will be ready.

TWELITE UART

The functions of pins used by the Serial Communication App are represented using the pin names of the 7P interface printed on the board (② in the figure below).

Board Antenna Type

Board Antenna Type

Coaxial Connector Type

Coaxial Connector Type

SilkscreenFunction
VCC GNDPower Input
TXD RXDSerial Input and Output
SETOverwriting Operation Mode
RSTReset Input

Power Input

Connect a 3.3V (2.0-3.6V) power supply to VCC/GND.

Serial Input and Output

TX/RX are used for transmitting and receiving serial communication (UART).

Overwriting Operation Mode

By connecting SET to GND at startup, the operation mode can be overwritten to format mode (ASCII).

Reset Input

By connecting a push button between RST and GND, a reset button can be implemented. RST has an internal pull-up resistor.

5.1.2 - Communication Modes of Serial Communication App

Explanation of each communication mode
The Serial Communication App (App_Uart) has five communication modes.

List of Communication Modes

Each mode is switched by Interactive Mode (some modes can be set via pin input).

IDMode
AFormat Mode (ASCII)
BFormat Mode (Binary)
CChat Mode
DTransparent Mode
EHeader Transparent Mode

Initial state is Header Transparent Mode.

A: Format Mode (ASCII)

When data is input to the transmitting terminal according to a specific format, the receiving terminal outputs data according to the same specific format.

Data represented in hexadecimal is expressed as ASCII strings.

Input on Transmitting SideOutput on Receiving Side
Simple/Extended format dataSimple/Extended format data

In TWELITE UART, this mode is enabled when started with the SET pin connected to GND.

There are two formats to represent data.

  • Simple format: Uses only logical device ID. Super simple! Compatible with the standard app’s UART transmission function.
  • Extended format: Uses transmission options such as serial ID and retransmission count in addition to logical device ID.

For example, 5-byte binary data 0x48 0x45 0x4C 0x4C 0x4F can be sent using the simple format as follows.

[Transmitting Side]

:000148454C4C4F8B  <- Input
:DBA1800103  <- Output

[Receiving Side]

:780148454C4C4F13  <- Output

In format mode, settings such as application ID can be dynamically applied not only by Interactive Mode but also by commands via UART (ASCII format).

B: Format Mode (Binary)

When data is input to the transmitting terminal according to a specific format, the receiving terminal outputs data according to the same specific format.

Data represented in hexadecimal is expressed in binary format as is.

Input on Transmitting SideOutput on Receiving Side
Simple/Extended format dataSimple/Extended format data

In TWELITE / TWELITE DIP, this mode is enabled when started with the EX1 pin connected to GND.

Like Format Mode (ASCII), there are two formats to represent data.

For example, 5-byte binary data 0x48 0x45 0x4C 0x4C 0x4F can be sent using the simple format as follows.

[Transmitting Side]

0xA5 0x5A 0x00 0x07 0x00 0x01 0x48 0x45 0x4C 0x4C 0x4F 0x43 0x04    <- Input
0xA5 0x5A 0x00 0x04 0xDB 0xA1 0x80 0x01 0xFB 0x04  <- Output

[Receiving Side]

0xA5 0x5A 0x00 0x07 0x78 0x01 0x48 0x45 0x4C 0x4C 0x4F 0x3B 0x04  <- Output

In format mode, settings such as application ID can be dynamically applied not only by Interactive Mode but also by commands via UART (binary format).

C: Chat Mode

Enables text chat.

Input on Transmitting SideOutput on Receiving Side
Any stringAuxiliary information + any string

Displays prompt and echoes back (outputs the entered characters). All terminals act as child devices and perform broadcast communication.

For example, when a terminal sends the string Hello to other terminals, the behavior is as follows.

[Transmitting Side]

810A4778:0> Hello  <- Input
810A4778:1>  <- Output

[Receiving Side]

[810A4778:0] Hello  <- Output
82018CA0:0>  <- Output

In the above example, the prompt shows the serial ID, but you can also use any handle name.

D: Transparent Mode

When arbitrary data is input to the transmitting terminal, the receiving terminal outputs the received data as is.

Input on Transmitting SideOutput on Receiving Side
Any dataAny data

Since no format is required, existing UART communication can be easily wirelessized.

On the other hand, data boundaries become ambiguous, and the receiving output cannot identify the sender, which are drawbacks.

By default, data input to the transmitting side is separated by CRLF, and data before CRLF is sent.

For example, when Hello<Enter> is input on the transmitting terminal, the receiving terminal outputs Hello as is.

[Transmitting Side]

Hello  <- Input

[Receiving Side]

Hello  <- Output

E: Header Transparent Mode

When arbitrary data is input to the transmitting terminal, the receiving terminal outputs the received content with auxiliary information added in a specific format.

Input on Transmitting SideOutput on Receiving Side
Any dataAny data + auxiliary information

By default, data input to the transmitting side is separated by CRLF, and data before CRLF is sent.

For example, when Hello<Enter> is input on the transmitting terminal, the receiving terminal outputs Hello in a format including auxiliary information. The transmitting terminal also outputs a format that conveys a transmission completion message.

[Transmitting Side]

Hello  <- Input
;U;00004;219;0x820163B2;000;000;0,1,Hel...;6E;  <- Output

[Receiving Side]

;U;00003;000;0x820163B2;255;000;Hello;42;  <- Output

The auxiliary information output by the receiving side includes the sender’s address, received signal strength, checksum, etc. The format of auxiliary information can be customized.

5.1.2.1 - Serial Communication App Format Mode (ASCII)

Mode that adds headers to both transmitted and received outputs (ASCII format)
Format mode adds headers to both transmitted and received outputs. In ASCII format, data is represented as hexadecimal strings.
Example network configuration with format mode

Overview

When data formatted in a specific manner is input on the transmitting side, the receiving side outputs data formatted in the same manner.

Data is represented as hexadecimal ASCII strings.

Transmitting Side InputReceiving Side Output
Simple/Extended format dataSimple/Extended format data
  • In TWELITE UART, format mode (ASCII) is enabled by starting up with the SET pin connected to GND.
  • In TWELITE / TWELITE DIP, format mode (binary) is enabled by starting up with the EX1 pin connected to GND.

There are two types of formats that can be handled.

  • Simple format: uses only the Logical Device ID. Extremely Simple! Compatible with the UART transmission function of the standard app.
  • Extended format: uses Logical Device ID plus transmission options such as Serial ID and retry count.

For example, 5-byte binary data 0x48 0x45 0x4C 0x4C 0x4F can be sent using the simple format as follows.

[Sending side]

:000148454C4C4F8B  <- Input
:DBA1800103  <- Output

[Receiving side]

:780148454C4C4F13  <- Output

Basic Format

When sending data sequences expressed in basic or extended formats, they are converted to ASCII strings (0-9, A-F).

The format is extremely simple! It starts with : and ends with CRLF, just like the output of the standard app (App_Twelite) or the parent device output of the parent/repeater app (App_Wings).

HeaderPayloadChecksumFooter
:Repeated 00-FFLRC8 of payloadCRLF
  • All ASCII characters
  • Starts with : (0x3A)
  • Checksum is the two’s complement of the sum of the payload
  • Ends with CRLF (\r\n/0x0D 0x0A)
  • Big-endian

For example, binary data 0x00 0x11 0x22 0x33 0xAA 0xBB 0xCC is expressed as follows.

:00112233AABBCC69<CR><LF>

Distinguishing Parent and Child Devices

Format mode distinguishes between parent and child devices.

The Application ID and frequency channel must be matched between parent and child devices.

Source Identification

Format mode allows identifying the source from the received data.

The simple format uses the Logical Device ID, and the extended format uses the Logical Device ID plus the extended address.

Simple Format

When using the simple format of format mode, follow the format below.

Transmitting Side Input

#DataDescriptionNotes
charHeaderOnly :
0uint8Destination Logical Device IDParent 0x00, child 0x01-0x64, all children 0x78
1uint8Command numberAny value less than 0x80
2[uint8]Arbitrary dataByte sequence of length (N) (recommended (N \leqq 80))
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Receiving Side Output

#DataDescriptionNotes
charHeaderOnly :
0uint8Source Logical Device IDParent 0x00, child 0x01-0x64, unset child 0x78
1uint8Command numberValue less than 0x80 specified by the sender
2[uint8]Arbitrary dataByte sequence of length (N)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Transmitting Side Output (Response Message)

#DataDescriptionNotes
charHeaderOnly :
0uint8Source Logical Device IDOnly 0xDB: indicates itself
1uint8Command numberOnly 0xA1
2uint8Response IDContinuation number in the range 128-255 (0x80-0xFF)
3uint8ResultSuccess 1, failure 0
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Usage

An example of sending byte sequence 0x11 0x22 0x33 0xAA 0xBB 0xCC from the parent to all children is shown.

[Sending side: Parent]

:7801112233AABBCCF0<CR><LF>  <- Input
:DBA1800103<CR><LF>  <- Output

The trailing 0xF0 is the checksum: the two’s complement of the sum from 0x78 to 0xCC (LSB 8 bits).

[Receiving side: All children]

:0001112233AABBCC68<CR><LF>  <- Output

The trailing 0x68 is the checksum: the two’s complement of the sum from 0x00 to 0xCC (LSB 8 bits).

Extended Format

When using the extended format of format mode, follow the format below.

Transmitting Side Input

When specifying destination using Logical Device ID

#DataDescriptionNotes
charHeaderOnly :
0uint8Destination Logical Device IDParent 0x00, child 0x01-0x64, all children 0x78
1uint8Command numberOnly 0xA0
2uint8Response IDAny value
3[uint8]OptionsOption list of length (N) (Details of option list)
3+(N)[uint8]Arbitrary dataByte sequence of length (M) (recommended (M \leqq 80))
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

When specifying destination using Extended Address

#DataDescriptionNotes
charHeaderOnly :
0uint8Extended Address SpecifierOnly 0x80
1uint8Command numberOnly 0xA0
2uint8Response IDAny value
3uint32Destination Extended AddressSerial ID with 0x8 added at the front
7[uint8]OptionsOption list of length (N) (Details of option list)
7+(N)[uint8]Arbitrary dataByte sequence of length (M) (recommended (M \leqq 80))
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Details of Option List

In the extended format, you can specify fine settings by specifying the option list.

The option list is represented by repeating option IDs and their arguments. The end is 0xFF.

IDArgumentDefaultDescription
0x01NoneDisabledEnable MAC ACK
0x02uint80x00Enable application retry
0x03uint160x0000Minimum initial transmission delay
0x04uint160x0000Maximum initial transmission delay
0x05uint1610Application retry interval
0x06NoneDisabledAllow parallel requests
0x07NoneDisabledDisable response messages
0x08NoneDisabledSleep after transmission
0x01: Enable MAC ACK

Enables MAC layer ACK (acknowledgment).

Not suitable for frequent data transmission, but can improve reliability.

0x02: Enable Application Retry

When using MAC ACK, specify 0x00-0x0F. Retries 0-16 times respectively until the transmission succeeds.

When not using MAC ACK, specify 0x81-0x8F. Always retries 1-16 times.

Response messages are output after all retries are completed.

0x03: Minimum Initial Transmission Delay

Specifies the minimum delay before the first transmission in milliseconds.

0x04: Maximum Initial Transmission Delay

Specifies the maximum delay before the first transmission in milliseconds.

0x05: Application Retry Interval

Specifies the retry interval in milliseconds when application retry is enabled.

0x06: Allow Parallel Requests

Allows parallel requests.

When allowed, the next request can be accepted without blocking until the current request completes.

For example, if three requests with a 0.5-second delay are input consecutively, normally they are processed sequentially at 0.5s, 1.0s, and 1.5s. When parallel requests are allowed, they are processed in no particular order after 0.5s. Note that it cannot be used when packet fragmentation is required.

0x07: Disable Response Messages

Disables the response messages output when data is input on the transmitting side.

0x08: Sleep After Transmission

Immediately puts the device to sleep after transmission.

When RX detects a rising edge, it wakes up from sleep. Please input any 1 byte of data.

After waking up, UART initialization completes and input is accepted.

Receiving Side Output

#DataDescriptionNotes
charHeaderOnly :
0uint8Source Logical Device IDParent 0x00, child 0x01-0x64, unset child 0x78
1uint8Command numberOnly 0xA0
2uint8Response IDValue specified by the sender
3uint32Source Extended AddressSerial ID with 0x8 added at the front
7uint32Destination Extended Address0xFFFFFFFF if using Logical Device ID
11uint8LQIRadio communication quality at reception
12uint16Length of following byte sequenceNumber of bytes (M)
14[uint8]Arbitrary dataByte sequence of length (M)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Transmitting Side Output (Response Message)

#DataDescriptionNotes
charHeaderOnly :
0uint8Source Logical Device IDOnly 0xDB: indicates itself
1uint8Command numberOnly 0xA1
2uint8Response IDValue specified at input
3uint8ResultSuccess 1, failure 0
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Usage

An example of sending byte sequence 0x11 0x22 0x33 0xAA 0xBB 0xCC from the parent to a child is shown.

Example specifying Logical Device ID

An example sending from the parent to the child with Logical Device ID 0x42.

  • Response ID is 0x01
  • No options
  • Parent’s extended address is 0x81000000 (Serial ID 0x1000000)

[Sending side: Parent]

:42A001FF112233AABBCC87<CR><LF>  <- Input
:DBA1010182<CR><LF>  <- Output

The trailing 0x87 is the checksum: the two’s complement of the sum from 0x42 to 0xCC (LSB 8 bits).

[Receiving side: Child]

:00A00181000000FFFFFFFFC80006112233AABBCC7D<CR><LF>  <- Output

The trailing 0x7D is the checksum: the two’s complement of the sum from 0x00 to 0xCC (LSB 8 bits).

Example specifying Extended Address

An example sending from the parent to the child with extended address 0x81000001 (Serial ID 0x1000001).

  • Response ID is 0x01
  • No options
  • Parent’s extended address is 0x81000000 (Serial ID 0x1000000)

[Sending side: Parent]

:80A00181000001FF112233AABBCCC7<CR><LF>  <- Input
:DBA1010182<CR><LF>  <- Output

The trailing 0xC7 is the checksum: the two’s complement of the sum from 0x80 to 0xCC (LSB 8 bits).

[Receiving side: Child]

:00A0018100000081000001C80006112233AABBCCF7<CR><LF>  <- Output

The trailing 0xF7 is the checksum: the two’s complement of the sum from 0x00 to 0xCC (LSB 8 bits).

Example using MAC ACK

An example sending from the parent to the child with Logical Device ID 0x42 using MAC ACK.

  • Response ID is 0x01
  • Option 0x01: Enable MAC ACK specified
  • Parent’s extended address is 0x81000000 (Serial ID 0x1000000)

[Sending side: Parent]

:42A00101FF112233AABBCC86<CR><LF>  <- Input
:DBA1010182<CR><LF>  <- Output

The trailing 0x86 is the checksum: the two’s complement of the sum from 0x42 to 0xCC (LSB 8 bits).

[Receiving side: Child]

:00A00181000000FFFFFFFFC80006112233AABBCC7D<CR><LF>  <- Output

The trailing 0x7D is the checksum: the two’s complement of the sum from 0x00 to 0xCC (LSB 8 bits).

Example using delay

An example sending from the parent to the child with Logical Device ID 0x42 with a 768ms delay.

[Sending side: Parent]

:42A001030300FF112233AABBCC81<CR><LF>  <- Input
:DBA1010182<CR><LF>  <- Output

The trailing 0x81 is the checksum: the two’s complement of the sum from 0x42 to 0xCC (LSB 8 bits).

[Receiving side: Child]

:00A00181000000FFFFFFFFC80006112233AABBCC7D<CR><LF>  <- Output

The trailing 0x7D is the checksum: the two’s complement of the sum from 0x00 to 0xCC (LSB 8 bits).

0xDB Command

Instead of setting interactive mode, you can operate and configure the module by inputting the 0xDB command from UART.

5.1.2.1.1 - 0xDB Command in Serial Communication App Format Mode (ASCII)

Setting functions using the 0xDB command in format mode (ASCII) without using Interactive Mode
In format mode, dynamic configuration can be performed from devices connected via UART by using the 0xDB command instead of Interactive Mode.

Input Format

#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB itself
1uint8Command numberSelected from values below
2[uint8]ParameterOptional length N bytes representing setting values
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

List of Command Numbers

Function
0xF0Enable ACK
0xF1Get Device Info
0xF2Apply Device Settings
0xF3Get Device Settings
0xFDErase Device Settings
0xFESave Device Settings
0xFFReset Device

0xF0: Enable ACK

Requests an ACK response.

No parameters.

Response Format

#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF0
2uint8DataOnly 0x01
uint8Checksum0x34: LRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0xF1: Get Device Info

Displays address and other information. Also output at startup.

No parameters.

Response Format

#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF1
2uint32Default Application ID67720103
6uint32Version numberFor 1.4.7, 00010407
10uint8Logical device ID
11uint32Serial ID
15uint8Silent mode statusEnabled 1, Disabled 0
16uint8Network statusUP 1, DOWN 0
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0xF2: Apply Device Settings

Applies the settings.

Response Format

On Success
#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF3
2[uint8]Settings contentIdentifier
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')
On Failure
#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF3
2uint8ErrorOnly 0xFF
uint8Checksum0x33: LRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0xF3: Get Device Settings

Gets the settings.

Response Format

#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF3
2[uint8]Settings contentIdentifier and data
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0xFD: Erase Device Settings

Resets device settings and resets the device.

No parameters or response.

0xFE: Save Device Settings

Saves applied settings and resets the device.

No parameters or response.

0xFF: Reset Device

Discards applied settings and resets the device.

No parameters or response.

Parameter List (0xF2 / 0xF3)

Parameters for 0xF2: Apply Device Settings and 0xF3: Get Device Settings are represented by repeated pairs of identifiers and data (big endian).

IdentifierDataContent
0x00uint32Application ID
0x01uint32Frequency Channel Mask
0x02uint16Retry Count and Output
0x03uint8Logical Device ID
0x04uint8Role
0x05uint8Relay Layer
0x06uint8Communication Mode
0x07uint32Baud Rate
0x08uint8Parity
0x09uint8Encryption Function
0x0A[uint8]Encryption Key
0x0B[uint8]Header / Handle name
0x0Cuint16Delimiter Character
0xFFuint8Error

0x00: Application ID

Specifies the application ID.

0x01: Frequency Channel Mask

Specifies the bit mask of frequency channels.

Set bits for channels to be used. For example, to use channel 11, specify 1<<11.

0x02: Retry Count and Output

Specifies the radio transmission output and the number of additional packet transmissions in transparent mode and header-attached transparent mode.

Only the lower 1 byte is used. The upper 4 bits represent the retry count (0-9), and the lower 4 bits represent the transmission output (0-3). For example, 8 retries / output 3 is 0x0083.

0x03: Logical Device ID

Specifies the logical device ID.

0x04: Role

Effective only for slave devices. Specify one of the following values. Normally, select a delivery method that does not use the network layer.

Delivery Methods Without Network Layer

  • 0: Normal designation (parent or child device)
  • 1-3: Relay slave devices (logical device IDs are 1-100 or 120). Numbers 1-3 indicate the maximum relay hop count. This method retransmits up to the maximum relay hops, which may cause duplicate packets depending on relay device placement and count.

Delivery Methods Using Network Layer

  • 11: Parent device
  • 12: Relay device
  • 13: Child device

0x05: Relay Layer

The relay layer number. Relay devices attempt to connect to relay devices or parent devices in upper (smaller value) relay layers. Effective only when Role is set to 12.

0x06: Communication Mode

  • 0: Transparent mode
  • 1: Format mode (ASCII)
  • 2: Format mode (Binary)
  • 3: Chat mode
  • 4: Header-attached transparent mode

0x07: Baud Rate

Specifies the UART baud rate.

0x08: Parity

Specifies the sum of settings in the following combination:

  • Bit
    • 0: 8Bit
    • 8: 7Bit
  • Parity
    • 0: None
    • 1: Odd
    • 2: Even
  • Stop
    • 0: STOP 1
    • 4: STOP 2

For example, 7-E-1 is specified as 8+2+0=10(0xA).

0x09: Encryption Function

Specifies whether encryption is enabled.

  • 0: Disabled
  • 1: AES128bit encryption enabled

0x0A: Encryption Key

Specifies a 16-byte encryption key.

Can store binary sequences that cannot be set in Interactive Mode. This may cause display issues in Interactive Mode.

0x0B: Header / Handle name

Specifies a header format on the mode E or handle name on the mode C.

0x0C: Delimiter Character

Specifies the delimiter character (0x00-0xFF).

5.1.2.2 - Serial Communication App Format Mode (Binary)

Mode that adds headers to both transmitted and received outputs (binary format)
Format mode adds headers to both transmitted and received outputs. In binary format, data is represented as raw binary.
Example network configuration with format mode

Overview

When data formatted in a specific manner is input on the transmitting side, the receiving side outputs data formatted in the same manner.

Data represented in hexadecimal is output as raw binary.

Transmitting Side InputReceiving Side Output
Simple/Extended Format DataSimple/Extended Format Data
  • On TWELITE UART, format mode (ASCII) is enabled by connecting the SET pin to GND at startup.
  • On TWELITE / TWELITE DIP, format mode (binary) is enabled by connecting the EX1 pin to GND at startup.

There are two types of supported formats.

  • Simple format: uses Logical Device ID only; Extremely Simple! Compatible with UART transmission function of the standard app
  • Extended format: uses Logical Device ID plus options such as Serial ID and retry count

For example, 5 bytes of binary data 0x48 0x45 0x4C 0x4C 0x4F can be transmitted using the simple format as follows.

[Transmitting Side]

A5 5A 80 07 00 01 48 45 4C 4C 4F 43 04    <- Input
A5 5A 80 04 DB A1 80 01 FB 04  <- Output

[Receiving Side]

A5 5A 80 07 78 01 48 45 4C 4C 4F 3B 04  <- Output

Basic Format

When sending data expressed in basic or extended format, handle it as raw binary data.

HeaderLengthPayloadChecksumFooter
A5 5APayload LengthRepeated 00-FFXOR of PayloadEOT
  • All binary
  • Header is 2 bytes: A5 5A
  • Payload length is 2 bytes representing the byte count, OR’ed with 0x8000
  • Checksum is XOR of payload
  • Footer is EOT 0x04 (can be omitted on input)
  • Big-endian

For example, binary data 00 11 22 33 AA BB CC is expressed as follows.

A5 5A 80 07 00 11 22 33 AA BB CC DD 04

Although debugging is troublesome, it offers high efficiency for communication between microcontrollers.

Distinguishing Parent and Child Devices

Format mode distinguishes between parent and child devices.

Parent and child devices must match Application ID and Frequency Channel.

Source Identification

Format mode allows identification of the source from received data.

Simple format uses Logical Device ID, and extended format uses Logical Device ID plus extended address.

Simple Format

When using the simple format of format mode, follow the format below.

Transmitting Side Input

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+2
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command NumberAny value less than 0x80
2[uint8]Arbitrary DataByte sequence of length \(N\) (recommended \(N\leqq80\))
uint8ChecksumXOR
uint8FooterEOT (0x04)

Receiving Side Output

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+2
0uint8Source Logical Device IDParent 0x00, Child 0x01-0x64, Unset Child 0x78
1uint8Command NumberValue less than 0x80 specified by sender
2[uint8]Arbitrary DataByte sequence of length \(N\)
uint8ChecksumXOR
uint8FooterEOT (0x04)

Transmitting Side Output (Response Message)

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length4
0uint8Source Logical Device IDOnly 0xDB: indicates itself
1uint8Command NumberOnly 0xA1
2uint8Response IDContinuation number in the range 128-255 (0x80-0xFF)
3uint8ResultSuccess 1, Failure 0
uint8ChecksumXOR
uint8FooterEOT (0x04)

Example

Example of sending byte sequence 11 22 33 AA BB CC from parent to all children.

[Transmitting Side: Parent]

A5 5A 80 08 78 01 11 22 33 AA BB CC A4 04  <- Input
A5 5A 80 04 DB A1 80 01 FB 04  <- Output

The last byte 0xA4 is the checksum: XOR from 0x78 to 0xCC.

[Receiving Side: All Children]

A5 5A 80 08 00 01 11 22 33 AA BB CC DC 04  <- Output

The last byte 0xDC is the checksum: XOR from 0x00 to 0xCC.

Extended Format

When using the extended format of format mode, follow the format below.

Transmitting Side Input

When using Logical Device ID as destination

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+\(M\)+3
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command NumberOnly 0xA0
2uint8Response IDAny value
3[uint8]OptionsOption list of length \(N\) (Details below)
3+\(N\)[uint8]Arbitrary DataByte sequence of length \(M\) (recommended \(M\leqq80\))
uint8ChecksumXOR
uint8FooterEOT (0x04)

When using Extended Address as destination

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+\(M\)+7
0uint8Extended Address SpecifierOnly 0x80
1uint8Command NumberOnly 0xA0
2uint8Response IDAny value
3uint32Destination Extended AddressSerial ID with 0x8 added at the front
7[uint8]OptionsOption list of length \(N\) (Details below)
7+\(N\)[uint8]Arbitrary DataByte sequence of length \(M\) (recommended \(M\leqq80\))
uint8ChecksumXOR
uint8FooterEOT (0x04)

Details of Option List

In extended format, detailed settings can be specified by providing an option list.

The option list consists of repeated option IDs and arguments. It ends with 0xFF.

IDArgumentDefaultDescription
0x01NoneDisabledEnable MAC ACK
0x02uint80x00Enable Application Retransmission
0x03uint160x0000Minimum Initial Transmission Delay
0x04uint160x0000Maximum Initial Transmission Delay
0x05uint1610Application Retransmission Interval
0x06NoneDisabledAllow Parallel Requests
0x07NoneDisabledDisable Response Messages
0x08NoneDisabledSleep After Transmission
0x01: Enable MAC ACK

Enables MAC layer ACK (acknowledgment).

Not suitable for frequent data transmissions but can improve reliability.

0x02: Enable Application Retransmission

When using MAC ACK, specify 0x00-0x0F. Retransmits 0-16 times until successful.

When not using MAC ACK, specify 0x81-0x8F. Always retransmits 1-16 times.

Response messages are output after all retransmissions are complete.

0x03: Minimum Initial Transmission Delay

Specifies the minimum delay before the first transmission in milliseconds.

0x04: Maximum Initial Transmission Delay

Specifies the maximum delay before the first transmission in milliseconds.

0x05: Application Retransmission Interval

Specifies the interval between application retransmissions in milliseconds.

0x06: Allow Parallel Requests

Allows parallel requests.

When allowed, the next request can be accepted without blocking until the previous request completes.

For example, if three requests each with 0.5 seconds delay are input consecutively, normally they are processed sequentially at 0.5s, 1.0s, and 1.5s. With parallel requests allowed, they are processed in any order after 0.5s. Note that this cannot be used when packet segmentation is required.

0x07: Disable Response Messages

Disables response messages output when data is input on the transmitting side.

0x08: Sleep After Transmission

Immediately puts the device to sleep after transmission.

RX detects rising edge to wake from sleep. Input any 1 byte of data.

After waking, UART initialization completes and input is accepted.

Receiving Side Output

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(M\)+14
0uint8Source Logical Device IDParent 0x00, Child 0x01-0x64, Unset Child 0x78
1uint8Command NumberOnly 0xA0
2uint8Response IDValue specified by sender
3uint32Source Extended AddressSerial ID with 0x8 added at the front
7uint32Destination Extended Address0xFFFFFFFF when using Logical Device ID
11uint8LQIRadio signal quality at reception
12uint16Length of Following BytesByte count \(M\)
14[uint8]Arbitrary DataByte sequence of length \(M\)
uint8ChecksumXOR
uint8FooterEOT (0x04)

Transmitting Side Output (Response Message)

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length4
0uint8Source Logical Device IDOnly 0xDB: indicates itself
1uint8Command NumberOnly 0xA1
2uint8Response IDValue specified on input
3uint8ResultSuccess 1, Failure 0
uint8ChecksumXOR
uint8FooterEOT (0x04)

Examples

Example of sending byte sequence 11 22 33 AA BB CC from parent to child.

Example specifying Logical Device ID

Example of sending from parent to child with Logical Device ID 0x01.

  • Response ID is 0x01
  • No options

[Transmitting Side: Parent]

A5 5A 80 0A 01 A0 01 FF 11 22 33 AA BB CC 82 04  <- Input
A5 5A 80 04 DB A1 01 01 7A 04  <- Output

The last byte 0xC1 is checksum: XOR from 0x42 to 0xCC.

[Receiving Side: Child]

A5 5A 80 14 00 A0 01 82 03 68 41 FF FF FF FF FF 00 06 11 22 33 AA BB CC 2D 04  <- Output

The last byte 0x2D is checksum: XOR from 0x00 to 0xCC.

Example specifying Extended Address

Example of sending from parent to child with Extended Address 0x820163B2 (Serial ID 0x20163B2).

  • Response ID is 0x01
  • No options

[Transmitting Side: Parent]

A5 5A 80 0E 80 A0 01 82 01 63 B2 FF 11 22 33 AA BB CC 51 04  <- Input
A5 5A 80 04 DB A1 01 01 7A 04  <- Output

The last byte 0x51 is checksum: XOR from 0x80 to 0xCC.

[Receiving Side: Child]

A5 5A 80 14 00 A0 01 82 03 68 41 82 01 63 B2 FF 00 06 11 22 33 AA BB CC 7F 04  <- Output

The last byte 0x7F is checksum: XOR from 0x00 to 0xCC.

Example using MAC ACK

Example of sending from parent to child with Logical Device ID 0x01 using MAC ACK.

[Transmitting Side: Parent]

A5 5A 80 0B 01 A0 01 01 FF 11 22 33 AA BB CC 83 04  <- Input
A5 5A 80 04 DB A1 01 01 7A 04  <- Output

The last byte 0x83 is checksum: XOR from 0x01 to 0xCC.

[Receiving Side: Child]

A5 5A 80 14 00 A0 01 82 03 68 41 00 00 01 01 FF 00 06 11 22 33 AA BB CC 2D 04  <- Output

The last byte 0x2D is checksum: XOR from 0x00 to 0xCC.

Example with Delay

Example of sending from parent to child with Logical Device ID 0x01 with 768ms delay.

[Transmitting Side: Parent]

A5 5A 80 0D 01 A0 01 03 03 00 FF 11 22 33 AA BB CC 82 04  <- Input
A5 5A 80 04 DB A1 01 01 7A 04  <- Output

The last byte 0x82 is checksum: XOR from 0x01 to 0xCC.

[Receiving Side: Child]

A5 5A 80 14 00 A0 01 82 03 68 41 FF FF FF FF FF 00 06 11 22 33 AA BB CC 2D 04  <- Output

The last byte 0x2D is checksum: XOR from 0x00 to 0xCC.

0xDB Command

Instead of setting interactive mode, you can operate and configure the module by inputting the 0xDB command from UART.

5.1.2.2.1 - 0xDB Command in Serial Communication App Format Mode (Binary)

Setting functions using the 0xDB command in format mode (binary) without using Interactive Mode
In format mode, you can dynamically configure settings from devices connected via UART by using the 0xDB command instead of Interactive Mode.

Input Format

#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+2
0uint8Destination Logical Device IDOnly 0xDB indicating itself
1uint8Command NumberSelected from values below
2[uint8]ParameterByte sequence of length \(N\) indicating setting value (optional)
uint8ChecksumXOR
uint8FooterEOT (0x04)

Command Number List

Function
0xF0Enable ACK
0xF1Get Device Info
0xF2Apply Device Settings
0xF3Get Device Settings
0xFDErase Device Settings
0xFESave Device Settings
0xFFReset Device

0xF0: Enable ACK

Requests ACK response.

No parameters.

Response Format

#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length3
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF0
2uint8DataOnly 0x01
uint8ChecksumXOR
uint8FooterEOT (0x04)

0xF1: Get Device Info

Displays information such as address. Also output at startup.

No parameters.

Response Format

#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length17
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF1
2uint32Default Application ID67720103
6uint32Version NumberFor 1.4.7, 00010407
10uint8Logical Device ID
11uint32Serial ID
15uint8Silent Mode StatusEnabled 1, Disabled 0
16uint8Network StatusUP 1, DOWN 0
uint8ChecksumXOR
uint8FooterEOT (0x04)

0xF2: Apply Device Settings

Applies settings.

Response Format

On Success
#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+2
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF3
2[uint8]Setting ContentIdentifier
uint8ChecksumXOR
uint8FooterEOT (0x04)
On Failure
#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length3
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF3
2uint8ErrorOnly 0xFF
uint8ChecksumXOR
uint8FooterEOT (0x04)

0xF3: Get Device Settings

Retrieves settings.

Response Format

#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+2
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF3
2[uint8]Setting ContentIdentifier and data
uint8ChecksumXOR
uint8FooterEOT (0x04)

0xFD: Erase Device Settings

Initializes settings and resets the device.

No parameters or response.

0xFE: Save Device Settings

Saves applied settings and resets the device.

No parameters or response.

0xFF: Reset Device

Discards applied settings and resets the device.

No parameters or response.

Parameter List (0xF2/0xF3)

Parameters for 0xF2: Apply Device Settings and 0xF3: Get Device Settings are represented as repeated identifier and data (big endian) pairs.

IdentifierDataContent
0x00uint32Application ID
0x01uint32Frequency Channel Mask
0x02uint16Retry Count and Output
0x03uint8Logical Device ID
0x04uint8Role
0x05uint8Relay Layer
0x06uint8Communication Mode
0x07uint32Baud Rate
0x08uint8Parity
0x09uint8Encryption Function
0x0A[uint8]Encryption Key
0x0B[uint8]Header / Handle name
0x0Cuint16Delimiter Character
0xFFuint8Error

0x00: Application ID

Specifies the application ID.

0x01: Frequency Channel Mask

Specifies the bit mask of frequency channels.

Set bits for channels to use. For example, to use channel 11, set 1<<11.

0x02: Retry Count and Output

Specifies the radio transmission output and the number of additional packets to send in transparent mode and header-attached transparent mode.

Only the lower 1 byte is used. The upper 4 bits indicate retry count (0-9), and the lower 4 bits indicate transmission output (0-3). For example, 8 retries/output 3 is 0x0083.

0x03: Logical Device ID

Specifies the logical device ID.

0x04: Role

Valid only for child devices. Specify the following values. Usually, select a delivery method without using the network layer.

Delivery Methods Without Using Network Layer

  • 0: Normal designation (parent or child)
  • 1-3: Relay child devices (logical device IDs 1-100 or 120). Numbers 1-3 indicate maximum relay hops. This method repeats retries up to the maximum relay hops, which may cause duplicate packets depending on relay device placement and number.

Delivery Methods Using Network Layer

  • 11: Parent device
  • 12: Relay device
  • 13: Child device

0x05: Relay Layer

The relay layer number. Relay devices attempt to connect to relay devices or parent devices with higher layers (lower values). Effective only when Role is set to 12.

0x06: Communication Mode

  • 0: Transparent mode
  • 1: Format mode (binary)
  • 2: Format mode (binary)
  • 3: Chat mode
  • 4: Header-attached transparent mode

0x07: Baud Rate

Specifies UART baud rate.

0x08: Parity

Specifies the sum of settings in the following combination.

  • Bit
    • 0: 8Bit
    • 8: 7Bit
  • Parity
    • 0: None
    • 1: Odd
    • 2: Even
  • Stop
    • 0: STOP 1
    • 4: STOP 2

For example, 7-E-1 is 8+2+0=10(0xA).

0x09: Encryption Function

Specifies whether encryption is enabled.

  • 0: Disabled
  • 1: AES128bit encryption enabled

0x0A: Encryption Key

Specifies a 16-byte encryption key.

Allows storing binary sequences that cannot be set in Interactive Mode. In this case, the display in Interactive Mode may be disrupted.

0x0B: Header / Handle name

Specifies a header format on the mode E or handle name on the mode C.

0x0C: Delimiter Character

Specifies the delimiter character string (0x00-0xFF).

5.1.2.3 - Serial Communication App Chat Mode

Mode that displays prompts and performs echo back
Chat mode realizes text chat through prompt display and echo back.

By connecting MONOSTICK to a PC etc., chat can be performed among multiple terminals.

Overview

Enables text chat.

Sending Side InputReceiving Side Output
Any stringAny string + auxiliary information

Displays prompt and echoes back (outputs input characters). All terminals operate as child devices, performing broadcast communication.

For example, when sending the string Hello from one terminal to another, it behaves as follows.

[Sending Side]

810A4778:0> Hello  <- Input
810A4778:1>  <- Output

[Receiving Side]

[810A4778:0] Hello  <- Output
82018CA0:0>  <- Output

Chat mode displays prompt and echoes back (outputs input characters entered by itself).

All terminals are treated as child devices and broadcast their transmitted content. Communication is possible with all terminals but destination cannot be specified. Binary data cannot be sent. Only strings are supported (0x00-0x1F, 0x7F cannot be sent).

Relay supports up to 3 hops. Relay is disabled by default.

Distinction between Parent and Child Devices

Chat mode does not distinguish between parent and child devices.

If the Application ID and frequency channel are the same, data entered in any terminal is sent to other terminals.

Network configuration image

Network configuration image

Identification of Source

The auxiliary information in the received output can identify the sender.

If the Interactive Mode’s h: Header format is blank, the 7-digit serial ID with a leading 0x8 is used as the extended address. For example, the following output indicates the sender’s serial ID was 0x10A4778.

[810A4778:0] Hello

If h: Header format is set to an arbitrary string, it is used as the handle name. Handle name consumes data space in the wireless packet.

Sending Side Input Format

Enter message and newline after prompt.

DataContentRemarks
[char]Message0x00-0x1F, 0x7F not allowed
charCR (0x0D/'\r')Allowed alone
charLF (0x0A/'\n')Allowed alone
810A4778:0> Hello

Receiving Side Output Format

Outputs received message following auxiliary info.

Auxiliary information includes the module’s extended address or handle name and a sequence number.

DataContentRemarks
charAuxiliary info header[ only
[char]Identification info8-digit extended address or handle name
charAuxiliary info delimiter: only
[char]Sequence numberStarting from 0
charAuxiliary info footer] only
charSeparatorSpace only
[char]Message
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')
[810A4778:0] Hello

Other Inputs

Terminals supporting escape sequences can use the following control commands.

  • Ctrl-L: Clear screen
  • Ctrl-C: Cancel input
  • BS/DEL: Move cursor back

5.1.2.4 - Serial Communication App Transparent Mode

Mode that purely wirelesss UART
Transparent mode realizes behavior similar to UART connected by wires without adding headers, echo back, or prompt display.
Image connecting external microcontrollers

External microcontrollers can be easily connected, but to optimize communication using formats, format modes (ASCII / Binary) are suitable.

Overview

Purely wirelesss UART.

Sending side inputReceiving side output
Any dataAny data

Since no format is required, existing UART communication can be easily wirelessized.

However, data delimiters are ambiguous and it is impossible to identify the sender from the receiver output.

The initial state specifies CRLF as the transmission trigger character. Therefore, data input to the transmitter is separated by CRLF, and the data before CRLF is transmitted.

For example, entering Hello<Enter> on the transmitting terminal results in Hello being output on the receiving terminal.

[Sending side]

Hello  <- Input

[Receiving side]

Hello  <- Output

Continuous input strings are split and sent in chunks of 80 bytes. Data up to the trigger character should normally be 80 bytes or less.

All terminals are considered child devices, and the transmitted content is broadcast. Communication with all terminals is possible, but the destination cannot be specified. Both ASCII characters and binary data can be sent.

Relay supports up to 3 hops. By default, relay is disabled.

Distinction between Parent and Child Devices

Transparent mode does not distinguish between parent and child devices.

If application ID and frequency channel are the same, data entered into any terminal is sent to other terminals.

Network configuration image

Network configuration image

Identification of Sender

Transparent mode cannot identify the sender.

To identify sender, sender information must be included in data input to the transmitter.

Transmission Trigger

Transmission trigger must be considered, as data is divided and transmitted wirelessly packet by packet.

Therefore, the following transmission triggers must be taken into account:

  • When a timeout after data input is reached
  • When the input data reaches the minimum data size
  • When the transmission trigger character is received

Transmission trigger settings can be specified from the interactive mode k: Transmission Trigger item.

Example Setting

When setting the transmission trigger character to LF, minimum data size to 8 bytes, and timeout to 30 ms, set as follows:

 m: set UART mode (D)
 k: set Tx Trigger (sep=0x0a, min_bytes=8 dly=30[ms])
 o: set option bits (0x00000100)

5.1.2.5 - Serial Communication App Header Transparent Mode

Mode that adds headers only to the received output
Header Transparent Mode adds auxiliary information only to the output on the receiving side.

Overview

Enabled by default.

When arbitrary data is input to the transmitting terminal, the receiving terminal outputs data with auxiliary information in a specific format.

Transmitting side inputReceiving side output
Any dataAny data + auxiliary info

By default, data input on the transmitting side is separated by CRLF and data before CRLF is sent.

For example, entering Hello<Enter> on the transmitting side results in output Hello with auxiliary info on the receiving side. The transmitting side also outputs a message indicating transmission completion.

[Transmitting side]

Hello  <- input
;U;00004;219;0x820163B2;000;000;0,1,Hel...;6E;  <- output

[Receiving side]

;U;00003;000;0x820163B2;255;000;Hello;42;  <- output

The auxiliary information output by the receiving side includes the source address, received signal strength, checksum, etc. The format of the auxiliary information can be customized.

Distinction between Parent and Child Devices

Header Transparent Mode does not distinguish between parent and child devices.

If the Application ID and frequency channel are the same, data input to any terminal is sent to other terminals.

Network configuration image

Network configuration image

Identification of Source

The header on the received data includes the logical device ID and serial ID of the sender.

Output Format on Receiving Side

The output format is represented as semicolon (;) separated fields.

[Example output in default state]

;U;00777;120;0x81025A17;120;013;HELLO;79;

This output can be interpreted as follows.

DataDescriptionValue
UcharFixed valueU
00777uint16Timestamp at output777 seconds
120uint8Source logical device ID120 ID-less child device
0x81025A17uint32Source extended address81025A17
120uint8LQI (link quality indicator)120/255
013uint8Source sequence number13
HELLO[uint8]Input dataHELLO
79uint8XOR checksum0x79

Customization by Header Format

The output format on the receiving side follows the header format.

Changing the header format customizes the content of the auxiliary information output and the checksum calculation range.

The header format can be changed via the interactive mode command h: set header format.

Simplest Format

The simplest header format is *\n. It outputs the received data with CRLF line endings.

 h: set header format [*\n]

When sending HELLO in this case, it behaves as follows.

[Receiving side]

HELLO<CR><LF> or HELLO<LF>

[Transmitting side]

HELLO<CR><LF>

Special Characters in Header Format

You can customize the output by including the following special characters in the header format.

General
Description
*Received data
&hlArbitrary ASCII character (e.g., &20 is space)
<Start position for checksum calculation (default is start of string)
>End position for checksum calculation (only from v1.4.6)
Characters following \ (backslash)
Description
\nCRLF (0x0D 0x0A)
\tTAB
\**
\%%
\<<
\>>
\&&
Characters following %
DescriptionLengthData format
%ASource address (32bit)8 charsHexadecimal
%aSource address (32bit)10 charsHexadecimal
%ISource logical address (8bit)2 charsHexadecimal
%iSource logical address (8bit)3 charsDecimal
%TCurrent system time (seconds)4 charsHexadecimal
%tCurrent system time (seconds)5 charsDecimal
%SSource sequence number (hex)2 charsHexadecimal
%sSource sequence number (hex)3 charsHexadecimal
%QReceived signal strength2 charsHexadecimal
%qReceived signal strength3 charsDecimal
%XChecksum2 charsHexadecimal
%xChecksum3 charsDecimal

Checksum Calculation

The checksum is calculated by XOR (exclusive OR) from the start of the data or from the position indicated by < in the header format up to just before %X or %x.

Example in Default State

The default header format is ;U;%t;%i;0x%A;%q;%s;<*;%X;\n, where the checksum calculation range is *;.

That is, when sending HELLO, the binary data HELLO; is targeted, resulting in checksum 0x79.

[Verification code in Python]

from functools import reduce

def main():
    data = "HELLO;"
    checksum = reduce(lambda x, y: x ^ y, data.encode("ascii"))
    print(f"{data} -> {hex(checksum)}")

if __name__ == "__main__":
   main()  # HELLO; -> 0x79

Other Examples

For example, consider the header format ;%I;*;%X.

Since < is not specified, the checksum calculation range is ;%I;*;.

That is, when sending HELLO, the binary data ;000;HELLO; is targeted, resulting in checksum 0x49.

[Verification code in Python]

from functools import reduce

def main():
    data = ";000;HELLO;"
    checksum = reduce(lambda x, y: x ^ y, data.encode("ascii"))
    print(f"{data} -> {hex(checksum)}")

if __name__ == "__main__":
   main()  # ;000;HELLO; -> 0x49

Transmission Trigger

There is no format on the transmitting side input, but data is split and transmitted packet by packet.

Therefore, the following transmission triggers must be considered.

  • When timeout after data input occurs
  • When input data reaches the minimum data size
  • When a transmission trigger character is received

Transmission trigger settings are specified via the interactive mode k: set transmission trigger item.

Example Setting

To set the transmission trigger character to LF, minimum data size to 8 bytes, and timeout to 30 ms, use the following settings.

 m: set UART mode (E)
 k: set Tx Trigger (sep=0x0a, min_bytes=8 dly=30[ms])
 o: set option bits (0x00000100)

5.1.3 - Interactive Mode (Serial Communication App)

Configuration via Interactive Mode
You can configure advanced settings of the app via Interactive Mode.

This section describes features specific to the serial communication app (App_Uart). For common functions, refer to the TWELITE APPS Manual Top Page.

Display Example

[CONFIG MENU/App_Uart:0/v1-05-1/SID=8300051A]
a: (0x67720103) Application ID [HEX:32bit]
i: (       120) Device ID [1-100,etc]
c: (18        ) Channel(s)
x: (      0x03) RF Power/Retransmissions [HEX:8bit]
b: (115200,8N1) UART Baud Alt. [XXXXX]
o: (0x00000100) Option bits [HEX:32bit]
r: (      0x00) Role [0-3,11-13]
l: (         1) LayerTree repeat layer [1-63]
m: (E         ) UART mode [ABCDE]
t: (    0x0D0A) Tx trigger character [XX,XXYY]
u: (         0) Minimum data size [0,1-80]
T: (         0) Timeout [0,10-200 msec]
h: (;U;%t;%i;0x%A;%q;%s;<*;%X;\n) Header format / Handle name
C: (         0) Encryption [0,1]
K: (*CRYPT_KEY_HERE*) Encryption key [16chrs]

 [ESC]:Exit [!]:Reset System [*]:Extr Menu [:]:AppSel

Commands

ParameterDefaultRemarks
aApplication ID0x6772010332bit
iLogical Device ID120Parent 121, Child 1-100, No ID Child 120
cFrequency Channel1811-26
xTX Power & Retransmit Count0x03
Retransmit Count01-9 times, 0 disables
TX Power30-3
bUART Alternate Setting115200,`8N1Enable with BPS pin
oOption Bits0x00000000Other detailed settings
rRole0Normal 0, Relay Child 1-3, Other
lLayerTree Relay Layer0x01
mCommunication ModeEA/B/C/D/E
tTX Trigger Characters0x0D0AASCII code of trigger characters
uMinimum Data Size0Disabled 0, 1-80
TTimeout0Disabled 0, 10-200ms
hHeader Format / Handle NameDetails
Header FormatWhen using Header Transmission Mode
Handle NameWhen using Chat Mode
CEncryption0Disabled 0, AES128bit 1
KEncryption Key*CRYPT_KEY_HERE*16 characters

Each command is described in detail below.

a: Application ID

All devices participating in communication must use the same value. This logically separates networks.

i: Logical Device ID

Set this value if it is necessary to distinguish between multiple child devices.

If no distinction is needed or possible, set it to 120. If distinction is required, use any value between 1 and 100 for child devices, and use 121 for parent devices.

c: Frequency Channel

All devices participating in communication must use the same value. This physically separates networks.

x: TX Power & Retransmit Count

Specifies the RF transmission power and the number of retransmissions in Transparent Mode and Header Transmission Mode.

b: UART Alternate Setting

Overrides the default 38400bps alternate baud rate used when booting with the BPS pin connected to GND.

Select from: 9600 / 19200 / 38400 / 57600 / 115200 / 230400.

o: Option Bits

Specify a 32-bit value. Each bit enables a corresponding setting.

BitSetting ItemDefaultABCDE
0x00000001Disable Internal Pull-up of M30️⃣
0x00000100Enable TX Trigger1️⃣
0x00000200Prioritize New Input Stream0️⃣
0x00001000Suppress Response Message0️⃣
0x00004000Relax Duplicate Checker0️⃣
0x00010000Force Apply Alternate Baud Rate0️⃣
0x00020000Simultaneous Output to Sub Port0️⃣
0x00040000Switch Primary Port0️⃣
0x01000000Disable LED0️⃣
0x02000000Disable LED in Standby0️⃣

r: Role

Valid for child devices only. Select one of the following. Normally, use a transmission mode that does not rely on the network layer (LayerTree).

Transmission Modes Not Using the Network Layer

  • 0: Default (Parent or Child)
  • 13: Repeater Child (set Logical Device ID to 1100 or 120). The value indicates the maximum number of relay hops. Duplicated packets may occur depending on placement and number of repeaters.

Transmission Modes Using the Network Layer

Only supported in Header Transmission Mode.

  • 11: Parent
  • 12: Repeater
  • 13: Child

l: LayerTree Relay Layer

Specifies the relay layer number. A repeater attempts to connect to parent or repeater devices with higher relay layers (smaller values). Valid only when Role is set to 12.

m: Communication Mode

  • A: Format Mode (ASCII)
  • B: Format Mode (Binary)
  • C: Chat Mode
  • D: Transparent Mode
  • E: Header Transmission Mode

t: TX Trigger Characters

In Transparent and Header Transmission modes, entering these characters triggers transmission of a packet.

If Minimum Data Size is specified, the characters will be ignored until that size is reached.

u: Minimum Data Size

Specifies the minimum size of data to be handled continuously. TX Trigger Characters are ignored until this size is met.

In Interactive Mode, specify a number between 180 as byte count. Set to 0 to disable. The default is disabled.

T: Timeout

Time to wait from the last input before transmitting a packet.

In Interactive Mode, specify a value between 10200 in milliseconds. Set to 0 to disable. The default is disabled.

h: Header Format / Handle Name

Specifies the header format for Header Transmission Mode, or the handle name for Chat Mode.

Header (Header Transmission Mode)

Specify the Header Format Syntax for use in Header Transmission Mode.

Handle Name (Chat Mode)

Specify the handle name to display on the receiving device.

Up to 23 characters. This consumes part of the data transmission area (80 bytes).

C: Encryption

Specifies whether to enable encryption.

To enable AES128-bit encryption, set this to 1.

K: Encryption Key

Specify a 16-character encryption key when encryption is enabled.

Option Bits Details

This section describes each setting associated with the bits of the Option Bits value.

00000001: Disable Internal Pull-up of M3

Disables the internal pull-up resistor of the M3 pin used for sleep configuration on TWELITE DIP.

00000100: Enable TX Trigger

Enables the TX Trigger setting in Transparent or Header Transmission Mode.

00000200: Prioritize New Input Stream

In Format Mode (ASCII/Binary), Transparent Mode, and Header Transmission Mode, if multiple input streams are received before the previous transmission is complete, the newer input is prioritized.

00001000: Suppress Response Message

In Format Mode (ASCII/Binary) and Header Transmission Mode, suppresses the response message after transmission completes.

00004000: Relax Duplicate Checker

Relaxes the duplicate check conditions on the receiver side.

00010000: Force Apply Alternate Setting

Applies the UART Alternate Setting even if the BPS pin is not pulled low at boot.

00020000: Simultaneous Output to Sub Port

Also outputs serial TX data to the secondary TX_SUB port.

00040000: Switch Primary Port

Switches the serial I/O between the main TX/RX and the sub TX_SUB/RX_SUB ports.

About Repeater Function

When the communication range is insufficient or obstructed, using a repeater can be effective.

A repeater device retransmits packets it receives to other devices.

01000000: Disable LED

Disables the LED on TWELITE STICK and MONOSTICK.

02000000: Disable LED in Standby

Disables the LED on TWELITE STICK and MONOSTICK while in standby.

Configuring Repeater Function

Normally, enter Interactive Mode and change the Role to a value between 1 and 3. The default is 0, which does not enable the repeater function.

r: set Role (0x0)

The values 1 to 3 indicate the maximum number of relay hops. For example, setting it to 3 allows up to 3 hops.

This setting is only valid for child devices, not for parent devices.

Example Configuration

The following network configuration shows an example where the Role of red devices is set to 0, and that of blue devices is set to 3.

Example of relaying via Role setting

Example of relaying via Role setting

By adding more red devices, communication with up to three relay hops between them can be established.

Example of adding transmitters and receivers

Example of adding transmitters and receivers

5.1.4 - Notes on Communication in Serial Communication App

Precautions for stable communication
Precautions for achieving stable communication.

UART Data Input and Output

4KB buffers are allocated for UART input and output. When outputting two UART lines, 2KB is used for input and output buffers for each line.

In format mode and chat mode, it is rarely necessary to be aware of buffer sizes, but in header transparent mode and transparent mode when continuously inputting streams, or even in format mode when inputting many streams at once, it is necessary to be aware of the buffer size limits. On the output side, if a slow baud rate is set, the output of data received wirelessly may not keep up.

Data beyond the buffer limits is not protected at the boundary, causing data loss. Especially on the input side, consider referring to the flow control pins described below.

UART Flow Control

Input flow control is implemented to behave like the RTS pin. The pin used is PWM1 (DIO5), targeting the main UART port. When input is not accepted, the state is High; when input is accepted, the state is Low. Output flow control is not supported. Receiving devices should ensure sufficient baud rate and processing speed.

  • After power-on or reset, the pin is High. It becomes Low once UART is initialized.
  • When the UART input buffer exceeds 7/8 full, the pin goes High; it goes Low when below that threshold.
  • In transparent mode, the pin is High during packet transmission.

Countermeasures for Wireless Communication Errors

If data loss occurs on the receiving side, increase the number of wireless retransmissions.

Increasing the number of additional packets sent can improve the success rate of reception.

The number of retransmissions can be set in Interactive Mode (x: set RF Conf).

5.1.5 - Custom Default Feature of Serial Communication App

Creating firmware with changed default settings
With the custom default feature, you can change the default parameters included in the firmware.

For example, if you create firmware that changes the baud rate from 115200bps to 9600bps, you can use it at 9600bps from the start.

Configuration Procedure

1. Apply Settings

Change the settings in Interactive Mode and press S to save.

2. Download Settings

Prepare software that can download data using the xmodem protocol.

While still in Interactive Mode (before selecting items), request xmodem download.

If the download succeeds, a 128-byte file is generated (may be smaller depending on xmodem implementation).

3. Creating Custom Binary

Concatenate the downloaded file to the end of the firmware binary file to create a custom binary.

Use command line tools or general file concatenation tools for concatenation.

Example

Example assuming downloaded xmodem file is conf.bin, original binary file is App_Uart_BLUE_L1305_V1-4-X.bin, and custom binary to create is App_Uart_custom_V1-4-X.bin.

【Windows】

copy App_Uart_BLUE_L1305_V1-4-X.bin App_Uart_custom_V1-4-X.bin
type conf.bin >> App_Uart_custom_V1-4-X.bin

【macOS / Linux】


cat App_Uart_BLUE_L1305_V1-4-X.bin conf.bin > App_Uart_custom_V1-4-X.bin

4. Writing Custom Binary

Write the concatenated custom binary to TWELITE.

5.2 - Serial Communication App Manual

v1.4.7 BLUE/RED Stable version

Download

To install the Serial Communication App (App_Uart), install the TWELITE STAGE SDK and rewrite using the TWELITE STAGE App.

5.2.1 - Pin Assignments of Serial Communication App

Functions of pins used by the Serial Communication App

TWELITE / TWELITE DIP

The functions of pins used by the Serial Communication App are represented using the pin names from the Super Simple! Standard App Pins shown in the figure below.

Super Simple! Standard App Pin Assignment Table

Super Simple! Standard App Pin Assignment Table

Serial CommunicationSuper Simple! StandardFunction
VCC GNDVCC GNDPower Input
TX RXTX RXSerial Input and Output
TX_SUB RX_SUBSCL SDASerial Sub Input and Output
RTSPWM1Serial Input Permission
M1M1Parent/Child Selection
M2M2Adding Relay Function to Child
M3M3Sleep
EX1AI2Overwriting Operation Mode
BPSBPSEnabling Alternative Baud Rate Setting
RSTRSTReset Input

Power Input

Connect a 3.3V (2.0-3.6V) power supply to VCC/GND.

Serial Input and Output

TX/RX are used for transmitting and receiving serial communication (UART).

Serial Sub Input and Output

TX_SUB (SCL) / RX_SUB (SDA) can be used as sub-ports for serial input and output.

Serial Input Permission

When RTS (PWM1) is at Low level, it indicates that serial input to RX is being accepted.

Parent/Child Selection

Connecting M1 to GND sets the device as a parent, while leaving it open or connecting to VCC sets it as a child.

Adding Relay Function to Child

When M2 is connected to GND in child mode, relay functionality can be added.

Sleep

Connecting M3 to GND puts the device into sleep mode.

Overwriting Operation Mode

By connecting EX1 to GND at startup, the operation mode can be overwritten to format mode (binary).

Enabling Alternative Baud Rate Setting

Connecting BPS to GND enables the alternative baud rate setting specified in interactive mode.

Reset Input

By connecting a push button between RST and GND, a reset button can be implemented. RST has an internal pull-up resistor.

TWELITE UART

The functions of pins used by the Serial Communication App are represented using the pin names of the 7P interface printed on the board (② in the figure below).

Board Antenna Type

Board Antenna Type

Coaxial Connector Type

Coaxial Connector Type

SilkscreenFunction
VCC GNDPower Input
TXD RXDSerial Input and Output
SETOverwriting Operation Mode
RSTReset Input

Power Input

Connect a 3.3V (2.0-3.6V) power supply to VCC/GND.

Serial Input and Output

TX/RX are used for transmitting and receiving serial communication (UART).

Overwriting Operation Mode

By connecting SET to GND at startup, the operation mode can be overwritten to format mode (ASCII).

Reset Input

By connecting a push button between RST and GND, a reset button can be implemented. RST has an internal pull-up resistor.

5.2.2 - Communication Modes of Serial Communication App

Explanation of each communication mode
The Serial Communication App (App_Uart) has five communication modes.

List of Communication Modes

Each mode is switched by Interactive Mode (some modes can be set via pin input).

IDMode
AFormat Mode (ASCII)
BFormat Mode (Binary)
CChat Mode
DTransparent Mode
EHeader Transparent Mode

Initial state is Header Transparent Mode.

A: Format Mode (ASCII)

When data is input to the transmitting terminal according to a specific format, the receiving terminal outputs data according to the same specific format.

Data represented in hexadecimal is expressed as ASCII strings.

Input on Transmitting SideOutput on Receiving Side
Simple/Extended format dataSimple/Extended format data

In TWELITE UART, this mode is enabled when started with the SET pin connected to GND.

There are two formats to represent data.

  • Simple format: Uses only logical device ID. Super simple! Compatible with the standard app’s UART transmission function.
  • Extended format: Uses transmission options such as serial ID and retransmission count in addition to logical device ID.

For example, 5-byte binary data 0x48 0x45 0x4C 0x4C 0x4F can be sent using the simple format as follows.

[Transmitting Side]

:000148454C4C4F8B  <- Input
:DBA1800103  <- Output

[Receiving Side]

:780148454C4C4F13  <- Output

In format mode, settings such as application ID can be dynamically applied not only by Interactive Mode but also by commands via UART (ASCII format).

B: Format Mode (Binary)

When data is input to the transmitting terminal according to a specific format, the receiving terminal outputs data according to the same specific format.

Data represented in hexadecimal is expressed in binary format as is.

Input on Transmitting SideOutput on Receiving Side
Simple/Extended format dataSimple/Extended format data

In TWELITE / TWELITE DIP, this mode is enabled when started with the EX1 pin connected to GND.

Like Format Mode (ASCII), there are two formats to represent data.

For example, 5-byte binary data 0x48 0x45 0x4C 0x4C 0x4F can be sent using the simple format as follows.

[Transmitting Side]

0xA5 0x5A 0x00 0x07 0x00 0x01 0x48 0x45 0x4C 0x4C 0x4F 0x43 0x04    <- Input
0xA5 0x5A 0x00 0x04 0xDB 0xA1 0x80 0x01 0xFB 0x04  <- Output

[Receiving Side]

0xA5 0x5A 0x00 0x07 0x78 0x01 0x48 0x45 0x4C 0x4C 0x4F 0x3B 0x04  <- Output

In format mode, settings such as application ID can be dynamically applied not only by Interactive Mode but also by commands via UART (binary format).

C: Chat Mode

Enables text chat.

Input on Transmitting SideOutput on Receiving Side
Any stringAuxiliary information + any string

Displays prompt and echoes back (outputs the entered characters). All terminals act as child devices and perform broadcast communication.

For example, when a terminal sends the string Hello to other terminals, the behavior is as follows.

[Transmitting Side]

810A4778:0> Hello  <- Input
810A4778:1>  <- Output

[Receiving Side]

[810A4778:0] Hello  <- Output
82018CA0:0>  <- Output

In the above example, the prompt shows the serial ID, but you can also use any handle name.

D: Transparent Mode

When arbitrary data is input to the transmitting terminal, the receiving terminal outputs the received data as is.

Input on Transmitting SideOutput on Receiving Side
Any dataAny data

Since no format is required, existing UART communication can be easily wirelessized.

On the other hand, data boundaries become ambiguous, and the receiving output cannot identify the sender, which are drawbacks.

By default, data input to the transmitting side is separated by CRLF, and data before CRLF is sent.

For example, when Hello<Enter> is input on the transmitting terminal, the receiving terminal outputs Hello as is.

[Transmitting Side]

Hello  <- Input

[Receiving Side]

Hello  <- Output

E: Header Transparent Mode

When arbitrary data is input to the transmitting terminal, the receiving terminal outputs the received content with auxiliary information added in a specific format.

Input on Transmitting SideOutput on Receiving Side
Any dataAny data + auxiliary information

By default, data input to the transmitting side is separated by CRLF, and data before CRLF is sent.

For example, when Hello<Enter> is input on the transmitting terminal, the receiving terminal outputs Hello in a format including auxiliary information. The transmitting terminal also outputs a format that conveys a transmission completion message.

[Transmitting Side]

Hello  <- Input
;U;00004;219;0x820163B2;000;000;0,1,Hel...;6E;  <- Output

[Receiving Side]

;U;00003;000;0x820163B2;255;000;Hello;42;  <- Output

The auxiliary information output by the receiving side includes the sender’s address, received signal strength, checksum, etc. The format of auxiliary information can be customized.

5.2.2.1 - Serial Communication App Format Mode (ASCII)

Mode that adds headers to both transmitted and received outputs (ASCII format)
Format mode adds headers to both transmitted and received outputs. In ASCII format, data is represented as hexadecimal strings.
Example network configuration with format mode

Overview

When data formatted in a specific manner is input on the transmitting side, the receiving side outputs data formatted in the same manner.

Data is represented as hexadecimal ASCII strings.

Transmitting Side InputReceiving Side Output
Simple/Extended format dataSimple/Extended format data
  • In TWELITE UART, format mode (ASCII) is enabled by starting up with the SET pin connected to GND.
  • In TWELITE / TWELITE DIP, format mode (binary) is enabled by starting up with the EX1 pin connected to GND.

There are two types of formats that can be handled.

  • Simple format: uses only the Logical Device ID. Extremely Simple! Compatible with the UART transmission function of the standard app.
  • Extended format: uses Logical Device ID plus transmission options such as Serial ID and retry count.

For example, 5-byte binary data 0x48 0x45 0x4C 0x4C 0x4F can be sent using the simple format as follows.

[Sending side]

:000148454C4C4F8B  <- Input
:DBA1800103  <- Output

[Receiving side]

:780148454C4C4F13  <- Output

Basic Format

When sending data sequences expressed in basic or extended formats, they are converted to ASCII strings (0-9, A-F).

The format is extremely simple! It starts with : and ends with CRLF, just like the output of the standard app (App_Twelite) or the parent device output of the parent/repeater app (App_Wings).

HeaderPayloadChecksumFooter
:Repeated 00-FFLRC8 of payloadCRLF
  • All ASCII characters
  • Starts with : (0x3A)
  • Checksum is the two’s complement of the sum of the payload
  • Ends with CRLF (\r\n/0x0D 0x0A)
  • Big-endian

For example, binary data 0x00 0x11 0x22 0x33 0xAA 0xBB 0xCC is expressed as follows.

:00112233AABBCC69<CR><LF>

Distinguishing Parent and Child Devices

Format mode distinguishes between parent and child devices.

The Application ID and frequency channel must be matched between parent and child devices.

Source Identification

Format mode allows identifying the source from the received data.

The simple format uses the Logical Device ID, and the extended format uses the Logical Device ID plus the extended address.

Simple Format

When using the simple format of format mode, follow the format below.

Transmitting Side Input

#DataDescriptionNotes
charHeaderOnly :
0uint8Destination Logical Device IDParent 0x00, child 0x01-0x64, all children 0x78
1uint8Command numberAny value less than 0x80
2[uint8]Arbitrary dataByte sequence of length (N) (recommended (N \leqq 80))
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Receiving Side Output

#DataDescriptionNotes
charHeaderOnly :
0uint8Source Logical Device IDParent 0x00, child 0x01-0x64, unset child 0x78
1uint8Command numberValue less than 0x80 specified by the sender
2[uint8]Arbitrary dataByte sequence of length (N)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Transmitting Side Output (Response Message)

#DataDescriptionNotes
charHeaderOnly :
0uint8Source Logical Device IDOnly 0xDB: indicates itself
1uint8Command numberOnly 0xA1
2uint8Response IDContinuation number in the range 128-255 (0x80-0xFF)
3uint8ResultSuccess 1, failure 0
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Usage

An example of sending byte sequence 0x11 0x22 0x33 0xAA 0xBB 0xCC from the parent to all children is shown.

[Sending side: Parent]

:7801112233AABBCCF0<CR><LF>  <- Input
:DBA1800103<CR><LF>  <- Output

The trailing 0xF0 is the checksum: the two’s complement of the sum from 0x78 to 0xCC (LSB 8 bits).

[Receiving side: All children]

:0001112233AABBCC68<CR><LF>  <- Output

The trailing 0x68 is the checksum: the two’s complement of the sum from 0x00 to 0xCC (LSB 8 bits).

Extended Format

When using the extended format of format mode, follow the format below.

Transmitting Side Input

When specifying destination using Logical Device ID

#DataDescriptionNotes
charHeaderOnly :
0uint8Destination Logical Device IDParent 0x00, child 0x01-0x64, all children 0x78
1uint8Command numberOnly 0xA0
2uint8Response IDAny value
3[uint8]OptionsOption list of length (N) (Details of option list)
3+(N)[uint8]Arbitrary dataByte sequence of length (M) (recommended (M \leqq 80))
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

When specifying destination using Extended Address

#DataDescriptionNotes
charHeaderOnly :
0uint8Extended Address SpecifierOnly 0x80
1uint8Command numberOnly 0xA0
2uint8Response IDAny value
3uint32Destination Extended AddressSerial ID with 0x8 added at the front
7[uint8]OptionsOption list of length (N) (Details of option list)
7+(N)[uint8]Arbitrary dataByte sequence of length (M) (recommended (M \leqq 80))
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Details of Option List

In the extended format, you can specify fine settings by specifying the option list.

The option list is represented by repeating option IDs and their arguments. The end is 0xFF.

IDArgumentDefaultDescription
0x01NoneDisabledEnable MAC ACK
0x02uint80x00Enable application retry
0x03uint160x0000Minimum initial transmission delay
0x04uint160x0000Maximum initial transmission delay
0x05uint1610Application retry interval
0x06NoneDisabledAllow parallel requests
0x07NoneDisabledDisable response messages
0x08NoneDisabledSleep after transmission
0x01: Enable MAC ACK

Enables MAC layer ACK (acknowledgment).

Not suitable for frequent data transmission, but can improve reliability.

0x02: Enable Application Retry

When using MAC ACK, specify 0x00-0x0F. Retries 0-16 times respectively until the transmission succeeds.

When not using MAC ACK, specify 0x81-0x8F. Always retries 1-16 times.

Response messages are output after all retries are completed.

0x03: Minimum Initial Transmission Delay

Specifies the minimum delay before the first transmission in milliseconds.

0x04: Maximum Initial Transmission Delay

Specifies the maximum delay before the first transmission in milliseconds.

0x05: Application Retry Interval

Specifies the retry interval in milliseconds when application retry is enabled.

0x06: Allow Parallel Requests

Allows parallel requests.

When allowed, the next request can be accepted without blocking until the current request completes.

For example, if three requests with a 0.5-second delay are input consecutively, normally they are processed sequentially at 0.5s, 1.0s, and 1.5s. When parallel requests are allowed, they are processed in no particular order after 0.5s. Note that it cannot be used when packet fragmentation is required.

0x07: Disable Response Messages

Disables the response messages output when data is input on the transmitting side.

0x08: Sleep After Transmission

Immediately puts the device to sleep after transmission.

When RX detects a rising edge, it wakes up from sleep. Please input any 1 byte of data.

After waking up, UART initialization completes and input is accepted.

Receiving Side Output

#DataDescriptionNotes
charHeaderOnly :
0uint8Source Logical Device IDParent 0x00, child 0x01-0x64, unset child 0x78
1uint8Command numberOnly 0xA0
2uint8Response IDValue specified by the sender
3uint32Source Extended AddressSerial ID with 0x8 added at the front
7uint32Destination Extended Address0xFFFFFFFF if using Logical Device ID
11uint8LQIRadio communication quality at reception
12uint16Length of following byte sequenceNumber of bytes (M)
14[uint8]Arbitrary dataByte sequence of length (M)
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Transmitting Side Output (Response Message)

#DataDescriptionNotes
charHeaderOnly :
0uint8Source Logical Device IDOnly 0xDB: indicates itself
1uint8Command numberOnly 0xA1
2uint8Response IDValue specified at input
3uint8ResultSuccess 1, failure 0
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

Example Usage

An example of sending byte sequence 0x11 0x22 0x33 0xAA 0xBB 0xCC from the parent to a child is shown.

Example specifying Logical Device ID

An example sending from the parent to the child with Logical Device ID 0x42.

  • Response ID is 0x01
  • No options
  • Parent’s extended address is 0x81000000 (Serial ID 0x1000000)

[Sending side: Parent]

:42A001FF112233AABBCC87<CR><LF>  <- Input
:DBA1010182<CR><LF>  <- Output

The trailing 0x87 is the checksum: the two’s complement of the sum from 0x42 to 0xCC (LSB 8 bits).

[Receiving side: Child]

:00A00181000000FFFFFFFFC80006112233AABBCC7D<CR><LF>  <- Output

The trailing 0x7D is the checksum: the two’s complement of the sum from 0x00 to 0xCC (LSB 8 bits).

Example specifying Extended Address

An example sending from the parent to the child with extended address 0x81000001 (Serial ID 0x1000001).

  • Response ID is 0x01
  • No options
  • Parent’s extended address is 0x81000000 (Serial ID 0x1000000)

[Sending side: Parent]

:80A00181000001FF112233AABBCCC7<CR><LF>  <- Input
:DBA1010182<CR><LF>  <- Output

The trailing 0xC7 is the checksum: the two’s complement of the sum from 0x80 to 0xCC (LSB 8 bits).

[Receiving side: Child]

:00A0018100000081000001C80006112233AABBCCF7<CR><LF>  <- Output

The trailing 0xF7 is the checksum: the two’s complement of the sum from 0x00 to 0xCC (LSB 8 bits).

Example using MAC ACK

An example sending from the parent to the child with Logical Device ID 0x42 using MAC ACK.

  • Response ID is 0x01
  • Option 0x01: Enable MAC ACK specified
  • Parent’s extended address is 0x81000000 (Serial ID 0x1000000)

[Sending side: Parent]

:42A00101FF112233AABBCC86<CR><LF>  <- Input
:DBA1010182<CR><LF>  <- Output

The trailing 0x86 is the checksum: the two’s complement of the sum from 0x42 to 0xCC (LSB 8 bits).

[Receiving side: Child]

:00A00181000000FFFFFFFFC80006112233AABBCC7D<CR><LF>  <- Output

The trailing 0x7D is the checksum: the two’s complement of the sum from 0x00 to 0xCC (LSB 8 bits).

Example using delay

An example sending from the parent to the child with Logical Device ID 0x42 with a 768ms delay.

[Sending side: Parent]

:42A001030300FF112233AABBCC81<CR><LF>  <- Input
:DBA1010182<CR><LF>  <- Output

The trailing 0x81 is the checksum: the two’s complement of the sum from 0x42 to 0xCC (LSB 8 bits).

[Receiving side: Child]

:00A00181000000FFFFFFFFC80006112233AABBCC7D<CR><LF>  <- Output

The trailing 0x7D is the checksum: the two’s complement of the sum from 0x00 to 0xCC (LSB 8 bits).

0xDB Command

Instead of setting interactive mode, you can operate and configure the module by inputting the 0xDB command from UART.

5.2.2.1.1 - 0xDB Command in Serial Communication App Format Mode (ASCII)

Setting functions using the 0xDB command in format mode (ASCII) without using Interactive Mode
In format mode, dynamic configuration can be performed from devices connected via UART by using the 0xDB command instead of Interactive Mode.

Input Format

#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB itself
1uint8Command numberSelected from values below
2[uint8]ParameterOptional length N bytes representing setting values
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

List of Command Numbers

Function
0xF0Enable ACK
0xF1Get Device Info
0xF2Apply Device Settings
0xF3Get Device Settings
0xF8Device Control
0xFDErase Device Settings
0xFESave Device Settings
0xFFReset Device

0xF0: Enable ACK

Requests an ACK response.

No parameters.

Response Format

#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF0
2uint8DataOnly 0x01
uint8Checksum0x34: LRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0xF1: Get Device Info

Displays address and other information. Also output at startup.

No parameters.

Response Format

#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF1
2uint32Default Application ID67720103
6uint32Version numberFor 1.4.7, 00010407
10uint8Logical device ID
11uint32Serial ID
15uint8Silent mode statusEnabled 1, Disabled 0
16uint8Network statusUP 1, DOWN 0
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0xF2: Apply Device Settings

Applies the settings.

Response Format

On Success
#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF3
2[uint8]Settings contentLength N repeated pairs of identifier and data
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')
On Failure
#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF3
2uint8ErrorOnly 0xFF
uint8Checksum0x33: LRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0xF3: Get Device Settings

Gets the settings.

Response Format

#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF3
2[uint8]Settings contentRepeated pairs of identifier and data
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0xF8: Device Control

If silent mode was enabled at startup, this disables it.

Response Format

#DataContentRemarks
charHeader: only
0uint8Destination logical device IDOnly 0xDB
1uint8Command numberOnly 0xF8
2uint8DataOnly 0x11
3uint8StatusDisabled 1, Not disabled 0
uint8ChecksumLRC8
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')

0xFD: Erase Device Settings

Resets device settings and resets the device.

No parameters or response.

0xFE: Save Device Settings

Saves applied settings and resets the device.

No parameters or response.

0xFF: Reset Device

Discards applied settings and resets the device.

No parameters or response.

Parameter List (0xF2 / 0xF3)

Parameters for 0xF2: Apply Device Settings and 0xF3: Get Device Settings are represented by repeated pairs of identifiers and data (big endian).

IdentifierDataContent
0x00uint32Application ID
0x01uint32Frequency Channel Mask
0x02uint16Retry Count and Output
0x03uint8Logical Device ID
0x04uint8Role
0x05uint8Relay Layer
0x06uint8Communication Mode
0x07uint32Baud Rate
0x08uint8Parity
0x09uint8Encryption Function
0x0A[uint8]Encryption Key
0x0Cuint16Delimiter Character
0xFFuint8Error

0x00: Application ID

Specifies the application ID.

0x01: Frequency Channel Mask

Specifies the bit mask of frequency channels.

Set bits for channels to be used. For example, to use channel 11, specify 1<<11.

0x02: Retry Count and Output

Specifies the radio transmission output and the number of additional packet transmissions in transparent mode and header-attached transparent mode.

Only the lower 1 byte is used. The upper 4 bits represent the retry count (0-9), and the lower 4 bits represent the transmission output (0-3). For example, 8 retries / output 3 is 0x0083.

0x03: Logical Device ID

Specifies the logical device ID.

0x04: Role

Effective only for slave devices. Specify one of the following values. Normally, select a delivery method that does not use the network layer.

Delivery Methods Without Network Layer

  • 0: Normal designation (parent or child device)
  • 1-3: Relay slave devices (logical device IDs are 1-100 or 120). Numbers 1-3 indicate the maximum relay hop count. This method retransmits up to the maximum relay hops, which may cause duplicate packets depending on relay device placement and count.

Delivery Methods Using Network Layer

  • 11: Parent device
  • 12: Relay device
  • 13: Child device

0x05: Relay Layer

The relay layer number. Relay devices attempt to connect to relay devices or parent devices in upper (smaller value) relay layers. Effective only when Role is set to 12.

0x06: Communication Mode

  • 0: Transparent mode
  • 1: Format mode (ASCII)
  • 2: Format mode (Binary)
  • 3: Chat mode
  • 4: Header-attached transparent mode

0x07: Baud Rate

Specifies the UART baud rate.

0x08: Parity

Specifies the sum of settings in the following combination:

  • Bit
    • 0: 8Bit
    • 8: 7Bit
  • Parity
    • 0: None
    • 1: Odd
    • 2: Even
  • Stop
    • 0: STOP 1
    • 4: STOP 2

For example, 7-E-1 is specified as 8+2+0=10(0xA).

0x09: Encryption Function

Specifies whether encryption is enabled.

  • 0: Disabled
  • 1: AES128bit encryption enabled

0x0A: Encryption Key

Specifies a 16-byte encryption key.

Can store binary sequences that cannot be set in Interactive Mode. This may cause display issues in Interactive Mode.

0x0C: Delimiter Character

Specifies the delimiter character (0x00-0xFF).

Silent Mode

Configuration Method

Perform the following settings in Interactive Mode.

  • Add 80 to r: Role. For example, set to 80 for normal parent or child devices.
  • Set m: UART mode to format mode (A/B).

Operation Check

Check the content of the DB F1 response output immediately after startup.

Disabling Method

Send DB F8 request (ASCII format: :DBF8101D<CR><LF>).

Notes

  • Silent mode cannot be reconfigured.
  • Behavior is undefined if a command is sent while silent mode is enabled.

5.2.2.2 - Serial Communication App Format Mode (Binary)

Mode that adds headers to both transmitted and received outputs (binary format)
Format mode adds headers to both transmitted and received outputs. In binary format, data is represented as raw binary.
Example network configuration with format mode

Overview

When data formatted in a specific manner is input on the transmitting side, the receiving side outputs data formatted in the same manner.

Data represented in hexadecimal is output as raw binary.

Transmitting Side InputReceiving Side Output
Simple/Extended Format DataSimple/Extended Format Data
  • On TWELITE UART, format mode (ASCII) is enabled by connecting the SET pin to GND at startup.
  • On TWELITE / TWELITE DIP, format mode (binary) is enabled by connecting the EX1 pin to GND at startup.

There are two types of supported formats.

  • Simple format: uses Logical Device ID only; Extremely Simple! Compatible with UART transmission function of the standard app
  • Extended format: uses Logical Device ID plus options such as Serial ID and retry count

For example, 5 bytes of binary data 0x48 0x45 0x4C 0x4C 0x4F can be transmitted using the simple format as follows.

[Transmitting Side]

A5 5A 80 07 00 01 48 45 4C 4C 4F 43 04    <- Input
A5 5A 80 04 DB A1 80 01 FB 04  <- Output

[Receiving Side]

A5 5A 80 07 78 01 48 45 4C 4C 4F 3B 04  <- Output

Basic Format

When sending data expressed in basic or extended format, handle it as raw binary data.

HeaderLengthPayloadChecksumFooter
A5 5APayload LengthRepeated 00-FFXOR of PayloadEOT
  • All binary
  • Header is 2 bytes: A5 5A
  • Payload length is 2 bytes representing the byte count, OR’ed with 0x8000
  • Checksum is XOR of payload
  • Footer is EOT 0x04 (can be omitted on input)
  • Big-endian

For example, binary data 00 11 22 33 AA BB CC is expressed as follows.

A5 5A 80 07 00 11 22 33 AA BB CC DD 04

Although debugging is troublesome, it offers high efficiency for communication between microcontrollers.

Distinguishing Parent and Child Devices

Format mode distinguishes between parent and child devices.

Parent and child devices must match Application ID and Frequency Channel.

Source Identification

Format mode allows identification of the source from received data.

Simple format uses Logical Device ID, and extended format uses Logical Device ID plus extended address.

Simple Format

When using the simple format of format mode, follow the format below.

Transmitting Side Input

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+2
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command NumberAny value less than 0x80
2[uint8]Arbitrary DataByte sequence of length \(N\) (recommended \(N\leqq80\))
uint8ChecksumXOR
uint8FooterEOT (0x04)

Receiving Side Output

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+2
0uint8Source Logical Device IDParent 0x00, Child 0x01-0x64, Unset Child 0x78
1uint8Command NumberValue less than 0x80 specified by sender
2[uint8]Arbitrary DataByte sequence of length \(N\)
uint8ChecksumXOR
uint8FooterEOT (0x04)

Transmitting Side Output (Response Message)

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length4
0uint8Source Logical Device IDOnly 0xDB: indicates itself
1uint8Command NumberOnly 0xA1
2uint8Response IDContinuation number in the range 128-255 (0x80-0xFF)
3uint8ResultSuccess 1, Failure 0
uint8ChecksumXOR
uint8FooterEOT (0x04)

Example

Example of sending byte sequence 11 22 33 AA BB CC from parent to all children.

[Transmitting Side: Parent]

A5 5A 80 08 78 01 11 22 33 AA BB CC A4 04  <- Input
A5 5A 80 04 DB A1 80 01 FB 04  <- Output

The last byte 0xA4 is the checksum: XOR from 0x78 to 0xCC.

[Receiving Side: All Children]

A5 5A 80 08 00 01 11 22 33 AA BB CC DC 04  <- Output

The last byte 0xDC is the checksum: XOR from 0x00 to 0xCC.

Extended Format

When using the extended format of format mode, follow the format below.

Transmitting Side Input

When using Logical Device ID as destination

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+\(M\)+3
0uint8Destination Logical Device IDParent 0x00, Child 0x01-0x64, All Children 0x78
1uint8Command NumberOnly 0xA0
2uint8Response IDAny value
3[uint8]OptionsOption list of length \(N\) (Details below)
3+\(N\)[uint8]Arbitrary DataByte sequence of length \(M\) (recommended \(M\leqq80\))
uint8ChecksumXOR
uint8FooterEOT (0x04)

When using Extended Address as destination

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+\(M\)+7
0uint8Extended Address SpecifierOnly 0x80
1uint8Command NumberOnly 0xA0
2uint8Response IDAny value
3uint32Destination Extended AddressSerial ID with 0x8 added at the front
7[uint8]OptionsOption list of length \(N\) (Details below)
7+\(N\)[uint8]Arbitrary DataByte sequence of length \(M\) (recommended \(M\leqq80\))
uint8ChecksumXOR
uint8FooterEOT (0x04)

Details of Option List

In extended format, detailed settings can be specified by providing an option list.

The option list consists of repeated option IDs and arguments. It ends with 0xFF.

IDArgumentDefaultDescription
0x01NoneDisabledEnable MAC ACK
0x02uint80x00Enable Application Retransmission
0x03uint160x0000Minimum Initial Transmission Delay
0x04uint160x0000Maximum Initial Transmission Delay
0x05uint1610Application Retransmission Interval
0x06NoneDisabledAllow Parallel Requests
0x07NoneDisabledDisable Response Messages
0x08NoneDisabledSleep After Transmission
0x01: Enable MAC ACK

Enables MAC layer ACK (acknowledgment).

Not suitable for frequent data transmissions but can improve reliability.

0x02: Enable Application Retransmission

When using MAC ACK, specify 0x00-0x0F. Retransmits 0-16 times until successful.

When not using MAC ACK, specify 0x81-0x8F. Always retransmits 1-16 times.

Response messages are output after all retransmissions are complete.

0x03: Minimum Initial Transmission Delay

Specifies the minimum delay before the first transmission in milliseconds.

0x04: Maximum Initial Transmission Delay

Specifies the maximum delay before the first transmission in milliseconds.

0x05: Application Retransmission Interval

Specifies the interval between application retransmissions in milliseconds.

0x06: Allow Parallel Requests

Allows parallel requests.

When allowed, the next request can be accepted without blocking until the previous request completes.

For example, if three requests each with 0.5 seconds delay are input consecutively, normally they are processed sequentially at 0.5s, 1.0s, and 1.5s. With parallel requests allowed, they are processed in any order after 0.5s. Note that this cannot be used when packet segmentation is required.

0x07: Disable Response Messages

Disables response messages output when data is input on the transmitting side.

0x08: Sleep After Transmission

Immediately puts the device to sleep after transmission.

RX detects rising edge to wake from sleep. Input any 1 byte of data.

After waking, UART initialization completes and input is accepted.

Receiving Side Output

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(M\)+14
0uint8Source Logical Device IDParent 0x00, Child 0x01-0x64, Unset Child 0x78
1uint8Command NumberOnly 0xA0
2uint8Response IDValue specified by sender
3uint32Source Extended AddressSerial ID with 0x8 added at the front
7uint32Destination Extended Address0xFFFFFFFF when using Logical Device ID
11uint8LQIRadio signal quality at reception
12uint16Length of Following BytesByte count \(M\)
14[uint8]Arbitrary DataByte sequence of length \(M\)
uint8ChecksumXOR
uint8FooterEOT (0x04)

Transmitting Side Output (Response Message)

#DataDescriptionNotes
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length4
0uint8Source Logical Device IDOnly 0xDB: indicates itself
1uint8Command NumberOnly 0xA1
2uint8Response IDValue specified on input
3uint8ResultSuccess 1, Failure 0
uint8ChecksumXOR
uint8FooterEOT (0x04)

Examples

Example of sending byte sequence 11 22 33 AA BB CC from parent to child.

Example specifying Logical Device ID

Example of sending from parent to child with Logical Device ID 0x01.

  • Response ID is 0x01
  • No options

[Transmitting Side: Parent]

A5 5A 80 0A 01 A0 01 FF 11 22 33 AA BB CC 82 04  <- Input
A5 5A 80 04 DB A1 01 01 7A 04  <- Output

The last byte 0xC1 is checksum: XOR from 0x42 to 0xCC.

[Receiving Side: Child]

A5 5A 80 14 00 A0 01 82 03 68 41 FF FF FF FF FF 00 06 11 22 33 AA BB CC 2D 04  <- Output

The last byte 0x2D is checksum: XOR from 0x00 to 0xCC.

Example specifying Extended Address

Example of sending from parent to child with Extended Address 0x820163B2 (Serial ID 0x20163B2).

  • Response ID is 0x01
  • No options

[Transmitting Side: Parent]

A5 5A 80 0E 80 A0 01 82 01 63 B2 FF 11 22 33 AA BB CC 51 04  <- Input
A5 5A 80 04 DB A1 01 01 7A 04  <- Output

The last byte 0x51 is checksum: XOR from 0x80 to 0xCC.

[Receiving Side: Child]

A5 5A 80 14 00 A0 01 82 03 68 41 82 01 63 B2 FF 00 06 11 22 33 AA BB CC 7F 04  <- Output

The last byte 0x7F is checksum: XOR from 0x00 to 0xCC.

Example using MAC ACK

Example of sending from parent to child with Logical Device ID 0x01 using MAC ACK.

[Transmitting Side: Parent]

A5 5A 80 0B 01 A0 01 01 FF 11 22 33 AA BB CC 83 04  <- Input
A5 5A 80 04 DB A1 01 01 7A 04  <- Output

The last byte 0x83 is checksum: XOR from 0x01 to 0xCC.

[Receiving Side: Child]

A5 5A 80 14 00 A0 01 82 03 68 41 00 00 01 01 FF 00 06 11 22 33 AA BB CC 2D 04  <- Output

The last byte 0x2D is checksum: XOR from 0x00 to 0xCC.

Example with Delay

Example of sending from parent to child with Logical Device ID 0x01 with 768ms delay.

[Transmitting Side: Parent]

A5 5A 80 0D 01 A0 01 03 03 00 FF 11 22 33 AA BB CC 82 04  <- Input
A5 5A 80 04 DB A1 01 01 7A 04  <- Output

The last byte 0x82 is checksum: XOR from 0x01 to 0xCC.

[Receiving Side: Child]

A5 5A 80 14 00 A0 01 82 03 68 41 FF FF FF FF FF 00 06 11 22 33 AA BB CC 2D 04  <- Output

The last byte 0x2D is checksum: XOR from 0x00 to 0xCC.

0xDB Command

Instead of setting interactive mode, you can operate and configure the module by inputting the 0xDB command from UART.

5.2.2.2.1 - 0xDB Command in Serial Communication App Format Mode (Binary)

Setting functions using the 0xDB command in format mode (binary) without using Interactive Mode
In format mode, you can dynamically configure settings from devices connected via UART by using the 0xDB command instead of Interactive Mode.

Input Format

#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+2
0uint8Destination Logical Device IDOnly 0xDB indicating itself
1uint8Command NumberSelected from values below
2[uint8]ParameterByte sequence of length \(N\) indicating setting value (optional)
uint8ChecksumXOR
uint8FooterEOT (0x04)

Command Number List

Function
0xF0Enable ACK
0xF1Get Device Info
0xF2Apply Device Settings
0xF3Get Device Settings
0xF8Device Control
0xFDErase Device Settings
0xFESave Device Settings
0xFFReset Device

0xF0: Enable ACK

Requests ACK response.

No parameters.

Response Format

#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length3
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF0
2uint8DataOnly 0x01
uint8ChecksumXOR
uint8FooterEOT (0x04)

0xF1: Get Device Info

Displays information such as address. Also output at startup.

No parameters.

Response Format

#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length17
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF1
2uint32Default Application ID67720103
6uint32Version NumberFor 1.4.7, 00010407
10uint8Logical Device ID
11uint32Serial ID
15uint8Silent Mode StatusEnabled 1, Disabled 0
16uint8Network StatusUP 1, DOWN 0
uint8ChecksumXOR
uint8FooterEOT (0x04)

0xF2: Apply Device Settings

Applies settings.

Response Format

On Success
#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+2
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF3
2[uint8]Setting ContentRepeated identifier and data of length \(N\)
uint8ChecksumXOR
uint8FooterEOT (0x04)
On Failure
#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length3
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF3
2uint8ErrorOnly 0xFF
uint8ChecksumXOR
uint8FooterEOT (0x04)

0xF3: Get Device Settings

Retrieves settings.

Response Format

#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length\(N\)+2
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF3
2[uint8]Setting ContentRepeated identifier and data of length \(N\)
uint8ChecksumXOR
uint8FooterEOT (0x04)

0xF8: Device Control

If silent mode was enabled at startup, this disables it.

Response Format

#DataContentRemarks
uint8HeaderOnly 0xA5
uint8HeaderOnly 0x5A
uint16Data Length4
0uint8Destination Logical Device IDOnly 0xDB
1uint8Command NumberOnly 0xF8
2uint8DataOnly 0x11
3uint8StatusDisabled 1, Not Disabled 0
uint8ChecksumXOR
uint8FooterEOT (0x04)

0xFD: Erase Device Settings

Initializes settings and resets the device.

No parameters or response.

0xFE: Save Device Settings

Saves applied settings and resets the device.

No parameters or response.

0xFF: Reset Device

Discards applied settings and resets the device.

No parameters or response.

Parameter List (0xF2/0xF3)

Parameters for 0xF2: Apply Device Settings and 0xF3: Get Device Settings are represented as repeated identifier and data (big endian) pairs.

IdentifierDataContent
0x00uint32Application ID
0x01uint32Frequency Channel Mask
0x02uint16Retry Count and Output
0x03uint8Logical Device ID
0x04uint8Role
0x05uint8Relay Layer
0x06uint8Communication Mode
0x07uint32Baud Rate
0x08uint8Parity
0x09uint8Encryption Function
0x0A[uint8]Encryption Key
0x0Cuint16Delimiter Character
0xFFuint8Error

0x00: Application ID

Specifies the application ID.

0x01: Frequency Channel Mask

Specifies the bit mask of frequency channels.

Set bits for channels to use. For example, to use channel 11, set 1<<11.

0x02: Retry Count and Output

Specifies the radio transmission output and the number of additional packets to send in transparent mode and header-attached transparent mode.

Only the lower 1 byte is used. The upper 4 bits indicate retry count (0-9), and the lower 4 bits indicate transmission output (0-3). For example, 8 retries/output 3 is 0x0083.

0x03: Logical Device ID

Specifies the logical device ID.

0x04: Role

Valid only for child devices. Specify the following values. Usually, select a delivery method without using the network layer.

Delivery Methods Without Using Network Layer

  • 0: Normal designation (parent or child)
  • 1-3: Relay child devices (logical device IDs 1-100 or 120). Numbers 1-3 indicate maximum relay hops. This method repeats retries up to the maximum relay hops, which may cause duplicate packets depending on relay device placement and number.

Delivery Methods Using Network Layer

  • 11: Parent device
  • 12: Relay device
  • 13: Child device

0x05: Relay Layer

The relay layer number. Relay devices attempt to connect to relay devices or parent devices with higher layers (lower values). Effective only when Role is set to 12.

0x06: Communication Mode

  • 0: Transparent mode
  • 1: Format mode (binary)
  • 2: Format mode (binary)
  • 3: Chat mode
  • 4: Header-attached transparent mode

0x07: Baud Rate

Specifies UART baud rate.

0x08: Parity

Specifies the sum of settings in the following combination.

  • Bit
    • 0: 8Bit
    • 8: 7Bit
  • Parity
    • 0: None
    • 1: Odd
    • 2: Even
  • Stop
    • 0: STOP 1
    • 4: STOP 2

For example, 7-E-1 is 8+2+0=10(0xA).

0x09: Encryption Function

Specifies whether encryption is enabled.

  • 0: Disabled
  • 1: AES128bit encryption enabled

0x0A: Encryption Key

Specifies a 16-byte encryption key.

Allows storing binary sequences that cannot be set in Interactive Mode. In this case, the display in Interactive Mode may be disrupted.

0x0C: Delimiter Character

Specifies the delimiter character string (0x00-0xFF).

Silent Mode

Setting Method

Perform the following settings in Interactive Mode.

  • Add 80 to r: Role. For example, for normal parent or child, set 80.
  • Set m: UART mode to format mode (A/B).

Operation Check

Check the content of the DB F1 response output immediately after startup.

Disable Method

Issue a DB F8 request (binary format: A5 5A 80 03 DB F8 10 33 04).

Notes

  • Silent mode cannot be reset.
  • Behavior when sending commands while silent mode is enabled is undefined.

5.2.2.3 - Serial Communication App Chat Mode

Mode that displays prompts and performs echo back
Chat mode realizes text chat through prompt display and echo back.

By connecting MONOSTICK to a PC etc., chat can be performed among multiple terminals.

Overview

Enables text chat.

Sending Side InputReceiving Side Output
Any stringAny string + auxiliary information

Displays prompt and echoes back (outputs input characters). All terminals operate as child devices, performing broadcast communication.

For example, when sending the string Hello from one terminal to another, it behaves as follows.

[Sending Side]

810A4778:0> Hello  <- Input
810A4778:1>  <- Output

[Receiving Side]

[810A4778:0] Hello  <- Output
82018CA0:0>  <- Output

Chat mode displays prompt and echoes back (outputs input characters entered by itself).

All terminals are treated as child devices and broadcast their transmitted content. Communication is possible with all terminals but destination cannot be specified. Binary data cannot be sent. Only strings are supported (0x00-0x1F, 0x7F cannot be sent).

Relay supports up to 3 hops. Relay is disabled by default.

Distinction between Parent and Child Devices

Chat mode does not distinguish between parent and child devices.

If the Application ID and frequency channel are the same, data entered in any terminal is sent to other terminals.

Network configuration image

Network configuration image

Identification of Source

The auxiliary information in the received output can identify the sender.

If the Interactive Mode’s h: Header format is blank, the 7-digit serial ID with a leading 0x8 is used as the extended address. For example, the following output indicates the sender’s serial ID was 0x10A4778.

[810A4778:0] Hello

If h: Header format is set to an arbitrary string, it is used as the handle name. Handle name consumes data space in the wireless packet.

Sending Side Input Format

Enter message and newline after prompt.

DataContentRemarks
[char]Message0x00-0x1F, 0x7F not allowed
charCR (0x0D/'\r')Allowed alone
charLF (0x0A/'\n')Allowed alone
810A4778:0> Hello

Receiving Side Output Format

Outputs received message following auxiliary info.

Auxiliary information includes the module’s extended address or handle name and a sequence number.

DataContentRemarks
charAuxiliary info header[ only
[char]Identification info8-digit extended address or handle name
charAuxiliary info delimiter: only
[char]Sequence numberStarting from 0
charAuxiliary info footer] only
charSeparatorSpace only
[char]Message
charFooterCR (0x0D/'\r')
charFooterLF (0x0A/'\n')
[810A4778:0] Hello

Other Inputs

Terminals supporting escape sequences can use the following control commands.

  • Ctrl-L: Clear screen
  • Ctrl-C: Cancel input
  • BS/DEL: Move cursor back

5.2.2.4 - Serial Communication App Transparent Mode

Mode that purely wirelesss UART
Transparent mode realizes behavior similar to UART connected by wires without adding headers, echo back, or prompt display.
Image connecting external microcontrollers

External microcontrollers can be easily connected, but to optimize communication using formats, format modes (ASCII / Binary) are suitable.

Overview

Purely wirelesss UART.

Sending side inputReceiving side output
Any dataAny data

Since no format is required, existing UART communication can be easily wirelessized.

However, data delimiters are ambiguous and it is impossible to identify the sender from the receiver output.

The initial state specifies CRLF as the transmission trigger character. Therefore, data input to the transmitter is separated by CRLF, and the data before CRLF is transmitted.

For example, entering Hello<Enter> on the transmitting terminal results in Hello being output on the receiving terminal.

[Sending side]

Hello  <- Input

[Receiving side]

Hello  <- Output

Continuous input strings are split and sent in chunks of 80 bytes. Data up to the trigger character should normally be 80 bytes or less.

All terminals are considered child devices, and the transmitted content is broadcast. Communication with all terminals is possible, but the destination cannot be specified. Both ASCII characters and binary data can be sent.

Relay supports up to 3 hops. By default, relay is disabled.

Distinction between Parent and Child Devices

Transparent mode does not distinguish between parent and child devices.

If application ID and frequency channel are the same, data entered into any terminal is sent to other terminals.

Network configuration image

Network configuration image

Identification of Sender

Transparent mode cannot identify the sender.

To identify sender, sender information must be included in data input to the transmitter.

Transmission Trigger

Transmission trigger must be considered, as data is divided and transmitted wirelessly packet by packet.

Therefore, the following transmission triggers must be taken into account:

  • When a timeout after data input is reached
  • When the input data reaches the minimum data size
  • When the transmission trigger character is received

Transmission trigger settings can be specified from the interactive mode k: Transmission Trigger item.

Example Setting

When setting the transmission trigger character to LF, minimum data size to 8 bytes, and timeout to 30 ms, set as follows:

 m: set UART mode (D)
 k: set Tx Trigger (sep=0x0a, min_bytes=8 dly=30[ms])
 o: set option bits (0x00000100)

5.2.2.5 - Serial Communication App Header Transparent Mode

Mode that adds headers only to the received output
Header Transparent Mode adds auxiliary information only to the output on the receiving side.

Overview

Enabled by default.

When arbitrary data is input to the transmitting terminal, the receiving terminal outputs data with auxiliary information in a specific format.

Transmitting side inputReceiving side output
Any dataAny data + auxiliary info

By default, data input on the transmitting side is separated by CRLF and data before CRLF is sent.

For example, entering Hello<Enter> on the transmitting side results in output Hello with auxiliary info on the receiving side. The transmitting side also outputs a message indicating transmission completion.

[Transmitting side]

Hello  <- input
;U;00004;219;0x820163B2;000;000;0,1,Hel...;6E;  <- output

[Receiving side]

;U;00003;000;0x820163B2;255;000;Hello;42;  <- output

The auxiliary information output by the receiving side includes the source address, received signal strength, checksum, etc. The format of the auxiliary information can be customized.

Distinction between Parent and Child Devices

Header Transparent Mode does not distinguish between parent and child devices.

If the Application ID and frequency channel are the same, data input to any terminal is sent to other terminals.

Network configuration image

Network configuration image

Identification of Source

The header on the received data includes the logical device ID and serial ID of the sender.

Output Format on Receiving Side

The output format is represented as semicolon (;) separated fields.

[Example output in default state]

;U;00777;120;0x81025A17;120;013;HELLO;79;

This output can be interpreted as follows.

DataDescriptionValue
UcharFixed valueU
00777uint16Timestamp at output777 seconds
120uint8Source logical device ID120 ID-less child device
0x81025A17uint32Source extended address81025A17
120uint8LQI (link quality indicator)120/255
013uint8Source sequence number13
HELLO[uint8]Input dataHELLO
79uint8XOR checksum0x79

Customization by Header Format

The output format on the receiving side follows the header format.

Changing the header format customizes the content of the auxiliary information output and the checksum calculation range.

The header format can be changed via the interactive mode command h: set header format.

Simplest Format

The simplest header format is *\n. It outputs the received data with CRLF line endings.

 h: set header format [*\n]

When sending HELLO in this case, it behaves as follows.

[Receiving side]

HELLO<CR><LF> or HELLO<LF>

[Transmitting side]

HELLO<CR><LF>

Special Characters in Header Format

You can customize the output by including the following special characters in the header format.

General
Description
*Received data
&hlArbitrary ASCII character (e.g., &20 is space)
<Start position for checksum calculation (default is start of string)
>End position for checksum calculation (only from v1.4.6)
Characters following \ (backslash)
Description
\nCRLF (0x0D 0x0A)
\tTAB
\**
\%%
\<<
\>>
\&&
Characters following %
DescriptionLengthData format
%ASource address (32bit)8 charsHexadecimal
%aSource address (32bit)10 charsHexadecimal
%ISource logical address (8bit)2 charsHexadecimal
%iSource logical address (8bit)3 charsDecimal
%TCurrent system time (seconds)4 charsHexadecimal
%tCurrent system time (seconds)5 charsDecimal
%SSource sequence number (hex)2 charsHexadecimal
%sSource sequence number (hex)3 charsHexadecimal
%QReceived signal strength2 charsHexadecimal
%qReceived signal strength3 charsDecimal
%XChecksum2 charsHexadecimal
%xChecksum3 charsDecimal

Checksum Calculation

The checksum is calculated by XOR (exclusive OR) from the start of the data or from the position indicated by < in the header format up to just before %X or %x.

Example in Default State

The default header format is ;U;%t;%i;0x%A;%q;%s;<*;%X;\n, where the checksum calculation range is *;.

That is, when sending HELLO, the binary data HELLO; is targeted, resulting in checksum 0x79.

[Verification code in Python]

from functools import reduce

def main():
    data = "HELLO;"
    checksum = reduce(lambda x, y: x ^ y, data.encode("ascii"))
    print(f"{data} -> {hex(checksum)}")

if __name__ == "__main__":
   main()  # HELLO; -> 0x79

Other Examples

For example, consider the header format ;%I;*;%X.

Since < is not specified, the checksum calculation range is ;%I;*;.

That is, when sending HELLO, the binary data ;000;HELLO; is targeted, resulting in checksum 0x49.

[Verification code in Python]

from functools import reduce

def main():
    data = ";000;HELLO;"
    checksum = reduce(lambda x, y: x ^ y, data.encode("ascii"))
    print(f"{data} -> {hex(checksum)}")

if __name__ == "__main__":
   main()  # ;000;HELLO; -> 0x49

Transmission Trigger

There is no format on the transmitting side input, but data is split and transmitted packet by packet.

Therefore, the following transmission triggers must be considered.

  • When timeout after data input occurs
  • When input data reaches the minimum data size
  • When a transmission trigger character is received

Transmission trigger settings are specified via the interactive mode k: set transmission trigger item.

Example Setting

To set the transmission trigger character to LF, minimum data size to 8 bytes, and timeout to 30 ms, use the following settings.

 m: set UART mode (E)
 k: set Tx Trigger (sep=0x0a, min_bytes=8 dly=30[ms])
 o: set option bits (0x00000100)

5.2.3 - Custom Default Feature of Serial Communication App

Creating firmware with changed default settings
With the custom default feature, you can change the default parameters included in the firmware.

For example, if you create firmware that changes the baud rate from 115200bps to 9600bps, you can use it at 9600bps from the start.

Configuration Procedure

1. Apply Settings

Change the settings in Interactive Mode and press S to save.

2. Download Settings

Prepare software that can download data using the xmodem protocol.

While still in Interactive Mode (before selecting items), request xmodem download.

If the download succeeds, a 128-byte file is generated (may be smaller depending on xmodem implementation).

3. Creating Custom Binary

Concatenate the downloaded file to the end of the firmware binary file to create a custom binary.

Use command line tools or general file concatenation tools for concatenation.

Example

Example assuming downloaded xmodem file is conf.bin, original binary file is App_Uart_BLUE_L1305_V1-4-X.bin, and custom binary to create is App_Uart_custom_V1-4-X.bin.

【Windows】

copy App_Uart_BLUE_L1305_V1-4-X.bin App_Uart_custom_V1-4-X.bin
type conf.bin >> App_Uart_custom_V1-4-X.bin

【macOS / Linux】


cat App_Uart_BLUE_L1305_V1-4-X.bin conf.bin > App_Uart_custom_V1-4-X.bin

4. Writing Custom Binary

Write the concatenated custom binary to TWELITE.

5.2.4 - Notes on Communication in Serial Communication App

Precautions for stable communication
Precautions for achieving stable communication.

UART Data Input and Output

4KB buffers are allocated for UART input and output. When outputting two UART lines, 2KB is used for input and output buffers for each line.

In format mode and chat mode, it is rarely necessary to be aware of buffer sizes, but in header transparent mode and transparent mode when continuously inputting streams, or even in format mode when inputting many streams at once, it is necessary to be aware of the buffer size limits. On the output side, if a slow baud rate is set, the output of data received wirelessly may not keep up.

Data beyond the buffer limits is not protected at the boundary, causing data loss. Especially on the input side, consider referring to the flow control pins described below.

UART Flow Control

Input flow control is implemented to behave like the RTS pin. The pin used is PWM1 (DIO5), targeting the main UART port. When input is not accepted, the state is High; when input is accepted, the state is Low. Output flow control is not supported. Receiving devices should ensure sufficient baud rate and processing speed.

  • After power-on or reset, the pin is High. It becomes Low once UART is initialized.
  • When the UART input buffer exceeds 7/8 full, the pin goes High; it goes Low when below that threshold.
  • In transparent mode, the pin is High during packet transmission.

Countermeasures for Wireless Communication Errors

If data loss occurs on the receiving side, increase the number of wireless retransmissions.

Increasing the number of additional packets sent can improve the success rate of reception.

The number of retransmissions can be set in Interactive Mode (x: set RF Conf).

5.2.5 - Interactive Mode (Serial Communication App)

Configuration changes via Interactive Mode
You can perform detailed configuration of the app via Interactive Mode.

This section explains functions specific to the Serial Communication App (App_Uart). For common features, see the TWELITE APPS Manual top page.

Example Display

The following screen will be displayed.

--- CONFIG/TWE UART APP V1-04-5/SID=0x82018ca0/LID=0x78 -- ---
 a: set Application ID (0x67720103)
 i: set Device ID (120=0x78)
 c: set Channels (18)
 x: set RF Conf (3)
 r: set Role (0x0)
 l: set Layer (0x1)
 b: set UART baud (38400)
 B: set UART option (8N1)
 m: set UART mode (E)
 k: set Tx Trigger (sep=0x0d0a, min_bytes=0 dly=0[ms])
 h: set header format [;U;%t;%i;0x%A;%q;%s;<*>;%X;\n]
 C: set crypt mode (0)
 o: set option bits (0x00000100)
---
 S: save Configuration
 R: reset to Defaults

Commands

Setting ItemDefaultRemarks
aApplication ID0x6772010332bit
iLogical Device ID120Parent device 0/121, child device 1-100, ID-less child device 120
cFrequency Channel1811-26
xRetry count and transmission output3
Retry count01-9 times, 0 disables
Transmission output30-3
rRole0Normal 0, relay child 1-3, others
lRelay Layer0x01
bUART alternative baud rate38400Enabled with BPS pin
BUART option8N1
mCommunication modeEA/B/C/D/E
kTransmission trigger0x0d0a,0,0Trigger character, minimum size, timeout
hHeader / Handle nameReference
HeaderFor header transparent mode
Handle nameFor chat mode
CEncryption0Disabled 0, AES128bit 1
oOption bits0x00000000Other detailed settings

Details of each command are as follows.

a: Application ID

All devices communicating must use the same value. This logically separates networks.

i: Logical Device ID

Set this to distinguish multiple child devices.

If no distinction is necessary or possible, set to 120. If distinction is necessary, child devices should use any value from 1 to 100, and parent devices should be 0 or 121.

c: Frequency Channel

All devices communicating must use the same value. This physically separates networks.

x: Transmission output and retry count

Specify the RF transmission output power and the number of additional packet transmissions in transparent mode and header transparent mode.

r: Role

Valid only for child devices. Specify the following values. Normally select the delivery method that does not use the network layer.

Delivery method not using network layer

  • 0: Normal designation (parent or child)
  • 1-3: Relay child (logical device ID is 1-100 or 120). The number 1-3 indicates the maximum number of relay hops. Since retransmission is repeated up to the maximum relay hops, duplicate packets may be relayed depending on the placement and number of relay devices.

Delivery methods using network layer

Supported only in format mode.

  • 11: Parent
  • 12: Relay
  • 13: Child

l: Relay Layer

The relay layer number. Relay devices attempt to connect to relay devices or parents in upper relay layers (smaller values). Effective only when Role is set to 12.

m: Communication mode

  • A: Format mode (ASCII)
  • B: Format mode (Binary)
  • C: Chat mode
  • D: Transparent mode
  • E: Header transparent mode

b: UART alternative baud rate

Overrides the alternative baud rate selected when the BPS pin is connected to GND at startup.

Selectable values are 9600/19200/38400/57600/115200/230400. Other values may cause inaccuracies.

B: UART option

Specify three characters in the order Bit-Parity-Stop.

  • Bit
    • 8: 8 Bit
    • 7: 7 Bit
  • Parity
    • N: None
    • O: Odd
    • E: Even
  • Stop
    • 1: STOP 1
    • 2: STOP 2

k: Transmission trigger

Set the transmission trigger applied to input in transparent mode and header transparent mode.

Enter separated by commas , in the following order:

  1. Transmission trigger character
  2. Minimum data size
  3. Timeout

Transmission trigger character

Packets are sent when this character is input (except when the minimum data size is not met).

In Interactive Mode, specify the ASCII code in hexadecimal. The leading 0x is ignored. Default is CRLF.

The transmitted data includes the transmission trigger character. To enable the transmission trigger character, specify option bit 0x00000100 (enabled by default).

Minimum data size

Specify the minimum size of continuous data to be handled. Even if the trigger character is included before reaching the minimum data size, it is invalid.

In Interactive Mode, specify a number between 1 and 80 as byte count. 0 disables. Default is disabled.

Timeout

The wait time until the packet is sent after the last input.

In Interactive Mode, specify a number between 10 and 200 milliseconds. 0 disables. Default is disabled.

h: Header / Handle name

For header transparent mode, specify the header format; for chat mode, specify the handle name.

Header (header transparent mode)

Specify the header format syntax.

Handle name (chat mode)

Specify the handle name displayed on the counterpart device.

Maximum 23 characters. Consumes the data area (80 bytes) for transmission.

C: Encryption

Specify whether to enable encryption.

Specify 1 to enable AES128bit encryption.

o: Option bits

Specify a 32-bit value. Various settings linked to each bit can be enabled.

Target bitSetting itemDefaultABCDE
0x00000001Disable internal pull-up of M30️⃣
0x00000002Unused0️⃣
0x00000100Enable transmission trigger1️⃣
0x00000200Prioritize new input series0️⃣
0x00001000Disable response message0️⃣
0x00004000Loosen duplicate checker0️⃣
0x00010000Force apply alternative baud rate0️⃣
0x00020000Simultaneous output to secondary port0️⃣
0x00040000Switch main port0️⃣
0x00100000Limit relay layer0️⃣

Details of Option Bits

Explanation of settings linked to each bit of the option bit value.

00000001: Disable internal pull-up of M3

Disables the internal pull-up of the M3 pin used for sleep setting on TWELITE DIP.

00000100: Enable transmission trigger

Enables the transmission trigger setting in transparent mode or header transparent mode.

00000200: Prioritize new input series

In format modes (ASCII/Binary), transparent mode, and header transparent mode, prioritize new input series if multiple series are input before transmission completes.

00001000: Disable response message

In format modes (ASCII/Binary) and header transparent mode, disables response messages after transmission completes.

00004000: Loosen duplicate checker

Loosens the duplicate checker conditions on the receiving side.

00010000: Force apply alternative baud rate

Applies the alternative baud rate setting even if the BPS pin input is not Low at startup.

00020000: Simultaneous output to secondary port

Outputs the serial output TX also to the serial secondary output TX_SUB.

00040000: Switch main port

Swaps the serial input/output TX/RX with the serial secondary input/output TX_SUB/RX_SUB.

00100000: Limit relay layer

In format modes (ASCII/Binary), when specifying delivery methods using network layer, always send to relay devices or parent devices one layer above. Normally, delivery methods using network layer send to the relay or parent device with the best radio quality in the upper layer.

About Relay Function

When communication distance is insufficient or there are obstacles preventing communication, using relay devices is useful.

Devices with relay function retransmit packets they receive to other devices.

Relay Function Settings

Normally, change the Role value to 1-3 while in Interactive Mode. The default value is 0, which does not have relay function.

r: set Role (0x0)

The number 1-3 indicates the maximum number of relay hops. For example, specifying 3 allows up to 3 relay hops.

Distinction between parent and child devices applies only to child devices.

Setting Example

The following network configuration shows devices with red color set to Role 0 and devices with blue color set to Role 3.

Example of relay by role setting

Example of relay by role setting

Adding red devices allows communication with up to 3 relay hops between red devices.

Example of adding transmitters and receivers

Example of adding transmitters and receivers

6 - Cue App Manual

Wireless notification of object movement.
The Cue App (App_CUE) is an app dedicated to the magnetic and acceleration sensor tag TWELITE CUE.

6.1 - Cue App Manual

Latest Edition

Features

By attaching to objects, it can wirelessly transmit movement and status.

  • Collect data from multiple wireless tags on the parent device
  • Control multiple wireless tags with the parent device
  • Operate multiple systems individually on 16 channels
  • Mix multiple systems on the same channel by setting different application IDs per group
  • Encryption and encryption key settings

6.1.1 - Cue App Operating Modes

Operating modes of the Cue app

6.1.1.1 - Cue App TWELITE CUE Mode

All-in-one mode for impact detection, door open/close, and acceleration measurement

This is an all-in-one mode that supports acceleration measurement, impact detection, posture detection, and magnet detection.

This mode is set as the factory default.

Settings

If you use this mode, please set the following items.

Setting CommandSetting ItemSetting ValueRemarks
pSensor-specific parameter setting00000000

Parent Device Output

Typical Battery Life

  • About 80 days if only periodic transmission every 5 seconds
  • About 80 days if periodic transmission every 5 seconds plus TWELITE CUE moved once per minute
  • About 700 days if only periodic transmission every 1 minute
  • About 565 days if periodic transmission every 1 minute plus TWELITE CUE moved once per minute

6.1.1.2 - Cue App Motion Sensor Pal Mode

Mode operating as a motion sensor pal

This mode provides equivalent functionality to the motion sensor pal.

Use this mode when measuring acceleration continuously or detecting impacts.

This mode is divided into three sub-modes:

  • Acceleration measurement mode
  • Event detection mode
  • Dice mode

Acceleration Measurement Mode

This mode intermittently or continuously measures acceleration and transmits the data.

Settings

Setting CommandSetting ItemSetting ValueRemarks
tTransmission interval0 or 1–4095Unit: seconds.
0: Continuous transmission
1+: Intermittent transmission
pSensor-specific parameterx3000yyyx: TWELITE 2525A mode flag
yyy: Accelerometer properties

TWELITE 2525A Mode Flag

Setting the TWELITE 2525A mode flag to 1 (sensor-specific parameter: 13000000) makes it operate as TWELITE 2525A FIFO (normal) mode. Use this mode if you want to substitute TWELITE 2525A.

Accelerometer Properties

You can change the number of samples and sampling frequency during intermittent transmission with accelerometer properties.

These settings can be combined by adding values.

Setting Value (Hex)Description
0x?3????00–0x?3????FFNumber of samples to send during intermittent transmission, set in 16-sample units.
Sample count = 16 + 16 x value.
Examples:
0x00000000: 16 samples (default)
0x00000001: 32 samples

0x00000007: 128 samples

0x000000FF: 4096 samples
0x?3???0??–0x?3???F??Sampling frequency of acceleration:
0x00000000: 25Hz (default)
0x00000100: 50Hz
0x00000200: 100Hz
0x00000300: 190Hz
0x00000400–0x00000F00: Undefined

Parent Device Output

Move Mode

Detects movements like Move and Shake.

You can control the notification pal’s LED.

Settings

Setting CommandSetting ItemSetting ValueRemarks
pSensor-specific parameter01100000

Parent Device Output

Usage Notes

This mode detects movement and sends data accordingly. Therefore, if moved slowly, it may not detect movement and output may not change. In that case, move it a little more vigorously.

Also, setting sensor-specific parameter (p) to 01000000 makes motion detection more sensitive. If transmissions occur at unintended times, set this parameter to 01000000.

Dice Mode

Detects the face of TWELITE CUE facing upward.

Controls the notification pal’s LED similar to event detection mode.

Settings

Setting CommandSetting ItemSetting ValueRemarks
pSensor-specific parameter02100000

Parent Device Output

Usage Notes

This mode detects movement and determines the face orientation. Therefore, if moved slowly, the face may not be detected and output may not change. In that case, place it on a desk or give it a light tap.

Also, setting sensor-specific parameter (p) to 02000000 makes motion detection more sensitive. If transmissions occur at unintended times, set this parameter to 02000000.

Typical Battery Life

  • About 3.5 years if transmitting once every minute in intermittent transmission acceleration measurement mode
  • About 20 days if transmitting continuously at 25 Hz sampling frequency in acceleration measurement mode
  • About 3 years if moving once every minute in event detection or dice mode

6.1.1.3 - Cue App Open/Close Sensor Pal Mode

Mode operating as an open/close sensor pal

This mode attaches to objects and detects open/close by the presence or absence of a magnet. Use this mode to measure door opening/closing or factory equipment operation status.

Settings

When using this mode, set the following items.

Setting CommandSetting ItemSetting ValueRemarks
pSensor-specific parameter setting04000000

Parent Device Output

Typical Battery Life

Approximately 4 years if 200 open/close operations per day (including 1-minute periodic transmissions). Approximately 4.5 years if 0 open/close operations per day (including 1-minute periodic transmissions).

6.1.2 - Cue App Settings

How to configure the Cue App
There are two ways to configure the TWELITE CUE: wired and wireless.

6.1.2.1 - Cue App Settings via OTA

How to configure via wireless communication

OTA settings allow you to configure the interactive mode settings wirelessly.

Steps for OTA Configuration

Perform OTA configuration using the following steps.

1. Launch the TWELITE STAGE APP

Install the TWELITE STAGE SDK on your PC, then launch TWELITE_Stage in the MWSTAGE folder.

2. Write the OTA configuration app to the MONOSTICK

Open 2: Rewrite App > 1: Select from BIN, and select App_CUE_OTA_....

3. Enter configuration values in interactive mode

Select 3: Interactive Mode, then edit and save the values.

4. Execute the OTA configuration

Place the TWELITE CUE within about 20cm of the MONOSTICK. Turn on the main unit’s power or bring a magnet close to the magnetic sensor more than 5 times to confirm that the TWELITE CUE’s LED is blinking.

5. Confirm the output from the MONOSTICK

Check for the following output messages. If no output is displayed, see here.

Example output when OTA is successful

6. Rewrite the app back to the MONOSTICK

Open 2: Rewrite App > 1: Select from BIN, and select App_Wings_MONOSTICK_....

OTA Failure Cases

Distance is too far

The following message indicates that the distance is too far.

OTA FAILURE
  OTA request TS=20515[ms]
  LQI:63 (RF strength, >= 100)
  SID:810BA765
  TWELITE CUE:v1.1.1
  Protocol Version:0x11

--— LQI is small. Please make TWELITE CUE closer. —--

In this case, bring the MONOSTICK and TWELITE CUE closer together.

Wrong target

The following message indicates that the TWELITE CUE firmware is different or that the wrong TWELITE CUE is being approached.

OTA FAILURE
  OTA request TS=20515[ms]
  LQI:180 (RF strength, >= 100)
  SID:810BA765
  TWELITE CUE:v1.1.1
  Protocol Version:0x13

--— Different protocol version. Please update TWELITE CUE. —--

In this case, check that you are not approaching the wrong TWELITE CUE. Also, if you have rewritten the TWELITE CUE firmware, please use TWELITE R2/R3 to rewrite it back to App_CUE.

6.1.2.2 - Cue App Settings via TWELITE R2/R3

How to configure using TWELITE R2/R3

Settings can be made by connecting TWELITE R2/R3 to the 7P interface of TWELITE CUE.

Example connection with TWELITE R2

Example connection with TWELITE R2

When using TWELITE R2/R3 for configuration, please follow the steps below.

1. Launch the TWELITE STAGE APP

Install the TWELITE STAGE SDK on your PC and launch TWELITE_Stage in the MWSTAGE folder.

2. Enter setting values in Interactive Mode

Select 3: Interactive Mode, then edit and save values.

6.1.2.3 - Interactive Mode (Cue App)

Detailed configuration changes via Interactive Mode

This app allows detailed configuration from Interactive Mode.

This page explains functions specific to the Cue App (App_CUE). For common functions, see the TWELITE APPS Manual top page.

When entering Interactive Mode, the following screen is displayed.

--- CONFIG/App_CUE V1-00-2/SID=0x810ba765/LID=0x01 ---
 a: set Application ID (0x67720102)
 i: set Device ID (--)
 c: set Channels (18)
 x: set Tx Power (13)
 b: set UART baud (38400)
 B: set UART option (8N1)
 k: set Enc Key (0xA5A5A5A5)
 o: set Option Bits (0x00000001)
 t: set Transmission Interval (5)
 p: set Senser Parameter (0x00000000)
---
 S: save Configuration
 R: reset to Defaults

List of Setting Commands

CommandSetting ItemDefaultExplanation
aApplication ID0x67720102Multiple groups can use the same frequency channel. The value is set as a 32-bit number.
iLogical Device IDSets the logical device ID of the child device. Values from 1 to 100 can be set.
If the setting is “–”, the logical device ID is internally set to 1.
cFrequency Channel Setting18Selects the channel (11–26). Multiple channel specifications are invalid to prioritize low power operation.
xTransmission Power Setting13Specify a one- or two-digit number. The second digit is optional. The first digit sets the transmission power. 3 is the strongest, and each step down to 2, 1, 0 reduces output by -11.5 dB. Use this to limit output and reduce the effective radio range. However, transmission distance is affected by environment (noise, obstacles, etc.).
※ Theoretically, transmission distance halves for every 6 dB reduction in output, so one step reduction reduces distance to about 1/4. The second digit sets the number of retransmissions. Specify 0–9 for the second digit; 0 means no retransmission (default), 1–9 correspond to the number of retransmissions.

Example:
3 -> No retransmission, strongest output (default, omitted)
42 -> 4 retransmissions, output level 2 (one step weaker)
bUART Baud Rate Setting38400Fixed at 115200 bps regardless of input value.
BUART Parity Setting8N1Fixed at 8N1 regardless of input value.
kEncryption Key Setting0xA5A5A5A5Enter the encryption key. Set a 32-bit hexadecimal number. Use the same value within the communication group.
oOption Bits Setting0x00000001Various detailed settings can be configured.
tTransmission Interval Setting5Sets the interval for periodic transmission packets in seconds. Valid values are 1 to 4095. Behavior outside this range is undefined.
pSensor-Specific Parameter Setting0Switch modes and set parameters. Specify as a hexadecimal number greater than or equal to 0. See the page Various Modes for details.
SSave SettingsSaves settings and restarts the module.
RReset to DefaultsResets settings to default. If you save immediately after without other operations using the S key, the save area is cleared.

Option Bits Setting

Explanation of each bit in the option bit setting value.

Bit (Hex)Explanation
0x00000001Transmits to each repeater or parent device, and all information received by the repeaters is forwarded to the parent device and output via serial.
In this case, analyzing multiple received packets allows identifying the router that received the signal closest.
0x00000040Disables OTA.
0x00001000Enables encrypted communication. (Please also set encryption on the counterpart.)
0x00010000Enables message output over UART communication.

7 - Aria App Manual

Wireless notification of temperature and humidity.
Aria App (App_ARIA) is an app dedicated to the magnetic, humidity, and temperature sensor tag TWELITE ARIA.

7.1 - Aria App Manual

Latest Edition

7.1.1 - How to Use the Aria App

How to use the Aria App
This section explains how to use the Aria app in two steps.

7.1.1.1 - Checking Operation of Aria App

Using MONOSTICK and PC to check operation of TWELITE ARIA
Let’s measure temperature using TWELITE CUE and MONOSTICK.

Required Items

  1. TWELITE CUE
  2. MONOSTICK

Insert the Battery

Insert the CR2032 battery with the + side aligned with the + side of the battery holder. If the LED on the TWELITE CUE blinks 3 times, it is normal.
After startup, it transmits every 5 seconds, and the LED blinks once during transmission.

Diagram explaining how to install the battery

Battery Installation

Also, because the battery holder of TWELITE ARIA is structurally prone to solder joint detachment, please be careful when inserting the battery as follows:

  • When removing the coin battery, it is recommended to lightly press the battery holder from above with your finger to reduce force on the solder joints while removing the coin battery.
  • When using TWELITE ARIA, it is recommended to use it with a dedicated case that presses the battery holder from above.

Attach Fixing Magnet

By attaching a magnet to the recess at the position shown in the figure, you can stick TWELITE ARIA to a metal surface. Use as needed.

Location for magnet installation

Magnet Installation Location

Insert into Case

Hook the board on the claws on the edge of the case as indicated by the circle marks.

Diagram explaining how to insert the board

Inserting the Board

Open the Case

Insert a coin into the notch on the case and pry it open.

Diagram explaining where to insert the coin

Where to Insert the Coin

Prepare Parent and Repeater

A parent device is required as a communication partner. If you want to extend communication distance, a repeater can be used. You can use MONOSTICK - MonoStick as the parent and repeater devices.

Please write the app version v1-01-4 or later of the Parent/Repeater App Wings to MONOSTICK - MonoStick.

Check Operation

Try moving the TWELITE ARIA or bringing a magnet close, and check the data received by the MONOSTICK connected to the PC.

Prepare TWELITE STAGE SDK

First, install the latest version of TWELITE STAGE SDK on your PC.

Launch TWELITE STAGE APP

  1. Connect MONOSTICK to the USB port of your PC.
  2. Double-click the following files inside the MWSTAGE folder of the installed TWELITE STAGE SDK.
    ・TWELITE_stage.exe (Windows)
    ・TWELITE_stage.command (macOS)
    ・TWELITE_stage.run (Linux)
    When launched, the MONOSTICK connected via USB will be displayed on the screen.
  3. Select 1: MONOSTICK from the serial port selection screen.
  4. When the device is selected, the top menu screen of TWELITE STAGE APP will be displayed.

Prepare Parent Device

A parent device is required as a communication partner. You can use MONOSTICK - MonoStick as the parent device.
Please write the Parent/Repeater App Wings to MONOSTICK - MonoStick following the steps below.

  1. From the top menu, select 2: Rewrite App > 1: Select from BIN.\
  2. If you are using MONOSTICK BLUE, select App_Wings_MONOSTICK_BLUE_…, and if you are using MONOSTICK RED, select App_Wings_MONOSTICK_RED_…
  3. After writing is complete, do not enter interactive mode; press and hold the ESC key to return to the top menu.

Select Viewer

  1. From the top menu, select 1: Viewer > 4: CUE/ARIA Viewer.
  2. Click the TWELITE ARIA tab.
Screen of TWELITE ARIA Viewer

TWELITE ARIA Viewer

Check Operation of TWELITE ARIA

Measure Temperature and Humidity

Temperature and humidity values are updated every 5 seconds.

Detect Magnet

  • When the N pole of a magnet is brought close to the magnetic sensor, “[N pole]” is displayed.
  • When the S pole of a magnet is brought close to the magnetic sensor, “[S pole]” is displayed.
  • When the magnet is moved away from the magnetic sensor, “ —- ” is displayed.

Change Mode

You can change the behavior of TWELITE ARIA by changing the mode.

Please refer to the following page for details.

Mode Selection

Change Settings

You can set grouping and transmission frequency changes in interactive mode.

Please refer to the following page for how to enter interactive mode.

Settings

Also, please refer to the following page for the items that can be set.

Interactive Mode

Output Log

You can output data such as temperature and humidity in CSV format to a log using pulse scripts.

Please refer to the following page for details.

Pulse Script

Draw Graph

You can view temperature, humidity, and magnetic sensor values as graphs using the PalViewer.

Please refer to the following page for details.

PalViewer

7.1.1.2 - Aria App Operating Modes

Operating modes of the Aria app
The Aria app has two operating modes: TWELITE ARIA mode and Open/Close Sensor Pal mode.

TWELITE ARIA mode

Initial mode of TWELITE ARIA.

An all-in-one mode that can measure temperature and humidity and detect door opening and closing simultaneously.

Open/Close Sensor Pal mode

Mode that operates as an open/close sensor pal.

Use this mode to measure door opening/closing or factory equipment operation status.

7.1.1.2.1 - Aria App TWELITE ARIA Mode

Initial mode
This is an all-in-one mode that allows you to try measuring temperature and humidity and detect the presence or absence of a magnet.

This mode is set as the factory default.

Settings

If you use this mode, please set the following items.

Setting CommandSetting ItemSetting ValueRemarks
pSensor-specific parameter setting00000000

Parent Device Output

Typical Battery Life

  • About 340 days if only periodic transmission every 5 seconds
  • About 300 days if periodic transmission every 5 seconds plus magnet approached every 1 minute
  • About 4 years if only periodic transmission every 1 minute
  • About 2.5 years if periodic transmission every 1 minute plus magnet approached every 1 minute

7.1.1.2.2 - Aria App Open/Close Sensor Pal Mode

Mode operating as an open/close sensor pal
This mode attaches to objects and detects open/close by the presence or absence of a magnet.

Settings

When using this mode, set the following items.

Setting CommandSetting ItemSetting ValueRemarks
pSensor-specific parameter setting04000000
Please refer to Settings for configuration instructions.

Parent Device Output

Typical Battery Life

Approximately 4 years if 200 open/close operations per day (including 1-minute periodic transmissions).
Approximately 4.5 years if 0 open/close operations per day (including 1-minute periodic transmissions).

7.1.2 - Aria App Settings

Aria App Settings

There are two ways to configure the Aria app.

For details on configurable items, please check Interactive Mode.

Configuration via OTA

OTA stands for Over the Air, meaning wireless communication. OTA configuration is a feature to configure settings without cable connection using Interactive Mode.

Executing OTA requires MONOSTICK.

Configuration using TWELITE R2

It is also possible to connect TWELITE R2/R3 to the 7P interface of TWELITE CUE and configure settings via Interactive Mode.

7.1.2.1 - OTA Settings for Aria App

Settings of TWELITE ARIA and MONOSTICK via wireless communication.

OTA settings is a function to perform interactive mode settings via wireless communication.

Procedure for OTA Settings

Perform OTA settings following the steps below.

1. Launch the TWELITE STAGE APP

Install the TWELITE STAGE SDK on your PC, then launch TWELITE_Stage in the MWSTAGE folder.

2. Write the OTA setting app to MONOSTICK

Open 2: Rewrite App > 1: Select from BIN and select App_ARIA_OTA_....

3. Enter setting values in interactive mode

Select 3: Interactive Mode, then edit and save the values.

4. Execute OTA setting

Place the TWELITE ARIA within about 20 cm from MONOSTICK. Turn on the power of the device or bring a magnet close to the magnetic sensor more than 5 times, and confirm that the LED of TWELITE ARIA blinks.

5. Check the output of MONOSTICK

Confirm the output of messages like the following. If no output is shown, see here.

Example output when OTA succeeds

6. Write back the app to MONOSTICK

Open 2: Rewrite App > 1: Select from BIN and select App_Wings_MONOSTICK_....

If OTA Fails

Distance is too far

Messages like the following indicate that the distance is too far.

OTA FAILURE
  OTA request TS=20515[ms]
  LQI:63 (RF strength, >= 100)
  SID:810BA765
  TWELITE ARIA:v1.1.1
  Protocol Version:0x13

--— LQI is small. Please make TWELITE ARIA closer. —--

In this case, bring MONOSTICK and TWELITE ARIA closer.

Different target

Messages like the following indicate that the firmware of TWELITE ARIA is different or that TWELITE CUE was mistakenly brought close.

OTA FAILURE
  OTA request TS=20515[ms]
  LQI:180 (RF strength, >= 100)
  SID:810BA765
  TWELITE ARIA:v1.1.1
  Protocol Version:0x11

--— Different protocol version. Please update TWELITE ARIA. —--

In this case, check if you mistakenly brought TWELITE CUE close. Also, if you rewrote the firmware of TWELITE ARIA, please use TWELITE R2/R3 to write back to App_ARIA.

7.1.2.2 - Settings for Aria App using TWELITE R2/R3

Settings performed by connecting TWELITE ARIA and TWELITE R2/R3 via wired connection.

Settings can be made by connecting TWELITE R2/R3 to the 7P interface of TWELITE ARIA.

Example connection with TWELITE R2

Example connection with TWELITE R2

When using TWELITE R2/R3 to configure, please follow the steps below.

1. Launch the TWELITE STAGE APP

Install the TWELITE STAGE SDK on your PC and launch TWELITE_Stage in the MWSTAGE folder.

2. Enter setting values in Interactive Mode

Select 3: Interactive Mode, then edit and save values.

7.1.3 - Interactive Mode (ARIA App)

Interactive mode of the ARIA app
You can perform detailed settings of the app in interactive mode.

This section explains features specific to the ARIA app (App_ARIA). For common features, please refer to the TWELITE APPS Manual Top Page.

Example Display

The screen will display as follows:

 --- CONFIG/App_ARIA V1-01-0/SID=0x810a7817/LID=0x01 ---
 a: set Application ID (0x67720102)
 i: set Device ID (--)
 c: set Channels (18)
 x: set Tx Power (13)
 b: set UART baud (38400)
 B: set UART option (8N1)
 k: set Enc Key (0xA5A5A5A5)
 o: set Option Bits (0x00000001)
 t: set Transmission Interval (5)
 p: set Senser Parameter (0x00000000)
 d: set Temperature Coefficient (0)
 D: set Temperature Offset (0)
 f: set Humidity Coefficient (0)
 F: set Humidity Offset (0)
---
 S: save Configuration
 R: reset to Defaults

Commands

Setting ItemDefault ValueRemarks
aApplication ID0x6772010232bit
iLogical Device ID-Child device 1-100
cFrequency Channel1811-26
xRetransmission Count and Transmission Power13
Retransmission Count11-9 times, 0 means none
Transmission Power30-3
bUART Alternative Baud Rate38400Not applicable
BUART Option8N1Not applicable
kEncryption Key0xA5A5A5A532bit
oOption Bits0x00000001Other detailed settings
tTransmission Interval51-4095 seconds
pSensor Specific Parameter0
dTemperature Coefficient00-60000
DTemperature Offset0-2000-2000
fHumidity Coefficient00-60000
FHumidity Offset0-2000-2000

Details of each command are shown below.

a: Application ID

All devices communicating must have the same value. This logically separates the network.

i: Logical Device ID

Set this when it is necessary to identify multiple child devices.

You can set any value from 1 to 100.

c: Frequency Channel

All devices communicating must have the same value. This physically separates the network.

x: Transmission Power and Retransmission Count

Specify the radio transmission power and the number of times to retransmit packets additionally in transparent mode and header-attached transparent mode.

b: UART Alternative Baud Rate

Not applicable. Unlike products such as TWELITE DIP, there is no BPS pin.

B: UART Option

Not applicable. Unlike products such as TWELITE DIP, there is no BPS pin.

k: Encryption Key

Specify the encryption key as a 32bit hexadecimal number when enabling encryption communication with the option bit Enable Encryption Communication.

o: Option Bits

Specify a 32bit number. You can enable settings associated with each bit.

Target BitSetting ItemDefault
0x00000001Enable Transmission to Relay Devices1️⃣
0x00000040Disable OTA Setting Function0️⃣
0x00001000Enable Encryption Communication0️⃣
0x00010000Enable UART Output on Child Device0️⃣

t: Transmission Interval

Specify the data transmission interval.

p: Sensor Specific Parameter

Used to switch the Operating Mode.

pMode
0x00000000TWELITE ARIA Mode
0x04000000Open/Close Sensor PAL Mode

d: Temperature Coefficient

Specify the coefficient \(d\) of temperature data in the range 0-60000.

If 0, it is disabled. Otherwise, the final temperature is multiplied by \(\frac{d}{1024}\).

D: Temperature Offset

Specify the temperature data offset \(D\) in the range -2000 to 2000.

Add \(D\) to the temperature multiplied by 100. The final temperature changes by \(\frac{D}{100}\) °C.

f: Humidity Coefficient

Specify the coefficient \(f\) of humidity data in the range 0-60000.

If 0, it is disabled. Otherwise, the final humidity is multiplied by \(\frac{f}{1024}\).

F: Humidity Offset

Specify the humidity data offset \(F\) in the range -2000 to 2000.

Add \(F\) to the humidity multiplied by 100. The final humidity changes by \(\frac{F}{100}\) %.

Details of Option Bits

Explanation of settings associated with each bit of the option bit value.

00000001: Enable Transmission to Relay Devices

Enable transmission not only to the parent device but also to relay devices.

You can use relay devices even if this option is not set, but the parent device will eliminate duplicate packets received. At this time, there is no way to know through which relay device the packet was transmitted or if it was not relayed.

If this option is set, the parent device can output a single packet received from multiple devices separately. By analyzing the output connected to the parent device, you can determine near which device the child device was located.

00000040: Disable OTA Setting Function

Disables the OTA setting function.

00001000: Enable Encryption Communication

Enables encrypted communication. The other party must also enable encrypted communication.

00010000: Enable UART Output on Child Device

Enables message output on the child device.

8 - Pal App Manual

For the TWELITE PAL Series

Pal App (App_PAL) is an application dedicated to the wireless tag system TWELITE PAL Series.

It is installed on TWELITE BLUE / RED PAL at factory shipment.

8.1 - Pal App Manual

Latest Edition

Installation

To write the Pal App (App_PAL), install TWELITE STAGE SDK and rewrite using the TWELITE STAGE App.

Supported Hardware

  • TWELITE BLUE / RED PAL with Open/Close Sensor Pal attached
  • TWELITE BLUE / RED PAL with Environmental Sensor Pal attached
  • TWELITE BLUE / RED PAL with Motion Sensor Pal attached
  • TWELITE BLUE / RED PAL with Notification Pal attached

8.1.1 - Interactive Mode (Pal App)

Interactive mode for the Pal app
You can perform detailed configuration of the app in interactive mode.

This section explains features specific to the Pal app (App_PAL). For common features, please refer to the TWELITE APPS Manual main page.

Example Display

The screen will display as follows.

--- CONFIG/App_PAL V1-05-2/SID=0x810e0e23/LID=0x01 ---
 a: set Application ID (0x67726305)
 i: set Device ID (--)
 c: set Channels (15)
 x: set Tx Power (13)
 b: set UART baud (38400)
 B: set UART option (8N1)
 k: set Enc Key (0xA5A5A5A5)
 o: set Option Bits (0x00000001)
 t: set Transmission Interval (60)
 p: set Sensor Parameter (0x00000000)
 e: set Event Parameter(s) (0180002A0208002A0300802A0488002A0580802A0608802A0880000A1008000A)
 d: set Temperature Coefficient (0)
 D: set Temperature Offset (0)
 f: set Humidity Coefficient (0)
 F: set Humidity Offset (0)
---
 S: save Configuration
 R: reset to Defaults

Commands

Setting ItemDefaultRemarks
aApplication ID0x6772010732bit
iLogical Device ID120Child 1-100
cFrequency Channel1611-26
xRetry Count and Tx Power3
Retry Count01-9 times, 0 is default: none
Tx Power30-3
bUART Alternative Baud Rate38400Enabled with BPS pin
BUART Option8N1Enabled with BPS pin
kEncryption Key0xA5A5A5A532bit
oOption Bits0x00000000Other detailed settings
tTransmission Interval601-4095 seconds
pSensor-specific Parameter0
eNotification Event0180002A
0208002A
0300802A
0488002A
0580802A
0608802A
0880000A
1008000A
Notification Pal only
dTemperature Coefficient0Environmental Pal only 0-60000
DTemperature Offset0Environmental Pal only -2000-2000
fHumidity Coefficient0Environmental Pal only 0-60000
FHumidity Offset0Environmental Pal only -2000-2000

Details of each command are as follows.

a: Application ID

All devices communicating must use the same value. This logically separates networks.

i: Logical Device ID

Set when it is necessary to distinguish multiple child devices.

If there is no need or it is not possible to distinguish, set to 120. If distinction is needed, children should use any value from 1 to 100, and the parent should use 0 or 121.

c: Frequency Channel

All devices communicating must use the same value. This physically separates networks.

x: Tx Power and Retry Count

Specify the radio transmission power and the number of additional packet transmissions in transparent mode and headered transparent mode.

b: UART Alternative Baud Rate

Overrides the alternative baud rate selected when the BPS pin is connected to GND at startup.

Selectable values are 9600/19200/38400/57600/115200/230400. Specifying other values may cause errors.

B: UART Option

Overrides the alternative UART settings selected when the BPS pin is connected to GND at startup.

Parity can be set to N: None, O: Odd, or E: Even. Hardware flow control cannot be set. Settings like 8N1 or 7E2 can be used, but settings other than 8N1 are unverified. Please confirm operation in advance.

k: Encryption Key

Specify the 32-bit hexadecimal encryption key used when enabling encrypted communication in option bits.

o: Option Bits

Specify a 32-bit value. Various settings linked to each bit can be enabled.

BitSetting DescriptionDefault
0x00000001Enable Transmission to Repeater0️⃣
0x00001000Enable Encrypted Communication0️⃣
0x00010000Enable UART Output on Child0️⃣

t: Transmission Interval

Specifies the data transmission interval. For notification pals, it indicates the interval for querying control information from the parent and reflecting it on LED output.

p: Sensor-specific Parameter

Depends on the hardware.

e: Notification Event

Notification Pal

Specifies the behavior when an event number is received.

For details, see Notification Event Details.

d: Temperature Coefficient

Environmental Sensor Pal

Specify the temperature data coefficient (d) in the range 0-60000.

0 disables it. Otherwise, the final temperature is multiplied by (\frac{d}{1024}).

D: Temperature Offset

Environmental Sensor Pal

Specify the temperature data offset (D) in the range -2000 to 2000.

(D) is added to the temperature multiplied by 100. The final temperature changes by (\frac{D}{100}) °C.

f: Humidity Coefficient

Environmental Sensor Pal

Specify the humidity data coefficient (f) in the range 0-60000.

0 disables it. Otherwise, the final humidity is multiplied by (\frac{f}{1024}).

F: Humidity Offset

Environmental Sensor Pal

Specify the humidity data offset (F) in the range -2000 to 2000.

(F) is added to the humidity multiplied by 100. The final humidity changes by (\frac{F}{100}) %.

Details of Option Bits

Explanation of settings linked to each bit of the option bits value.

00000001: Enable Transmission to Repeater

Enables transmission not only to the parent but also to repeaters.

You can use repeaters even without setting this option, but the parent will remove duplicated packets. In this case, there is no way to determine which repeater the packet passed through or if it was not relayed.

If this option is set, the parent can output packets received from multiple devices separately. Devices connected to the parent can analyze the output to determine which device the child was near.

00001000: Enable Encrypted Communication

Enables encrypted communication. The other party must also enable encrypted communication.

00010000: Enable UART Output on Child

Enables message output on the child device.

Details of Sensor-specific Parameters

Explanation of settings linked to the sensor-specific parameter value.

Open/Close Sensor Pal

Not used.

Environmental Sensor Pal

Not used.

Motion Sensor Pal

Specify a 32-bit value.

bit31-2827-2423-2019-1615-1211-87-43-0
Function----ATHSFQSCT:7-4SCT:3-0
Default00000000

Each function represents the following:

NameItemDescription
SCTSample CountNumber of acceleration samples
SFQSampling FrequencySampling frequency of acceleration
ATHActive Detection ModeAcceleration threshold, 0 disables

SCT: Sample Count

SCT affects the number of samples transmitted.

Intermittent Transmission Mode

When ATH is 0 and t: Transmission Interval is non-zero, intermittent transmission mode is active.

If SCT value is (C_i), the sample count is represented as (16C_i+16).

pSCTSample Count
0x??????000x0016 samples (default)
0x??????010x0132 samples
0x??????070x07128 samples
0x??????FF0xFF4096 samples
Active Detection Mode

When ATH and t: Transmission Interval are both non-zero, active detection mode is active.

In active detection mode, when acceleration exceeds the threshold given by ATH, it transmits the samples immediately after, in addition to the previous 30 samples.

If SCT value is (C_a), the number of subsequent samples is (30C_a+30).

pSCTSubsequent Sample Count
0x??????000x0030 samples (default)
0x??????010x0160 samples
0x??????070x07240 samples
0x??????FF0xFF7680 samples

SFQ: Sampling Frequency

SFQ affects the sampling frequency of acceleration data.

pSFQSampling Frequency
0x?????0??0x025Hz (default)
0x?????1??0x150Hz
0x?????2??0x2100Hz
0x?????3??0x3190Hz

ATH: Active Detection Mode

ATH affects the behavior of active detection mode.

0 disables it. Values 1-F enable it with the value as the threshold.

pATHDescription
0x????0???0x0Disabled (default)
0x????1???0x11G (not recommended)
0x????2???0x22G
0x????F???0xF15G

Notification Pal

Specify a 32-bit value.

pDescription
0x00000000Tap & Shake Mode
0x00000001Dice Mode

00000000: Tap & Shake Mode

Sends data when tapped or shaken.

00000001: Dice Mode

Detects six different top faces and sends data.

Notification Event Details

The value is binary data up to 68 bytes, represented as a hexadecimal string.

One event consists of 4 bytes. The maximum number of events is 17.

#DataDescriptionRemarks
1st event
0uint8Event ID0x00-0x10
1uint8Red and Green BrightnessRed 0x0?-0xF?, Green 0x?0-0x?F
2uint8Blue and White BrightnessBlue 0x0?-0xF?, White 0x?0-0x?F
3uint8Blink Pattern and On Time
Blink PatternSteady 0x0?, Slow 0x1?, Medium 0x2?, Fast 0x3?
On TimeNo off 0x?0, Seconds specified 0x?1-0x?F
2nd event
4uint8Event ID0x01-0x10
5uint8Red and Green BrightnessRed 0x0?-0xF?, Green 0x?0-0x?F
6uint8Blue and White BrightnessBlue 0x0?-0xF?, White 0x?0-0x?F
7uint8Blink Pattern and On Time
Blink PatternSteady 0x0?, Slow 0x1?, Medium 0x2?, Fast 0x3?
On TimeNo off 0x?0, Seconds specified 0x?1-0x?F
3rd event
17th event
64uint8Event ID0x01-0x10
65uint8Red and Green BrightnessRed 0x0?-0xF?, Green 0x?0-0x?F
66uint8Blue and White BrightnessBlue 0x0?-0xF?, White 0x?0-0x?F
67uint8Blink Pattern and On Time
Blink PatternSteady 0x0?, Slow 0x1?, Medium 0x2?, Fast 0x3?
On TimeNo off 0x?0, Seconds specified 0x?1-0x?F

Example Configuration Data

An example of the default setting is shown.

0180002A0208002A0300802A0488002A0580802A0608802A0880000A1008000A
#DataDescriptionValue
1st event
010uint8Event ID0x01
801uint8Red and Green BrightnessRed 8/15, Green 0/15
002uint8Blue and White BrightnessBlue 0/15, White 0/15
2A3uint8Blink Pattern and On TimeMedium, 10 seconds
2nd event
024uint8Event ID0x02
085uint8Red and Green BrightnessRed 0/15, Green 8/15
006uint8Blue and White BrightnessBlue 0/15, White 0/15
2A7uint8Blink Pattern and On TimeMedium, 10 seconds
3rd event
8th event
1028uint8Event ID0x10
0829uint8Red and Green BrightnessRed 0/15, Green 8/15
0030uint8Blue and White BrightnessBlue 0/15, White 0/15
0A31uint8Blink Pattern and On TimeSteady, 10 seconds