Skip to main content

PamojaLorawanMacCommand

Struct PamojaLorawanMacCommand 

Source
#[repr(C)]
pub struct PamojaLorawanMacCommand {
Show 71 fields pub cid: u8, pub direction: PamojaLorawanDirection, pub margin: u8, pub gateways: u8, pub data_rate: u8, pub tx_power: u8, pub channel_mask: u16, pub mask_control: u8, pub transmissions: u8, pub power_ack: u8, pub data_rate_ack: u8, pub channel_mask_ack: u8, pub max_duty_cycle: u8, pub rx1_offset: u8, pub rx2_data_rate: u8, pub frequency_hz: u32, pub rx1_offset_ack: u8, pub rx2_data_rate_ack: u8, pub channel_ack: u8, pub battery: u8, pub snr_margin: i8, pub index: u8, pub max_data_rate: u8, pub min_data_rate: u8, pub data_rate_range_ok: u8, pub frequency_ok: u8, pub delay: u8, pub max_eirp: u8, pub uplink_dwell: u8, pub downlink_dwell: u8, pub uplink_frequency_exists: u8, pub seconds: u32, pub fraction: u8, pub enabled: u8, pub cad_periodicity: u8, pub default_channel_index: u8, pub second_channel_index: u8, pub second_channel_data_rate: u8, pub second_channel_ack_offset: u8, pub cad_periodicity_ack: u8, pub default_channel_index_ack: u8, pub second_channel_index_ack: u8, pub second_channel_data_rate_ack: u8, pub second_channel_ack_offset_ack: u8, pub second_channel_frequency_ack: u8, pub relay_mode: u8, pub smart_enable_level: u8, pub back_off: u8, pub action: u8, pub eui_len: u8, pub eui: [u8; 16], pub combined_rules_ack: u8, pub eui_len_ack: u8, pub action_ack: u8, pub reload_rate: u8, pub bucket_size: u8, pub dev_addr: u32, pub wfcnt: u32, pub root_wor_s_key: [u8; 16], pub index_ack: u8, pub reset_limit_counters: u8, pub join_request_reload_rate: u8, pub notify_reload_rate: u8, pub global_uplink_reload_rate: u8, pub overall_reload_rate: u8, pub join_request_bucket_size: u8, pub notify_bucket_size: u8, pub global_uplink_bucket_size: u8, pub overall_bucket_size: u8, pub rssi_dbm: i16, pub snr_db: i8,
}
Expand description

One command, with the fields of whichever command it is.

cid names the command and direction says which way it travels; together they decide which of the other fields carry anything. The rest are zero.

Fields§

§cid: u8

Which command this is.

§direction: PamojaLorawanDirection

Which way it travels.

§margin: u8

How far above the floor a link check arrived, in dB.

§gateways: u8

How many gateways heard it.

§data_rate: u8

The data rate a network asks a device to use.

§tx_power: u8

The transmit power it may use, as a ceiling.

§channel_mask: u16

Which channels may carry an uplink.

§mask_control: u8

Which block of sixteen channels that mask applies to.

§transmissions: u8

How many times to send an unconfirmed uplink.

§power_ack: u8

Whether the power was set, 1 for yes.

§data_rate_ack: u8

Whether the data rate was set.

§channel_mask_ack: u8

Whether the channel mask was usable.

§max_duty_cycle: u8

The share of the air a device is held to, as one over two to this.

§rx1_offset: u8

How far the first receive window sits below the uplink rate.

§rx2_data_rate: u8

The rate of the second receive window.

§frequency_hz: u32

A frequency in hertz, for the windows and the channel commands.

§rx1_offset_ack: u8

Whether the window offset was in range.

§rx2_data_rate_ack: u8

Whether the window rate was known.

§channel_ack: u8

Whether the frequency was usable.

§battery: u8

A device battery level: 0 on external power, 255 when it cannot tell.

§snr_margin: i8

The signal-to-noise ratio of the last request, in dB.

§index: u8

Which channel a channel command names.

§max_data_rate: u8

The fastest rate allowed on it.

§min_data_rate: u8

The slowest rate allowed on it.

