On the same trail...
Dear Charlie,
I've both been-on, and am-currently-on a similar path. Here's what I've learned.
Where I've been
- Early Wathers/Helijan non-DCC HO turntable, converted to dual-gauge On2/On42
- Drive/Indexing circuitry by our own Pelsea's "Arduino Driven Turntable"
https://model-railroad-hobbyist.com/node/28501
/> https://model-railroad-hobbyist.com/node/28501/?page=3/#comment-272281
- Original drive system was a common Arduino 28BYJ-48 stepper motor + ULN2003 driver
https://www.jaycar.com.au/arduino-compatible-5v-stepper-motor-with-controller/p/XC4458
/> https://www.jaycar.com.au/medias/sys_master/images/images/9594847035422/XC4458-dataSheetMain.pdf
fed thru a repurposed Ath Bluebox diesel truck
(RH gearbox with worm drive, 14:1 ratio, and easily tuned for minimum backlash)
The initial testing looked very promising, even under an actual 1 kilo (2.2pounds) of brass loco,...
...but then, for "reasons lost in the sands of time", (something about "layout built with no clear leadership"?)
the proposed Ath-truck gearbox solution was replaced with a scratchbuilt 90-deg 1:1 ratio spurgear gearbox
(milled styrene gearbox frame, brass hardware and shafts, 3d print gears)
The result was that the gearbox failed to provide either the required torque, step-ratio accuracy,
(as you've already worked out yourself),
and essentially failed to hold together in any meaningful way,
rendering the turntable "non-functional" for the layout's debut show... :-(
("...mistakes were made, lessons were learned, we moved on swiftly and don't generally talk about it...")
Where I'm at right now
- A 40" long, 5-track "train staging turntable" in On2
(think about that, fully loaded, that's almost 10 kilos of train, + the turntable itself)
- Sitting on a metal roller-bearing "lazy susan" bearing pivot unit
- Again, controlled/indexed by the self-same Arduino stepper motor unit C/O Pelsea's excellent threads above
- With an upgraded Stepper motor driver array (more on this later)
- driving a NEMA17 100:1 gearhead Stepper motor
https://www.omc-stepperonline.com/precision-planetary-gearbox/nema-17-stepper-motor-l39mm-gear-raio-1001-high-precision-planetary-gearbox-17hs15-1684s-hg100.html
- This motor is mounted vertically, and coupled directly to the turntable, with a horn/slot coupling.
(No intermediate gearbox, no 90-deg gearbox or worm, 100% rigid-lock rotation-transmission while tolerating any slight out-of-perpendicular alignment in mounting between the motor and the turntable deck).
The resulting rig has a step-angle of 0.018deg, which gives an arc-length per step on a 40" turntable-end of 0.006".
FYI, given a piece of PECO Code 83 rail has a railhead width of 0.030",
0.006" (5-steps across the width of a railhead) is well-enough "step granularity" to achieve required alignment...
It also delivers around 60kilos of torque (15nm), so more-than-enough to handle the proposed Turntable+Load from a standing start, and a standing-stop!
The Gotcha is the Volt/Amp behaviour. While the specs say the motor draws 1.68Amps (per coil, x2),
reading further that's at 2.7 volts.
I'll admit I missed this detail,
tried to drive it using ONE L298P stepper motor driver (2A per H-bridge) at 12Volts,
which means I tried to drag 2x 7.5Amps out of the poor hapless L298P driver circuit,
and somehow managed to NOT let the smoke out!?!?!?!?
(some DCC++ fans have said that the L298P H-bridge doesn't have adequate "over-current protection",
but I took a pair of L2998P driver units well over 4x their MAX rated current, and they somehow survived to fight another day!!!)
After powering the entire smelly (but NOT smoky!), obviously unhappy rig down,
taking a good long night's sleep,
and re-assessing the whole situation in the cold hard light of day,
I realised:
- If I use a 2-channel L298P driver unit
- in "Bridged Mode" (both channels of the unit wired in parallel, and working as a 4Amp-capable team)
- multiplied by 2x L298P units (One of the Bridged L298P per coil, the motor having 2x coils)
- each L298P powered by it's own 5Amp 5Volt PSU
(That's 2x 5Amp 5V PSUs for the "driver circuits", + a lower-current 5VDC PSU for the Arduino "brains")
the resulting rig:
- achieves the stated 0.018deg/0.006"-per-step accuracy (20000 steps/rotation)
- while staying well within "operating temp" specs
- easily handling over 2x the expected operating load, inc "inertia loading" (stopping and starting consistently/accurately)
- and achieving a full-speed rotation in 60 seconds
In terms of "the seeking of speed", I would suggest:
- Remember that, unlike a regular Permanent magnet motor (loco motor),
Voltage is not directly relevant to speed of a stepper. Rather, it's all down to the switching speed/code speed of the drive circuitry. Increasing the Operating Voltage of the "driver" part of the circuit will only increase the Strength/Torque and Current-Draw of the system, NOT the Speed!
- Make sure your Arduino code is optimised, ANY excess-lines in the sketch inc comments only serve to Slow-Down the speed the Arduino can run-the-code-loop and do a "stepper output state update"
- If you have "Serial Print" statements in your sketch, IE so the Arduino IDE can give you are readout of "Current step position", etc, remove them once you're comfy the Arduino code works.
I found that my unit would actually change speed of Stepper-motor steps as the # of characters in the "current position" serial readback changed.
EG given an acceptable speed when the Serial Monitor was showing "Current step = xx" (tens of steps),
the motor moved Slower when it jumped-up to "Current step = xxx" (hundreds of steps)
and slowed again when the Serial Monitor jumped-up to "Current step = xxxx" (thousands of steps),
and slower-still when we stepped up to "xxxxx" (10,000s of steps).
By eliminating the "Serial write 'current steps' " lines in the sketch, the motor sustained a constant speed,
(set by the potentiometer in Pelsea's Arduino Turntable circuit),
all the way from "Step 1" to "Step 20000", and even when it "wrapped around" from 20000 -> 1...
I'm not sure if these experiences and musings help, but assuming a decent-spec NEMA motor and mating gearbox (remember, Overkill is Under-rated, esp in "I don't care what gets thrown at the system,
I want it to Just Work" situations, it's called "Ensuring Adequate Headroom"),
you should be able to achieve a "low single-digit minutes per rotation" performance from your turntable...
If you'd like any pics of the example parts and circuitry mentioned above, just holler...
Happy Modelling,
Aim to Improve,
Prof Klyzlr