Try It: Size Your Own Message

Try It: Size Your Own Message

animation
data
formats
iot

Try It: Size Your Own Message

The reference example uses an EU863-870 LoRaWAN uplink at DR0 (SF12 at 125 kHz), with no FOpts and an application-payload budget of up to 51 bytes. Other regions, data rates, MAC-command use and device profiles have different limits.

Take a sensor you know. Write the message as JSON and count its UTF-8 bytes, then rewrite the same fields with short keys, then as integer-scaled values. Test each result against this example’s 51-byte DR0 application budget, and record which step recovered the most space.

Incremental Practice

Beginner

For a Wi-Fi sensor that posts every minute, justify staying on JSON instead of switching to binary.

Intermediate

For a LoRaWAN node, convert a JSON message to short keys and integer scaling, and record the byte count at each step.

Advanced

Design a hand-packed layout for a 12-byte Sigfox uplink, including a version byte and reserved bits for one future field.

Decode One Reading After Every Handoff

Encode one known reading in each candidate format, move it through the real path, and decode it at the end. Change a field, omit a unit, use an older version, repeat the message, and restart the receiver. Compare bytes, energy, readability, and rejection behavior.

Back to the chapter