MCPcopy Index your code
hub / github.com/secdev/scapy / ModbusPDU02ReadDiscreteInputsResponse

Class ModbusPDU02ReadDiscreteInputsResponse

scapy/contrib/modbus.py:71–81  ·  view source on GitHub ↗

inputStatus: result is represented as bytes, padded with 0 to have a integer number of bytes. The field does not parse this result and present the bytes directly

Source from the content-addressed store, hash-verified

69
70
71class ModbusPDU02ReadDiscreteInputsResponse(Packet):
72 """ inputStatus: result is represented as bytes, padded with 0 to have a
73 integer number of bytes. The field does not parse this result and
74 present the bytes directly
75 """
76 name = "Read Discrete Inputs Response"
77 fields_desc = [XByteField("funcCode", 0x02),
78 BitFieldLenField("byteCount", None, 8,
79 count_of="inputStatus"),
80 FieldListField("inputStatus", [0x00], ByteField("", 0x00),
81 count_from=lambda pkt: pkt.byteCount)]
82
83
84class ModbusPDU02ReadDiscreteInputsError(Packet):

Callers

nothing calls this directly

Calls 4

XByteFieldClass · 0.90
BitFieldLenFieldClass · 0.90
FieldListFieldClass · 0.90
ByteFieldClass · 0.90

Tested by

no test coverage detected