#[unsafe(no_mangle)]pub unsafe extern "C" fn pamoja_lorawan_end_device_personalized(
plan: *const PamojaLoraPlan,
session: *const PamojaLorawanSession,
settings: *const PamojaLorawanDeviceSettings,
fcnt_up: u32,
has_fcnt_down: u8,
fcnt_down: u32,
out_device: *mut *mut PamojaLorawanEndDevice,
) -> PamojaStatusExpand description
Makes a device activated by personalization, with its session provisioned.
Such a device never resets its frame counters, TS001-1.0.4 section 4.3.1.5, so a device that lost power passes the ones it kept.
§Arguments
plan- a published channel plan.session- the address and session keys it was provisioned with, which the device copies.settings- what its radio can do.fcnt_up- the next uplink frame counter.has_fcnt_down-1iffcnt_downholds the last downlink counter accepted.fcnt_down- that counter.out_device- receives the device.
§Returns
PamojaStatus::Ok on success, with *out_device set to a handle the caller must
release with pamoja_lorawan_end_device_free.
§Errors
As pamoja_lorawan_end_device_new.
§Safety
plan and session must be live handles, settings must point to a readable
PamojaLorawanDeviceSettings, and out_device to a writable pointer.