¿ªÔÆÌåÓý

Locked Communication Port Issues #nce


 

I'm having issues with the communication port. It looks like JMRI is not getting the NCE EPROM version correctly.?
?
My JMRI is both 5.8 and 5.9.2
My operating system is Windows 10 on all computers.
?
I use W610 serial servers, see
?
This allows me to have several computers connected to my NCE configuration.
?
My NCE is configured, such, two PHP 5am systems. One command station is a programmer only.
The other PHP is mainline only, with the two boosters.
NCE has the latest EPROM.
?
Each computer has virtual communication software installed.
?
Com2 is directed to 192.168.1.2 port xxxx
Com3 is directed to 192.168.1.3 port xxxx
and so on...
?
Com3 is connected to the command station for programming only.
Com4 is connected to the command station for mainline only.
?
The benefits of this arrangement are any computer has access to the NCE system with threading. If computer 1 sends AA command, them computer 1 get the repsonce 6.2.3 (or 6.3.2, my memory)
?
If JMRI does not get the right response, it tries again.
?
Here is what I' getting.
?
13:27:16,565 apps.util.Log4JUtil ? ? ? ? ? ? ? ? ? INFO ?- * JMRI log ** [main]
13:27:16,586 apps.util.Log4JUtil ? ? ? ? ? ? ? ? ? INFO ?- This log is stored in file: C:\Users\Darrin Calcutt\JMRI\log\session.log [main]
13:27:16,587 apps.util.Log4JUtil ? ? ? ? ? ? ? ? ? INFO ?- This log is appended to file: C:\Users\Darrin Calcutt\JMRI\log\messages.log [main]
13:27:16,619 apps.Apps? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- PanelPro version 5.8+Rbc21ce2ce7 starts under Java 17.0.11 on Windows 10 amd64 v10.0 at Fri Aug 02 13:27:16 EDT 2024 [main]
13:27:16,717 apps.Apps? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- Starting with profile My_JMRI_Railroad.3ef69f83 [main]
13:27:16,852 jmri.util.node.NodeIdentity ? ? ? ? ? INFO ?- Using 80242dbc-de4b-4c63-ab68-6e32a7fea13d as the JMRI storage identity for profile id 3ef69f83 [AWT-EventQueue-0]
13:27:16,940 xml.AbstractSerialConnectionConfigXml INFO ?- Starting to connect for "NCE" [main]
13:27:17,035 .nce.serialdriver.SerialDriverAdapter INFO ?- Connecting NCE to COM3 ELTIMA_Virtual_Serial_Port_00 [main]
13:27:17,036 .nce.serialdriver.SerialDriverAdapter INFO ?- Port COM3 ELTIMA Virtual Serial Port (COM3) opened at 9600 baud, sees DTR: true RTS: true DSR: true CTS: true DCD: true flow: NONE [main]
13:27:17,112 xml.AbstractSerialConnectionConfigXml INFO ?- Starting to connect for "NCE" [main]
13:27:17,123 .nce.serialdriver.SerialDriverAdapter INFO ?- Connecting NCE to COM4 ELTIMA_Virtual_Serial_Port_02 [main]
13:27:17,124 .nce.serialdriver.SerialDriverAdapter INFO ?- Port COM4 ELTIMA Virtual Serial Port (COM4) opened at 9600 baud, sees DTR: true RTS: true DSR: true CTS: true DCD: true flow: NONE [main]
13:27:17,197 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: ffffffaa [nce.NceTrafficController Receive thread]
13:27:17,197 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: 6 [nce.NceTrafficController Receive thread]
13:27:17,198 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: 2 [nce.NceTrafficController Receive thread]
13:27:17,198 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: 3 [nce.NceTrafficController Receive thread]
13:27:17,198 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: ffffffa8 [nce.NceTrafficController Receive thread]
13:27:17,198 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: b [nce.NceTrafficController Receive thread]
13:27:17,199 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: ffffffea [nce.NceTrafficController Receive thread]
13:27:17,199 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: ffffffc0 [nce.NceTrafficController Receive thread]
13:27:17,199 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: 30 [nce.NceTrafficController Receive thread]
13:27:17,312 jmri.jmrix.nce.NceConnectionStatus ? ?ERROR - Wrong major revision: aa [AWT-EventQueue-0]
13:27:17,313 jmri.jmrix.nce.NceConnectionStatus ? ?INFO ?- NCE EPROM revision = aa.6.2 [AWT-EventQueue-0]
13:27:17,313 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: 3 [nce.NceTrafficController Receive thread]
13:27:17,415 jmri.jmrix.nce.NceConnectionStatus ? ?WARN ?- Incorrect or no response from NCE command station [nce.NceTrafficController Transmit thread]
13:27:17,476 jmri.jmrit.roster.Roster ? ? ? ? ? ? ?INFO ?- Reading roster file with rootFromName(C:\Users\Darrin Calcutt\JMRI\My_JMRI_Railroad.jmri\roster.xml) [main]
13:27:17,485 jmri.jmrix.nce.NceConnectionStatus ? ?ERROR - Wrong major revision: aa [AWT-EventQueue-0]
13:27:17,486 jmri.jmrix.nce.NceConnectionStatus ? ?INFO ?- NCE EPROM revision = aa.6.2 [AWT-EventQueue-0]
13:27:17,486 mri.jmrix.AbstractMRTrafficController ERROR - unsolicited character received: 3 [nce.NceTrafficController Receive thread]?
?
?
?


 

I was on the phone with tech support till midnight the other day.
He checked my setting and all communications with well, as, COM2, COM3, COM4 should all be the same.
?
Some software he ran was?
Savage CommUartAssistant V4.2
Powered by Cmsoft Technology (SavageStudio)
email?ming@...?QQ 10865600
?
With this software I an about to talk with the NCE and repeatedly send the AA command.
??2024-08-02 13:37:50:491??AA 06 02 03?
??2024-08-02 13:37:51:498??AA 06 02 03?
??2024-08-02 13:37:52:504??AA 06 02 03?
??2024-08-02 13:37:53:528??AA 06 02 03?
??2024-08-02 13:37:54:539??AA 06 02 03?
??2024-08-02 13:37:55:560??AA 06 02 03?
??2024-08-02 13:37:56:567??AA 06 02 03?
??2024-08-02 13:37:57:587??AA 06 02 03?
??2024-08-02 13:37:58:608??AA 06 02 03?
??2024-08-02 13:37:59:613??AA 06 02 03?
??2024-08-02 13:38:00:637??AA 06 02 03?
??2024-08-02 13:38:01:657??AA 06 02 03?
??2024-08-02 13:38:02:661??AA 06 02 03?
??2024-08-02 13:38:03:682??AA 06 02 03?
??2024-08-02 13:38:04:703??AA 06 02 03?
??2024-08-02 13:38:05:712??AA 06 02 03?
??2024-08-02 13:38:06:730??AA 06 02 03?
??2024-08-02 13:38:07:749??AA 06 02 03?
??2024-08-02 13:38:08:757??AA 06 02 03?
??2024-08-02 13:38:09:782??AA 06 02 03?
??2024-08-02 13:38:10:787??AA 06 02 03?
??2024-08-02 13:38:11:806??AA 06 02 03?
??2024-08-02 13:38:12:825??AA 06 02 03?
??2024-08-02 13:38:13:846??AA 06 02 03?
??2024-08-02 13:38:14:848??AA 06 02 03?
??2024-08-02 13:38:15:871??AA 06 02 03?
??2024-08-02 13:38:16:889??AA 06 02 03?
??2024-08-02 13:38:18:004??AA 06 02 03?
??2024-08-02 13:38:18:938??AA 06 02 03?


 

The virtual serial port software is
?
?
very easy to set up.
?
And it comes with it own monitoring software built in.
?
Here is what I'm getting.
?
0 ? 16 ? Com ? ? ?COM Open ? ? ?
1 ? 94 ? Com ? ? ?COM Open ? ? ?
2 ? 25313 ? COM ? 1 ? ? ? AA ? ?
3 ? 25359 ? NET ? 4 ? ? ? AA 06 02 03 ? ?
4 ? 25484 ? COM ? 1 ? ? ? AA ? ?
5 ? 25531 ? NET ? 4 ? ? ? AA 06 02 03 ? ?
6 ? 25672 ? COM ? 1 ? ? ? AA ? ?
7 ? 25719 ? NET ? 4 ? ? ? AA 06 02 03 ? ?
8 ? 25844 ? COM ? 1 ? ? ? AA ? ?
9 ? 25891 ? NET ? 4 ? ? ? AA 06 02 03 ? ?
10 ? 26016 ? COM ? 1 ? ? ? AA ? ?
11 ? 26078 ? NET ? 4 ? ? ? AA 06 02 03 ? ?
12 ? 26188 ? COM ? 1 ? ? ? AA ? ?
?
I'm wandering now id the command AA is being echoed back.
What are you thoughts?


 

I used all version of Java
?
Java 11
Java 17
and Java 21
?
I have rolled back the software in JMRI from 5.9.2
to 5.8
now going back to 5.7.9
?
I'm sure the communication part of JMRI is solid, as it has bee around for a long time.
?
When was the last time this part of the software was edited? Just so I have a timeframe to reference with.
?


 

I would not try two computers to one command station. Many actions are
multiple packets and neither the JMRI nor command station code is
designed for this. Some actions take quite a while and it isn't
expecting anything else in between. I would say this isn't a problem
for JMRI or NCE. Now using the devices for remotely using the command
stations, that should work ok but keep it single thread, only one to
one for a connection.

-Ken Cameron, Member JMRI Dev Team
www.jmri.org
www.fingerlakeslivesteamers.org
www.cnymod.com


 

The only issue I have, is the double A command.?

Everything else seems to work great!
?
So I wondered if there was a way to bypass this command?
?


 

On Sun, Aug 4, 2024 at 07:33 PM, Canadian Locomotive Logistics wrote:
Everything else seems to work great!
?
So I wondered if there was a way to bypass this command?
?
Glad you believe everything is working great. Just ignore the AA status command.? It doesn't affect the communications.? But after 18 years of supporting NCE users, I've never seen where the AA command test fails, but the rest works correctly.? The NCE AA EPROM check was coded by me about 18 years ago, so you'll have to go way back to not find it!? I believe your problem is with your serial port adapter.? It seems to echo the command back.
?
Dan JMRI Developer


 

Which command station and firmware version? I've got a long shot idea
but need to know these details.

-Ken Cameron, Member JMRI Dev Team
www.jmri.org
www.fingerlakeslivesteamers.org
www.cnymod.com


 

Ken,
?
Looking at the console messages, It looks to me that the command stations is trying to report version 6.2.3.


Tim Kelley
 

Good day,

I have a Digitrax DCS240+ command station. I did a firmware update on it and the firmware version number did not change

so I dont think you can reliably tell which firmware revision is loaded into that command station. I guess when Digitrax does

an "official release build" someone didnt bother to bump up the revision number.

Tim

On Sunday, August 4, 2024 at 09:50:51 PM CDT, Dan Boudreau <daboudreau@...> wrote:


Ken,
?
Looking at the console messages, It looks to me that the command stations is trying to report version 6.2.3.


 

Yes it is, but the problem is the serial-ethernet-serial conversion is screwing up the AA message by sending some FF characters.

Now a notable thing here is that the LIN message protocol uses? the AA character preceded by a break to do automatic baud rate detection. I suspect that is what the Ethernet boxes are attempting to do, and as a result the NCE box is echoing the whole character string, then understanding the AA command and sending the appropriate response. But JMRI doesn't understand the response because of the extra characters that get echoed and so misunderstands both the echo and then the NCE response.

Go take a step back and instead of trying to use technology that isn't needed, and use a direct connection. The time that it would take to set up a direct connection will be considerably less than the time you have spent attempting to use a fancy system. Ever heard of the KISS principle?



On Mon, 5 Aug 2024 at 03:50, Dan Boudreau via <daboudreau=[email protected]> wrote:
Ken,
?
Looking at the console messages, It looks to me that the command stations is trying to report version 6.2.3.


 

Tim,

I think something is confused here. So far this thread has been about
an NCE system but you have a Digitrax system. You need to start your
own thread as it doesn't belong here.

-Ken Cameron, Member JMRI Dev Team
www.jmri.org
www.fingerlakeslivesteamers.org
www.cnymod.com


 

I would agree that removing the remote device to prove out the basic
system is an important proof of what's working or not.

If we were getting the command repeated for everything to the command
station, there could be a reason there. A feature was added in the
firmware that would include the command with every reply to resolve an
issue with the AIU with broadcast mode. But we found that not using
broadcast mode for the AIU worked fine. Insuring that the option is
turned off to not use AIU broadcast mode in the command station is
important.

-Ken Cameron, Member JMRI Dev Team
www.jmri.org
www.fingerlakeslivesteamers.org
www.cnymod.com


 

I¡¯m all for the idea.?

if you want, you can install the virtual com port software yourself and connect to my layout JMRI.?
?
I ?just need to give you the IP address and port number to connect to then.?


 

Ive had this serial server for a long time.?

and i don¡¯t have 30¡¯ serial cables.?

i have multiple JMRIs using my layout. One does programming and two run the layout. One is for the public, the other is personal.?


 

Ken, it is ?just the first couple of AA commands.?

i see a AA command before the panel Pro shows, them more after. ?Well if you connect to my serial port, im sure you will see.?


 

The AA commands get sent by JMRI to see what is connected or not on
the port. A reply with three digits is expected. Nominally it is on a
10 second loop. This accounts for why some people say on starting JMRI
it says there is a connection but 10 seconds later, it 'goes red'.
Until that times out, it leaves the status alone which defaults as
green.

My guess is your network hardware is delaying or buffering some of the
data and that is confusing things.

The proof for this would be temporarily moving the computer and
command station together and eliminate the network connection. If the
error goes away, that points to something in the net connection. If it
remains the same, then it would seem the network connection isn't
making a difference.

-Ken Cameron, Member JMRI Dev Team
www.jmri.org
www.fingerlakeslivesteamers.org
www.cnymod.com


 

Of you want to try using my my NCE mainline¡­
?
download the virtual com software here
?
?
?


 

ken, you will have to email me direct?
?
djcalcutt@... for the rest of the details.?

My ip address and port number.?

thanks for the help. In the mean time my layout is unavailable for running trains publicly.?

?


 

The way to bypass the problem (not the command) is to have something like a Raspberry Pi running JMRI at the layout, and then connect over the network using whatever the NCE equivalent of LoconetOverTCP from whatever other computers you want to use.

On Mon, 5 Aug 2024 at 00:33, Canadian Locomotive Logistics via <CanadianLocomotiveLogistics=[email protected]> wrote:

The only issue I have, is the double A command.?

Everything else seems to work great!
?
So I wondered if there was a way to bypass this command?
?