Skip to content
Snippets Groups Projects
Commit e2bcf722 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

If configured COM port byte size is less than 8, strip high 8-n bits on RX

Some USB modems (reportedly, USRobotics USB modem) don't strip the parity bit
of data received from modem connections operating in < 8 bit modes
(e.g. 7-E-1), as is normally don't with a modem connected to a UART, so we'll
do that stripping (forcing to 0) here, as recommended by Deuce.

Nelgin, if you're doing some manually stripping of the 7th bit bytes received
from 7-E-1 connected modems and then sent to your server/BBS over TCP, you
shouldn't need to do that now.
parent 2382d298
No related branches found
No related tags found
No related merge requests found
......@@ -985,6 +985,8 @@ void input_thread(void* arg)
YIELD();
continue;
}
if(com_byte_size < 8)
ch &= (1 << com_byte_size) - 1;
if(com_debug)
lprintf(LOG_DEBUG, "Received char from COM port (%s): %s", com_dev, chr(ch, dbg, sizeof(dbg)));
if(telnet && ch==TELNET_IAC)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment