diff --git a/domo_proto/src/packet/packet_data.rs b/domo_proto/src/packet/packet_data.rs index 0c47bf7..b676372 100644 --- a/domo_proto/src/packet/packet_data.rs +++ b/domo_proto/src/packet/packet_data.rs @@ -1,4 +1,5 @@ use std::io; +use std::os::linux::raw; use crate::commands::property_control::PropertyControlCommand; use crate::commands::node_management::NodeManagementCommand; use crate::commands::raw_data_transmission::RawDataTransmission; @@ -40,7 +41,7 @@ impl TryFrom for PacketData { 0x0 => Ok(PacketData::NodeManagement(NodeManagementCommand::try_from(raw_packet)?)), 0x1 => Ok(PacketData::PropertyControl(PropertyControlCommand::try_from(raw_packet)?)), 0xF => Ok(PacketData::RawDataTransmission(RawDataTransmission::try_from(raw_packet)?)), - _ => Err(io::Error::new(io::ErrorKind::InvalidInput, "command group is unsupported")) + _ => Ok(PacketData::Unknown(raw_packet.data)) } } } \ No newline at end of file