|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.wimpi.modbus.msg.ModbusMessageImpl net.wimpi.modbus.msg.ModbusResponse net.wimpi.modbus.msg.WriteMultipleCoilsResponse
public final class WriteMultipleCoilsResponse
Class implementing a WriteMultipleCoilsResponse. The implementation directly correlates with the class 1 function read coils (FC 15). It encapsulates the corresponding response message.
Coils are understood as bits that can be manipulated (i.e. set or unset).
Constructor Summary | |
---|---|
WriteMultipleCoilsResponse()
Constructs a new WriteMultipleCoilsResponse instance. |
|
WriteMultipleCoilsResponse(int ref,
int count)
Constructs a new WriteMultipleCoilsResponse instance with a given count of coils (i.e. |
Method Summary | |
---|---|
int |
getBitCount()
Returns the number of bits (i.e. |
int |
getReference()
Returns the reference of the register to to start reading from with this WriteMultipleCoilsRequest. |
void |
readData(DataInput din)
Reads the subclass specific data from the given DataInput instance. |
void |
setBitCount(int count)
Sets the number of bits (i.e. |
void |
writeData(DataOutput dout)
Writes the subclass specific data to the given DataOutput. |
Methods inherited from class net.wimpi.modbus.msg.ModbusResponse |
---|
createModbusResponse |
Methods inherited from class net.wimpi.modbus.msg.ModbusMessageImpl |
---|
getDataLength, getFunctionCode, getHexMessage, getOutputLength, getProtocolID, getTransactionID, getUnitID, isHeadless, readFrom, setDataLength, setHeadless, setProtocolID, setTransactionID, setUnitID, writeTo |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public WriteMultipleCoilsResponse()
public WriteMultipleCoilsResponse(int ref, int count)
ref
- the offset to begin writing from.count
- the number of bits to be read.Method Detail |
---|
public int getReference()
public int getBitCount()
public void setBitCount(int count)
count
- the number of bits in the response.public void writeData(DataOutput dout) throws IOException
ModbusMessageImpl
writeData
in class ModbusMessageImpl
dout
- the DataOutput to be written to.
IOException
- if an I/O related error occurs.public void readData(DataInput din) throws IOException
ModbusMessageImpl
readData
in class ModbusMessageImpl
din
- the DataInput to read from.
IOException
- if an I/O related error occurs.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |