Jump to content
 

Budget Battery Powered 00 Gauge Loco


Robin2
 Share

Recommended Posts

A while ago I converted an N Gauge Grafar large prairie to Battery powered radio control using a Deltang wireless module

More recently, having discovered the cheap nRF24L01+ wireless transceivers I have been experimenting with using them as a basis or 00 Gauge BPR/C.

And more recently still I got a Silhouette Portrait computer cutter which makes it convenient to make cheap loco bodies from card.

Since getting the Portrait I discovered that it is easy to electro-etch brass using salt-water and 12v DC electricity.

This Thread shows the first fruits (well maybe we are still at the flowering stage) of bringing those three concepts together.

First, a short video just to prove it works.


 

 

The loco body is being copied from this Bachmann Midland 1F just because I have it and it is easy to take measurements from it. Also I had a set of wheels that are about the right size.
post-10065-0-54360800-1493118428.jpg

This is view of the project as it is now, But please note that the card body in these pictures has had a lot of rough handling and will eventually be replaced by a new one.
post-10065-0-66296600-1493118555.jpg

With the electronics and motor removed
post-10065-0-64442600-1493119438.jpg

The electronics and motor
post-10065-0-41046600-1493119593.jpg

The electronics consist of an nRF24L01+ transceiver, an Atmega Attiny 1634 microprocessor and a Pololu DRV8833 motor driver. - total cost about £8. The antenna is the short piece of wire  pointing straight up. The other brown wire is just for testing and will be removed eventually. The standard nRF24Lo1+ module has its antenna on the PCB but I have sawn that off to shorten the PCB by about 7mm.

The motor is from a small servo – I believe the size of the motor is known as an N20, based on Mabuchi nomenclature.

The black thing on the motor shaft is a small piece of plastic with a white spot painted on it. This is used to determine the speed of the motor and to count the number of revolutions. The optical detector is under the piece of white plastic stuck to the top of the motor.

The brass rods at the left hand side slide into two brass tubes on the body and both support the electronics and connect it to the battery power. I wanted a plug and socket system that does not require force that could not be sustained by the card body.

The chassis and body separated
post-10065-0-24409200-1493119926.jpg

Another view of the card body. All the parts have been cut using the Silhouette Portrait
post-10065-0-35834300-1493120218.jpg

And the chassis
post-10065-0-43408000-1493120358.jpg

The 30 tooth gear is from a pack of cheap gears I bought from Squires. At the moment I am not using the worm gear from that pack because it seems to have a lot of friction compared to some others I have - but I have no idea where the better ones came from.

The motor is a tight slide fit in its brass holder. That makes it easy to remove and refit.

The chassis without wheels
post-10065-0-57794200-1493120572.jpg

I designed and etched this myself. It is not intended to be a scale replica of a real loco chassis. It will never be seen in normal use so I am quite content for it to be simple and functional. There are also etched coupling rods that work very well but I have removed them to make motor testing easier.

I used the Portrait cutter to make the etch-mask from self-adhesive vinyl which I stuck to both sides of the brass sheet prior to etching. The motor-holder is a bit of a bodge at the moment as my original plan had been for a completely different mounting so the present arrangement was not designed into the etch.


One of the ideas in my head is the possibility of using the same chassis and electronics with a variety of card bodies. That could mean the same shape in different liveries for different historical periods. Or completely different shapes which have roughly the same wheel arrangement.

 

...R

Edited by Robin2
  • Like 9
Link to post
Share on other sites

Brilliant. I was keen to see how you were doing the electronics, but had no idea about the card bodies and using a Silhouette, which makes it even better, as the whole thing fits in with the direction I'm aiming for. My first BPRC trials will be in O gauge, and I'm sure there will be room to squeeze all this into a Dapol Terrier somewhere. Then it will be on to the scratchbuilt card locos!

Link to post
Share on other sites

Robin,

 

That looks to be coming together really well. There is so much innovation in that loco and it is all helping to turn the basic concept of radio control into a very economical and workable solution for a small scale loco.

 

A couple of questions, are you running the electronics straight off the battery or is there some stabilisation and/or voltage step up? And what software are you running? Will it enable DCC codes to drive a sound chip? Ok, thee questions!

 

Frank

Link to post
Share on other sites

The LiPo battery voltage is a little too high for the nRF24 so I am using a diode to drop the voltage by about 0.8v and then the Attiny and the nRF24 run directly from that. The Attiny is running at 8MHz.

 

The programming is done with the Arduino system. The basics of the wireless system are described here. I will probably post the full program for the loco when I have done some more development work on it. However I am a little concerned that it will give rise to a great many questions.

 

I have no plans for sound. If I am going to do sound it will probably be under the baseboard where there is room for proper speakers.

 

It is possible to make a small MP3 player with an Arduino - I think it would probably be easiest to use a separate microprocessor for that. I don't think there would be space in the 1F loco but a tender loco should have plenty of spare space. And, of course, a large part of the cost of DCC sound is the sound recordings themselves which I am too mean to pay for. :)

 

...R

Link to post
Share on other sites

Could we have a complete list of parts, including batteries, diodes, connectors etc., and where you get them from please? I'd like to get some to start experimenting with, once I get my head round the more basic Arduino stuff. I've currently got infrared remote controlled servos working, but can't get a LED to light up!! Once I've overcome that, I want to start planning various ideas for RC.

Link to post
Share on other sites

Could we have a complete list of parts, including batteries, diodes, connectors etc., and where you get them from please?

Where will this end? I am happy to help, but there are limits :)

 

The principal parts are listed in my Original Post here. The diode is a IN4001 which are probably more common than muck. The batteries are a pair of 80mAh LiPo cells (wired in parallel to give 160 mAh) that I got from HobbyKing. I got the nRF24L01s from HobbyComponents; the motor drivers from HobbyTronics and the Attinys from RS Components.

 

All the connectors are DIY and already described - brass tube and 0.8mm brass rod

 

...R

Edited by Robin2
Link to post
Share on other sites

Where will this end? I am happy to help, but there are limits :)

 

The principal parts are listed in my Original Post here. The diode is a IN4001 which are probably more common than muck. The batteries are a pair of 80mAh LiPo cells (wired in parallel to give 160 mAh) that I got from HobbyKing. I got the nRF24L01s from HobbyComponents; the motor drivers from HobbyTronics and the Attinys from RS Components.

 

All the connectors are DIY and already described - brass tube and 0.8mm brass rod

 

...R

Sorry Robin, I wasn't trying to get you to do all the work for me! It's just that the Attiny is only the chip, so I assumed there may be extra components needed to go with it. The 292 page data sheet is a bit beyond me! And you mentioned the marking on the motor for a speed sensor. Is this part of the installation, or just used for testing?

 

Anyway, I've ordered some nRF24L01s, and will start off by just getting a couple of Arduinos to talk to each other.

Link to post
Share on other sites

I have pushed a short piece of round plastic onto the motor shaft to make the active part of a sensor. It is painted black with one white stripe to trigger the sensor which is a QRE1113 reflective optical detector. This is all completely optional. If you just want a system where you control the speed by turning the control knob you will not need it.

 

I want to be able to control the loco with a PC program and (hopefully) the program will be able to tell the loco to move forwards (or backwards) by X millimeters by getting the Arduino to count the rotations of the motor. Also (hopefully) by measuring the motor speed the Arduino will automatically compensate for changes in load.

 

If you use the internal 8MHz oscillator on the Attiny1634  the only external component required is a 0.1µF capacitor across Vcc and GND. There should also be a 10µF capacitor across Vcc and GND for the nRF24. I forgot to add that and it seems to be working without it. But I will add it for certainty.

 

If you have more space it would be easier to build a similar system with an Atmega 328 because its pins are larger

 

In either case I suggest you build a working system on a breadboard before trying to reduce the size to fit into your Loco. Wireless can be particularly difficult to debug.

 

Also, get each separate part working on its own (wireless, motor control etc) before trying to build a complex program.

 

...R

Edited by Robin2
Link to post
Share on other sites

In either case I suggest you build a working system on a breadboard before trying to reduce the size to fit into your Loco. Wireless can be particularly difficult to debug.

 

Also, get each separate part working on its own (wireless, motor control etc) before trying to build a complex program.

 

...R

