5 - Class B

This book explores in depth how to use Class B in end devices implementing LoRaWAN® 1.0.4. Class B mode enables the end device to receive downlinks at regular intervals. We teach you how to configure your end device to receive Class B downlinks using beacons and ping slots and best practices to follow to increase the chance of receiving downlinks while maintaining reasonable battery life.

Handling Absence of Beacons

If the end device does not detect a beacon at the expected time, it must continue to listen for beacons and Class B downlinks using the end device’s internal clock for two hours. Beacons may not be received for various reasons, such as a gateway going offline or excessive interference. During the two-hour period, the internal clock on the end device may drift from the internal clock on the network server, which would lead to missed beacons and downlinks. To compensate for this drift, the times when the end device begins and ends listening for beacons and Class B downlinks should be progressively expanded, listening slightly earlier and for slightly longer with each passing beacon period.

During this two-hour window, if a beacon is detected, the internal clock must be updated and the duration the end device listens for beacons and ping slots must be reset to the original size. The two-hour timer must then be reset, and the process described in this section is repeated.

Learn more in section 10 ‘Class B Beacon Acquisition and Tracking’ (page 57) of the LoRaWAN Link Layer Specification v1.0.4.