Closed Miq1 closed 3 years ago
I can narrow it down now to a situation, where the Modbus AsyncServer
is trying to send a log line to the Telnet AsyncServer
. So from within a onData()
Modbus callback I am trying to have the Telnet server do a client.write()
.
Could this provoke a race condition between the two AsyncServer
s that is 'solved' by the WDT?
The reason was:
The solution was to write in the callback function into a buffer and have the Telnet server work on the buffer later, after the callback had returned.
I have an application here that needs to serve three separate TCP ports - 23 (Telnet), 80 (HTTP) and 502 (Modbus). I have set up three
AsyncServer
instances in parallel. While this seemed to work at the beginning, I am experiencing crashes now, if I get a Modbus request while a Telnet output is done.Is it valid at all to run more than one AsyncServer at the same time?