The `read_coils` function in the `ModbusTcpClient` class of the `pymodbus.client.sync` module in Python is used to read the current state of a range of Modbus coils from a Modbus TCP server. It accepts the starting address of the coil range and the number of coils to read as input parameters and returns the corresponding coil states as a list. Coils are discrete output values in the Modbus protocol and are typically used for devices that can be turned on or off.
Python ModbusTcpClient.read_coils - 43 examples found. These are the top rated real world Python examples of pymodbus.client.sync.ModbusTcpClient.read_coils extracted from open source projects. You can rate examples to help us improve the quality of examples.