Sets the TCP port number of the Modbus slave device.
BusProtocolErrors.FTALK_SUCCESS on success or error code. See BusProtocolErrors for possible error codes.
Usually the port number remains unchanged and defaults to 502 for Modbus/TCP and 1100 for RTU over TCP. However if the port number has to be different this function must be called before opening the connection with openProtocol().
Note A protocol must be closed in order to configure it.
MbusTcpMasterProtocol Class | FieldTalk Namespace