diff --git a/src/pyhoff/__init__.py b/src/pyhoff/__init__.py index 0d8e90b..7cc2f04 100644 --- a/src/pyhoff/__init__.py +++ b/src/pyhoff/__init__.py @@ -225,19 +225,10 @@ class BusCoupler(): """ Base class for ModBus TCP bus coupler - Args: - host: ip or hostname of the bus coupler - port: port of the modbus host - debug: outputs modbus debug information - timeout: timeout for waiting for the device response - watchdog: time in seconds after the device sets all outputs to - default state. A value of 0 deactivates the watchdog. - debug: If True, debug information is printed. - Attributes: - bus_terminals: A list of bus terminal classes according to the + bus_terminals (list[BusTerminal]): A list of bus terminal classes according to the connected terminals. - modbus: The underlying modbus client used for the connection. + modbus (SimpleModbusClient): The underlying modbus client used for the connection. """ def __init__(self, host: str, port: int = 502, bus_terminals: Iterable[type[BusTerminal]] = [], diff --git a/src/pyhoff/modbus.py b/src/pyhoff/modbus.py index 50941ea..15a1166 100644 --- a/src/pyhoff/modbus.py +++ b/src/pyhoff/modbus.py @@ -48,20 +48,13 @@ class SimpleModbusClient: """ A simple Modbus TCP client - Args: - host: hostname or IP address - port: server port - unit_id: ModBus id - timeout: socket timeout in seconds - debug: if True prints out transmitted and received bytes in hex - Attributes: - host: hostname or IP address - port: server port - unit_id: ModBus id - timeout: socket timeout in seconds - last_error: contains last error message or empty string if no error occurred - debug: if True prints out transmitted and received bytes in hex + host (str): hostname or IP address + port (int): server port + unit_id (int): ModBus id + timeout (float): socket timeout in seconds + last_error (str): contains last error message or empty string if no error occurred + debug (bool): if True prints out transmitted and received bytes in hex """