Class FC1ReadCoilsTask
java.lang.Object
io.openems.edge.bridge.modbus.api.task.AbstractTask<com.ghgande.j2mod.modbus.msg.ReadCoilsRequest,com.ghgande.j2mod.modbus.msg.ReadCoilsResponse>
io.openems.edge.bridge.modbus.api.task.AbstractReadTask<com.ghgande.j2mod.modbus.msg.ReadCoilsRequest,com.ghgande.j2mod.modbus.msg.ReadCoilsResponse,CoilElement,Boolean>
io.openems.edge.bridge.modbus.api.task.AbstractReadDigitalInputsTask<com.ghgande.j2mod.modbus.msg.ReadCoilsRequest,com.ghgande.j2mod.modbus.msg.ReadCoilsResponse>
io.openems.edge.bridge.modbus.api.task.FC1ReadCoilsTask
- All Implemented Interfaces:
ReadTask
,Task
,ManagedTask
public class FC1ReadCoilsTask
extends AbstractReadDigitalInputsTask<com.ghgande.j2mod.modbus.msg.ReadCoilsRequest,com.ghgande.j2mod.modbus.msg.ReadCoilsResponse>
Implements a Read Coils Task, implementing Modbus function code 1
(http://www.simplymodbus.ca/FC01.htm).
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.openems.edge.bridge.modbus.api.task.Task
Task.ExecuteState
-
Field Summary
Fields inherited from class io.openems.edge.bridge.modbus.api.task.AbstractTask
elements, length, name, responseClazz, startAddress
-
Constructor Summary
ConstructorDescriptionFC1ReadCoilsTask
(int startAddress, Priority priority, CoilElement... elements) -
Method Summary
Modifier and TypeMethodDescriptionprotected com.ghgande.j2mod.modbus.msg.ReadCoilsRequest
Factory for aModbusRequest
.protected com.ghgande.j2mod.modbus.util.BitVector
parseBitResponse
(com.ghgande.j2mod.modbus.msg.ReadCoilsResponse response) Methods inherited from class io.openems.edge.bridge.modbus.api.task.AbstractReadDigitalInputsTask
calculateNextPosition, handleResponse, parseResponse, payloadToString, toBooleanArray
Methods inherited from class io.openems.edge.bridge.modbus.api.task.AbstractReadTask
execute, getPriority, payloadToString
Methods inherited from class io.openems.edge.bridge.modbus.api.task.AbstractTask
deactivate, debug, executeRequest, getElements, getLength, getLogVerbosity, getParent, getStartAddress, logError, logInfo, logRequest, setParent, toLogMessage, toLogMessage, toLogMessage, toLogMessage
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.openems.edge.bridge.modbus.api.task.Task
deactivate, getElements, getLength, getParent, getStartAddress, setParent
-
Constructor Details
-
FC1ReadCoilsTask
-
-
Method Details
-
createModbusRequest
protected com.ghgande.j2mod.modbus.msg.ReadCoilsRequest createModbusRequest()Description copied from class:AbstractReadTask
Factory for aModbusRequest
.- Specified by:
createModbusRequest
in classAbstractReadTask<com.ghgande.j2mod.modbus.msg.ReadCoilsRequest,
com.ghgande.j2mod.modbus.msg.ReadCoilsResponse, CoilElement, Boolean> - Returns:
- a new
ModbusRequest
-
parseBitResponse
protected com.ghgande.j2mod.modbus.util.BitVector parseBitResponse(com.ghgande.j2mod.modbus.msg.ReadCoilsResponse response) - Specified by:
parseBitResponse
in classAbstractReadDigitalInputsTask<com.ghgande.j2mod.modbus.msg.ReadCoilsRequest,
com.ghgande.j2mod.modbus.msg.ReadCoilsResponse>
-