开云体育

Locked WiThrottle crash? #withrottleserver


 

Since 4.18 I've been running the console all the time during my session and tonight with 6 smartphone throttles running there were repeated Engine Driver / WiTHrottle drop outs. Androids seemed to recover automatically and iPhones dit not.?


Scanning through the console log I see this:?

2020-01-30 20:40:57,487 ptionhandler.UncaughtExceptionHandler ERROR - Uncaught Exception caught by jmri.util.exceptionhandler.UncaughtExceptionHandler [DeviceServer-335]

java.util.ConcurrentModificationException

at java.util.HashMap$HashIterator.nextNode(HashMap.java:1445)

at java.util.HashMap$KeyIterator.next(HashMap.java:1469)

at java.util.AbstractCollection.toArray(AbstractCollection.java:141)

at java.util.ArrayList.<init>(ArrayList.java:178)

at jmri.jmrit.withrottle.MultiThrottle.passActionsToControllers(MultiThrottle.java:212)

at jmri.jmrit.withrottle.MultiThrottle.handleMessage(MultiThrottle.java:70)

at jmri.jmrit.withrottle.DeviceServer.run(DeviceServer.java:218)

at java.lang.Thread.run(Thread.java:748)

2020-01-30 20:41:03,499 withrottle.FacelessServer ? ? ? ? ? ? INFO? - Creating new WiThrottle DeviceServer(socket) on port 12090, waiting for incoming connection... [WiThrottleServer]


Seems like WiThrottle crashed and re-started am I correct in seeing that. Also is it correct that the DeviceServer -335 is a little high 1h40" into a session with only 6 throttles?

With the session complete I will upgrade from 4.19.1 to 4.19.2 - will I see a difference I wonder?

Also I'm wondering about how the client act when the router is not connected to the internet (it's a stand alone) some phones were trying to use cell data - and might this be resulting in the phone dropping off of the withrottle server?

Thanks,
Dave


 

Hey Dave,
Yes, that looks like a crash in a WiThrottle Server instance. Do you have several of those at nearly the same time, or are they at different times?

Most recent Android versions try to use cell data, but that prevents the initial connection, I've not heard of it causing drops later. More info on that here:?

I don't see any recent changes to this code, so I'm not sure why you're seeing this now when you did not before.

--SteveT


 

Dave,?
If the problem persists, it would be helpful if you could enable WiThrottle server debugging and post your session.log file after some of these crashes. Steps to enable this are here:?
--SteveT


 

Thanks Steve I will run the debugging.

Would a WireShark log be at all helpful?

Dave


 

Dave,
I don't think a WireShark log will be helpful in diagnosing the crash. It is in JMRI.
I've created a GitHub issue to track it:?
While collecting the debug log, if you find a repeatable way to cause the error, please provide those steps.
--SteveT


 

Restarted the Mac and started JMRI (WiThrottle set to start with app). During JMRI start there was an iPhone running withrottle. This phone showed up as "unknown" (mac address was same one as when phone was connected earlier with proper name). When I see "Unknown" in the device name it means that its time for some buggy operation. Sometimes unknown and "Daves iPhone" appear together, but the iPhone throttle doesn't actually work.

