[Ser2net-devel] chardelay not doing anything?
Brought to you by:
cminyard
|
From: Rogan D. <ro...@da...> - 2023-07-09 13:47:03
|
Hi, I am trying to interact with a Lithium Battery Management System, accessible over RS232, using the BMS PACE protocol. When reading over direct serial, the application (https://github.com/tertiush/bmspace) works fine, but when going via ser2net, it reads less than the expected number of bytes, and errors out. Part of the problem is that the bmspace application simply does a single read, and expects everything to be there. I have fixed this by making bmspace keep reading until it sees the end of line character on the TCP socket, so that is not a huge problem. But it is my understanding that the chardelay group of options is supposed to be able to address this as well, by making ser2net read more into its buffer from the serial port before forwarding it to the TCP gensio. However, setting `chardelay-min` and `chardelay-scale` had absolutely no impact on the number of characters forwarded into the TCP connection and read by bmspace's solitary read. My configuration file is appended below. I did also try putting them under the "options:" stanza, but there was no difference in behaviour. Am I missing something in the intent of these parameters? Regards, Rogan default: name: chardelay value: true default: name: chardelay-scale value: 200 default: name: chardelay-min value: 65535 default: name: chardelay-max value: 500000 connection: &con0096 accepter: tcp,5000 enable: on options: kickolduser: true connector: serialdev(readbuf=512),/dev/ttyUSB0,9600n81 |