§data_rate_range_ok: u8

Whether the device can run that range of rates.

§frequency_ok: u8

Whether its radio can reach that frequency.

§delay: u8

How long a device waits before its first receive window, as the command codes it.

§max_eirp: u8

The coded transmit power ceiling a region imposes.

§uplink_dwell: u8

Whether an uplink is held to 400 ms of air time.

§downlink_dwell: u8

Whether a downlink is.

§uplink_frequency_exists: u8

Whether the channel already had an uplink frequency to pair a downlink with.

§seconds: u32

Seconds since the GPS epoch.

§fraction: u8

The fraction of that second, in steps of one part in 256.

§enabled: u8

Whether a relay runs.

§cad_periodicity: u8

How often a relay scans, as TS011-1.0.1 table 18 codes it.

§default_channel_index: u8

Which of the region’s relay channels is a relay’s default one.

§second_channel_index: u8

Whether a relay configuration sets a second channel, 1 for yes.

§second_channel_data_rate: u8

The second channel’s data rate; its frequency is the frequency field.

§second_channel_ack_offset: u8

How far above its frequency the second channel is acknowledged, as table 35 codes it.

§cad_periodicity_ack: u8

Whether the scan period was valid.

§default_channel_index_ack: u8

Whether the default channel was valid.

§second_channel_index_ack: u8

Whether the second channel index was valid.

§second_channel_data_rate_ack: u8

Whether the second channel’s data rate was valid.

§second_channel_ack_offset_ack: u8

Whether its acknowledgment offset was valid.

§second_channel_frequency_ack: u8

Whether its frequency was valid.

§relay_mode: u8

How an end device uses a relay, as TS011-1.0.1 table 40 codes it.

§smart_enable_level: u8

How many unanswered uplinks turn relaying on, as table 41 codes it.

§back_off: u8

How many WOR frames without an acknowledgment before an uplink goes anyway.

§action: u8

What a join filter rule does, or whether a trusted end device is read or removed.

§eui_len: u8

How many leading bytes of JoinEUI and DevEUI a join filter rule matches.

§eui: [u8; 16]

Those bytes, most significant first, with the rest zero.

§combined_rules_ack: u8

Whether a join filter rule was one to create, change or remove.

§eui_len_ack: u8

Whether its length was valid.

§action_ack: u8

Whether its action was valid.

§reload_rate: u8

Tokens a trusted end device earns an hour, 63 for no limit.

§bucket_size: u8

Its bucket size multiplier, as TS011-1.0.1 table 55 codes it.

§dev_addr: u32

An end device address a relay command names.

§wfcnt: u32

A wake-on-radio frame counter.

§root_wor_s_key: [u8; 16]

An end device’s root relay session key.

§index_ack: u8

Whether a trusted list entry was in use.

§reset_limit_counters: u8

What a forwarding limit command does to a relay’s token counters, as table 63 codes it.

§join_request_reload_rate: u8

Join requests a relay forwards an hour, 127 for no limit.

§notify_reload_rate: u8

New end device notifications a relay sends an hour.

§global_uplink_reload_rate: u8

Uplinks a relay forwards an hour across every trusted end device.

§overall_reload_rate: u8

Every message a relay sends an hour.

§join_request_bucket_size: u8

The join request bucket size multiplier.

§notify_bucket_size: u8

The notification bucket size multiplier.

§global_uplink_bucket_size: u8

The global uplink bucket size multiplier.

§overall_bucket_size: u8

The overall bucket size multiplier.

§rssi_dbm: i16

The signal strength of a WOR frame a relay could not verify, in dBm.

§snr_db: i8

Its signal-to-noise ratio, in dB.

Trait Implementations§

Source§

impl Clone for PamojaLorawanMacCommand

Source§

fn clone(&self) -> PamojaLorawanMacCommand

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for PamojaLorawanMacCommand

Source§

impl Debug for PamojaLorawanMacCommand

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for PamojaLorawanMacCommand

Source§

impl PartialEq for PamojaLorawanMacCommand

Source§

fn eq(&self, other: &PamojaLorawanMacCommand) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for PamojaLorawanMacCommand

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.