Class LorawanBackoff
A device's count of how long the network has been silent.
public sealed class LorawanBackoff : IDisposable
- Inheritance
-
LorawanBackoff
- Implements
- Inherited Members
Remarks
A network running adaptive data rate moves a device to the fastest rate and lowest power that still reach it. Once uplinks go unanswered, this says when to ask the network to answer and which of those settings to give back, a step at a time, as LoRaWAN 1.0.3 or TS001-1.0.4 describes.
Constructors
LorawanBackoff(LorawanVersion, uint, uint)
Starts a count from zero.
public LorawanBackoff(LorawanVersion version = LorawanVersion.V1_0_4, uint limit = 64, uint delay = 32)
Parameters
versionLorawanVersionThe revision whose steps to follow.
limituintHow many unanswered uplinks before asking.
delayuintHow many more before the first step, and between steps after that. Zero is taken as one.
Exceptions
- PamojaException
The version names no revision.
Properties
Counter
How many uplinks have gone unanswered.
public uint Counter { get; }
Property Value
Version
The revision whose steps this count follows.
public LorawanVersion Version { get; }
Property Value
Methods
Dispose()
Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
public void Dispose()
Downlink()
Counts a Class A downlink, which proves the network still hears the device.
public void Downlink()
Uplink(bool)
Counts one new uplink, and says what to do before sending it.
public LorawanBackoffStep Uplink(bool atDefaultDataRate)
Parameters
atDefaultDataRateboolWhether the device is already at its default data rate, the slowest it uses.
Returns
- LorawanBackoffStep
Whether to ask for an answer, and which step this uplink takes.
Remarks
Call it once per uplink the frame counter moves for; a repeat of the same uplink does not count.