Closed sebastian-bantel closed 2 years ago
custom function codes can be easily send by setting "pdu", "data_format" and "expected_length"
example caller code for custom function codes:
def Execute_CustomFunctionCode(customFunctionCode): pdu = struct.pack('>BBHHI', customFunctionCode, 0x01, 0x0000, 0xffff, 0x00000010) expected_length = 11 data_format = ">BHHH" regs = client.execute(0x01, defines.RAW, 0x0000, pdu = pdu, data_format = data_format, expected_length = expected_length) return regs
custom function codes can be easily send by setting "pdu", "data_format" and "expected_length"
example caller code for custom function codes: