Keyboard Shortcuts
ctrl + shift + ? :
Show all keyboard shortcuts
ctrl + g :
Navigate to a group
ctrl + shift + f :
Find
ctrl + / :
Quick actions
esc to dismiss
Likes
Search
java portnamepattern not recognized until after connection fails
#startup
#dcc-ex
#linux
I'm trying to get my new dcc system recognized by jmri running on linux.? Based on my reading of previous messages, I have my udev rules configured to create /dev/DCCEX and /dev/TCHLCC, and in my .bashrc I have
JMRI_OPTIONS= -Dpurejavacomm.portnamepattern=(ttyACM0|ttyUSB0|DCCEX|TCHLCC|sprog2)
?
At the moment I've only got my DCCEX connection configured in decoderpro, so I'm not worried about the LCC connection just yet.
?
When I start DecoderPro, I get an error that the device DCCEX is not found, and then later on in the log, I see DCCEX and TCHLCC are added as matching patterns for serial ports.? How can I get the matching patterns to be set?before?decoderpro tries to open the ports?? Here's my session.log:
?
2025-03-10T13:47:42,798 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- * JMRI log ** [main]
2025-03-10T13:47:42,860 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- This log is stored in file: /home/jmri/.jmri/log/session.log [main] 2025-03-10T13:47:42,863 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- This log is appended to file: /home/jmri/.jmri/log/messages.log [main] 2025-03-10T13:47:42,961 apps.AppsBase ? ? ? ? ? ? ? ? ? ? ? ? INFO ?- DecoderPro version 5.11.4+R87a9dadc80 starts under Java 17.0.14 on Linux aarch64 v6.1.21-v8+ at Mon Mar 10 13:47:42 CDT 2025 [main] 2025-03-10T13:47:43,863 gui3.Apps3 ? ? ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- Starting with profile HGVW.3f76bfa4 [main] 2025-03-10T13:47:44,089 node.NodeIdentity ? ? ? ? ? ? ? ? ? ? INFO ?- Using 6c786e77-a0ea-4429-9ee0-dba4434b6eea as the JMRI storage identity for profile id 3f76bfa4 [AWT-EventQueue-0] 2025-03-10T13:47:44,299 xml.AbstractSerialConnectionConfigXml INFO ?- Starting to connect for "DCC++" [main] 2025-03-10T13:47:44,534 serial.DCCppAdapter ? ? ? ? ? ? ? ? ? ERROR - Serial port DCCEX not found: This port appears to have been shutdown or disconnected. [main] 2025-03-10T13:47:44,540 serial.DCCppAdapter ? ? ? ? ? ? ? ? ? ERROR - failed to connect DCC++ to DCCEX [main] 2025-03-10T13:47:44,544 jmrix.ConnectionConfigManager ? ? ? ? ERROR - Unable to create jmri.jmrix.dccpp.serial.configurexml.ConnectionConfigXml for [Element: <connection/>], load returned false [main] 2025-03-10T13:47:44,550 plementation.JmriConfigurationManager ERROR - Exception initializing jmri.jmrix.ConnectionConfigManager: Unable to create several of your connections. [main] 2025-03-10T13:47:45,647 roster.Roster ? ? ? ? ? ? ? ? ? ? ? ? INFO ?- Reading roster file with rootFromName(/home/jmri/.jmri/HGVW.jmri/roster.xml) [main] 2025-03-10T13:48:00,702 plementation.JmriConfigurationManager ERROR - Exception initializing jmri.util.startup.StartupActionsManager: jmri.util.prefs.InitializationException: Unable to run startup actions due to earlier failures. [main] 2025-03-10T13:48:09,441 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path program: is /opt/jmri/jmri_5.11.4/ [main] 2025-03-10T13:48:09,444 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path preference: is /home/jmri/.jmri/HGVW.jmri/ [main] 2025-03-10T13:48:09,446 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path profile: is /home/jmri/.jmri/HGVW.jmri/ [main] 2025-03-10T13:48:09,449 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path settings: is /home/jmri/.jmri/ [main] 2025-03-10T13:48:09,452 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path home: is /home/jmri/ [main] 2025-03-10T13:48:09,455 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path scripts: is /opt/jmri/jmri_5.11.4/jython/ [main] 2025-03-10T13:48:10,552 permission.DefaultPermissionManager ? INFO ?- Permission file: /home/jmri/.jmri/.permissions.xml [main] 2025-03-10T13:48:10,563 permission.DefaultPermissionManager ? INFO ?- Permission system is enabled: no [main] 2025-03-10T13:48:11,237 throttle.PowerManagerButton ? ? ? ? ? INFO ?- No power manager instance found, panel not active [main] 2025-03-10T13:48:29,767 jserialcomm.JSerialPort ? ? ? ? ? ? ? INFO ?- Adding symlink port [serial1, serial0] [main] 2025-03-10T13:48:29,780 jserialcomm.JSerialPort ? ? ? ? ? ? ? INFO ?- Adding user-specified ports [TCHLCC, DCCEX] matching pattern (ttyACM0|ttyUSB0|DCCEX|TCHLCC|sprog2) [main] 2025-03-10T13:48:29,803 jserialcomm.JSerialPort ? ? ? ? ? ? ? INFO ?- Adding symlink port [serial1, serial0] [main] 2025-03-10T13:48:29,810 jserialcomm.JSerialPort ? ? ? ? ? ? ? INFO ?- Adding user-specified ports [TCHLCC, DCCEX] matching pattern (ttyACM0|ttyUSB0|DCCEX|TCHLCC|sprog2) [main] 2025-03-10T13:49:12,464 throttle.PowerManagerButton ? ? ? ? ? INFO ?- No power manager instance found, panel not active [Thread-5] 2025-03-10T13:49:16,538 managers.DefaultShutDownManager ? ? ? INFO ?- Normal termination complete [Thread-5] ?
Thanks.
?
Joel
--
Joel Davidson
Austin TX |
Joel, Try using jmri.conf. ?Copy the installed version to ~/.jmri and modify it. ? default_options="--serial-ports=/dev/ttyUSB_NCE_PH_Pro, /dev/ttyUSB_PowrCab” Dave Sand ----- Original message ----- From: "Joel Davidson via groups.io" <jrdst1100=[email protected]> Subject: [jmriusers] java portnamepattern not recognized until after connection fails #dcc-ex #linux #startup Date: Monday, March 10, 2025 2:01 PM I'm trying to get my new dcc system recognized by jmri running on linux.? Based on my reading of previous messages, I have my udev rules configured to create /dev/DCCEX and /dev/TCHLCC, and in my .bashrc I have JMRI_OPTIONS= -Dpurejavacomm.portnamepattern=(ttyACM0|ttyUSB0|DCCEX|TCHLCC|sprog2) ? At the moment I've only got my DCCEX connection configured in decoderpro, so I'm not worried about the LCC connection just yet. ? When I start DecoderPro, I get an error that the device DCCEX is not found, and then later on in the log, I see DCCEX and TCHLCC are added as matching patterns for serial ports.? How can I get the matching patterns to be set?before?decoderpro tries to open the ports?? Here's my session.log: ? 2025-03-10T13:47:42,798 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- * JMRI log ** [main] 2025-03-10T13:47:42,860 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- This log is stored in file: /home/jmri/.jmri/log/session.log [main] 2025-03-10T13:47:42,863 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- This log is appended to file: /home/jmri/.jmri/log/messages.log [main] 2025-03-10T13:47:42,961 apps.AppsBase ? ? ? ? ? ? ? ? ? ? ? ? INFO ?- DecoderPro version 5.11.4+R87a9dadc80 starts under Java 17.0.14 on Linux aarch64 v6.1.21-v8+ at Mon Mar 10 13:47:42 CDT 2025 [main] 2025-03-10T13:47:43,863 gui3.Apps3 ? ? ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- Starting with profile HGVW.3f76bfa4 [main] 2025-03-10T13:47:44,089 node.NodeIdentity ? ? ? ? ? ? ? ? ? ? INFO ?- Using 6c786e77-a0ea-4429-9ee0-dba4434b6eea as the JMRI storage identity for profile id 3f76bfa4 [AWT-EventQueue-0] 2025-03-10T13:47:44,299 xml.AbstractSerialConnectionConfigXml INFO ?- Starting to connect for "DCC++" [main] 2025-03-10T13:47:44,534 serial.DCCppAdapter ? ? ? ? ? ? ? ? ? ERROR - Serial port DCCEX not found: This port appears to have been shutdown or disconnected. [main] 2025-03-10T13:47:44,540 serial.DCCppAdapter ? ? ? ? ? ? ? ? ? ERROR - failed to connect DCC++ to DCCEX [main] 2025-03-10T13:47:44,544 jmrix.ConnectionConfigManager ? ? ? ? ERROR - Unable to create jmri.jmrix.dccpp.serial.configurexml.ConnectionConfigXml for [Element: <connection/>], load returned false [main] 2025-03-10T13:47:44,550 plementation.JmriConfigurationManager ERROR - Exception initializing jmri.jmrix.ConnectionConfigManager: Unable to create several of your connections. [main] 2025-03-10T13:47:45,647 roster.Roster ? ? ? ? ? ? ? ? ? ? ? ? INFO ?- Reading roster file with rootFromName(/home/jmri/.jmri/HGVW.jmri/roster.xml) [main] 2025-03-10T13:48:00,702 plementation.JmriConfigurationManager ERROR - Exception initializing jmri.util.startup.StartupActionsManager: jmri.util.prefs.InitializationException: Unable to run startup actions due to earlier failures. [main] 2025-03-10T13:48:09,441 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path program: is /opt/jmri/jmri_5.11.4/ [main] 2025-03-10T13:48:09,444 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path preference: is /home/jmri/.jmri/HGVW.jmri/ [main] 2025-03-10T13:48:09,446 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path profile: is /home/jmri/.jmri/HGVW.jmri/ [main] 2025-03-10T13:48:09,449 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path settings: is /home/jmri/.jmri/ [main] 2025-03-10T13:48:09,452 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path home: is /home/jmri/ [main] 2025-03-10T13:48:09,455 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path scripts: is /opt/jmri/jmri_5.11.4/jython/ [main] 2025-03-10T13:48:10,552 permission.DefaultPermissionManager ? INFO ?- Permission file: /home/jmri/.jmri/.permissions.xml [main] 2025-03-10T13:48:10,563 permission.DefaultPermissionManager ? INFO ?- Permission system is enabled: no [main] 2025-03-10T13:48:11,237 throttle.PowerManagerButton ? ? ? ? ? INFO ?- No power manager instance found, panel not active [main] 2025-03-10T13:48:29,767 jserialcomm.JSerialPort ? ? ? ? ? ? ? INFO ?- Adding symlink port [serial1, serial0] [main] 2025-03-10T13:48:29,780 jserialcomm.JSerialPort ? ? ? ? ? ? ? INFO ?- Adding user-specified ports [TCHLCC, DCCEX] matching pattern (ttyACM0|ttyUSB0|DCCEX|TCHLCC|sprog2) [main] 2025-03-10T13:48:29,803 jserialcomm.JSerialPort ? ? ? ? ? ? ? INFO ?- Adding symlink port [serial1, serial0] [main] 2025-03-10T13:48:29,810 jserialcomm.JSerialPort ? ? ? ? ? ? ? INFO ?- Adding user-specified ports [TCHLCC, DCCEX] matching pattern (ttyACM0|ttyUSB0|DCCEX|TCHLCC|sprog2) [main] 2025-03-10T13:49:12,464 throttle.PowerManagerButton ? ? ? ? ? INFO ?- No power manager instance found, panel not active [Thread-5] 2025-03-10T13:49:16,538 managers.DefaultShutDownManager ? ? ? INFO ?- Normal termination complete [Thread-5] ? Thanks. ? Joel -- Joel Davidson Austin TX |
Thanks Dave.? Unfortunately, that didn't work either.? According to the comments in jmri.conf, for linux I don't need that path "/dev/", but I tried it both ways, using /dev/DCCEX as well as DCCEX, and in both cases the device wasn't found.
?
2025-03-10T14:30:37,129 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- * JMRI log ** [main]
2025-03-10T14:30:37,205 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- This log is stored in file: /home/jmri/.jmri/log/session.log [main] 2025-03-10T14:30:37,210 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- This log is appended to file: /home/jmri/.jmri/log/messages.log [main] 2025-03-10T14:30:37,325 apps.AppsBase ? ? ? ? ? ? ? ? ? ? ? ? INFO ?- DecoderPro version 5.11.4+R87a9dadc80 starts under Java 17.0.14 on Linux aarch64 v6.1.21-v8+ at Mon Mar 10 14:30:37 CDT 2025 [main] 2025-03-10T14:30:38,045 gui3.Apps3 ? ? ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- Starting with profile HGVW.3f76bfa4 [main] 2025-03-10T14:30:38,343 node.NodeIdentity ? ? ? ? ? ? ? ? ? ? INFO ?- Using 6c786e77-a0ea-4429-9ee0-dba4434b6eea as the JMRI storage identity for profile id 3f76bfa4 [AWT-EventQueue-0] 2025-03-10T14:30:38,578 xml.AbstractSerialConnectionConfigXml INFO ?- Starting to connect for "DCC++" [main] 2025-03-10T14:30:38,796 serial.DCCppAdapter ? ? ? ? ? ? ? ? ? ERROR - Serial port DCCEX not found: This port appears to have been shutdown or disconnected. [main] 2025-03-10T14:30:38,802 serial.DCCppAdapter ? ? ? ? ? ? ? ? ? ERROR - failed to connect DCC++ to DCCEX [main] 2025-03-10T14:30:38,805 jmrix.ConnectionConfigManager ? ? ? ? ERROR - Unable to create jmri.jmrix.dccpp.serial.configurexml.ConnectionConfigXml for [Element: <connection/>], load returned false [main] 2025-03-10T14:30:38,810 plementation.JmriConfigurationManager ERROR - Exception initializing jmri.jmrix.ConnectionConfigManager: Unable to create several of your connections. [main] 2025-03-10T14:30:39,815 roster.Roster ? ? ? ? ? ? ? ? ? ? ? ? INFO ?- Reading roster file with rootFromName(/home/jmri/.jmri/HGVW.jmri/roster.xml) [main] 2025-03-10T14:30:54,942 plementation.JmriConfigurationManager ERROR - Exception initializing jmri.util.startup.StartupActionsManager: jmri.util.prefs.InitializationException: Unable to run startup actions due to earlier failures. [main] 2025-03-10T14:31:03,014 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path program: is /opt/jmri/jmri_5.11.4/ [main] 2025-03-10T14:31:03,017 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path preference: is /home/jmri/.jmri/HGVW.jmri/ [main] 2025-03-10T14:31:03,020 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path profile: is /home/jmri/.jmri/HGVW.jmri/ [main] 2025-03-10T14:31:03,023 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path settings: is /home/jmri/.jmri/ [main] 2025-03-10T14:31:03,026 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path home: is /home/jmri/ [main] 2025-03-10T14:31:03,030 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path scripts: is /opt/jmri/jmri_5.11.4/jython/ [main] 2025-03-10T14:31:03,200 permission.DefaultPermissionManager ? INFO ?- Permission file: /home/jmri/.jmri/.permissions.xml [AWT-EventQueue-0] 2025-03-10T14:31:03,224 permission.DefaultPermissionManager ? INFO ?- Permission system is enabled: no [AWT-EventQueue-0] 2025-03-10T14:31:03,279 managers.DefaultShutDownManager ? ? ? INFO ?- Normal termination complete [Thread-2] ?
Config file (~/.jmri/jmri.conf):
default_options="--serial-ports=DCCEX,TCHLCC,sprog2"
?
Also tried with:
default_options="--serial-ports=/dev/DCCEX,/dev/TCHLCC,sprog2"
?
ll /dev/DCC*
lrwxrwxrwx 1 root root 15 Mar 10 14:42 /dev/DCCEX -> bus/usb/001/003
?
ll /dev/bus/usb/001/003
crw-rw-rw- 1 jmri staff 189, 2 Mar 10 14:42 /dev/bus/usb/001/003 ?
id
uid=510(jmri) gid=501(staff) groups=501(staff),20(dialout),27(sudo) ?
So I think the permissions are all ok.? I'm baffled.
Joel ?
? |
Joel, Try including "tty" at the beginning of the device name, i.e. ttyDCCEX. Dave Sand ----- Original message ----- From: "Joel Davidson via groups.io" <jrdst1100=[email protected]> Subject: Re: [jmriusers] java portnamepattern not recognized until after connection fails #startup #dcc-ex #linux Date: Monday, March 10, 2025 2:48 PM Thanks Dave.? Unfortunately, that didn't work either.? According to the comments in jmri.conf, for linux I don't need that path "/dev/", but I tried it both ways, using /dev/DCCEX as well as DCCEX, and in both cases the device wasn't found. ? 2025-03-10T14:30:37,129 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- * JMRI log ** [main] 2025-03-10T14:30:37,205 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- This log is stored in file: /home/jmri/.jmri/log/session.log [main] 2025-03-10T14:30:37,210 util.Log4JUtil ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- This log is appended to file: /home/jmri/.jmri/log/messages.log [main] 2025-03-10T14:30:37,325 apps.AppsBase ? ? ? ? ? ? ? ? ? ? ? ? INFO ?- DecoderPro version 5.11.4+R87a9dadc80 starts under Java 17.0.14 on Linux aarch64 v6.1.21-v8+ at Mon Mar 10 14:30:37 CDT 2025 [main] 2025-03-10T14:30:38,045 gui3.Apps3 ? ? ? ? ? ? ? ? ? ? ? ? ? ?INFO ?- Starting with profile HGVW.3f76bfa4 [main] 2025-03-10T14:30:38,343 node.NodeIdentity ? ? ? ? ? ? ? ? ? ? INFO ?- Using 6c786e77-a0ea-4429-9ee0-dba4434b6eea as the JMRI storage identity for profile id 3f76bfa4 [AWT-EventQueue-0] 2025-03-10T14:30:38,578 xml.AbstractSerialConnectionConfigXml INFO ?- Starting to connect for "DCC++" [main] 2025-03-10T14:30:38,796 serial.DCCppAdapter ? ? ? ? ? ? ? ? ? ERROR - Serial port DCCEX not found: This port appears to have been shutdown or disconnected. [main] 2025-03-10T14:30:38,802 serial.DCCppAdapter ? ? ? ? ? ? ? ? ? ERROR - failed to connect DCC++ to DCCEX [main] 2025-03-10T14:30:38,805 jmrix.ConnectionConfigManager ? ? ? ? ERROR - Unable to create jmri.jmrix.dccpp.serial.configurexml.ConnectionConfigXml for [Element: <connection/>], load returned false [main] 2025-03-10T14:30:38,810 plementation.JmriConfigurationManager ERROR - Exception initializing jmri.jmrix.ConnectionConfigManager: Unable to create several of your connections. [main] 2025-03-10T14:30:39,815 roster.Roster ? ? ? ? ? ? ? ? ? ? ? ? INFO ?- Reading roster file with rootFromName(/home/jmri/.jmri/HGVW.jmri/roster.xml) [main] 2025-03-10T14:30:54,942 plementation.JmriConfigurationManager ERROR - Exception initializing jmri.util.startup.StartupActionsManager: jmri.util.prefs.InitializationException: Unable to run startup actions due to earlier failures. [main] 2025-03-10T14:31:03,014 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path program: is /opt/jmri/jmri_5.11.4/ [main] 2025-03-10T14:31:03,017 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path preference: is /home/jmri/.jmri/HGVW.jmri/ [main] 2025-03-10T14:31:03,020 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path profile: is /home/jmri/.jmri/HGVW.jmri/ [main] 2025-03-10T14:31:03,023 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path settings: is /home/jmri/.jmri/ [main] 2025-03-10T14:31:03,026 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path home: is /home/jmri/ [main] 2025-03-10T14:31:03,030 util.FileUtilSupport ? ? ? ? ? ? ? ? ?INFO ?- File path scripts: is /opt/jmri/jmri_5.11.4/jython/ [main] 2025-03-10T14:31:03,200 permission.DefaultPermissionManager ? INFO ?- Permission file: /home/jmri/.jmri/.permissions.xml [AWT-EventQueue-0] 2025-03-10T14:31:03,224 permission.DefaultPermissionManager ? INFO ?- Permission system is enabled: no [AWT-EventQueue-0] 2025-03-10T14:31:03,279 managers.DefaultShutDownManager ? ? ? INFO ?- Normal termination complete [Thread-2] ? Config file (~/.jmri/jmri.conf): default_options="--serial-ports=DCCEX,TCHLCC,sprog2" ? Also tried with: default_options="--serial-ports=/dev/DCCEX,/dev/TCHLCC,sprog2" ? ll /dev/DCC* lrwxrwxrwx 1 root root 15 Mar 10 14:42 /dev/DCCEX -> bus/usb/001/003 ? ll /dev/bus/usb/001/003 crw-rw-rw- 1 jmri staff 189, 2 Mar 10 14:42 /dev/bus/usb/001/003 ? id uid=510(jmri) gid=501(staff) groups=501(staff),20(dialout),27(sudo) ? So I think the permissions are all ok.? I'm baffled. Joel ? ? |
No good.? I tried changing just the config file to use ttyDCCEX and ttyTCHLCC, as well as changing the udev rules to create ttyDCCEX and ttyTCHLCC.? The devices get created as defined, but still seeing the same error on startup and the new devices don't appear in the connection configuration menu.
Joel ? |
One thing I noticed is that if I define the devices in the udev rules as lower case names (dccex, tchlcc), then the names show up in the jmri config menu for the serial ports, but jmri still can't connect to them.? If I configure the jmri interface using ttyUSB0 and ttyUSB1 they connect ok.? Maybe I have multiple issues here?? Near as I can tell, all of the permissions are correct.??
Joel ? |
Joel, A previous message had some list commands. ?The symbolic link looks strange. ?Here is what I see on a Raspberry Pi. This is the udev rule: SUBSYSTEM=="tty", ATTRS{interface}=="LocoBuffer-USB", SYMLINK+="ttyUSBLocoBuffer" Dave Sand ----- Original message ----- From: "Joel Davidson via groups.io" <jrdst1100=[email protected]> Subject: Re: [jmriusers] java portnamepattern not recognized until after connection fails #startup #dcc-ex #linux Date: Monday, March 10, 2025 3:30 PM One thing I noticed is that if I define the devices in the udev rules as lower case names (dccex, tchlcc), then the names show up in the jmri config menu for the serial ports, but jmri still can't connect to them.? If I configure the jmri interface using ttyUSB0 and ttyUSB1 they connect ok.? Maybe I have multiple issues here?? Near as I can tell, all of the permissions are correct.?? Joel ? |
I'm not sure if this will assist, but on my Linux laptop, I added udev rules to give my DCC-EX system a name that doesn't changed based on order of connecting USB devices, or which port it gets plugged into.? JMRI works successfully using that udev symbolic link name.
?
I'm not able to fire that laptop up right now, but my recollection is that my symbolic link looked very similar to what Joel showed (i.e. pointing to bus/usb/xxx/yyy)
?
I will check later today and confirm - just in case it helps.
?
Trevor |
I tried this again with the symlinks prefaced with "tty", but I still see the same behavior.? From the log it looks like the code is trying to connect to the devices before the additionl device names from the config file have actually been enumerated by the serial communication subsystem.? ??
?
Joel
? |
OK, I should have checked first, and typed later...
?
I've just checked my laptop, and the DCCEX symbolic link isn't as I remember it.? It is just like Dave Sand's example.? Possibly I saw the bus/usb/xxx/yyy type of link when I was setting up my udev rules and before I had my final version established.
?
My current udev rule for my DCC-EX system is:
?
SUBSYSTEM=="tty", SUBSYSTEMS=="usb", ATTRS{idProduct}=="xxxx", ATTRS{idVendor}=="yyyy", SYMLINK+="DCCEX"
?
As you can see, the symbolic link name I'm using is the same as what Joel is trying to use (DCCEX), and JMRI works with it.
?
Here's the output from my System Console when starting this profile:
?
13:13:20,492 apps.util.Log4JUtil ? ? ? ? ? ? ? ? ? INFO ?- * JMRI log ** [main]
13:13:20,540 apps.util.Log4JUtil ? ? ? ? ? ? ? ? ? INFO ?- This log is stored in file: /home/trevor/.jmri/log/session.log [main] 13:13:20,542 apps.util.Log4JUtil ? ? ? ? ? ? ? ? ? INFO ?- This log is appended to file: /home/trevor/.jmri/log/messages.log [main] 13:13:20,631 apps.AppsBase ? ? ? ? ? ? ? ? ? ? ? ? INFO ?- DecoderPro version 5.10+Rca461bd266 starts under Java 17.0.14 on Linux amd64 v6.8.0-53-generic at Tue Mar 11 13:13:20 ACDT 2025 [main] 13:13:23,646 apps.gui3.Apps3 ? ? ? ? ? ? ? ? ? ? ? INFO ?- Starting with profile DCCEX_via_USB.3e69ea00 [main] 13:13:24,038 jmri.util.node.NodeIdentity ? ? ? ? ? INFO ?- Using be480800-a10f-4f01-98ed-c565af496af6 as the JMRI storage identity for profile id 3e69ea00 [AWT-EventQueue-0] 13:13:24,280 xml.AbstractSerialConnectionConfigXml INFO ?- Starting to connect for "DCC++" [main] 13:13:24,450 jmri.jmrix.dccpp.serial.DCCppAdapter ?INFO ?- Connecting DCC++ to DCCEX User-Specified Port [main] 13:13:24,457 jmri.jmrix.dccpp.serial.DCCppAdapter ?INFO ?- DCC++: Port User-Specified Port opened at 115200 baud, sees DTR: true RTS: true DSR: false CTS: false DCD: false flow: NONE [main] 13:13:24,645 mrix.dccpp.DCCppInitializationManager INFO ?- DCC++ Initialization Complete [main] 13:13:25,657 jmri.jmrit.roster.Roster ? ? ? ? ? ? ?INFO ?- Reading roster file with rootFromName(/home/trevor/JMRI_Shared_Data/roster.xml) [main] 13:13:27,110 jmri.util.FileUtilSupport ? ? ? ? ? ? INFO ?- File path program: is /home/trevor/JMRI/ [main] 13:13:27,111 jmri.util.FileUtilSupport ? ? ? ? ? ? INFO ?- File path preference: is /home/trevor/JMRI_Shared_Data/ [main] 13:13:27,116 jmri.util.FileUtilSupport ? ? ? ? ? ? INFO ?- File path profile: is /home/trevor/.jmri/DCCEX_via_USB.jmri/ [main] 13:13:27,117 jmri.util.FileUtilSupport ? ? ? ? ? ? INFO ?- File path settings: is /home/trevor/.jmri/ [main] 13:13:27,121 jmri.util.FileUtilSupport ? ? ? ? ? ? INFO ?- File path home: is /home/trevor/ [main] 13:13:27,123 jmri.util.FileUtilSupport ? ? ? ? ? ? INFO ?- File path scripts: is /home/trevor/JMRI/jython/ [main] 13:13:28,050 t.permission.DefaultPermissionManager INFO ?- Permission file: /home/trevor/.jmri/.permissions.xml [main] 13:13:28,058 t.permission.DefaultPermissionManager INFO ?- Permission system is enabled: no [main] 13:13:34,655 jmri.jmrix.dccpp.DCCppCommandStation ?INFO ?- changing maxNumSlots from 12 to 50 [AWT-EventQueue-0] 13:13:34,738 jmri.jmrix.dccpp.DCCppCommandStation ?INFO ?- Station Type set to 'DCC-EX' [AWT-EventQueue-0] 13:13:34,741 jmri.jmrix.dccpp.DCCppCommandStation ?INFO ?- Build set to 'devel-202501021826Z' [AWT-EventQueue-0] 13:13:34,742 jmri.jmrix.dccpp.DCCppCommandStation ?INFO ?- Version set to '5.2.95' [AWT-EventQueue-0] ?
And a screenshot of my connection for this system:
?
So, based on my system, I can only say that JMRI can work with a DCC-EX system using a symbolic link to the USB port called "DCCEX".
?
Trevor. |
to navigate to use esc to dismiss