Jump to content
 

JMRI IR detection


Brian Joseph
 Share

Recommended Posts

Hi

 

I am interested in using IR to detect trains at numerous locations including the fiddle yard, station and goods yard on my layout.

I am using JMRI software through a Digitrax Zephyr Xtra controller using a LocoBuffer USB. Static decoders are Lenz ls110s & ls150s.

 

I would appreciate any ideas or information about if and how I could do that. In particular, what hardware is available and how can I connect it with my set-up.

 

KR,

Brian

Link to post
Share on other sites

IR Detectors, numerous of them, either DIY or commercial such as IR-DOT.  

 

Connection to computer, go via LocoNet based input devices.  I've used LocoIO boards (DIY assembly), or could use Arduino based equivalent boards these days (cheaper and also DIY).   There are commercial equivalents. 

 

Are you prepared to self-assemble the electronics, or must it come ready-to-use ? 

Link to post
Share on other sites

Thanks. I haven't done self-assembly before but I would be happy to give it a go. I would need to be reasonably straightforward. Have you any recommendations?

What I would like to know is how the information gets from the IR detectors back to the computer?

 

Hi,

 

If the LocoNet input device is supported by JMRI then plugging the input device into LocoNet (connected to computer via your LocoBuffer USB I guess), you can then set up JMRI Panel Pro to set the used inputs of the LocoNet input devices as sensors.

 

With your IR detectors connected to your LocoNet input device connected to your Loconet and LocoBuffer start JMRI Panel Pro and

select Edit/Preferences/Connections. Create new connection, Select Digitrax from the list and then select LocoNext LocoBuffer USB from the system connection list.

 

Then press the Save button in preferences. You may be prompted to restart JMRI. Do this.

 

You now have each of the IR sensors physically connected to the computer via the hardware above and JMRI.

 

On restart of JMRI select Tools/Tables/Sensors. You will then see a list on the middle of the screen. There should be a tab in that list saying LocoNet.

Click on that tab and you are now in a position to add LocoNet sensors to JMRI. I cant help with the numbering scheme for LocoNet inputs - I use NCE at present, but the info may be on the internet.

 

Add sensors by pressing the Add button. If you have more than one sensor to add and they have consecutive numbers then there is an option to do that on the right hand side of the dialog box.

 

Once you have your sensors added to JMRI save the Table away with File/Store/Store configuration only to file.

 

You can test the numbering is correct by waving your hand in front of the IR detector and the appropriate box in the Sensor table you've created should change to Active and then back to Inactive when you remove your hand.

post-29876-0-25488200-1506268896_thumb.png

 

If you create a control panel on the screen in JMRI then you would use the references created by JMRI to link to those sensors. So a Loconet sensor number one might be called LS1 by JMRI and that is what you would type or select when adding it to a control panel. The same reference would be used for JMRI Logix.

 

Regards

 

Nick

Edited by NIK
  • Informative/Useful 1
Link to post
Share on other sites

Thanks. I haven't done self-assembly before but I would be happy to give it a go. I would need to be reasonably straightforward. Have you any recommendations?

What I would like to know is how the information gets from the IR detectors back to the computer?

 

Pretty much as Nik describes it.  

Only key point is that just about any LocoNet input device (bought or DIY build) suitable for an IR sensor will automatically create a LocoNet sensor message, so its picked up automatically by JMRI.  No need to actually create them in the table. Some report their presence automatically, and if not, just cause them to trigger (put something over the IR beam) and JMRI will register their presence in the Sensor table.   Then save things to a Panel file and you go away from there.

 

 

Devices;

 

LocoIO comes from Hans De Loof in Belgium, he sells boards/kits through a shop in Belgium which is fine supplying the UK (I've bought stuff from there).   Instructions are decent, in English, its all through-hole assembly (ie. much easier than surface mount would be).  Read the instructions, there is a fairly large parts list needed. 

And a "BUT", because you have a RR Circuits LocoBuffer, there is a problem doing the initial setup/programming of the LocoIO - the utility Hans supplies doesn't work with the RR Circuits LocoBuffer ( it works with the LocoBuffer that Hans supplies, but there seems to be a subtle difference between them).   So, you'll need to find the alternative setup programming software from Jeff Law in New Zealand.  Once programmed, they will work fine with the RR Circuits LocoBuffer. 

 

Arduino LocoIO equivalents, numerous articles on the internet for them.  There is a PCB "kit" from Peter Giling in the Netherlands which provides the interface between the Arduino processor and the LocoNet.   That simplifies things a lot.   Part CGA185 on http://wiki.rocrail.net/doku.php?id=gca:gca-index-en/

 

A bit of reading needed before setting out on either path.

 

 

If going to "WorkShop Wise" organised by an EM Gauge Society group in Northumberland in mid October, I plan to be there and could have some LocoIO stuff with me if needed. 

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
 Share

×
×
  • Create New...