Jump to content
Sign in to follow this  
Kris

Raspberry Pi setup for model railway

Recommended Posts

This is my own take on the setup for the Raspberry Pi to run JMRI – there are probably different (and probably better) ways of doing it, but this is what worked for me! Anything I recommend should be taken with a pinch of salt, especially if you know what you’re doing around Linux (which I don’t) and have a more elegant way of doing it!

I have split it into 2 parts for ease of reading and because I can't upload more than 10 (albeit dodgy) photos.

Part 1

The first step is to connect everything together and use a TV with HDMI inputs, plug in a WiFi dongle, keyboard and mouse. We will set the Pi up to use without a monitor later on, but you will need one to start with.

NOOBS operating system

I would recommend this page...

https://www.raspberrypi.org/help/noobs-setup/

...and also download SD Formatter 4.0 for either Windows or Mac from the link on the same page. It takes you through how to put the data on the SD card following formatting. I have tried a couple of other operating systems, but this is the only one that worked the way I wanted it to.

This is the first screen on bootup. Select “Raspbian [RECOMMENDED]” option

1.jpg

2.jpg

3.jpg

4.jpg

5.jpg

6.jpg

7.jpg

Share this post


Link to post
Share on other sites

Now we're into desktop mode...

Click the start button just like you would a Windows PC, and navigate through the drop-down menus to the WiFi configuration tool (you can use a mouse this time)

Now Ctrl+X to exit, then Y to agree to save, then enter. You have just created all the files and passwords required to start X11VNC when the Pi starts.

Your mobile device

Download a VNC app onto your mobile device - I use the free versions of “VNC Viewer” for my Android phone, and “Mocha VNC Lite” on my Ipad. These are really easy to set up.

Once they’re installed they will ask you for a connection. Remember the IP address and password you wrote down earlier? Here’s where you need them. Enter the IP address followed by :5900 (so it looks like 192.145.21.1:5900). This is the port on which you will access the screen output of the Pi. Don’t worry if you don’t understand that bit, just make sure you do it! Some web guides will tell you that you can connect to the Pi by using name, but I found that to be extremely unreliable for some reason; the IP and port has always worked. When it asks for the password, that’s the other bit you wrote down earlier…

The test

Shut the Pi down, and unplug it from everything. Now power it up and give it about a minute.

Open your mobile VNC app, and click on the connection you made. You may need to enter the password again depending on the app you’re using.

You should now see the desktop of the Pi on your mobile gadget. It’s a bit slower that running it straight from the HDMI output and you may need to scroll about to see all of the screen, but from there you can launch whichever JMRI software you want. Once it’s running you can forget all about the Pi desktop as the mobile throttles will communicate directly with JMRI without anyone needing to know what is going on with the Pi itself. Just make sure that you log back onto the Pi with the VNC to shut it down properly, otherwise you can ruin the SD card by just unplugging it.

As I’ve said previously, there are probably more elegant ways of doing this, but this is just a walk-through of the method that worked for me.

Good luck

8.jpg

9.jpg

10.jpg

11.jpg

12.jpg

Share this post


Link to post
Share on other sites

Just to add that I would probably do all the setting up of the JMRI stuff while it's connected to a TV and while you have a keyboard and mouse. There is a zip file on the JMRI website to download, and the rest is fairly self-explanatory, and it's explained very well on the website. It will definitely save some frustration later on doing it in this order.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...