pub const fn decode_type(pkt_type: u8) -> (u8, u8)
Expand description
Decodes packed type. Returns packet type
and flags
.
Example:
use mid_net::utils::{
decode_type,
encode_type,
};
assert_eq!(decode_type(encode_type(10, 0b111)), (10, 0b111));