pub struct DataReceivedResult {Show 17 fields
pub source_node: NodeId,
pub is_emergency: bool,
pub is_ack: bool,
pub counter_changed: bool,
pub emergency_changed: bool,
pub total_count: u64,
pub event_timestamp: u64,
pub relay_data: Option<Vec<u8>>,
pub origin_node: Option<NodeId>,
pub hop_count: u8,
pub callsign: Option<String>,
pub battery_percent: Option<u8>,
pub heart_rate: Option<u8>,
pub event_type: Option<u8>,
pub latitude: Option<f32>,
pub longitude: Option<f32>,
pub altitude: Option<f32>,
}Expand description
Result from receiving BLE data
Fields§
§source_node: NodeIdNode that sent this data
is_emergency: boolWhether this contained an emergency event
is_ack: boolWhether this contained an ACK event
counter_changed: boolWhether the counter changed (new data)
emergency_changed: boolWhether emergency state changed (new emergency or ACK updates)
total_count: u64Updated total count
event_timestamp: u64Event timestamp (if event present) - use to detect duplicate events
relay_data: Option<Vec<u8>>Data to relay to other peers (if multi-hop relay is enabled)
When present, the platform adapter should send this data to peers
returned by get_relay_targets(Some(source_node)).
origin_node: Option<NodeId>Origin node for relay (may differ from source_node for relayed messages)
hop_count: u8Current hop count (for relayed messages)
callsign: Option<String>Sender’s callsign (up to 12 chars)
battery_percent: Option<u8>Sender’s battery percentage (0-100)
heart_rate: Option<u8>Sender’s heart rate (BPM)
event_type: Option<u8>Sender’s event type (from PeripheralEvent)
latitude: Option<f32>Sender’s latitude
longitude: Option<f32>Sender’s longitude
altitude: Option<f32>Sender’s altitude (meters)
Trait Implementations§
Source§impl Clone for DataReceivedResult
impl Clone for DataReceivedResult
Source§fn clone(&self) -> DataReceivedResult
fn clone(&self) -> DataReceivedResult
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more