Tag Archives: Electrical

WiThrottle and DCC++

One of the major design points for my shelf switcher layout is a compact way to power it.  Well, I pretty much have that ready now.

I put together a DCC++ Base Station using an Arduino MEGA board, an Ethernet shield and a Pololu MC33926 motor shield, then I added a TP-Link TP-WR802N pocket router for wireless connectivity.  I then worked on the software a bit, and added the ability for the DCC++ Base Station to communicate with the WiThrottle (or Engine Driver if you’re Android) app on my iPhone.

Now, when I install this in the shelf layout, I’ll be able to control the trains from my phone for a pretty low price…

Here’s a video of the gear in action…

February Progress Update

I’m a little surprised that it’s been over a month since the update video! Looks like I should be getting the camera out again. Progress has been slow, and not always photogenic, but there have been a few changes worth reporting on in the last six weeks. Lots of “real life” things going on right now that are keeping me from moving forward, but even slow progress is progress!

This post will be something of a mixed bag of content, since there are several different work items going on, and I feel I need to get the blog caught up quickly.

Structure Mock-Up

First up, this is a construction paper mockup of the Commonwealth Paper Products structure that will be on the narrow shelf behind the entry door.
Commonwealth Paper

I drew the building structure in SketchUp, and then printed 2D views of the model to glue onto a core that I built from cereal boxes. I think it’s a pretty convincing stand-in, and I plan to do these for many of the structures on the layout.

Custom Electronics

Next we have a couple of different electronics projects… a trio of CDU-based Kato turnout controllers that I built for a friend, and the completed control circuit for my animated swing gate.

Kato Crossover Controls

The CDUs are based on an integrated design I have that incorporates a switch and indicator LEDs, but my friend wanted to mount these remotely from his control panel, so I provided connectors for the switch and LED. These are a very simple design (not mine, just adapted), and the selected capacitor is powerful enough to handle a double crossover.

Stepper Motor Control

The swing gate control board has screw terminals for all of the motor, sensor, and control connections, and sockets for an Arduino Pro Mini and a stepper motor driver. This is ready to hook up, once I solve the mechanical issues with connecting to the shaft of the swing gate itself.

New Power

CXST1141 Atlas MP15DC

This is the latest addition to the power roster, an Atlas MP15DC that I bought second-hand from a friend and that will be used in the yard. It’s DC for now, but I will upgrade it to DCC soon. I’ve tested it on the branch line, and it runs quite well.

Dixie Cup Factory Model

I’ve built up a SketchUp model of the Dixie Cup factory as well…

Dixie Cup Mockup

Dixie Cup Mockup

Dixie Cup Mockup

New Lighting

Finally, I replaced the ceiling fan in the room with a much, much brighter 4-tube fluorescent lighting fixture with 5000K daylight tubes. It’s almost too bright in here now!

New room lighting

As part of the lighting upgrade I also moved the wall switch for the room down below the layout deck. The “standard” switch location was behind the backdrop and would be impossible to reach once scenery was in place.

New room lighting

The new wall switch incorporates a very convenient outlet that will help with working on that part of the room.

That’s all for now! I have some track laying progress to report, but I will include that in a separate post after I take some better pictures with the new lighting.

Con-Cor / Rivarossi N Scale 4-6-2 “Pacific” Decoder Install (Part 2)

In Part 2 of this install, we’ll explore the trickiest problem involved in this install:  connecting power from the tender to the locomotive.

