Skip to content

Instantly share code, notes, and snippets.

@ah01
Last active July 11, 2018 12:36
Show Gist options
  • Save ah01/96c0557ebfb9f2f100b3464676ddcedf to your computer and use it in GitHub Desktop.
Save ah01/96c0557ebfb9f2f100b3464676ddcedf to your computer and use it in GitHub Desktop.
BC LoRa Thermometer MSG Format

Message format description

⬆️ Uplink

✉️ Status information message (port 1)

Status message is 7 bytes long and send to port 1.

Contains all information about device including measured temperature. This message is send after reset, button press or after request by sending downlink message Status request.

Payload

byte value format notes
0 Status bit map
1 Version uint TODO
2 Battery uint TODO
3 - 4 Measurement interval uint16 TODO
5 Temperature measurement (integer part) int
6 Temperature measurement (decimal part) uint

Status bit map

bit value note
0 reset set in case if message is send after reset of device
1 button set in case of button press

✉️ Temperature measurement message (port 2)

Temperature measurement message is 2 bytes long and send to port 2.

Contains temperature measurement. This message is send periodically.

Payload

byte value format notes
0 Integer part of temperature int8
1 Decimal part of temperature uint8

✉️ Measurement error message (port 3)

Measurement error message is 1 byte long and send to port 3.

Send in case of measurement error (sensor failure)

Payload

byte value format notes
0 Error code TODO

⬇️ Downlink

✉️ Status request message (port 1)

Status request message is 1 byte long and send to port 1.

Ask for status message.

Payload

byte value format note
0 request bit map

Request bit map

bit value note
0 immediate uplink if set uplinks status message should be send immediately, otherwise it will be send instead of next measurement
1 LED if set LED will be blinking for next 60 sec

✉️ Configuration message (port 2)

Configuration message is 2 byte long and send to port 2.

Set interval of measurements. Interval is calculated on device as <value> * 10 sec.

byte value format note
0 -1 interval uint16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment