Trains.com

Subscriber & Member Login

Login, or register today to interact in our online community, comment on articles, receive our newsletter, manage your account online and more!

JMRI Programmers Missing in Raspbian Build?

1902 views
9 replies
1 rating 2 rating 3 rating 4 rating 5 rating
  • Member since
    September 2003
  • 10,582 posts
JMRI Programmers Missing in Raspbian Build?
Posted by mlehman on Friday, June 24, 2016 12:46 AM

You used to need to do some hacking to get JMRI working on the Raspberry Pi. Per: http://jmri.sourceforge.net/install/Raspbian.shtml

5. Copy RxTx

Matt Harris reported July 2015: The comms libraries fix is no longer necessary with JMRI development releases 3.11.1 and up as the Linux start-up script has been updated to better detect the ARM architecture. Move on to step 7.

The RxTx library used to be a problem requiring modifications to enable JMRI to run. JMRI requires a package called RXTXcomm. The version that was included with JMRI 3.5 and earlier did not work on the Raspberry Pi. So, if you are using or updating a version of JMRI prior to 3.8 then the RxTx library in JMRI must be replaced by the original. There is a script to do this in the JMRI users Yahoo group "Files" area if you wish to run JMRI 3.8 on Raspbian 3.18 Wheezy. Since JMRI version 3.8 this is no longer required.