That's what I'm doing with developing a standard system for operating all my layouts, which is what I'm doing first to learn about all this stuff. Some layouts will be DC, others all RC, but I may try to use RC locos alongside DC ones on some, where it would be useful to have, for example, a shunter that can go anywhere while there are other locos around. I've currently got IR remote control working, and once I've cracked operating the most complex layout with a minimum number of controls, I can hopefully make a full hand held RC loco/layout controller. It will all happen a step at a time, and once it's working well I hope to have a big session of installing it on all the layouts that are ready in one go. By that time I hope to have a good idea of what I can do with RC locos.

Link to post
Share on other sites

  • 2 weeks later...

Hi Robin and all,

 

Robin's project is very nice.  I know a number of people who have been playing with nRF24L01 and locos (as well as other forms of model transport).  Here is a quick overview of what I have been doing.

 

 

About three years ago someone at my workplace showed me Arduino and its capabilities. So then I started off trying to control my trains: first with an OO gauge loco, an Arduino UNO and a transistor:

 

post-31785-0-37273800-1494199112_thumb.jpg

 

As I had little experience with electronics, this design was a great pleasure to see working but was terrible on many accounts:

  • The locomotive could only run in one direction.
  • The 9 volt battery did not have a high charge capacity, so could not supply current to drive the motor for very long.
  • For power and to send control commands to the Arduino, the Arduino was connected to a PC using a USB cable.  All in all, the operation was not prototypical.

Some time later I had been successful in learning to use nRF24L01+ radio transceivers.  One of these could be carried with each locomotive plus an Arduino for control and an L298 pulse-width-modulation motor driver module (the red circuit board in the photo below, you can see the twisted orange wires going to the DC motor of an HO scale loco).  The system was powered by 2x 3.6 – 4.2 volt Li ion cells in series.  This worked but needed some miniaturization in order to be hidden under the loco body shell.

 

post-31785-0-08482700-1494199634_thumb.jpg

 

In 2016 I shrunk the design down to use SMD (surface mount device) version of the nRF24L01+ module (black circuit board in photo).  I had a smaller PWM motor driver module (Pololu TB6612FNG, green circuit board in photo, 2 A peak current) and was using an Arduino pro mini (blue circuit board) as the microcontroller.  These components are all mounted on a custom-made PCB (purple circuit board, fabricated by OSHpark) to avoid wires trailing everywhere. This is how it looks:

 

post-31785-0-56368800-1494199199_thumb.jpg

 

The photo shows the battery-powered radio control system added to a dash-9 locomotive in HO scale from Athearn.  At the bottom of the picture is the DCC socket board that came with the locomotive.  My system is pretty much the same width and length, but half the thickness (even without the DCC decoder added) and I am sure further miniaturization is possible.  There was enough space inside the loco shell for two 750 mAh Li ion cells, which is enough capacity to allow between 8 and 10 hours loco running at full speed.  This is fine for my needs! 

 

The design is very similar to that of Robin, so costs about the same to build.  The most expensive part of the whole operation is the lithium ion cells.

 

I’m at the stage where I would like other people to help test and develop the RC system.  Please get in touch with me!  The nRF transceivers have a maximum data packet length of 32 bytes, so can be used to transmit standardized

DCC strings and integrate with established layout control softwares such as JMRI. 

 

There is a full writeup of all this work as a “how to guide” which I’d like to publish in a magazine, e.g. MRJ.  If that takes too long I will find another place to distribute.

 

Unless otherwise specified the design is licensed under Creative Commons CC-BY-NC-SA 4.0.

 

 

  • Like 1
Link to post
Share on other sites

I only discovered Arduinos a few weeks ago, inspired by Robin's posts, and I'm already hooked! I'm starting to use them for every aspect of layout operation. My ultimate aim at the moment is radio control in O gauge, but the system is so cheap that it may spread to my 4mm models eventually. I've got some nRF24L01+ already, and a few Pro Minis are on the way from China, along with some DRV8833 boards that are a fraction of the price of the Polulu ones. If it works, I reckon the cost will be nearer £4 than the £8 Robin's cost! Plus batteries of course. I'm going to take this a step at a time, maybe using RC for a wireless DC layout controller first.

 

