Skip to main content

pamoja_lorawan_relay_unsynchronized_preamble

Function pamoja_lorawan_relay_unsynchronized_preamble 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn pamoja_lorawan_relay_unsynchronized_preamble( cad_periodicity: u8, symbol_us: u64, cad_to_rx: u8, out_symbols: *mut u16, ) -> PamojaStatus
Expand description

Works out the WOR preamble of an end device that does not know when the relay scans, TS011-1.0.1 section 5.2.

§Arguments

  • cad_periodicity - how often the relay scans, coded 0 to 5.
  • symbol_us - the symbol time of the WOR frame’s data rate, in microseconds.
  • cad_to_rx - the relay’s time to start receiving, coded 0 to 3.
  • out_symbols - receives the preamble length in symbols.

§Returns

PamojaStatus::Ok on success.

§Errors

Returns PamojaStatus::InvalidArgument for a null pointer or a code out of range.

§Safety

out_symbols must be writable.