From f67963c8a4078ac42e36e0efcaa1efa8560e1ade Mon Sep 17 00:00:00 2001 From: Liam Kinne Date: Thu, 21 Mar 2024 05:56:46 +1000 Subject: [PATCH] debug derives --- src/client.rs | 1 + src/server/mod.rs | 1 + src/server/storage.rs | 1 + 3 files changed, 3 insertions(+) diff --git a/src/client.rs b/src/client.rs index 504fa64..7f43b5a 100644 --- a/src/client.rs +++ b/src/client.rs @@ -7,6 +7,7 @@ use crate::{calc_crc16, calc_lrc, ErrorKind, ModbusFrameBuf, ModbusProto, Vector /// Modbus client generator/processor /// /// One object can be used for multiple calls +#[derive(Debug)] #[cfg_attr(feature = "defmt", derive(defmt::Format))] pub struct ModbusRequest { /// transaction id, (TCP/UDP only), default: 1. To change, set the value manually diff --git a/src/server/mod.rs b/src/server/mod.rs index c0b2383..7ce2382 100644 --- a/src/server/mod.rs +++ b/src/server/mod.rs @@ -62,6 +62,7 @@ macro_rules! tcp_response_set_data_len { }; } +#[derive(Debug)] #[cfg_attr(feature = "defmt", derive(defmt::Format))] pub struct ModbusFrame<'a, V: VectorTrait> { pub unit_id: u8, diff --git a/src/server/storage.rs b/src/server/storage.rs index 08d6907..8a38e39 100644 --- a/src/server/storage.rs +++ b/src/server/storage.rs @@ -20,6 +20,7 @@ pub type ModbusStorageFull = /// Contains standard Modbus register contexts #[allow(clippy::module_name_repetitions)] +#[derive(Debug)] #[cfg_attr(feature = "with_serde", derive(Deserialize, Serialize))] #[cfg_attr(feature = "with_bincode", derive(Decode, Encode))] #[cfg_attr(feature = "defmt", derive(defmt::Format))]