# Automated Train Control?



## dpersian (May 10, 2017)

Hi, I'm a new member here. I've always loved trains and I had a pretty nice O scale setup when I was younger. Anyways, I'm planning on making a whole new setup in the HO scale since I'd be able to fit more things in terms of trains/scenery/ together to make it look more realistic (basically something cool). 

I've seen a couple of videos on youtube showcasing layouts that were completely automated and I was drawn to the idea immediately. I wanted to know if any of you guys have experience with this kind of stuff and if you are able to recommend any systems/setups for this. I'm interested in things that would make my layout completely autonomous or close. I'm not concerned with cost. If possible, it would be cool if the tracks could switch themselves as well (you get the idea, a setup on autopilot the whole time).

I suppose any additional details involving what I mentioned and what I would want to be automated would be the following:
-Trains
-Vehicles
-Crossings
-Signals
-Switches/Junctions

I would prefer a system that would be controlled via software on a computer where I can program things, for example, a train stopping at a station for a set period of time and then departing. Thanks


----------



## gunrunnerjohn (Nov 10, 2010)

Your post was trapped in our SPAM filter, I've released you.


----------



## fcwilt (Sep 27, 2013)

dpersian said:


> I would prefer a system that would be controlled via software on a computer where I can program things, for example, a train stopping at a station for a set period of time and then departing. Thanks


So you are starting from scratch?

Full automation can be a little pricey.

My layout is fully automated - a quick summary:

The software is TrainController: http://www.freiwald.com/pages/traincontroller.htm

The hardware is from the RR-CirKits Simple Serial Bus (SSB) product line: http://www.rr-cirkits.com/

The web site is not much to look at but the products are very cost effective, the design is top notch, the installation is simple and the support is great.

I started with as mix of hardware from different vendors including Digitrak and others. Someone put me on to RR-CirKits. After getting some samples in-house it was clear to me that RR-CirKits was the way to go.

So I sold all the other gear and purchased the components I needed from the SSB line.

If you would like more details let me know.

Frederick


----------



## DonR (Oct 18, 2012)

If you are technically oriented you should have little
difficulty going into DCC systems that work with
computers to control your layout. There are DCC
decoders that are used to throw turnouts as well
as to control the locomotives. You also need a detection
system so the controls know where your trains are
at all times to avoid collisions.

There have been several threads that discussed
automated layouts. One of them showed a layout
with several running trains that stopped and
started under computer control. Check our Technical Forum for
threads related to it.

Here's one of them:

http://www.modeltrainforum.com/showthread.php?t=126761

Some of our members are working with arduinos to
automate their layouts and that is discussed in the
Technical Forum.

Don


----------



## RT_Coker (Dec 6, 2012)

Do you want layout-automation (do you like to tinker, fix & clean), or reliable-layout-automation? 

Reliable-layout-automation is difficult to achieve (and to maintain) when control is on signals traveling through the rails (DCC). As an old embedded-systems-engineer I found DCC disappointing for even a medium size layout. There are a number of new solutions that provide wireless HO locomotive control, but be careful (to my knowledge) they all have proprietary-interfaces. 

Before you pick an automation approach, I would take a good look at what is behind-the-scenes (under-the-layout, behind-the-controls,…). 
Bob


----------



## fcwilt (Sep 27, 2013)

Relying on DCC for automation is not something that is typically done.

All of the control and sensing aspects of my automated layout use LocoNet which is designed to just those purposes.

DCC is still used for running of the trains but that is all.

I have found TC and the electronics to be very reliable. 

The main problem I have is some turnout linkages I made. The solder joints between the steel and brass parts have not be reliable. It turned out I used the wrong kind of solder and flux.

Frederick


----------



## johnfl68 (Feb 1, 2015)

For DCC layouts, many people are doing this with *JMRI*:

http://jmri.sourceforge.net/

Depending on which DCC system you use, and how it can be connected to a computer interface, this will then allow from the simplest to very extensive control and scripting based on how carried away you want to get.

It has a fairly large community, and is updated and features added on a regular basis.


----------



## RT_Coker (Dec 6, 2012)

I briefly looked in to doing the sensor-part of layout-automation using a camera(s) above the layout. It should not be too hard to detect track occupancy by software-comparing the current image(s) with a baseline no-occupancy image(s). Plus the camera(s) would be useful for other things as well. Of course hidden areas would require extra camera(s) or …

Unfortunately the software work was out of my comfort zone. It would not surprise me to find out that someone has already used this approach. As you can probably tell I don’t like the idea of having to run a lot of wires.
Bob

Found one here:


----------



## dpersian (May 10, 2017)

