I am using the SerialOpen() routine in digi_serial.py and no matter what I pass it for parameters the gateway always has software flow control enabled. If I select N for none or H for hardware, the web UI shows XON XOFF and shuts down when a XOFF character (13h) is received. Is there any way to disable this?
RTS and CTS flow control can be disabled using D6 and D7 commands.
Thanks, but RTS and CTS is “hardware” flow control, the gateway allows me to turn that on or off, the gateway does NOT allow me to turn “software” flow control off, it’s always on and I need it off.
Here is the answer for your question-
The character 0x13 (ControlS or DC3 or XOFF) when sent across the serial link tells the other side to stop sending. The character 0x11 (Control-Q or DC1 or XON) tells the other side to resume sending. When software ﬂow control is in use, it follows that these characters cannot be sent as part of the data stream.
When sending API packets it isn’t possible to avoid the need to include the software control characters. For instance, checksums and addresses can contain any values. Therefore the API escape mode (AP=2) exists. In this mode the character 0x7d is deﬁned as the escape character. When a host wants to transmit 0x11 or 0x13 it transmits the escape character ﬁrst, and then the desired character XORed with 0x20.