[youtube=http://youtu.be/-s0yAFzUSAc]

Older versions of the Rivarossi 4-6-2 used a plastic drawbar, and only the little spring wire pressing against the drawbar pin in the locomotive to transfer power.  For a DC locomotive, this turned out to be a fairly poor design, but for a DCC install, it makes isolating the tender from the motor pickups easy.

(Un)fortunately, this version of the model uses a metal drawbar, which is much better for ensuring good power transfer under DC, but makes it much trickier to isolate the tender from the motor.

A few options that either I considered or were suggested, which I rejected (and the reasons why):

  • Enlarge the hole in the loco end of the drawbar and put shrink wrap over the drawbar pin.  I was concerned about friction and wear on the shrink wrap, so no.
  • Replace the drawbar with a plastic one.  This would have been an excellent option if I could have disassembled the pin at the tender end.  I couldn’t figure out how without destroying it.
  • Insulate the axle wipers from the bar rivets and wire directly to them.  Again, I was concerned about wear, and I just didn’t have the parts.

In the end, the simplest solution seemed to be to cut the brass bar.  It would have been much easier if I could have removed it from the tender first, but it’s riveted in place, so no.  Instead, I used a drill press to drill up from the bottom where there’s an opening in the plastic, and then cut the rest of the way through the bar with a Dremel tool and a reamer bit.  I did a somewhat messy job of it, but it worked.

Here’s a view of the bottom of the tender before the cut. You can see the opening where I made the cut on the left.
Untitled

Once the cutting was done, I soldered a piece of wire to the bar in the middle of the tender and routed it through the hole to the front near the drawbar. At the drawbar end of the wire, I attached one pin of a NEM651 female connector and shrink-wrapped the connection.

Untitled

Finally, I finished the end of the wire coming from the loco with a single pin of a NEM651 male connector. At that point, we’re done except for buttoning things up and testing her out.

Untitled

I found when testing that with the female socket secured to the tender, it was very difficult to connect up the locomotive on the track. The quarters are very tight between the cab and tender, and I had cut the loco wire just a tad short. By leaving the plug loose, I was able to bring it out of the tender enough that the wires can be connected before the drawbar is hooked up. Much easier, and with everything being black it still looks OK. We’ll see what the customer thinks. I hope he likes it.

 

Con-Cor / Rivarossi N scale 4-6-2 “Pacific” Decoder Install (Part I)

I was recently asked by a friend to install a decoder in an N scale Con-Cor / Rivarossi 4-6-2 “Pacific” locomotive. It seems that install instructions for this model are scarce, so I will share how I managed.

DCC decoder install in a Con-Cor/Rivarossi 4-6-2
(shown with the steam-dome shell screw partially removed)

This locomotive model has an odd (really, just old) method of pickup. The fireman’s side (left, going forward) rail is picked up through the drivers, while the engineer’s side (right, going forward) is picked up through the tender. Power is transferred from the tender to the engine through the drawbar and a stiff bit of spring-wire that contacts a peg sticking down below the cab.

This is actually the trickiest part of the install. The drawbar peg on the engine is directly connected to the lower motor brush, and the drawbar itself is conductive. So in order to isolate the motor from the rails, you have to somehow insulate the drawbar and provide an alternate path for the tender pickup to the decoder. More on that later.

For this install we chose the Digitrax DZ126T as the best balance between cost and size. The TCS Z2 (also a good choice) is slightly smaller but more expensive. The Lenz LE077XF is only a little more expensive than the Digitrax, but is the largest of the three. Any of these would work, though, and would follow the same basic install process.

The first step is to locate a good spot to fit the decoder, and do any necessary milling or other modifications to make room. Another install page showed installing the Lenz decoder under the cab roof, after some milling to the inside of the roof and to the top of the frame. On looking at the frame design, I decided to fit the decoder into the boiler where the upper headlamp contact is. There is room for the DZ126T at that location without any frame modifications.

DCC decoder install in a Con-Cor/Rivarossi 4-6-2

Remove the shell by taking out the screw in the top of the steam dome on the boiler and then spreading the firebox sides slightly. It is a tight fit, but with some shaking the frame will drop out. Next, remove the two headlamp contacts from the center of the frame and disconnect the black wire running from the upper contact to the rear of the locomotive. Keep the lower contact. You will need it later. Also remove and keep the spade lug on the back end of the black wire. The upper contact and the wire itself can be discarded.

Next, I test-fit a pre-wired T1 white LED that I had handy. It fits nicely into the brass slug that previously held the headlamp. I went ahead and used this pre-wired model, but next time I would probably custom build a T1 LED and resistor to make it as compact as possible and make a little bit more room for the decoder. The shrink wrap on this LED assembly got in the way.
DCC decoder install in a Con-Cor/Rivarossi 4-6-2
Pre-wired T1 LED in the boiler

DCC decoder install in a Con-Cor/Rivarossi 4-6-2
Test fit of the pre-wired LED

After test fitting, I trimmed the LED assembly as short as I could and wired it to the decoder. The decoder Blue wire (common +) goes to the current limit resistor (connected to the LED’s anode) (red wire) and the white wire (forward headlight function) goes to the cathode.

DCC decoder install in a Con-Cor/Rivarossi 4-6-2

The upper brush contact of the motor contacts the frame through a brass spade lug. We must remove that lug, turn it around to face away from the frame, and attach the decoder grey wire to it.

To remove the motor, you must first remove the lower brush contact. Pull straight down on the white plastic ring around the tender pin until it comes loose. Be very careful. It is a tight fit, and when it comes loose it is likely to fly off, taking the spring and motor brush with it.

Next, pull the motor out of the frame by pulling (or pushing) straight back firmly but gently. Remove the spade lug tab from the top motor contact and solder it to the grey decoder wire. Solder the spade lug removed from the lighting tab wire to the orange decoder wire.

After measuring for proper length of the grey and orange wires (they’ll reach back from the decoder position over the top of the frame), I cut and soldered the wires to the spade lugs away from the loco to prevent overheating the motor brushes.

Aesthetically, it would be better to solder the grey wire to the bottom contact and the orange wire to the top contact, so the orange wire is hidden from view. This would make the motor run in reverse, but that can be corrected by programming the decoder.

I lined the inside of the back of the motor mount hole in the frame with Kapton tape to ensure no contact between the brushes and the frame. This might have been overkill but I wanted to be extra-safe.

Reinstall the motor in the frame and reinstall the lower brush contact and tender pin. Slip the spade lugs back onto the motor brush contacts with the tab pointing back away from the frame.

DCC decoder install in a Con-Cor/Rivarossi 4-6-2

DCC decoder install in a Con-Cor/Rivarossi 4-6-2

Once the motor is back in place, bend both spade lugs flush with the back of the motor.

Now, we’re almost done.

Cut and solder the red decoder wire to the lower headlamp tab and re-insert the tab into the frame. Secure the decoder to the top of the frame where the upper headlamp tab used to be. Tuck and secure all of the wires. The black wire should run back along the Engineer’s side of the frame where the black headlamp wire used to be, and will stick out the back of the cab for some length. The yellow wire can be cut short and tucked.

DCC decoder install in a Con-Cor/Rivarossi 4-6-2

Bend the red wire tab up a little past vertical. This will ensure the red wire is not sticking down where it can be seen when the shell is re-installed.

Slip the headlamp into the hole in the boiler slug, then carefully reinstall the shell. It is a tight fit, so you may have to do some “encouraging” to get everything in. It helps to take a small screwdriver and tuck the black wire under the lower edge of the boiler to hide it, much the way one would tuck a cable beneath the baseboard of a house wall. Be careful not to damage anything.

At this point, you should have a complete, running locomotive, except the black wire is sticking a few inches out the back of the cab. To test the locomotive, use an alligator-clip test lead to connect the black wire to the engineer’s side rail of your test track. The locomotive should power up, respond to DCC commands, and run (at least as far as the test lead will reach).

Now is the time to fix anything that is wrong.

In the next installment, we will see how to connect the black wire to the tender and complete the installation.

Not So Easy-Peasy Lighting

Untitled

Having just purchased some new passenger equipment, I decided to add some lighting. Rapido Trains has a very nice kit for just this purpose. It’s called the “Easy Peasy Lighting Kit” and frankly, it’s the bee’s knees when it comes to lighting passenger cars.

Rapido Easy-Peasy Lighting System

The kit consists of a battery-powered light board that you install in the roof of the passenger car using double-sided tape (not provided) or your favorite “other” means of attachment, and a magnetic “magic wand” that is used to turn the lights on and off. There is a magnetic reed switch in the center of the board. When you bring the wand near the car roof, the lights come on. Bring the wand near the roof again and the lights go on. The system doesn’t require track pickup, so you don’t have to worry about DC vs. DCC or metal wheelsets or loading down your booster or power pack with lighted cars.

On the other hand, the batteries will eventually die, and if you used a strong adhesive (like I mistakenly did), replacing the batteries could be a bit tricky.

Installation in most passenger cars is pretty easy. You just install the batteries, pull off the car roof, tape the board in place, and replace the roof. Done. Here’s the board installed in a Con-Cor Union Pacific smooth-side coach…

Rapido Easy-Peasy Lighting

… and the same car in the dark…

Rapido Easy-Peasy Lighting

All is not dandelions and lollipops, though. I bought these boards to go inside some old Rivarossi varnish that I had repainted for the CH&FR Railroad. To my chagrin, I discovered that the board does not fit in the cars. On all three cars (coach, diner and Pullman), the clear plastic ends of the roof/glazing part are too close in, and the board is too long to fit between the ends. In addition, on at least the coach, the bathroom walls on both ends of the car are too high to allow the batteries to fit inside the car.

Rapido Easy-Peasy Lighting System

Rapido Easy-Peasy Lighting System

Clearly some modifications are required. The diner and Pullman are going to have to be modified fairly significantly, so I will cover them in a later post when I’ve figured out how I want to do it. I will document here how I made the lighting fit in the coach.

The first step was to shorten the length of the light board enough to fit inside the roof-and-glazing part of the coach. To do this, I used a razor saw to trim as much of the battery end of the board off as possible. I got right up against the battery holder here, so much so that you can see I opened up the hole for the one of the battery holder legs. This is a tad risky, so use good judgement.

Rapido Easy-Peasy Lighting System

This is almost, but not quite enough to make the board fit. Unfortunately, the other end has a fairly narrow but important circuit trace around the end, so cutting it with a saw would be dangerous. Instead, I used some 300-ish grit sandpaper to file down the end just a smidge, enough to make it work.

Rapido Easy-Peasy Lighting System

Alternately you could cut the board with the saw, breaking the trace, and then solder a wire to re-establish the circuit.

Now the board fits lengthwise, but we still haven’t solved the “too tall battery” problem.

Rapido Easy-Peasy Lighting System

To make room for the batteries, I used the razor saw to trim 1/8″ off the height of the bathroom walls on one end of the car’s interior part, and then sanded the cut edge smooth. This frees up enough room for the batteries, but leaves the walls tall enough to look OK through the windows.

Rapido Easy-Peasy Lighting System

Finally, after a test fit, we add the tape and reassemble the car.

Rapido Easy-Peasy Lighting System

And that’s pretty much it. Voila! … almost…

Rapido Easy-Peasy Lighting System

The custom paint job on these cars didn’t include the roof, which I elected to leave the original silver. Trouble is, as you can see, the paint has worn thin in spots, so I’ll have to repaint it to keep the lights from bleeding through.

Rapido Easy Peasy Lighting

This isn’t a perfect solution. The foam tape I used is pretty high-adhesive. Probably too high. I’m quite concerned that I’m going to have some trouble when it comes time to replace the batteries, especially since I carved off all the “wiggle room” on the battery end of the light bar. I might actually find myself buying another car to scavenge a new roof from it, if things get bad enough.

In hindsight, it may have been better to cut the ends off the roof/glazing part to make room from the bar instead of shortening the bar to fit in the roof. I could easily have added some thin clear plastic to re-glaze the car ends. But, the car is lit and ready to go, once I replace the couplers again.

I’ll also point you to Mike Fifer’s succinct how-to on installing these lights in a Micro-Trains Heavyweight car.  Notable differences (and I should have listened to Mike!) are that he wraps the LEDs and the light spreader in tape to stabilize the board, and he doesn’t secure the board to the roof, instead just letting it rest on the tops of the seat backs.  That latter difference will certainly make battery replacement easier.

The CH&FR Goes Digital Part 7

[youtube=http://youtu.be/pGdrG5i_q1I]

Today we present the long-awaited (I hope!) Part 7 of my “The CH&FR Goes Digital” series.

This episode dives into block detection using the Digitrax BDL168 16-input block detector.  We cover track setup, wiring, connecting the BDl168 to your computer with JMRI, and provide a live demo.

Block detection is what we call “knowing where your trains are”, and it works very similarly to how the real railroads do it.  The layout is divided up into electrically separate segments, or “Blocks”.  Each Block is a section of track where you want to be able to tell whether there is a train on that track or not.  It might be a siding, or a length of mainline track, or (less likely) a track in a yard.  The Block is electrically isolated from all the other blocks, and the power feed to one rail is fed through a block detector like the BDL168.

When a locomotive sits on that section of track, even if it is not moving (under DCC) a small current flows through the locomotive’s decoder from one rail to the other, and the BDL168 can detect this current flow.  When it sees the locomotive’s current draw, it reports that section of track as “occupied”.  If there is no current flow, the BDL168 will report “unoccupied” for that track section.

Of course, on the prototype railroad, the trains provide their own power, but the block detectors are able to work very similarly.  By inducing a voltage between the rails, the detector can watch for the metal wheels of the train to short the rails together, indicating that the track is occupied.

On the model, without a little work, we can only detect the presence of locomotives.  Most model railroad cars (in N scale at least) come with plastic wheels which do not conduct.  On the few which come with metal wheels, the axles are insulated to prevent the car from shorting out the track.

By adding a small resistor to one wheelset on each car, the entire train can be detected, not just the locomotive.  One of my favorite videos on how to add resistive wheelsets is by Daryl Kruse who runs the UPRR Geneva Subdivision in N Scale.

For further reference, here are some links…

55″ Dispatcher Panel

55" Dispatcher Panel by BGTwinDad
55″ Dispatcher Panel, a photo by BGTwinDad on Flickr.

This is an early step in the “dream plan” for dispatching my layout(s).  The photo doesn’t really do the scale justice.  This is JMRI displaying my layout panels on our 55″ living room TV.  It’s big enough I can tell track occupancy from my kitchen thirty feet away.

For now, it’s just a novelty, because the current Glover’s Bend layout is small, but the ultimate goal, the “Chestnut Hill Sub” will be an around the room shelf layout big enough for multiple operators, and a panel this big will be easy for everyone to check when they want to see what’s coming.

Ultimately, all of this will also be web-accessible, enabling truly remote dispatching, for my friends who are too far away to visit in person.

Someday, when I win the lottery.

Technicals:  I just installed a Digitrax BDL168 block detector circuit under the layout, and it is monitoring 16 different blocks around the two main lines.  It’s feeding information back over LocoNet to my train room computer, which is generating the displays using the JMRI train control software.  My train room computer happens to have an HDMI display port, which makes it easy to convert my TV into a monitor.  Add a wireless keyboard and trackpad, and I can dispatch trains from my couch!  Easy-Peasey!

I’ll write an article or two about installing the BDL168 and setting up the panel once I get everything debugged and working properly.