Details on this approach would be great since I've researched automation software and came across this exact one from Freiwald. I'm great with computers (I'm 20) but I'm a bit shaky with wiring so I'm hoping the wiring for this kind of stuff isn't daunting lol


----------



## fcwilt (Sep 27, 2013)

dpersian said:


> Details on this approach would be great since I've researched automation software and came across this exact one from Freiwald. I'm great with computers (I'm 20) but I'm a bit shaky with wiring so I'm hoping the wiring for this kind of stuff isn't daunting lol


The wiring using the RR-CirKits SSB devices is fairly simple if you follow the instructions.

But if you take it step by step it is not difficult.

The hardest part for many folks is that the SSB devices need to be configured using JMRI Decoder Pro and "programming" is not something they have a had experience with.

For example each SSB device comes from the factory with a default address. But to have multiple devices connected to the SSB "bus" each device needs to have it's own, unique address.

Otherwise TrainController could not communicate with each device separately.

Changing the address involves several simple steps and once you've get the hang of it the process goes quickly.

But if you skip just one step things are not going to work and that can cause some folks to freak a bit at first.

There are other settings that need to be changed but again if you do it step by step and are careful it is easily done.

Frederick


----------



## RT_Coker (Dec 6, 2012)

dpersian said:


> Details on this approach would be great since I've researched automation software and came across this exact one from Freiwald. I'm great with computers (I'm 20) but I'm a bit shaky with wiring so I'm hoping the wiring for this kind of stuff isn't daunting lol


Well there are not many “(I'm 20)”s that are “not concerned with cost” in the hobby. The hobby can certainly use all it can get! I am only 23½. However my body and mind are aware that that ½ is half-a-century.

What “Freiwald” has done is very interesting and commendable; but needs some more thought/work, in my opinion.
Here is another image processing approach (something like an optical-intrusion-detection would use):
1.	Make a baseline no-occupancy image. Do not allow (or adjust for) any overall lighting changes.
2.	Mask everything out of the images but the visible track.
3.	Difference the current image with the baseline no-occupancy image.
4.	Identify areas in the difference image that are large enough to be potential locos/cars.
5.	Check that these areas do not have the characteristics of the layout track.
6.	…
Bob


----------



## dpersian (May 10, 2017)

fcwilt said:


> The wiring using the RR-CirKits SSB devices is fairly simple if you follow the instructions.
> 
> But if you take it step by step it is not difficult.
> 
> ...


Quick question, I'm currently making a list of the locomotives I plan on buying and I see that there are variants that include "DCC". Would I need a DCC equipped locomotive for this or not? I see that there is a drastic price difference in locomotives not fitted with it.


----------



## fcwilt (Sep 27, 2013)

dpersian said:


> Quick question, I'm currently making a list of the locomotives I plan on buying and I see that there are variants that include "DCC". Would I need a DCC equipped locomotive for this or not? I see that there is a drastic price difference in locomotives not fitted with it.


Yes you will need DCC equipped locos.

Now many DCC equipped locos will have sound which makes them more expensive than a DCC loco without sound.

You can find DCC "ready" locos which don't come with a DCC decoder but with a socket into which you can plug a DCC decoder.

Since you can use a non-sound DCC decoder in these you can save money with a bit of work.

It is possible to equip a "DC" loco with a DCC decoder even when they don't have a socket BUT this is going to be more work and in some cases a lot of work.

Frederick


----------



## D&J Railroad (Oct 4, 2013)

One of the most important points in all this is that you choose a system that you can get support with, including on the forums like this one.


----------



## dpersian (May 10, 2017)

RT_Coker said:


> Well there are not many “(I'm 20)”s that are “not concerned with cost” in the hobby. The hobby can certainly use all it can get! I am only 23½. However my body and mind are aware that that ½ is half-a-century.
> 
> What “Freiwald” has done is very interesting and commendable; but needs some more thought/work, in my opinion.
> Here is another image processing approach (something like an optical-intrusion-detection would use):
> ...


I like this idea, however I have too many constraints for an image based solution. Basically I'd like to have the ceilings in the area I'm using clean, so nothing sticking out or anything. I also plan on having the lights in the area to be set to a timer to replicate a day/night cycle meaning that an image based solution would struggle unless I compensate by get more sensitive cameras or mounting a bunch of infrared lights which pretty much kills the point of having a clean ceiling to begin with and complicates things even more lol


----------



## JerryH (Nov 18, 2012)

dpersian said:


> Hi, I'm a new member here. I've always loved trains and I had a pretty nice O scale setup when I was younger. Anyways, I'm planning on making a whole new setup in the HO scale since I'd be able to fit more things in terms of trains/scenery/ together to make it look more realistic (basically something cool).
> 
> I've seen a couple of videos on youtube showcasing layouts that were completely automated and I was drawn to the idea immediately. I wanted to know if any of you guys have experience with this kind of stuff and if you are able to recommend any systems/setups for this. I'm interested in things that would make my layout completely autonomous or close. I'm not concerned with cost. If possible, it would be cool if the tracks could switch themselves as well (you get the idea, a setup on autopilot the whole time).
> 
> ...


 Here is my version of where you are going. It is a long thread but should help you understanding your project as it is a start to "finish" how it was done.

http://www.modeltrainforum.com/showthread.php?t=14852


----------

