MERG Article - TOTI Motherboard
Bit of a short article this time around, I'd hoped to have been able to afford to be somewhat further along with this mini project by now. So I'll just cover the starting of the design phase.
As you may recall from previous articles my ControlPlayground (or rather its first control board) is using DCC (via a SPROG) to control the trains and RPC to control the railway. Whilst RPC has a module for detecting the presense of trains (or rather that a section is drawing current) it does so by using a current transformer which involves passing the track feeds round a ferrite core. Not that there's alything wrong with that but I prefer the MERG TOTI method of just connecting the section feeds to the PCB. So here comes the problem, how to interface 8 TOTI PCBs (from the MERG kits) to an SRI4's input (from the RPC kits).
The SRI4 works by taking an input which is either connected to 0V (on) or not connected (off). In the event it is not connected a pull-up resistor on the SRI4 connects it to the +ve supply so that the RPC stack sees it as either high or low.
The TOTI works by either making (train on track) or breaking (block empty) a connection between two ports.
The way these work means that the TOTI to SRI part is quite simple, we take a 10 way connector to the SRI, connecting pin 10 (0V) to pin 5 (output, -ve) on all the TOTIs. Pin 9 on the TOTI (output, +ve) is then connected to one of the input lines on the SRI connector (pins 2 to 9). The rest of the TOTI pins are then connected as normal (+5v to pin 6, -5v to pin 2, 0v & controller -ve to pins 1 and 7 and track section to pins 3 and 4). The other controller lead is connected to the other side of the track.
The only other thing to bear in mind is that if we're using DC then we need to add a DC bias so that there is enough current flowing (even in a stationary train) to be detected, this is arranged by adding a resistor and diode (supplied with the TOTI kits) between the +5V supply and the side of the track not connected to the TOTI.