Model Railroad Turntable Control - manual; possibly automated feasibility?

Model Railroad Turntable Control with a 6 wire stepper motor

I’m new to Arduino, but have some experience programming in dBase and more in Paradox (about 12 years).

I have a good strong 200 step 6 wire stepper from an old Epson dot matrix printer, and a timing belt that fits the 20 tooth cog. I have a couple other 20 tooth cogs, one to mount to the turntable drive shaft, and on to use as a spring-loaded tensioner.

For manual control I plan to have pushbuttons to select normal, slow or nudge (1/4 step) speed, and a spring loaded center off toggle to run in either CW or CCW rotation. Positioning would be by eye, like the prototype.

But I got to thinking that I could count the total 1/4 steps from some arbitrary reference point to each track position around the turntable, and enter them in an 18 element array (one for each stall, garden, o r enter/exit track plus the zero mark).

Zeroing in could be done by aligning the bridge to some arbitrary scratchmark; given the accuracy and reliability of timing belts like the one in question it shouldn’t have to be re-zeroed very often. Then the user would just select the button for the track you want the control shack end of the bridge to move to.

The control logic would choose the direction of rotation for the minimum number of 1/4 steps from the current location. Slowing to slow speed and then to nudge would be some number of 1/4 steps to be chosen by me on esthetic bases.

Welcome to the Forum. This sounds like a cool, fun project. Are you questioning the feasibility of using an Arduino for this project? - Scotty

Search this forum for previous posts. this is a cool idea.
I think the biggest point of concern is the final alignment. I seem to remember someone offering that a stepper that drives an alignment pin into a receiving pin will lock in a fixed and repeatable alignment.

one motor to get close, the second to make the alignment perfect.

You may find some useful stuff in Stepper Motor Basics

It would be usual to have a micro-switch or optical detector to identify the ZERO position. When the Arduino starts it would drive the turntable to the ZERO position and reset the position counter.

It might be wise to lay the tracks after the motor is made to function. That way you can match them exactly to the step positions.

...R

PS, I wonder if @dave-in-nj meant to say a servo that drives the alignment pin

> It would be usual to have a micro-switch or optical detector to identify the ZERO position. When the Arduino starts it would drive the turntable to the ZERO position and reset the position counter.
>
> It might be wise to lay the tracks after the motor is made to function. That way you can match them exactly to the step positions.

Robin, thanks for a helpful reply. I had read the Stepper Motor Basics material - but noted that it said “This note only relates to bipolar motors and does NOT apply to 5-wire motors or the ULN2003 driver.”

I have several small micro switches in my junk box, and like the idea of the automatic zeroing at power on. And a power switch for the Arduino 5v supply would mean you could re-zero whenever it seemed needed. I think it could be made fairly inconspicuous, or even hidden on the under-table structure.

Best of all, the idea of marking track positions first to match Arduino setpoints and laying track later really makes sense. Minor alignment variations can be easily dealt with, even in as crowded a space as my TT will have. While I plan to operate with manual/visual indexing at first, marking the track centerlines at full step increments (1.8 degrees) would simplify later programming for automated indexing.

At the moment the biggest problem I have is extending the shaft below the slip ring contacts at the bottom end, making it both strong and centered, and leaving me able to undo the set screw on the timing pulley. I have to epoxy a short piece of 5mm rod and keep it centered while it sets.

When I can get my hand on a ULN2004A I may just start with the Knob example for controlling it.

Thanks again.

BrownshoeSailor:
but noted that it said "This note only relates to bipolar motors and does NOT apply to 5-wire motors or the ULN2003 driver."

You said you have a 6-wire stepper. They can usually be treated as bipolar by ignoring (not connecting to each other or anything else) the wires to the coil centres. Equally, they can be used as unipolar if you connect the two centre wires together thus making it a 5-wire motor. Bipolar stepper drivers are probably a bit more expensive than a ULN2003 but they have a lot of extra capability (such as microstepping) and are much easier to use.

At the moment the biggest problem I have is extending the shaft below the slip ring contacts at the bottom end, making it both strong and centered, and leaving me able to undo the set screw on the timing pulley. I have to epoxy a short piece of 5mm rod and keep it centered while it sets.

You might try getting some brass tube in a hobby store that is a snug fit over the motor shaft.

The brass connectors in some of the large-sized chocolate-block connectors may fit the motor shaft and they include screws.

...R

BrownshoeSailor:
Model Railroad Turntable Control with a 6 wire stepper motor

I'm new to Arduino, but have some experience programming in dBase and more in Paradox (about 12 years).

I have a good strong 200 step 6 wire stepper from an old Epson dot matrix printer, and a timing belt that fits the 20 tooth cog. I have a couple other 20 tooth cogs, one to mount to the turntable drive shaft, and on to use as a spring-loaded tensioner.

If you have, or can find, a larger cog, fit that instead to the turntable shaft to give you smaller steps.

The large cogs I've located cost more that all the other parts put together - not counting shipping. I'd love to do it but not at another $30-40 plus shipping.

BrownshoeSailor:
The large cogs I've located cost more that all the other parts put together

This is a Heath-Robinson / Rube Goldberg suggestion but might still work because the load is low.

Get a wooden disk the size of the large cog and glue some pieces of matchstick to it to make gear teeth. Align the matchsticks with the toothed belt while the glue is setting.

...R

I'm not sure witch turn table you have but mine is like this one.

https://jet.com/product/detail/22117152591f4b8e9ce00a6fadbab9b7?jcmp=pla:ggl:toys_games_a3:toys_play_vehicles_toy_race_car_track_sets_a3_other:na:na:na:na:na:2&code=PLA15&k_clickid=eac1ff4d-26c3-49e2-b43d-c4fd9cbca8a8&gclid=CjwKEAjwzdGxBRC3rPWZq83FzyUSJAB9IC5iNecfUFT2o8RPVIeeiXcdS1RiE-ZJKfljeJxQqXrj-BoCy1Xw_wcB

It is indexed and referenced on its own. after turning the crank enough times it stops at the next index even if you are still turning the crank and the tracks are marked where they only fit at a index. I thought about doing this by using a h-bridge and a dc motor, then position indicators either micro switched or led based.

Robin2:
This is a Heath-Robinson / Rube Goldberg suggestion but might still work because the load is low.

Get a wooden disk the size of the large cog and glue some pieces of matchstick to it to make gear teeth. Align the matchsticks with the toothed belt while the glue is setting.

Or, if you know someone with a laser cutter, you can get it cut from ply or acrylic sheet.

for telescopes, they cut their own gears from blanks and then use a threaded rod. not sure how many hundred thousand steps per revolution you are looking for, but a 20 thread per inch threaded rod connected directly to your stepper would need 4,000 steps per inch.
if your gear were say, 6.3 inches in circumference, that would be a 2 inch diameter, about 125 tooth gear
Pi x diameter = circumference.
6.3 x 4,000 = over 25,000 full steps per revolution.with a half step on a great driver like the L298, you would have over 50,000 steps per revolution.
and since you only need to power the motor when in motion, power is not wasted. the worm gear is a locking type of gear arrangement.

http://www.astronomyasylum.com/gears.html

the downside is the speed. if you get your stepper up to 500 RPM, and need to take 50,000 steps.....

I would offer that you should just get a belt from an old scanner and use that. it will offer a great ratio, and with calibrated feedback sensors at the stopping points, you would be able to get it done with a modicum of time and parts.

Hi brownshoesailor,

Looking to do the exact same thing to modify my marklin turntable to a stepper driven by arduino.

How are you getting on ?

Cheers
Bart