Skip to main content

pamoja_lorawan_end_device_channel

Function pamoja_lorawan_end_device_channel 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn pamoja_lorawan_end_device_channel( device: *const PamojaLorawanEndDevice, position: u16, out_index: *mut u16, out_channel: *mut PamojaLorawanChannel, ) -> PamojaStatus
Expand description

Reads one of the channels a device may send on.

§Arguments

  • device - the device.
  • position - the channel’s position among the enabled ones, below the count pamoja_lorawan_end_device_status reports.
  • out_index - receives the channel’s index in the device’s table.
  • out_channel - receives the channel.

§Returns

PamojaStatus::Ok on success.

§Errors

Returns PamojaStatus::InvalidArgument if a pointer is null or position is past the last enabled channel.

§Safety

device must be a live handle and the out pointers writable.