I'd be very interested to read your writeup Michael, or see any other information you'd like to provide. I think the great thing about this DIY approach, rather than buying an off the shelf system, like Deltang (apart from the massive cost saving), is that it can be built to suit the needs of the layout and operator. So sharing knowledge and experience that can be applied or adapted in different ways is very useful. And it's so cheap that it's no problem to upgrade or replace components as new products or knowledge come along.

Link to post
Share on other sites

Hi Michael,

 

That is a very impressive piece of work. It's fascinating to see how you have improved and miniaturised the kit over the project. You look to have developed a very workable and useful system there. I hope you find somewhere to publish it soon.

 

I'm guessing that you have used standard modules for the Arduino, radio link, etc. with a custom motherboard to link them all together. Are you going to make the motherboard and software available for other people to try out?

 

The link to a DCC system is interesting. One criticism of radio control that comes up frequently is that you cannot easily have sound. If your system can use DCC codes then I guess it could eventually be linked to a DCC sound card?

 

Frank

Link to post
Share on other sites

The Americans and Canadians have the great advantage that their prototype locomotives are huge and the models have lots of space inside for batteries and electronics.

 

I built another chassis that allowed me to try different gear ratios between the motor and the wheels because with my original 30:1 ratio I was not getting the sort of slow running I want. When I increased the ratio to 90:1 the slow running was great, but the top speed was far too low. Consequently I reluctantly concluded that I need to use a bigger motor. I have a couple of RF-20 motors from standard servos and they seem to work very well with the simple 30:1 gear ratio. These motors have a circular cross-section and are 17mm diameter and 18mm long. They just fit within the outline of the boiler in the model I am making.

 

This is disappointing because the smaller motors would have been much more convenient in many different ways - but, as in most things, size matters :)

 

...R

Link to post
Share on other sites

Have you considered using a coreless motor which is much more efficient on power consumption?

 

Gordon A

I am open to suggestions - do you have a link to a supplier? And are they cheap - like £4 or £5? (or less). If I had more space I could use the 130 motors that cost about £1.50

 

...R

Link to post
Share on other sites

Hi Michael,

 

I'm guessing that you have used standard modules for the Arduino, radio link, etc. with a custom motherboard to link them all together. Are you going to make the motherboard and software available for other people to try out?

 

The link to a DCC system is interesting. One criticism of radio control that comes up frequently is that you cannot easily have sound. If your system can use DCC codes then I guess it could eventually be linked to a DCC sound card?

 

 

Hi Frank, BG John, Robin

 

Thanks for the positive comments!

 

Yes, sure, everything is built using open-source tools (CC license as I mentioned in previous post) and the whole point of the exercise, at least from my point of view, is to make BPRC freely available for others to use.  The model rail hobby is big business these days and although there are cases where it is worth paying more for quality, it is generally expensive. 

 

Also, for new products, paywall = slow adoption, unless there is a critical mass.

 

 

The idea of electronic modules + motherboard is that a beginner can get the system up and running with minimal work.  You do not need to know how the modules are connected together, but if you wish to find out, it's not kept a mystery.

 

I can provide the build info but at this stage it may be easier for me to provide you "kits" at the cost price since I have lots of spares.  You will spend less time sourcing components and more time building/using the setup.  It would be very useful if you can provide some feedback on this forum or other suitable place. 

 

 

RE size of the locomotives:  I can easily fit this control system into coal tenders, DMUs, class 37s in 4 mm scale.  This is not a problem for me, though I can appreciate some people model smaller locos.

 

Sound:  open-source tools including Arduino/Teensy make this possible already.  You should need to pre-load the sound files onto an SD card and carry an SD reader plus loudspeaker on board the locomotive (space is premium!).  Then it is a matter of writing the microcontroller code.  I have never used DCC so don't know what sound card you are referring to, anyway the point is that you won't need it.

Link to post
Share on other sites

What motor you use and what bettery setup you have are of course linked. You can generally run a Radio Control setup with a lower voltage supply than the motor is rated at, because you are putting the volts directly on the motor with no losses due to track contact etc. And you do not really want the very high speed that full rated voltage would give you.

 

