canboat_rs/pgns/
simnet_set_engine_and_tank_configuration.rs1use crate::pgn_types::PgnType;
2pub const LENGTH: usize = 2usize;
3pub const PGN: u32 = 130835u32;
4use bitfield::bitfield;
5bitfield! {
6 #[doc = "Simnet: Set Engine and Tank Configuration"] pub struct
7 SimnetSetEngineAndTankConfiguration([u8]); impl Debug; u32; pub manufacturer_code, _
8 : 10usize, 0usize; pub reserved, _ : 12usize, 11usize; pub industry_code, _ :
9 15usize, 13usize;
10}
11impl SimnetSetEngineAndTankConfiguration<&[u8]> {
12 pub fn is_match(&self, pgn: u32) -> bool {
13 130835u32 == pgn && self.manufacturer_code() == 1857u32
14 && self.industry_code() == 4u32
15 }
16 pub fn get_pgn() -> u32 {
17 130835u32
18 }
19 pub fn get_message_type() -> PgnType {
20 PgnType::Fast
21 }
22}