GENERALINTEREST
Märklin Digital Model
( )
Train Control 1
A low-budget approach
From an idea by J. Schröder
This circuit provides an excellent opportunity to upgrade your Märklin
model train system from traditional AC to digital control.
GENERALINTEREST
Main Features
- Direct connection to PC parallel port.
- Simple to operate software (Windows 3.1x, 95, 96, NT) for individual control of up to 15
model trains.
- Controls Märklin Digital H0 stock using classic Motorola data format and Delta decoders.
- Integrated compact booster, max. 3.5 A output current, with overload protection.
- Powered by original Märklin transformer or single 15-VAC
- Manual on/off control of extra function.
Beginning model train enthusiasts fans. The Digital Control discussed in EEDTs, plus a short description of the latest
may have more digital-ready this article allows anyone and an old developments in the field.
(Märklin) locomotives moving about PC in the attic, and capable of han- The crux of digital model train control is
on the track than they are aware of. dling a soldering iron, to get the feel of that several trains on the track can be con-
Usually, these locomotives are sim- digital model train control at a very trolled independently. As opposed to tradi-
ply powered by the speed regulator small outlay. So, if you do not yet tionally operated tracks, where turning the
on the main transformer. These days, have a locomotive with a Delta (or speed governor on the transformer puts all
model locomotives with an internal regular) decoder, you have a perfect rolling stock in motion at the same time, the
digital decoder are hardly more excuse to step inside a model build- digital track is marked by each locomotive
expensive than traditional types. ing shop when it s not December& having its own control element, allowing its
That is not surprising because elec- speed and direction to be controlled individ-
tronic circuits are easier and cheaper ually. In addition to this function, there is
Recapping
to produce in large volumes than any often a plethora of options of the bells and
of the traditional reversing relays. Newcomers to the hobby can, of whistles variety, including control of turnouts
Märklin always continued to produce course, not be expected to know all and signals via the track. Unfortunately, how-
decoders capable of working in AC the ins and outs of digital control for ever, these extras and their control are out-
mode as well, allowing them to be model trains. Hence, a brief recap is side the scope of this article.
used without problems with the given of what we already described How does it all work, you may wonder.
famous Märklin transformer. Upgrad- in the long series of articles on the With traditional control systems, a voltage is
ing to all-digital control is then pos-
sible at a later stage. Possible, yes,
but admittedly at a price because
the cost of the upgrade will easily
exceed that of all rolling stock.
Several attempts have been made
to lower the threshold. From 1987
roughly to 1991, Elektor Electronics
published items to create the all-
home-made EEDTs (Elektor Electron-
ics Digital Train System), a hugely
successful series! Some time ago,
Märklin introduced their Delta sys-
tem, which is actually a stripped
down version of the original Digital
H0 with limited addressing options
(4 instead of the usual 80). In fact, the
Delta system triggered the author to
design the circuit and software
described in this article. Many
Märklin locomotives come with a
Delta decoder fitted as standard,
instead of the traditional reversing
relay. These locomotives, too, are
Figure 1. Two trinary signals on the scope: The top trace shows loco address 56 (X00X),
controlled in old-fashioned AC mode
function bit = 1, speed = 7 (0001).Below, in stretched-display mode, logic 0 (00), logic
(i.e., by transformer speed regulator),
Open (10) and the start of a logic 1 (1& )
by the vast majority of model train
GENERALINTEREST
U U
PWR
C10
C11
100n
R11 1 8x 10k R8 1 4x 10k
CON1
2
100n
1
VS
14 8
IC2a BOOT2
2 1
C5
2 3 4 5 6 7 8 9 2 3 4 5
3 7
IC1
e"1 IN2
15 2
IC4
16
15n K3
10
IC2d
3 1
OUT2
12
+VS
16 1 18 1 15 11 11
I1 O1 A1/D1 D0 e"1 ENA
13
4 2 17 2 3
I2 O2 A2/D2 OUT1
17 3 16 3 R9
C6
K4
I3 O3 A3/D3 L6203
13 5
RTC IN1
22k
5 4 15 4
IC3
I4 O4 A4/D4
15n
18 5 C8 4
A5/D5 BOOT1
ULN2803A 12 9
CTC VREF
6 5 14 6
I5 O5 A6/D6
1n
19 6 13 7 R10 GND SENSE
C4
I6 O6 A7/D7
11
RS
47k 6 10
7 7 12 9
I7 O7 A8/D8
220n
20 8 11 10 14
I8 O8 A9/D9 TE
VEE
8
JP1
21 9
J1
on 8 R3 R4 R5
9
FUNCTION
22
MC145026
off
10
5W 5W
23
11
PWR
24
U
PWR
12
D1 D2
25 see text
*
STOP
13
siehe Text
STOP GO
IC2b
*
T2
6
voir texte 4
e"1
*
5
K1 S1
T3
zie tekst
*
BC547B U
BC547B
U
12 - 16V
B1
R7
IC2c
T1
9
10
S2
e"1
8
K2
* *
C3 C2 C1
14
C7
BC547B
R1 R2 R6
D3
KBPC601
IC2
C9
GO
4700µ 2200µ 2200µ IC2 = 4001
10µ
35V 40V 40V 7
16V
10n
5V6
400mW
000066 - 11
PWR
Figure 2. Circuit diagram of the Märklin Model Train Control System. The control elements, a mouse and your PC keyboard, are not
shown here.
simply applied to the rails (alternating volt- ital H0, Lenz, Fleischmann and bilities of the pulse pairs are actually
age in Märklin systems, direct voltage in Selectrics), only the first two actually employed. 00 equals logic zero, 11
most others), where overvoltage (Märklin) or got a foothold. In addition, Märklin equals logic 1, and 10 is logic open.
polarity (other brands) provides information Digital H0 is now flanked by several In the original Motorola data format,
about the direction the locomotive has to dialects including the EEDTs data the combination 01 is not used in
travel in. With digitally controlled tracks, the format and the New Motorola the New Motorola Dataformat, you
rails carry a signal that alternates between a Dataformat . Other brands, too, have guessed it, it is.
fixed positive and a fixed negative level. variants. In this article, we will limit A single data burst or packet con-
Depending on the model train brand and ourselves to Märklin Digital H0, sists of nine pulse pairs. The first
gauge, this voltage usually lies between because that is the format recog- four are used as (locomotive)
Ä
12 V and Ä
18 V. The rate at which the volt- nized by the system described here. addresses, supplying 34 = 81
age swings from + to represents control Märklin Digital H0 employs a addresses of which only 80 are used
information for individual locomotives and, if switching sequence once designed by Märklin. The remaining five pairs
applicable, other devices like signals. by Motorola for use in remote con- are only decoded in binary fashion:
As with too many other products, the trols. Information is bundled into 00 or 11; with bit 5 flagging the
industry did not succeed in agreeing on a packs of 18 pulses. In fact, these on/off state of the extra function, and
common standard in this field. Of the four dig- pulses are pairs of two pulses each. bits 6-9 containing speed and engine
ital systems originally available (Märklin Dig- Three of the four combination possi- reversing commands.
10k
1
&!
5
1
&!
5
2k2
10k
560
&!
560
&!
GENERALINTEREST
Some time ago, Märklin intro- directly to the parallel port, it would technology, we need not concern ourselves
duced the so-called New Motorola not have been possible to activate too much with switching speeds or power
data format, in which all four combi- any Delta decoder at all! dissipation. At the maximum output current
nation options are allowed (00, 01, 10 The second nibble of the parallel of 3.5 A chosen for this circuit, the L6203
and 11). The extra combinations in port is used for setting bits 6-9 on remains reasonably cool. With insufficient
the function bit and the remaining the encoder. These bits contain cooling, an internal overheating protection
four bits are used for non-volatile speed information and the reversing arranges for the IC to be switched off once a
direction information and extra command: the bit combination is certain temperature limit is exceeded. Com-
switching functions. The standard 1000. ponents C5 and C6 are so-called bootstrap
Motorola encoders and decoders, Bit 5, the function bit, is given a capacitors which serve to ensure a suffi-
however, are unable to process these fixed state with the aid of a jumper ciently high gate voltage on the two power
pulse pair combinations. or switch (JP1) and is therefore on or MOSFETs in the upper section of the bridge.
Finally, we should mention that a off for all locomotives to be The output current flows to ground via the
pause with a certain length is addressed. That should not be a sense connection and R3-R4. These resistors
inserted between the 18-pulse pack- problem because this bit usually serve to monitor the maximum output current
ets. This is done to synchronize the controls the lighting function, which because the L6203 is not wholly and truly
transmitter and the receiver. The is preferably on by default. Only the short-circuit proof. The voltage developed
packet has length of about 3.8 ms, oldest EEDTs decoder employs bit 5 across R3 and R4 is fed to the input of NOR
while the pause takes about 2 ms. for (non-volatile) direction informa- gate IC2b via R5-C9, a low-pass filter to sup-
As an extra safety measure, tion. Hence that decoder can not be press inevitable switching pulses. Together
Motorola have built in a protocol that used with this circuit, because with IC2c, the NOR gate forms a bistable
arranges for the receiver to be sup- changing the state of JP1 would with a special treat in that IC2b is (mis-
plied with the same data packet cause all trains to reverse. Later )used as an analogue comparator. Standard
twice in sequence for it to be recog- EEDTs loco decoder variants, includ- CMOS circuits are designed to switch at
nized as valid. This protocol appears ing the most recent EEDTs Pro, are about half the supply voltage. If the voltage
to be surprisingly effective for all fully compatible with the present at pin 6 of IC2b reaches 2.5 V (which happens
rolling stock moving at considerable system. at 2.5 V / 0.75 &! or 3.5 A), IC2b and IC2c tog-
speed across the track. Components R9, R10 and C8 gle.
determine the timing of the encoder. The enable input of the L6203 is then
Resistor R9 determines the length pulled low, the bridge is switched off, and the
The circuit
(duration) of one packet of 18 pulses tracks are disconnected from the supply. The
The circuit diagram shown in Fig- (3.8 to 4 ms), while R10 takes care of green GO LED, D2, also goes out and its red
ure 2 is of an attractive simplicity. the synchronisation pauses between counterpart, D1, marked STOP, lights. When
The core is formed by IC4, a pulse packets. this happens, switch S2 may be used to
Motorola encoder chip type Originally, the circuit was rerestart the circuit. A stop condition may be
MC14026 which looks after all con- designed for direct connection to the forced by operating switch S1.
verting into serial digital format of EEDTs Booster. However, the The two remaining gates in IC2 are used
data received from the PC parallel Booster, with its 10-amp output cur- to supply the bridge with the normal and
port. In a way, the encoder IC also rent capacity and considerable cost inverted digital signal.
restricts the operation of the circuit: it and effort of building may be too The 5-V logic supply voltage is derived
is capable of generating the old (tra- much of a good thing, and beyond from the unregulated power supply. A zener
ditional) data format only. This the reach of beginners. That is why diode is used in combination with emitter fol-
allows standard and Delta locomo- the present circuit comes with its lower T3 acting as a power buffer, because
tives to be controlled. Decoders from own mini booster, IC1, which is the input voltage conditions are rather uncer-
other brands (for example, Lenz) or short-circuit as well as overload tain. If, for example, a Märklin transformer is
decoders having the four extra func- resistant. To keep the cost of build- connected and the speed control knob is
tion outputs utilizing the New ing the project down to the absolute turned back to the train reversing position, an
Motorola data format can not be minimum, it is possible to connect alternating input voltage of 24-30 V appears
used in conjunction with this circuit. the existing Märklin transformer and at the supply inputs. When rectified, that
Darlington array IC3 acts as an use it as a power supply. Using B1 would produce an input voltage surge that is
interface between the parallel port and C1/C2 (or C3, see construction sure to endanger the life of a 7805 voltage
on the PC and the encoder chip. The details), a single direct voltage is regulator. With D3 and T3 included, the cir-
first four outputs are used to set the derived from the transformer s sec- cuit will withstand this abnormal condition.
locomotive address on the decoder. ondary voltage. A full bridge output The output bridge can also safely handle this
Because the open-collector outputs stage has to be chosen to enable a voltage surge of up to 52 volts.
are not fitted with pull-up resistors, single-rail input voltage to be turned (000066-1)
the status of the address lines is into an output voltage that switches
always Low or High-Z. The ability to between a positive and a negative Next month s second and final instalment will
set a High-Z status is essential value. The L6203 from ST Microelec- cover the system software and hardware con-
because the Delta addresses defined tronics combines the required func- struction.
by Märklin all have logic open bits. tions in a single IC. Plus, because
If the encoder were connected the IC is manufactured in DMOS
Wyszukiwarka
Podobne podstrony:
0620 Removal and installation of control unit for airbag seat belt tensioner Model 126 (to 08?)Model Railroader Basic electricity and control0622 Removal and installation of control unit for airbag seat belt tensioner Model 126 (from 09?)Dynapower Model 66 & 99 Modular Controls PartsSPIO To Digital IO Module MODEL SDIOB8A Digital Control Technique for a single phase PWM inverterModel kartonowy Digital Card Model 2001 Nieuport RNAS School 1 32control structures continueRzutparteru Model (1)A Digital12 control statementsmodel ekonometryczny zatrudnienie (13 stron)EB TOU Ho Ho Ho GI Blog TrainwiÄcej podobnych podstron