# Turntable Project



## fcwilt (Sep 27, 2013)

Hi,

Some time ago I started work on designing new electronics for a Walthers 130' DCC turntable.

The old Walthers DCC implementation left a lot to be desired.

So I set out to come up with something better.

See attached for some idea of what I have been doing.

https://www.dropbox.com/sh/lh9cu03wum0zzlq/AADDU1eKV_v-FgzcNxoIO7w1a?dl=0

The new design includes Arduino based electronics in the bridge. The program running in this Arduino is called the "agent".

There is also a layout mounted Arduino based device. The program running in this Arduino is called the "commander".

Commands are issued to the "commander" which in turn commands the "agent" as needed to carry out the specific command.

Commands can be issue to the commander via a network connection, a LocoNet connection or a IR remote.

A small layout mounted touch screen is being contemplated.


The most recent addition was construction of the "learning units". 

The purpose of these two devices is to simplify programming the lead /storage track positions into the bridge electronics memory.

With the Walthers unit you had to use the DCC controller box to move the bridge into position by eye and store each track setting.

It was not fast, fun or efficient. And correcting mistakes was a pain.

Since the Walthers round house buildings are based on a 10 degree interval a full round house would encompass 36 tracks.

Because of this the new bridge electronics are capable of memorizing the bridge position for up to 36 different locations.

When using the turntable you issue a command to go to one of the programmed locations and the bridge moves to whatever position corresponds to that location.

I wanted to make programming this location information as simple as possible.

The Walthers turntable uses a pit wall mounted IR emitter and a bridge end mounted IR sensor so that the "home" position of the bridge can be established.

The "learning units" are a variation on this idea. 

Both units are designed to fit snugly between the rails.

The smaller unit is placed on the house end of the bridge right at the end of the track with the upright portion facing out. This unit has an IR detector and is tied into the the bridge electronics so the bridge can determine at what position the IR detector is triggered.

The larger unit is a simple battery powered IR emitter. This unit is placed on a lead/storage track close to the pit with the upright portion facing the turntable. 

In use you first issue a "find home" command to establish the "home" position (position zero) of the bridge.

Then you place the larger unit on the first lead /storage track you wish to program and issue the "learn" command.

At this point the bridge starts to turn looking for the IR detector to be triggered. When it is exactly in line with the IR emitter (or very nearly so) it associates the current bridge position with location 1.

At this point the control unit beeps 5 times at one second intervals. During this time you move the IR emitter to the next location you wish to program.

Again the bridge starts to move and when the IR detector is again triggered the new position is associated with location 2.

This process is repeated until all 36 locations are programmed OR you leave the IR emitter on the last location programmed.

In either case the "learning" process ends and you are done. 

Nothing done by eye - no fiddling with the bridge location via the controller. 

You just have to get the IR emitter placed on the desired track within 5 seconds (or whatever time I ultimately settle on).


Should any location need to be adjusted slightly over time there are commands to move the bridge by as little as a single position and update the location with the new position information. 

A complete rotation of the bridge encompasses appx 62,000 positions - so moving by a single position is quite a fine adjustment.

Anyway there is a lot more to the new design then what is discussed very briefly above but I mostly wanted to mention the "learning units" and how well the idea turned out to work in practice.

If anyone wants more info please post your questions.

Thanks.

Frederick


----------



## wvgca (Jan 21, 2013)

interesting project 
pictures?


----------



## fcwilt (Sep 27, 2013)

wvgca said:


> interesting project
> pictures?


Didn't the Dropbox link work?

Frederick


----------



## Peter Herron (Jun 30, 2015)

*Frederick, you know if this works...............*

.............you could probably start a cottage industry selling RTR units and quit your day job! All I see is how crappy the Walther's turntable indexing system is. 

Peter


----------



## Peter Herron (Jun 30, 2015)

Oh, forgot to say it's nice to see a "how to" post instead of "how to vote" post.

Thank you, sir...........

Peter


----------



## jlc41 (Feb 16, 2016)

fcwilt, are the agent and commander units you buy or did you build them? Do they come with the programs or did you program them? Very interesting, accurate indexing and smart. I like it, good stuff.


----------



