[−][src]Function async_resol_vbus::id_hash
pub fn id_hash<H>(h: &H) -> u64 where
H: IdHash,
Calculate the identification hash for a given VBus data value.
Examples
use resol_vbus::{Header, id_hash}; use resol_vbus::utils::utc_timestamp; let header = Header { timestamp: utc_timestamp(1485688933), channel: 0x11, destination_address: 0x1213, source_address: 0x1415, protocol_version: 0x16, }; assert_eq!(8369676560183260683, id_hash(&header));