en Custom LEGO Power Functions 9V Power Supply
In all the GBC videos I saw, there was an endless line of the classic train controllers, used for powering the motors from a wall supply instead of a battery pack. And it makes perfect sense, except it's missing a feature that is essential for using a servo motor or IR receiver: the fixed 9V and ground lines that the Power Functions cables has.
The Power Functions Standard
In the old days, motor cables had two wires. It could be attached to a train controller or a battery pack, and it could power the motors with up to 9 Volts, with switchable polarity to change the direction. The Power Functions cable on the other hand has 4 wires (see picture below). The middle two are the same control lines as with the old ones, but the outer two are a fixed 9 Volts and a ground line. The point is, that these two never change polarity or voltage level, and they are used exclusively for the servo motor and the IR receiver.
Power Functions from a Wall Supply
One solution would be to buy a Power Functions Rechargeable Battery Box1 and keep it plugged in, although I don't have one so I cannot confirm if it works.
I went with a different approach. I had built my own Power Functions 9V power supply, which can use the old train controller's 10V AC wall adapter, or any 12V DC adapter that you can buy for cheap.
First, I took a look at what the train controller had, and I was suprised to see how simple the whole thing is. Basically there's a very sturdy little voltage regulator, which can be manually set to a specific voltage level using a set of voltage divider resistors, depending where the big rotary wheel stands. This regulator is the KA317 2. It features:
- Output current in excess of 1.5A
- Output adjustable between 1.2V and 37V (used between 0V and 9V)
- Internal thermal overload protection
- Internal short circuit current limiting
I had the luck of testing out that short circuit protection once, and it works, and so does my train controller, luckily. That 1.5 Amps of maximum load though... keep in mind, that most motors consume around 0.3A to 0.5A under normal load, and up to 3 times as much when stalled 4.
Knowing the specs, I did a seach for a similar voltage regulator but with a fixed 9V output, and found the L78S09CV 3, which can even do an additional half Amp, up to a total of 2.
The circuit is very simple. For the input I'm using two different DC connectors. One is a size 5.5 / 2.1 mm, which is compatible with the LEGO wall supply, the other one is a 5.5 / 2.5 mm, which is a common size for universal power supplies you can buy. The diode bridge5 turns the input alternating current (AC) into a direct current (DC). It also works with direct current as an input; it either does nothing, or corrects the polarity, so the input can really be anything as long as it's below the maximum input voltage the voltage regulator can take (18V in this case).
The Final Assembly