Here's the short log:?
2020-02-03 20:23:56,147 util.Log4JUtil? ? ? ? ? ? ? ? ? ? ? ? INFO? - * JMRI log ** [main]
2020-02-03 20:23:57,418 util.Log4JUtil? ? ? ? ? ? ? ? ? ? ? ? INFO? - This log is appended to file: /Users/davebarraza/Library/Preferences/JMRI/log/messages.log [main]
2020-02-03 20:23:57,418 util.Log4JUtil? ? ? ? ? ? ? ? ? ? ? ? INFO? - This log is stored in file: /Users/davebarraza/Library/Preferences/JMRI/log/session.log [main]
2020-02-03 20:23:57,427 apps.Apps? ? ? ? ? ? ? ? ? ? ? ? ? ? ?INFO? - PanelPro version 4.19.2+R846b684 starts under Java 1.8.0_231 on Mac OS X x86_64 v10.15.3 at Mon Feb 03 20:23:57 EST 2020 [main]
2020-02-03 20:23:57,639 apps.Apps? ? ? ? ? ? ? ? ? ? ? ? ? ? ?INFO? - Starting with profile My_JMRI_Railroad.3e80976d [main]
2020-02-03 20:23:57,723 node.NodeIdentity? ? ? ? ? ? ? ? ? ? ?INFO? - Using c6f7c494-1590-4edf-83b6-fe19a3b8d450 as the JMRI storage identity for profile id 3e80976d [AWT-EventQueue-0]
2020-02-03 20:23:57,789 xml.AbstractSerialConnectionConfigXml INFO? - Starting to connect for "CAN" [main]
2020-02-03 20:24:00,157 gridconnect.GcSerialDriverAdapter? ? ?INFO? - cu.usbmodem1461301 port opened at 57600 baud, sees? DTR: true RTS: true DSR: false CTS: false? CD: false [main]
2020-02-03 20:24:00,218 xml.AbstractSerialConnectionConfigXml INFO? - Starting to connect for "SPROG Programmer" [main]
2020-02-03 20:24:00,237 serialdriver.SerialDriverAdapter? ? ? INFO? - cu.usbserial-feedcode port opened at 9600 baud, sees? DTR: true RTS: true DSR: true CTS: true? CD: false [main]
2020-02-03 20:24:00,252 xml.AbstractSerialConnectionConfigXml INFO? - Starting to connect for "LocoNet" [main]
2020-02-03 20:24:00,270 locobufferusb.LocoBufferUsbAdapter? ? INFO? - LocoBuffer-USB adapter set hardware flow control, mode=2 RTSCTS_OUT=2 RTSCTS_IN=1 [main]
2020-02-03 20:24:00,270 locobuffer.LocoBufferAdapter? ? ? ? ? INFO? - cu.usbserial-FTXPTBL0 port opened at 57600 baud with DTR: true RTS: true DSR: true CTS: true? CD: false [main]
2020-02-03 20:24:00,289 loconet.LnPacketizer? ? ? ? ? ? ? ? ? INFO? - lnPacketizer Started [main]
2020-02-03 20:24:00,290 xml.AbstractSerialConnectionConfigXml INFO? - Starting to connect for "LocoNet" [main]
2020-02-03 20:24:00,308 locobufferusb.LocoBufferUsbAdapter? ? INFO? - LocoBuffer-USB adapter set hardware flow control, mode=2 RTSCTS_OUT=2 RTSCTS_IN=1 [main]
2020-02-03 20:24:00,309 locobuffer.LocoBufferAdapter? ? ? ? ? INFO? - cu.usbserial-FTOYEDZV port opened at 57600 baud with DTR: true RTS: true DSR: true CTS: true? CD: false [main]
2020-02-03 20:24:00,310 loconet.LnPacketizer? ? ? ? ? ? ? ? ? INFO? - lnPacketizer Started [main]
2020-02-03 20:24:00,747 withrottle.FacelessServer? ? ? ? ? ? ?DEBUG - WiThrottle listening on TCP port: 12090 [WiThrottleServer]
2020-02-03 20:24:00,804 withrottle.FacelessServer? ? ? ? ? ? ?INFO? - Published ZeroConf service for 'new york and atlantic._withrottle._tcp.local.' on fe80:0:0:0:f81f:26a0:e5d0:778f%utun1:12090 [WiThrottleServer]
2020-02-03 20:24:00,804 withrottle.FacelessServer? ? ? ? ? ? ?INFO? - Published ZeroConf service for 'new york and atlantic._withrottle._tcp.local.' on fe80:0:0:0:b727:325d:9a87:7eb1%utun0:12090 [WiThrottleServer]
2020-02-03 20:24:00,806 withrottle.FacelessServer? ? ? ? ? ? ?INFO? - Published ZeroConf service for 'new york and atlantic._withrottle._tcp.local.' on fe80:0:0:0:4c67:9eff:fe2e:f985%awdl0:12090 [WiThrottleServer]
2020-02-03 20:24:00,806 withrottle.FacelessServer? ? ? ? ? ? ?INFO? - Published ZeroConf service for 'new york and atlantic._withrottle._tcp.local.' on fe80:0:0:0:0:0:0:1%lo0:12090 [WiThrottleServer]
2020-02-03 20:24:00,807 withrottle.FacelessServer? ? ? ? ? ? ?INFO? - Published ZeroConf service for 'new york and atlantic._withrottle._tcp.local.' on fe80:0:0:0:1494:f9da:15e4:6394%en1:12090 [WiThrottleServer]
2020-02-03 20:24:00,807 withrottle.FacelessServer? ? ? ? ? ? ?INFO? - Published ZeroConf service for 'new york and atlantic._withrottle._tcp.local.' on 192.168.1.102:12090 [WiThrottleServer]
2020-02-03 20:24:00,808 withrottle.FacelessServer? ? ? ? ? ? ?INFO? - Published ZeroConf service for 'new york and atlantic._withrottle._tcp.local.' on fe80:0:0:0:aede:48ff:fe00:1122%en6:12090 [WiThrottleServer]
2020-02-03 20:24:00,808 withrottle.FacelessServer? ? ? ? ? ? ?INFO? - Creating new WiThrottle DeviceServer(socket) on port 12090, waiting for incoming connection... [WiThrottleServer]
2020-02-03 20:24:06,247 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Creating input? stream reader for /fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [WiThrottleServer]
2020-02-03 20:24:06,251 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Creating output stream writer for /fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [WiThrottleServer]
2020-02-03 20:24:06,255 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: VN2.0? ? ? ? ? ? ? ? ?to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [WiThrottleServer]
2020-02-03 20:24:06,257 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: RL78]\[BA 67}|{67}|{S]\[BA 78}|{78}|{S]\[BR 1338}|{1338}|{L]\[BR 1350}|{1350}|{L]\[CP 5723}|{5723}|{L]\[CP 5726}|{5726}|{L]\[CSX 1303}|{1303}|{L]\[CSX 1304}|{1304}|{L]\[CSX 8058}|{8058}|{L]\[CSX 8199}|{8199}|{L]\[CSX_4042}|{4042}|{L]\[CSX_4049}|{4049}|{L]\[DCR 31452}|{1452}|{L]\[DH 7414}|{7414}|{L]\[DH 7418}|{7418}|{L]\[EMD 779}|{779}|{L]\[Korea Brass 7566}|{7566}|{L]\[LI 1500 old baseline}|{1500}|{L]\[LI 1501}|{1501}|{L]\[LI 151}|{151}|{L]\[LI 1558}|{1558}|{L]\[LI 158}|{158}|{L]\[LI 164}|{164}|{L]\[LI 172}|{172}|{L]\[LI 172 backup}|{172}|{L]\[LI 2007}|{2007}|{L]\[LI 202}|{202}|{L]\[LI 222}|{222}|{L]\[LI 224}|{224}|{L]\[LI 225}|{225}|{L]\[LI 226}|{226}|{L]\[LI 229}|{229}|{L]\[LI 254}|{254}|{L]\[LI 256}|{256}|{L]\[LI 276}|{276}|{L]\[LI 3101}|{3101}|{L]\[LI 3121}|{3121}|{L]\[LI 4137}|{4137}|{L]\[LI 4137 blowedup}|{3}|{S]\[LI 4145 New}|{4145}|{L]\[LI 4145 old baseline}|{4145}|{L]\[LI 464}|{464}|{L]\[LI 466}|{466}|{L]\[MW-418}|{628}|{L]\[MW-628}|{628}|{L]\[NJT 4428}|{4428}|{L]\[NJT 7001}|{7001}|{L]\[NYA 151}|{151}|{L]\[NYA 156}|{156}|{L]\[NYA 159}|{159}|{L]\[NYA 261}|{261}|{L]\[NYA 261(spare)}|{261}|{L]\[NYA 268}|{268}|{L]\[NYA 270}|{270}|{L]\[NYA 271}|{271}|{L]\[PKP 1028}|{1028}|{L]\[PNCX 3634}|{3634}|{L]\[PRR 88030}|{8030}|{L]\[PSX-AR 1125T}|{988}|{L]\[PW 2009}|{2009}|{L]\[PW 3902}|{3902}|{L]\[PW 4005}|{4005}|{L]\[PW 4301}|{4301}|{L]\[PW 4302}|{4302}|{L]\[QLN11004}|{11004}|{L]\[QLN11004v2}|{11004}|{L]\[QLN11005}|{11005}|{L]\[QLN11006}|{11006}|{L]\[QLN11007}|{11007}|{L]\[S057ML}|{12023}|{L]\[S079ML}|{12101}|{L]\[SignalMan Default}|{9999}|{L]\[SignalMan in Test Lab 11101}|{11101}|{L]\[SLRG 8542}|{8542}|{L]\[SNC 8524}|{8524}|{L]\[SP 4809}|{4809}|{L]\[Vaughan Black Porter}|{1001}|{L]\[William Penn}|{6}|{S? to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [WiThrottleServer]
2020-02-03 20:24:06,258 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Track Power valid. [WiThrottleServer]
2020-02-03 20:24:06,259 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: PPA2? ? ? ? ? ? ? ? ? to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [WiThrottleServer]
2020-02-03 20:24:06,259 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Turnout Controller valid. [WiThrottleServer]
2020-02-03 20:24:06,263 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: PTT]\[Turnouts}|{Turnout]\[Closed}|{2]\[Thrown}|{4? to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [WiThrottleServer]
2020-02-03 20:24:06,267 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Route Controller valid. [WiThrottleServer]
2020-02-03 20:24:06,268 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: PRT]\[Routes}|{Route]\[Active}|{2]\[Inactive}|{4? to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [WiThrottleServer]
2020-02-03 20:24:06,269 withrottle.ConsistController? ? ? ? ? DEBUG - Using JMRIConsisting [WiThrottleServer]
2020-02-03 20:24:06,270 consisttool.ConsistFile? ? ? ? ? ? ? ?INFO? - Consist file does not exist.? One will be created if necessary. [WiThrottleServer]
2020-02-03 20:24:06,270 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Consist Controller valid. [WiThrottleServer]
2020-02-03 20:24:06,271 withrottle.ConsistController? ? ? ? ? DEBUG - 0 consists found. [WiThrottleServer]
2020-02-03 20:24:06,271 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: RCC0? ? ? ? ? ? ? ? ? to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [WiThrottleServer]
2020-02-03 20:24:06,272 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Fast Clock Controller valid. [WiThrottleServer]
2020-02-03 20:24:06,272 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: PFT1580761446<;>1.0? ?to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [WiThrottleServer]
2020-02-03 20:24:06,272 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: PW12080? ? ? ? ? ? ? ?to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [WiThrottleServer]
2020-02-03 20:24:06,273 withrottle.FacelessServer? ? ? ? ? ? ?DEBUG - Starting thread 'DeviceServer-1' [WiThrottleServer]
2020-02-03 20:24:06,273 withrottle.FacelessServer? ? ? ? ? ? ?INFO? - Creating new WiThrottle DeviceServer(socket) on port 12090, waiting for incoming connection... [WiThrottleServer]
2020-02-03 20:24:06,273 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Notify Device Add [DeviceServer-1]
2020-02-03 20:24:06,274 ptionhandler.UncaughtExceptionHandler ERROR - Uncaught Exception caught by jmri.util.exceptionhandler.UncaughtExceptionHandler [DeviceServer-1]
java.lang.NullPointerException
at jmri.jmrit.withrottle.UserInterface.notifyDeviceConnected(UserInterface.java:265)
at jmri.jmrit.withrottle.DeviceServer.run(DeviceServer.java:170)
at java.lang.Thread.run(Thread.java:748)
2020-02-03 20:24:31,097 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: PPA1? ? ? ? ? ? ? ? ? to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [AWT-EventQueue-0]
2020-02-03 20:24:31,213 util.FileUtilSupport? ? ? ? ? ? ? ? ? INFO? - File path program: is /Applications/JMRI/ [main]
2020-02-03 20:24:31,214 util.FileUtilSupport? ? ? ? ? ? ? ? ? INFO? - File path preference: is /Users/davebarraza/Dropbox/JMRI/NY&A Model Railroad/ [main]
2020-02-03 20:24:31,214 util.FileUtilSupport? ? ? ? ? ? ? ? ? INFO? - File path profile: is /Users/davebarraza/Dropbox/JMRI/NY&A Model Railroad/ [main]
2020-02-03 20:24:31,214 util.FileUtilSupport? ? ? ? ? ? ? ? ? INFO? - File path settings: is /Users/davebarraza/Library/Preferences/JMRI/ [main]
2020-02-03 20:24:31,214 util.FileUtilSupport? ? ? ? ? ? ? ? ? INFO? - File path home: is /Users/davebarraza/ [main]
2020-02-03 20:24:31,214 util.FileUtilSupport? ? ? ? ? ? ? ? ? INFO? - File path scripts: is /Users/davebarraza/Dropbox/JMRI/Jython/ [main]
2020-02-03 20:24:31,544 server.WebServer? ? ? ? ? ? ? ? ? ? ? INFO? - Starting Web Server on port 12080 [WebServer]
2020-02-03 20:24:31,735 PanelPro.PanelPro? ? ? ? ? ? ? ? ? ? ?INFO? - Main initialization done [main]
2020-02-03 20:24:32,195 server.WebServer? ? ? ? ? ? ? ? ? ? ? INFO? - Starting ZeroConfService _http._tcp.local for Web Server with properties {path=/, json=5.3.0} [WebServer]
2020-02-03 20:25:00,382 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: PFT1580761500<;>1.0? ?to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [AWT-EventQueue-0]
2020-02-03 20:25:00,382 withrottle.DeviceServer? ? ? ? ? ? ? ?DEBUG - Sent: PFT1580761500<;>1.0? ?to? Unknown/fe80:0:0:0:835:6d53:56b4:41dc%7:52404 [AWT-EventQueue-0]


 

Thanks, Dave.
This one shows a completely different crash, seemingly from an attempt to update the WiThrottle window before it has been fully prepared.?
Can you provide a bit more context here? Does this occur every time you restart JMRI with a WiThrottle client connected? What happens if you restart the client?
Also, were you able to duplicate the earlier crash?
--SteveT


 

Sorry for my confusion -What am I looking for to verify that I have duplicated the original crash, a specific error code of some kind?

I think the earlier crash may be related to 6-7 users at once - at least that was true when I captured it.

I will try to duplicate the results from the reboot scenario.

Restarting the client results in a quasi-connected state on the phone. The screen changes from the "connect" screen to the throttle screen, but it is non functional - for example you are not able to acquire a DCC address, or toggle the layout power, and the web server option does not appear.

Dave


 

On Tue, Feb 4, 2020 at 08:10 AM, Dave Barraza wrote:
What am I looking for to verify that I have duplicated the original crash, a specific error code of some kind?
I cannot duplicate either of these crashes, so it's very hard to verify potential fixes.
What would be perfect is if you could describe a repeatable scenario where one or both occur, so that I can then repeat those steps and see the error.
It would also be helpful to get the session.log file after a session where one or both of these errors occurred. You can email them to me or post them online.
--SteveT


 

Update:
I have pushed possible fixes for both of these, available in the Development version here:?
Dave, I would appreciate it if you could try this version and advise results.
I was able to duplicate the 2nd crash, where a client connects/reconnects before the WiThrottle Server window is shown.
I still could not duplicate the 1st crash to verify that fix.
--SteveT


 

Hello @ all
?
someone has news about this problem, which i have too.
?
since the update of Engine Driver (v2.24.93), JMRI (vJMRI.4.18 + R37ad3d0), Android (v7.0) unable to connect. Deadlines exceeded.
Even when deactivating the GSM network.
?
The problem is the same on Linux, W10 and RPi3B +.
?
Thank you


 

FCOT2002,
This sounds like a very different problem from the server-side crash being discussed in this thread. Please create another thread, or contact me directly via email (mstevetodd at gmail), to work on this new problem.
--SteveT


 

Hello,

Ok Steve I will open a new thread. Thank's.?


 

Update:

With 4.19.2 running I had a session with 9 operators, all with various smartphones, and everything was pretty much perfect. (The "Stress Test" I was mentioning.)

The crew was 100% *different* from the one where throttles had been problematic. This begs a question. is it plausible that there may be one person's smartphone which may be disrupting the system?


Dave


 

开云体育

At the session with the problems were their any visitors or other people around that had phones but we not trying to run withrottle?

Jim




On Feb 14, 2020, at 18:33, Dave Barraza <dave@...> wrote:

?Update:

With 4.19.2 running I had a session with 9 operators, all with various smartphones, and everything was pretty much perfect. (The "Stress Test" I was mentioning.)

The crew was 100% *different* from the one where throttles had been problematic. This begs a question. is it plausible that there may be one person's smartphone which may be disrupting the system?


Dave


 

开云体育

Dave Barraza wrote: “The crew was 100% *different* from the one where throttles had been problematic. This begs a question. is it plausible that there may be one person's smartphone which may be disrupting the system?”

?

Our club had some of these drop out / disconnect WiThrottle Server problems a few years back. No one in this group was able to pin point the cause. I always suspected there was one individual with an i-Phone who was a bad player. Interestingly, we haven’t had any problems since that person stopped showing up. Coincidence?

?

Mark Granville


 

were their any visitors or other people around that had phones but we not trying to run withrottle

no, dedicated router with no connection to the www.


 

开云体育

Doesn’t need to be connected to the web. ?Just having them in there pocket and turned on will tie up the access point because it sees those devices and has to make a socket available in case someone were to try and connect . ?

I have found that most home WiFi access points will start to fall apart when about 25 devices are in the area.?

Jim




On Feb 15, 2020, at 18:38, Dave Barraza <dave@...> wrote:

?were their any visitors or other people around that had phones but we not trying to run withrottle

no, dedicated router with no connection to the www.