Uplink Messages
Overview
This page documents the CBOR-encoded messages that Haltian ENTRYWAY transmits from the sensor to the gateway over the Wirepas mesh network.
For the Haltian IoT Platform equivalent (JSON over MQTT/GraphQL), see Data Output.
Wirepas endpoint: 21/21
MQTT topic: haltian-iot/wirepas/gw-event/received_data/{gateway-id}/sink1/{network-id}/21/21
Each message is identified by tsmId (message structure ID). Examples below are shown in both JSON (decoded CBOR) and CBOR (numeric indexes as transmitted on the wire).
People Counting Report (tsmId 13103)
The primary application message. Reports entry/exit counts accumulated since the last report.
| JSON Property | CBOR Index | Description |
|---|---|---|
tsmId | 1 | Message ID: 13103 |
tsmEv | 2 | Event type: 10 (timed), 11 (startup) |
tsmTs | 3 | UTC timestamp in seconds (added by gateway) |
tsmTuid | 4 | Device unique identifier |
tsmGw | 5 | Gateway identifier (added by gateway) |
tsmSeq | — | Sequence counter |
in | 1210 | People entered since last report |
out | 1211 | People exited since last report |
averaging | 288 | Array of 3 PIR signal averages (diagnostic) |
errorCount | — | Array of 3 PIR error counts (diagnostic) |
Reporting Behavior
| Condition | Timing |
|---|---|
| First movement detected | Immediate report |
| Continued activity | Every measurement interval (default 30s) |
| No movement | Every idle reporting interval (default 1 hour) |
Example
{
"tsmId": 13103,
"tsmEv": 10,
"tsmTs": 1755064655,
"tsmTuid": "XXCN01TSC20205507",
"tsmGw": "TSGW06EWK31903495",
"tsmSeq": 5657,
"in": 1,
"out": 0,
"averaging": [94, 89, 101],
"errorCount": [3, 3, 3]
}
{1: 13103, 2: 10, 3: 1755064655, 4: "XXCN01TSC20205507", 5: "TSGW06EWK31903495",
1210: 1, 1211: 0, 288: [94, 89, 101]}
Interpretation: Device XXCN01TSC20205507 reports 1 person entered and 0 exited since the last report. PIR signal averages [94, 89, 101] indicate all three PIR sensors are functioning normally.
System Info (tsmId 1100)
Sent once on device boot-up. Contains firmware version and device model.
| JSON Property | CBOR Index | Description |
|---|---|---|
tsmId | 1 | Message ID: 1100 |
tsmEv | 2 | Event type: 11 (startup) |
swVersion | 70 | Firmware version string |
modelCode | 71 | Device model code (e.g., XXCN01) |
psn | — | Production serial number |
Example
{
"tsmId": 1100,
"tsmEv": 11,
"tsmTs": 1755060000,
"tsmTuid": "XXCN01TSC20205507",
"tsmGw": "TSGW06EWK31903495",
"swVersion": "3.2.1",
"modelCode": "XXCN01",
"psn": "TSC20205507"
}
{1: 1100, 2: 11, 3: 1755060000, 4: "XXCN01TSC20205507", 5: "TSGW06EWK31903495",
70: "3.2.1", 71: "XXCN01"}
Battery Level (tsmId 1110)
Reported every 6 hours (21600 seconds). Monitors remaining battery capacity.
| JSON Property | CBOR Index | Multiplier | Description |
|---|---|---|---|
tsmId | 1 | — | Message ID: 1110 |
tsmEv | 2 | — | Event type: 10 (timed) |
batl | 21 | 10^1 | Battery level percentage |
batl uses multiplier 10^1 — CBOR value 920 decodes to 92.0% in JSON. Divide the raw CBOR value by 10 when decoding.
Example
{
"tsmId": 1110,
"tsmEv": 10,
"tsmTs": 1755081600,
"tsmTuid": "XXCN01TSC20205507",
"tsmGw": "TSGW06EWK31903495",
"batl": 92
}
{1: 1110, 2: 10, 3: 1755081600, 4: "XXCN01TSC20205507", 5: "TSGW06EWK31903495",
21: 920}
Network Diagnostics (tsmId 1202)
Reported every 12 hours (43200 seconds). Provides mesh network connectivity metrics.
| JSON Property | CBOR Index | Description |
|---|---|---|
tsmId | 1 | Message ID: 1202 |
tsmEv | 2 | Event type: 10 (timed) |
tuid | 62 | Device identifier |
rssi | 61 | Received signal strength |
rssiDbm | 65 | Signal strength in dBm |
Example
{
"tsmId": 1202,
"tsmEv": 10,
"tsmTs": 1755103200,
"tsmTuid": "XXCN01TSC20205507",
"tsmGw": "TSGW06EWK31903495",
"tuid": "XXCN01TSC20205507",
"rssi": -62,
"rssiDbm": -62
}
{1: 1202, 2: 10, 3: 1755103200, 4: "XXCN01TSC20205507", 5: "TSGW06EWK31903495",
62: "XXCN01TSC20205507", 61: -62, 65: -62}
Firmware Binary Info (tsmId 1312)
Sent once on boot alongside System Info. Reports firmware binary details.
Example
{
"tsmId": 1312,
"tsmEv": 11,
"tsmTs": 1755060000,
"tsmTuid": "XXCN01TSC20205507",
"tsmGw": "TSGW06EWK31903495",
"binaryType": 1,
"binaryVersion": "3.2.1"
}
{1: 1312, 2: 11, 3: 1755060000, 4: "XXCN01TSC20205507", 5: "TSGW06EWK31903495"}
Error Event (tsmId 1403)
Sent when an error condition occurs. Use errorType and errorCause to diagnose issues.
Example
{
"tsmId": 1403,
"tsmEv": 29,
"tsmTs": 1755064700,
"tsmTuid": "XXCN01TSC20205507",
"tsmGw": "TSGW06EWK31903495",
"errorType": 1,
"errorCause": 3
}
{1: 1403, 2: 29, 3: 1755064700, 4: "XXCN01TSC20205507", 5: "TSGW06EWK31903495"}
Event Types Reference
All tsmEv values used by ENTRYWAY uplink messages:
| tsmEv | Name | Description |
|---|---|---|
| 10 | Timed | Periodic report at configured interval |
| 11 | Startup | Device boot-up / power-on |
| 29 | Error | Critical error report |
| 34 | Timed diagnostics | Periodic diagnostic event |
CBOR Index Reference (Uplink)
| CBOR Index | JSON Property | Category |
|---|---|---|
| 1 | tsmId | Header |
| 2 | tsmEv | Header |
| 3 | tsmTs | Header |
| 4 | tsmTuid | Header |
| 5 | tsmGw | Header |
| 21 | batl | System (multiplier 10^1) |
| 61 | rssi | Network |
| 62 | tuid | Network |
| 65 | rssiDbm | Network |
| 70 | swVersion | System |
| 71 | modelCode | System |
| 288 | averaging | Diagnostic |
| 1210 | in | People counting |
| 1211 | out | People counting |