pub fn wor_uplink(
keys: &WorKeys,
dev_addr: u32,
wfcnt: u32,
uplink: Carrier,
wor: Carrier,
) -> Result<[u8; 15], LorawanError>Expand description
Builds the wake-on-radio frame ahead of a Class A uplink, TS011-1.0.1 section 5.3.2.
The uplink’s carrier is encrypted under WorSEncKey with a block that folds in the
frame’s own carrier and counter, and the frame is signed with WorSIntKey.
§Arguments
keys- the device’s keys.dev_addr- the device’s address.wfcnt- the WOR frame counter, which the device raises for every WOR frame it sends.uplink- where and how fast the uplink follows.wor- the carrier this WOR frame goes out on.
§Returns
The frame.
§Errors
Returns LorawanError::MalformedFrame for a data rate past 15 or a frequency the
three-byte field cannot carry, in either carrier.