pub struct ModbusTcpConfig {
pub host: String<64>,
pub port: u16,
pub connection_timeout_ms: u32,
pub response_timeout_ms: u32,
pub retry_attempts: u8,
pub retry_backoff_strategy: BackoffStrategy,
pub retry_jitter_strategy: JitterStrategy,
pub retry_random_fn: Option<RetryRandomFn>,
}Expand description
Configuration parameters for establishing a Modbus TCP connection.
Fields§
§host: String<64>The hostname or IP address of the Modbus TCP server to connect to.
port: u16The TCP port number on which the Modbus server is listening (default is typically 502).
connection_timeout_ms: u32Timeout for establishing a connection in milliseconds
response_timeout_ms: u32Timeout for waiting for a response in milliseconds
retry_attempts: u8Number of retry attempts for failed operations
retry_backoff_strategy: BackoffStrategyBackoff strategy used when scheduling retries.
retry_jitter_strategy: JitterStrategyOptional jitter strategy applied on top of retry backoff delay.
retry_random_fn: Option<RetryRandomFn>Optional application-provided random callback used by jitter.
Implementations§
Trait Implementations§
Source§impl Clone for ModbusTcpConfig
impl Clone for ModbusTcpConfig
Source§fn clone(&self) -> ModbusTcpConfig
fn clone(&self) -> ModbusTcpConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ModbusTcpConfig
impl RefUnwindSafe for ModbusTcpConfig
impl Send for ModbusTcpConfig
impl Sync for ModbusTcpConfig
impl Unpin for ModbusTcpConfig
impl UnsafeUnpin for ModbusTcpConfig
impl UnwindSafe for ModbusTcpConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more