The following script will fix the PanelPro etc. comms libraries not working due to incorrectly recognized processor. Type: sudo cp -v /opt/JMRI/lib/linux/armv6l/* /opt/JMRI/lib/linux/armv7l/ Note that this step is no longer required on a fresh install of JMRI 3.8 and up.

Nonetheless, when trying to set Preferences, I keep getting this when trying to set the Connection to NCE, Serial:

Failed to load comm libraries. You have to fix that before setting preferences.

OK, fair enough. Should be in the  drop down menu of Preference choices, right?

Noooo.

OK, must be in Help?

Noooo.

That would be too easy.

So how do I pick a Programmer (I presume the choice is between DecoderPro or DecoderPro3, since the "Simple Programmer" doesn't do the trick?), given that you can get it to open a file window with a Programmers file tantilizingly dangled before the user, which when the file is opened is empty...gee, would've been nice if SOMEWHERE a choice were offered that was obvious, since anyone setting up a system then likely gets stuck on this, especially when the first preference offered to be set is the Connections tab. Even better would be an error message that linked to a solution or set of choices, because that's a lot easier for the user than getting run in circles about what is obviously a vital first step to getting things up an running.

 

Mike Lehman

Urbana, IL

  • Member since
    February 2002
  • From: Reading, PA
  • 30,002 posts
Posted by rrinker on Friday, June 24, 2016 6:55 AM

 You're jumping way ahead if you are trying to select a programmer without getting an interface set up because the comm library isn't there. If you are unable to select a port, then perhaps the step of installing the comm library IS still needed - what version are you trying to use? Also, i dunno about Raspian, but on a standard Intel/AMD system with Ubuntu and some other Linux flavors, you do not have permission to the serial port and must manually change it before you cna connect to the port, comm library or no comm library.

 One you have the interface configured and working, then you can move on. DecoderPro and DecoderPro3 are two different programs. The Programmer choice will be a list - there's the single CV programmer, Ops Mode programmer, Service Mode programmer, and Multi Decoder Control, at least in the early 4.x version I have installed. If the preferences aren;t set, this will be blank because part of the preferences also sets what program modes are available - for example if you had a system that does not support ops mode, thent he ops mode choice would not be available.

                      --Randy

 


Modeling the Reading Railroad in the 1950's

 

Visit my web site at www.readingeastpenn.com for construction updates, DCC Info, and more.

  • Member since
    September 2003
  • 10,582 posts
Posted by mlehman on Friday, June 24, 2016 9:15 AM

Randy,

I did try running the line that was previosuly required and I cited above as no longer being needed. Got a file not found or some similar response, which seemed OK since I am using the latest Raspbian build and that would no longer need fixing with it.

Am doing this via xming, so I only get a GUI and no way for me to really communicate with the Pi that way except once JMRI starts. Maybe I need to pull it from the layout and bring into the shop and run it with the GUI to set the Com port via a direct cable from my PC? I think I've got just enough cabling to the usb to serial converter that I may still be able to control the layout once it's up. Thing is, there's nothing about which port to run it on.

Darnedest thing was I had WiThrottle up and working, but couldn't connect to the layout because the comm library being MIA, the NCE wouldn't start and I had nothing to talk to via WiThrottle.

Nothing obvious in the Preferences that were available to set the Programmer so those options would appear, which is what is so frustrating as it constantly demands I do that with no obvious way to accomplish this.

Mike Lehman

Urbana, IL

  • Member since
    December 2001
  • 1,932 posts
Posted by Stevert on Friday, June 24, 2016 9:59 AM

rrinker

  DecoderPro and DecoderPro3 are two different programs.

Actually, ALL of JMRI is a single program.  The various launchers just present different styles of entry points into the same back-end code.

So say you launch PP, you can still get to all the DP/DP3 functions, etc.  Conversely, if you launch DP/DP3, you can still get to all the PP functions.

For example:  I never actually liked the DP3 interface, so I created a launcher that starts the "old" DP.  All the code is still there, I just launch it in the format I like. 

  • Member since
    September 2003
  • 10,582 posts
Posted by mlehman on Friday, June 24, 2016 3:06 PM

rrinker
You're jumping way ahead if you are trying to select a programmer without getting an interface set up because the comm library isn't there.

Only responding to the squeaky wheel here. The box says it wants that, I'm just trying to give it what it needs. Since there seems to be no succinct documentation on what is needed and in what order to get JMRI running, this tends to throw the beginner in the deep end of the pool, given there seems to be no default "I'm working, now modify me" version of an initial build...I remember swim class, a lot of kids just quit, but that was the 60s and we're smarter about making the entry level more inviting instead of like being hazed at Animal House.

rrinker
If you are unable to select a port, then perhaps the step of installing the comm library IS still needed - what version are you trying to use?

Yeah, as I noted, tried that, didn't work. The JMRI build I've got on it is 3.8. The Raspbian is whatever was fresh there this week.

Speaking of Interface, I do have Serial enabled. I'm still searching for where you set COM ports, so my wife may need to help with that this evening.

Under Preferences, I set the Start Up for Load Default Throttle Layout, which opens fine on boot but remains unrecognized as a throttle. Under Throttles, I've tried both checking and unchecking the Use Extended Throttle box. Defaults offers nothing except "No new-form system connections configured." After taking the (unrecognized) Default Throttle and clicking File, Open Throttle, got some Throttle Preferences, etc to come up in Defaults, helpfully already checked, which suggested I might have to save and restart, so I rebooted and they...disappeared again. Started the Default Throttle again, so tried Save Current Throttle, which brought up a message which suggested File ThrottlePreferences.xml already exists and do I want to override it? Odd, since it can't otherwise seem to find that with both hands. If I Cancel and return to the Default Throttle and only Open Throttle, I get the NCE options already checked again in the Defaults, but it never Saves, so I'm back to nuttin on reboot.

In JMRI, the Throttles option under Tools remains grayed out.

And searching Help for anything on how to load, enable, activate, or give blood to get the comm libraries it demands as ransom to before setting my preference for NCE is, to be kind, unhelpful.

Just wish there was some very basic guidance to get this thing started or for it to have some basic settings on by default or at least linked to choices to try, instead of assuming you have a minty fresh CS degree and the time to parse all the options.

Mike Lehman

Urbana, IL

  • Member since
    December 2001
  • 1,932 posts
Posted by Stevert on Friday, June 24, 2016 4:43 PM

mlehman

 The JMRI build I've got on it is 3.8.

Why in heaven's name would you be using such an ancient version of JMRI?

Version 3.8 was released on July 3rd of last year, so it's darn near a year old.  That's practically forever in terms of how new functionality has been integrated into JMRI.

  4.3.8 is the current test version, and 4.3.9 is scheduled to be released this weekend.  I suggest you use one of those.  Or 4.2.1 at the very least, although that will be superceded by 4.4 in a week or so.

  You probably want to read the release notes, too.  ARM V7 processor libraries were added in JMRI 3.9.2 (released 08/13/2014), with additional ARM updates in JMRI 3.11.6 (released 05/10/2015).

  I'll be the first to admit I'm not a Linux/Pi person.  But it seems to me that if you're trying to set up a version of JMRI *without* the necessary ARM updates, using the instructions for a version that *does* have them, then yeah, you'll have issues.

(As an aside, I've been using the latest JMRI test versions since the 1.1.x series back in late 2002/early 2003.  There is absolutely NO reason not to.) 

Edited for clarity.

  • Member since
    September 2003
  • 10,582 posts
Posted by mlehman on Friday, June 24, 2016 5:59 PM

Stevert
Why in heaven's name would you be using such an ancient version of JMRI? Version 3.8 was released on July 3rd of last year, so it's darn near a year old. That's practically forever in terms of how new functionality has been integrated into JMRI.

Well, it started with needing a comprehensive set of instructions, which I found in this thread: (now lost to Mozilla hosing cut and paste in it's latest build, but about three pages back in the thread where someone wanted Wi throttle connectivity without JMRI and I said why reivent the wheel?)

Somewhere along the way, in some of the older instructional links it linked back to a 3.8 build. Not sure of the path I got there now.

But maybe that's the issue, makes sense. Thanks. Will see what we can do to swap in a new version. I guess sudo-ing an older version doesn't automatically suggest a newer version? Me and the command line aren't good friends, so maybe that went right past me or simply isn't implemented for JMRI builds?

 

Mike Lehman

Urbana, IL

  • Member since
    December 2001
  • 1,932 posts
Posted by Stevert on Friday, June 24, 2016 6:32 PM

mlehman
I guess sudo-ing an older version doesn't automatically suggest a newer version?

  Again, I'm not a *nix person, but I thought "sudo" was just a way to give yourself an elevated permission to perform a restricted task. 

From https://en.wikipedia.org/wiki/Sudo:  "...that allows users to run programs with the security privileges of another user, by default the superuser."

  What I get from that, is "sudo XYZ" would simply let you perform XYZ with superuser privileges.  Kind of like "Run as administrator" in Windows.  

  Don't see how that would somehow turn your old version of JMRI into a new one.

  • Member since
    February 2002
  • From: Reading, PA
  • 30,002 posts
Posted by rrinker on Friday, June 24, 2016 7:29 PM

 Currect, 'sudo' is the linux equivalent of "run as administrator" - it;s what comes after it, whatever is being run, that does the work. sudo apt-get <package> is a way to retrieve and install an application from whichever source repositories you have configured - if JMRI is in any of the common ones, it's likely an older version unless someone is maintaining that, which, given that the official JMRI distribution point is through SourceForge, is unlikely.

                     --Randy


Modeling the Reading Railroad in the 1950's

 

Visit my web site at www.readingeastpenn.com for construction updates, DCC Info, and more.

  • Member since
    September 2003
  • 10,582 posts
Posted by mlehman on Monday, June 27, 2016 9:43 AM

The place you want to be to do this is here: http://jmri.org/install/Raspbian.shtml

Good to see that. I wasn't even looking for it, given most of the RPi and JMRI projects previously involved hacking the Linux distro. I was able to get things working on WiThrottle last night, my primary goal right now since I have visitors from the NMRA National on tap next weekend.

For whatever reason, I wasn't able to grab the roster as a whole and drop it where it needed to be, so had to do each entry manually. That worked for my 40 locos or so, but those with a longer roster list to move might wish there was another way, which there probably is but I haven't found it. Am doing the Turnout Tables tonight, but I have relatively few so not a big deal to simply do it over if I must.

Mike Lehman

Urbana, IL

Subscriber & Member Login

Login, or register today to interact in our online community, comment on articles, receive our newsletter, manage your account online and more!

Users Online

Search the Community

ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT
Model Railroader Newsletter See all
Sign up for our FREE e-newsletter and get model railroad news in your inbox!