Page updated on 26 March 2025

Photo of me
My banner

Supply

This web page is about designing and building two power supplies for my model railway. One of the power supplies is a Dual plus and minus 15V power supply for the traction current for self propelled vehicles, to operate points of turnouts and to operate decoupler solenoids. The other power supply is a 'Logic 5V and miscellaneous 5V power supply' for logic circuits, respectively train detection and miscellaneous devices like line site signals, houses etc. The last section is about measures to improve immunity to avoid disturbances in logic circuits.

Logic 5V and miscellaneous 5V power supply

Application switch mode power supply

This power supply provides two independent power outputs, one for logic digital circuits and one for track circuits and miscellaneous loads like illumination devices. The power supply for the track circuits and miscellaneous components is a independent unit to avoid the wrong operation of track circuits. At the other hand the power supply for logic digital components is a independent unit to avoid the faulty operation of logic digital components due to noise.

Two AC/DC switch mode power supply modules are used. They have a power rating of 7A. This is higher than required but avoids reformation of the plastic enclosure due to overheating. It is the same enclosure used for the above 'Dual plus and minus 15V power supply'.


Description components and wiring

The used switch mode power supply is a Mean Well RPS-65-5 5, see image below. The price of each unit was around €17.00 in 2020.

Figure with switch mode power supply Mean Well_RPS-65-5 5.

The logic 5V and miscellaneous 5V power supply circuits have each its own mains power switch S1 resp. S2 and fuse F1 resp. F2. These and the neutral are connected to the hot side of the switch mode power supply X1 resp. X2 by a female crimp plug J1 resp. J2, see photo below.

Figure with switch mode power supply Mean Well_RPS-65-5 5.

The 5VDC cold side of the switch mode power supply for logic circuits is connected to a violet pole terminal J5 and the one for miscellaneous devices to a brown pole terminal J6. The GND of each switch mode power supply is individually connected to the black pole terminals J7 resp. J8. All these 5VDC and GND wires are connected to the switch mode power supplies with 4 pole female crimp plug J3 resp. J4. The current rating for the DC connectors and wires is 22 A.
The 5VDC for logic circuits is connected via a current limiting resistor R1 to a blue LED D1. The 5VDC for miscellaneous devices is connected via a current limiting resistor R2 to a green LED D2.

Part list with components are stated below.

ID Component Properties Qty
X1, X2 AC/DC PSU module (open frame) Mean Well RPS-65-5 5, ripple(PP) 80mV, efficiency 84% 5VDC, 11A 2pcs
D1 LED wired Blue Circular 5 mm, 1150mcd, 20° 20 mA, 3.5V 1pcs
D2 LED wired Green Circular 5 mm, 1000mcd, 20° 20 mA, 2.1V 1pcs
F1, F2 TRU COMPONENTS TC-R3-12 Fuse holder Suitable for Micro fuse 5 x 20mm, 10A, 250V AC D=15mm∅ 2pcs
F1, F2 Püschel FST0,315B Micro fuse (Ø x L) 5 x 20mm, time delay 0.315A, 250V 2pcs
R1, R2 Carbon film resistor 270Ω Axial lead 0207, 0.25W, 5% Type 0207 2pcs
S1, S2 SCI Toggle switch R13-66B2-02 (250V/AC 150KR) 250VAC, 6A, 1 x Off/On latch L=19.4mm, W=13mm 2pcs
W1 GAO 6777 Current cable white 1.50m     Max. 2.5A 1pcs
W2 TRU COMPONENTS TC-SR-F21203 Strain relief Terminal Ø (max.) 5.3mm black
2pcs
J1, J2 JST VHR-3N VHR-3N Casing Series VH Number of pins: 3 Nominal current: 10A AWG #22 to #16 2pcs
J3, J4 JST VHR-4N VHR-4N Casing Series VH Number of pins: 4 Nominal current: 10A AWG #22 to #16
2pcs
J1, J2, J3, J4 JST BVH-21T-P1.1 BVH-21T-P1.1 Crimp Contact For Series VH Nominal current: 10A AWG #22 to #16 12pcs
J5 Hirschmann 35A SKS pole terminal PKI 10 A Stift-Ø: 4mm violet
M4, 35A, ~7∅
1pcs
J6 Hirschmann 35A SKS pole terminal PKI 10 A Stift-Ø: 4mm brown M4, 35A 1pcs
J7, J8 Hirschmann 35A SKS pole terminal PKI 10 A Stift-Ø: 4mm black M4, 35A
2pcs
E1 Universal enclosure 180 x 205 x 70mm Polystyrene (EPS) black
1pcs
E2 TOOLCRAFT 839971 Countersunk screws M4 - 25 mm Phillips DIN 965 plastic, polyamide 10 pc(s) Bag of 10 1pcs
E3 Spacer w/o thread M4 Polystyrene Distance 15mm 

8pcs

Immunity

This page is about measures on printed circuit boards (PCBs) to avoid disturbances in logic circuits due to noise on supply lines. and also avoid this with logic IC families with high tolerance to voltage variations.

Decoupling capacitor

In electronics, a decoupling capacitor is a capacitor used to decouple one part of a circuit from another. Noise caused by other circuit elements is shunted through the capacitor, reducing its effect on the rest of the circuit. Rigorous calculations for these capacitors is complicated, but in early days there was as a rule of thumb to place by one 10nF ceramics MULTILAYER capacitor near every IC, and one electrolytic capacitor of 10µF (preferred Tantalum one) between main traces that supply groups of 10-20 IC. The 10nF caps need to be small—preferably 0402 or at most 0603 sized—to avoid the lead inductance from the package nullifying the effect of the capacitor.

The part list with Decoupling capacitors is shown below.

ID Component Properties Qty.
- Tantalum capacitor Radial lead 2.5 mm 10 µF (Ø x H) 6 mm x 10 mm AVX TAP106M035SCS 35 Vdc 20 % -

Voltage variations logic families

All ICs used for my model railway have a supply voltage of 5 volts and they must have immunity to voltage variations on the supply lines between 4.5 and 5.5 volts. Logic families with this property are mentioned in the next two sections and are contenders for electronic circuits depending on their other properties. Also stated is how popular a particular logical family is so you can see if they are readily available.

Microchip ATmega

The voltage variation for the Microchip ATmega48P/88P/168P/328P/808/809/1608/1609/4808/4809 is 5V ±0.5V.

74xx families

Logic 74xx families with immune for supply voltage variations between 4.5 and 5.5 volts are:

  1. 74ACxx (POPULAR)
    Advanced CMOS Logic (ACL for short). The AC is faster than the HC subfamilie. Not pin compatible with TTL. Improved noise immunity.
  2. 74ASxx (RELATIVELY POPULAR)
    Advanced Schottky TTL – Improved design over 74Sxx Schottky types optimised to increase switching speed at the expense of power consumption of about 22mW
  3. 74ALSxx (POPULAR)
    Advanced Low Power Schottky TTL – Lower power consumption of about 1mW and higher switching speed of 4ns compared to 74LSxx types
  4. 74HCxx (VERY POPULAR)
    High Speed CMOS – CMOS technology and transistors to reduce power consumption of less than 1µA with CMOS compatible inputs
  5. 74HCTxx: (POPULAR IN CERTAIN CASES)
    High Speed CMOS – CMOS technology and transistors to reduce power consumption of less than 1uA but has increased propagation delay of about 16nS due to the TTL compatible inputs. This is the reason for the existence of this logical family because TTL or NMOS outputs are incompatible with the inputs of the HC family unless a pull-up resistor from the TTL output to VCC is used.