lbServer and Rocrail
lucadentella opened this issue · 5 comments
Hi!
I'm trying to use the included lbServer with Rocrail.
The esp32 devboard has IP address 192.168.1.4 and I can see the mDNS advertise (_lbserver._tcp.)
This is my configuration in Rocrail:
<digint lib="loconet" iid="lbServer" device="com1" host="192.168.1.4" port="1234" localip="" swtime="250" bps="19200" flow="no" ctsretry="1000" sublib="socket" fbmod="0" fastclock="true" absent="false" stress="false" guid="6045CBC7069B20210406183454540000" libpath=".">
When I run rocrail, I can see the connection attempt:
20210406.184037.715 r9999W lnlbsr lbtcp 0040 trying to connect to 192.168.1.4:1234...
and the corresponding log in the serial monitor:
[I][LbServer.h:41] operator()(): onConnect: New client(3FFD3EFC): 192.168.1.5
but nothing more... the connection seems "pending" forever...
Thanks!
In addition: I made a test with PanelPro (JMRI), with a similar configuration (LocoNet over TCP).
Again when I run the software I can see the incoming connection:
[I][LbServer.h:41] operator()(): onConnect: New client(3FFD3EBC): 192.168.1.5
but the communication is not established:
- if I try to control a locomotive, I get a "timeout error" from PanelPro
- if I press the button that should send the status of sensor 1 ("reporting sensor 1"), I cannot get it in PanelPro
- if I try to turn on the power of my layout using PanelPro, nothing happens
Thanks again!
... to complete my tests: with Engine Driver (android app using WiThrottle protocol) I can control locomotives, power, turnouts... so with WiThrottle the command stations works fine!
Hi and thanks for report.
Yes, you are correct, for some reasson LbServer does not work and I see the same behavior with JMRI. I'll look into it in the next few days. Meanwhile, you can try previous version made before I rewrote LbServer with AsyncTCP library. Probably this one would work: https://github.com/positron96/LocoNetControlStation/tree/81a7c9c0d75cc1c3b0dbd959d8f647bf62077d4d
Should be working now.
Hi! Yes, it works, thanks!