DevDomainSnapshot

Struct DevDomainSnapshot 

Source
pub struct DevDomainSnapshot {
Show 25 fields pub version: u32, pub channel_keys: Vec<[u8; 32], MAX_CHANNEL_KEYS>, pub peers: Vec<[u8; 32], MAX_DEV_PEERS>, pub admins: Vec<[u8; 32], MAX_DEV_ADMINS>, pub dev_key: Option<[u8; 32]>, pub repeater_enabled: bool, pub repeater_region_codes: Vec<[u8; 2], MAX_REPEATER_REGIONS>, pub repeater_region_names: Vec<Vec<u8, REGION_STRING_MAX_LEN>, MAX_REPEATER_REGIONS>, pub repeater_default_region: Option<[u8; 2]>, pub repeater_min_rssi: Option<i16>, pub repeater_min_snr: Option<i8>, pub ident_role: Option<u8>, pub ident_mobile: bool, pub ident_location: Vec<u8, { umsh_ulcp::gnss::MAX_LOCATION_LEN }>, pub ident_altitude_m: Option<i32>, pub discoverable: bool, pub advert_interval_s: u32, pub beacon_interval_s: u32, pub startup_beacon: bool, pub tz_offset_min: i16, pub gnss_enabled: bool, pub gnss_ident_update: bool, pub gnss_ident_precision: u8, pub gnss_time_trust: bool, pub ble_enabled: bool,
}
Expand description

The session’s device-domain tables, mirrored to the board’s device node whenever their generation moves (device-node plan increment 3).

Fields§

§version: u32

The session’s device-domain generation when this snapshot was taken. Every mutation moves it, which is what a Node Management cursor encodes so that a position taken before a change is detected rather than served wrong.

§channel_keys: Vec<[u8; 32], MAX_CHANNEL_KEYS>§peers: Vec<[u8; 32], MAX_DEV_PEERS>§admins: Vec<[u8; 32], MAX_DEV_ADMINS>

PROP_DEV_ADMINS: the nodes allowed to manage this device over the mesh. Mirrored here because authorization is checked against the arriving frame’s source key before anything reaches the session, and the responder holds no session borrow.

§dev_key: Option<[u8; 32]>

The session’s live PROP_DEV_KEY.

The device node compares this against the key its MAC was built with rather than merely checking that some identity exists. The two can disagree — a newly installed PROP_DEV_PRIVATE_KEY takes effect at the next boot, and CMD_CLEAR + CMD_RST erases the stored one — and in every such case the running node is no longer the identity the session describes and must stop originating traffic under it.

§repeater_enabled: bool

PROP_MAC_REPEATER_ENABLED: whether the device node should forward overheard routable frames. Advertised as the REP capability bit — a fact about what the node does, not a choice about what it calls itself.

§repeater_region_codes: Vec<[u8; 2], MAX_REPEATER_REGIONS>

PROP_MAC_REPEATER_REGIONS as the MAC’s forwarding filter needs it: the 2-octet code derived from each configured region. Empty imposes no restriction.

§repeater_region_names: Vec<Vec<u8, REGION_STRING_MAX_LEN>, MAX_REPEATER_REGIONS>

The same regions as the identity advertises them: the string form of each, which is what a reader can make sense of — a hash-derived code cannot be turned back into a name.

§repeater_default_region: Option<[u8; 2]>

PROP_MAC_REPEATER_DEFAULT_REGION: the code the node inserts into an untagged flood packet, or None to never tag.

§repeater_min_rssi: Option<i16>

PROP_MAC_REPEATER_MIN_RSSI: minimum RSSI in dBm to flood-forward, or None for no threshold.

§repeater_min_snr: Option<i8>

PROP_MAC_REPEATER_MIN_SNR: minimum SNR in whole dB to flood-forward, or None for no threshold.

§ident_role: Option<u8>

PROP_IDENT_ROLE: the advertised ROLE byte, or None to derive it from the forwarding state.

§ident_mobile: bool

PROP_IDENT_MOBILE: whether to advertise the MOB capability bit.

§ident_location: Vec<u8, { umsh_ulcp::gnss::MAX_LOCATION_LEN }>

PROP_IDENT_LOCATION: the position the advertised identity carries, in the variable-precision encoding, or empty for none.

§ident_altitude_m: Option<i32>

PROP_IDENT_ALTITUDE: meters above the WGS-84 ellipsoid, or None.

§discoverable: bool

PROP_DEV_DISCOVERABLE: whether the device identity answers Identity Requests.

§advert_interval_s: u32

PROP_ADVERT_INTERVAL: seconds between unsolicited advertisements, 0 for none.

§beacon_interval_s: u32

PROP_BEACON_INTERVAL: seconds between unsolicited beacons, 0 for none.

§startup_beacon: bool

PROP_STARTUP_BEACON: whether one beacon goes out at bring-up.

§tz_offset_min: i16

PROP_TZ_OFFSET: minutes east of UTC, for whatever renders a local time.

§gnss_enabled: bool

PROP_GNSS_ENABLED: whether the receiver should be powered. Always false on a board without CAP_GNSS.

Carried here rather than as an effect of its own so that a host write, a boot restore, and a CMD_RST all reach the receiver by the same path — the mirror is published whenever the device domain moves, which is exactly the set of moments this can change.

§gnss_ident_update: bool

PROP_GNSS_IDENT_UPDATE: whether fixes refresh the advertised node identity’s location.

§gnss_ident_precision: u8

PROP_GNSS_IDENT_PRECISION: how far the advertised location is clamped down from the fix.

§gnss_time_trust: bool

PROP_GNSS_TIME_TRUST: whether receiver-derived time may set the wall clock.

§ble_enabled: bool

PROP_BLE_ENABLED: whether the device is reachable over Bluetooth. Always false on a board without CAP_BLE.

Carried here for the same reason the receiver switch is: the mirror is published whenever the device domain moves, which is exactly the set of moments this can change, so the transport hears about a host write, a boot restore, a CMD_RST and a menu entry by one path instead of four.

Auto Trait Implementations§

Blanket Implementations§

§

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

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

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

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

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

§

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

Mutably borrows from an owned value. Read more
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

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

§

fn into(self) -> U

Calls U::from(self).

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

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
§

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

§

type Error = Infallible

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

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

Performs the conversion.
§

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

§

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

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

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

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V