Most of my Radio Control setups are for small 009 locos, using n gauge chassis. These use a single lipo cell (3.7v nominal) and for those it is useful to have a lower voltage motor (six to nine volts) although modern locos often have motors that run very nicely on lower voltages anyway. For bigger locos, OO scale and similar, I use a two cell setup (7.4 v nominal) which runs normal 12 v motors OK.

 

You also have the option of a voltage conversion board which can within reason give you whatever voltage you need.

 

What is important whatever setup you use is that the motor is efficient and in this modern motors are much better than old designs and very much better than old ones that are worn due to use.

 

Frank

Link to post
Share on other sites

My first two locos will be O gauge Dapol Terriers, with modern 12 volt motors, but due to the low cost I'm getting tempted to convert 4mm locos too. Most have old motors, and I could make more space available by replacing them with small modern ones. I've got a variety of cheap Chinese 12 volt motors, but is it worth buying low voltage motors instead, and if so, what? Converting voltage takes up more space, and they are mostly tank locos without a lot of space (in OO, EM and P4).

 

As the nRF24L01s I've got, and the motor driver boards I've ordered, are both 3 volt, I've also ordered 3.3 volt Pro Minis, as that seemed to make sense. But it means I'll need to convert voltage somewhere in the system, adding to the space needed. Probably not a problem in O gauge, but it may well be in 4mm.

Link to post
Share on other sites

Nigel Lawton has some nice small motors that are efficient and work well with radio control. Not as cheap as £4-5 but not expensive at £6.50-8.50.

 

http://www.nigellawton009.com/VeeTipper.html

 

Frank

Thanks. I have his website on my bookmarks. His 2 bigger motors are intended for 12v and 10v so I expect they would not have as much power on 3.7v as the small motor that I have already tried and rejected. The smaller 6v motors would be interesting if I was building a smaller model.

 

Of course it is difficult to be certain without buying and testing.

 

------

On a somewhat separate theme... A short time ago I thought it would be best to use higher-voltage versions of the N20 motor with a 2S LiPo but I came to the conclusion that arranging for balanced charging of the two LiPos without removing them from the Loco was just too much trouble. I want to be able to drive a loco into a "charging station" and I could not conceive of any connection system that was not going to give a too great risk of short circuits. With a 1S LiPo the options for charging connections can be much more varied.

 

...R

Edited by Robin2
Link to post
Share on other sites

On a somewhat separate theme... A short time ago I thought it would be best to use higher-voltage versions of the N20 motor with a 2S LiPo but I came to the conclusion that arranging for balanced charging of the two LiPos without removing them from the Loco was just too much trouble. I want to be able to drive a loco into a "charging station" and I could not conceive of any connection system that was not going to give a too great risk of short circuits. With a 1S LiPo the options for charging connections can be much more varied.

 

...R

I want to be able to drive onto a "charging station" too, but if that's a potential problem with multiple batteries, the idea doesn't look too promising for my O gauge locos.

Link to post
Share on other sites

I want to be able to drive onto a "charging station" too, but if that's a potential problem with multiple batteries, the idea doesn't look too promising for my O gauge locos.

With 0 Gauge you probably have space to have a proper LiPo charger inside the Loco which would be an even better solution. Then you just need some means to drive onto the power supply for the charger.

 

Because there is no spare space in a small 00 Gauge loco I was planning to bring out the three charging connections (for the 2S LiPo) and that would have presented three opportunities for a short circuit :)

 

...R

Link to post
Share on other sites

Most of my locos are 009 but I have converted a OO Bachmann Prarie tank. It was the older split chassis one not the current one, and had a canned motor. It was nearly new, I don't think it had seen much running.

 

I used two LiPo cells in series to give 7.4 v nominal and it worked fine. The cells were about 150 mAh capacity, and ran it for well over an hour. The cells were put in the side tanks ; I had to make cutouts in the metal of the chassis to make room for them. You don't need so much weight with radio control, the weight in a normal loco is mainly to improve electrical contact with the track.

 

For a charging connector I used a standard servo connector. I mounted this in the footplate, facing downwards, hidden behind the cab steps. It's simple, cheap and well shrouded.

 

If you want to go the "charging station" route with some sort of automatic connection, I suspect you will end up using a single cell

LiPo with voltage step-up and an on board charging circuit, which can be quite small for a single cell.

 

Frank

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...