5.3.1.17.6.5. cli.com.parameter.ModbusParameter

class cli.com.parameter.ModbusParameter(host: str, port: int = 502, timeout: int = 1, retries: int = 3, ignore: bool = False)

Bases: object

Immutable configuration for a Modbus TCP connection.

Holds connection parameters used by a Modbus client.

host

IP address or hostname of the Modbus server.

Type:

str

port

TCP port of the Modbus server. Defaults to 502.

Type:

int

timeout

Request/response timeout in seconds. Defaults to 1.

Type:

int

retries

Number of retry attempts on transient I/O errors. Defaults to 3.

Type:

int

ignore

If True, specific exceptions are ignored.

Type:

bool

Notes

Instances are immutable (frozen=True) and use __slots__ for reduced memory footprint.