The `close` method in `ModbusTcpClient` class of the `pymodbus` library is used to close the connection with the Modbus TCP server. It terminates the established connection and releases any allocated resources associated with the client. This method is typically called when the communication with the server is no longer required or when the client needs to disconnect from the server. Closing the client ensures proper cleanup and allows the server to handle other incoming connections efficiently.
Python ModbusTcpClient.close - 60 examples found. These are the top rated real world Python examples of pymodbus.client.sync.ModbusTcpClient.close extracted from open source projects. You can rate examples to help us improve the quality of examples.