## fcwilt (Sep 27, 2013)

Peter Herron said:


> .............you could probably start a cottage industry selling RTR units and quit your day job! All I see is how crappy the Walther's turntable indexing system is.
> 
> Peter


Walther's has a new system but I haven't investigated it.

One other thing I didn't like about the Walther's system was the cheap commutator - it tended to get out of adjustment and it was tedious to get it just right.

So I replaced that as well using a closed 12 circuit unit. I only needed 6 circuits so I was able to use 2 commutator circuits for each circuit I needed thus gaining some redundancy.

Time will tell how it works.

One interesting thing was that the diameter of the larger of the two commutator units that I found for sale on Adafruit was EXACTLY the diameter of the Walther's bridge "shaft".

You can see in the picture of the underside of the bridge the black commutator with the wires coming out of it and leading down and out through the hole in the Walther's pit. 

All I had to do was remove the little Walther's circuit board that was mounted to the end of the "shaft" and securely glue the commutator in place.

A perfect fit - just sheer dumb luck - love it.

Frederick


----------



## fcwilt (Sep 27, 2013)

jlc41 said:


> fcwilt, are the agent and commander units you buy or did you build them? Do they come with the programs or did you program them? Very interesting, accurate indexing and smart. I like it, good stuff.


The electronics in the bridge is a combination of a Arduino "mini" (now obsolete) and a piece of copper clad perf board with electronics of my own design.

One other thing I added was four IR position sensors up on the bridge deck. I run my layout via TrainController and I needed a way to accurately report to TrainController that the loco was positioned correctly on the bridge - on the bridge not hanging over the end.

The electronics in the layout mounted controller consists of a Arduino Mega2560 processor board, a Arduino Ethernet shield (now obsolete) and a prototyping shield with electronics of my own design.

The "proto-shield" holds the circuitry for:
- power to the bridge electronics
- the I2C communications link to the bridge Arduino "mini"
- the LocoNet connection for TrainController
- the power connection for controlling the pit LED 
- the power/signal connections from a little IR receiver

Both Arduino units are running programs of my own design.

It was a good deal of fun working out how best to make all of the bits and pieces play nicely together.

It all works better than I hoped for.

Frederick


----------



## wvgca (Jan 21, 2013)

fcwilt said:


> Didn't the Dropbox link work?
> 
> Frederick


didn't last night, but fine now ..


----------



## fcwilt (Sep 27, 2013)

wvgca said:


> didn't last night, but fine now ..


The picture files are rather large so I guess they were still being uploaded.

Around here I only have DSL service with a blazing download speed of 5 Mbs and an equally impressive upload speed of under 1 Mbs.

Sigh...

Frederick


----------



## wvgca (Jan 21, 2013)

fcwilt said:


> Around here I only have DSL service with a blazing download speed of 5 Mbs and an equally impressive upload speed of under 1 Mbs.
> Frederick


mine is exactly the same speed, with sasktel, for $45 a month ..
still, better than nothing, or dialup ..


----------



## Lemonhawk (Sep 24, 2013)

I think most sites are geared to about 10 mega bits/sec. The advantage of a high bit/rate connection is that multiple people in the household can be on at the same time and enjoy that 10 mbs..


----------



## Lemonhawk (Sep 24, 2013)

But back to the topic, I have always wanted to build a turntable and even of more interest was ways to index it. And now we have a fresh approach to indexing. I read with great interest. --- and my 85 mbs up/down speed will be exercised


----------



## Odyknuck (Dec 31, 2015)

Impressive . Curious what do you do for a living? So wheres mine lol.

Sent from my SM-G920V using Tapatalk


----------



## fcwilt (Sep 27, 2013)

Odyknuck said:


> Impressive . Curious what do you do for a living? So wheres mine lol.
> 
> Sent from my SM-G920V using Tapatalk


Thanks. On the bench it is working well. 

I am doing a lot of testing to be sure all is well before I actually install it on the layout.

I'm retired but I worked as a digital circuit designer, then programmer for many, many years.

That background helped a little. 

Frederick


----------



## Odyknuck (Dec 31, 2015)

Yea,i expected as much.

Sent from my SM-G920V using Tapatalk


----------

