ORD-1 is a hardware interface for model train control. It is designed for use with Rocrail.
This do-it-yourself (DIY) command station module connects your computer to your model train setup. The computer generates the data stream needed to control locos and turnouts. ORD-1 amplifies this data stream. Also, the computer read sensors status back from S88 modules through ORD-1. The most unique ORD-1 feature is the opto isolation, minimizing the risk for computer hardware damage when playing with the relatively high model train voltages.
To run Rocrail in auto mode, with DDX as interface library, a minimal testing setup will use:
All documentation: https://gitlab.com/rocrail/GCA/tree/master/ord-1
Last version is 1.52; Older versions are not longer available.
Schematics and PCB artwork was created with KiCad, an Open Source (GPL) PCB Suite.
Use standard straight cables with one male and one female connector.
9-pin D-Sub for the serial port (RS232) and 25-pin D-Sub for parallel port (printer port).
You may change the printer port bios settings if the relay does not work. Some PC's work well with standard setting, some must be set to ECP+EPP.
When the ORD-1 is connected to a com port and Rocrail server is running (and no com port errors was shown in log), the LEDs looks like:
D10 unlit = no S88 data on bus 1 D12 unlit = no positive track voltage D13 unlit = no negative track voltage D14 unlit = no data D15 unlit = STOP D16 unlit = normal (not programming mode) D17 lit = SC detected D18 lit = +5V working D19 lit = +12V working D20 lit = negative voltage working
When power to track is on (the power lamp in Rocrail gui is pressed), the LED looks like:
D10 unlit = no S88 data on bus 1 (with no S88 bus connected) D12 blinking very fast D13 blinking very fast D14 blinking very fast D15 lit = GO D16 unlit = normal (not programming mode) D17 unlit = no SC detected D18 lit = +5V working D19 lit = +12V working D20 lit = negative voltage working
Since Rocrail 1.1, use DDX as control station module. All parameters can be set in the GUI.
A three pole screw terminal, J3, accept incoming AC-power. Two fuses, F1 & F2, secures against fatal over currents. Four diodes, D6-D9, rectifies the voltage. Capacitors C11 & C12 or C13-C24 smooths the voltage. The smoothed voltage is expected to be +-20-24V with no load. Note about 1x16VAC supply: Only ground and one of the AC input terminals is used, and then only one fuse and two diodes. The circuit then becomes a half-wave rectifier. The smoothing capacitors stores charge between the AC-cycle pulses. With 1x16VAC transformer and half-wave rectifying, there is a half cycle gap between each power pulse and the smoothing capacitors must in this case be very much larger. At power off, the positive capacitors will discharge quickly through the linear regulators. The negative half can discharge through R58.
Two standard 7805 and 7812 linear voltage regulators, U5 & U6, creates voltage supply for the electronics. Two small capacitors, C9 & C10, decouple the regulated supplies.
Three diagnostic LEDs makes it easy to see if some voltage is missing. An optional fan output makes it easy to use a 12V CPU-fan for cooling.
Data: PC sends serial data on TX, J2 pin 3. Nominal voltage is +-12V but most serial port outputs have limited drive strength, so voltage will drop when we load it with R42, C1, O9 and O10. O9 and O10 is anti-parallell and only one LED will be lit at a time.
GO: PC sends GO/STOP signal on DTR, J2 pin 4. Positive output > DTR low > O11 LED on > Booster GO. SC: PC receives short circuit signal on DSR, J2 pin 6. Short circuit > O12 transitor driven positive signal > DSR low PT: PC receives programming track ack on RI, J2 pin 9. Ack?? > transistor driven 0V??? > RI???
Data is sent through two opto couplers, O9 + O10. A flip-flop, U1A + U1B restores the signal. R39 + R40 pullup value, 1k, is chosen to give proper rise time. Data signal is sent to booster bus output and to ORD-1 booster. D23 + D24 prevents over voltage destruction of U1, due to wrong booster bus connectivity. R31 gives output over current protection.
DTR line from computer signals Power On/Off (GO/STOP). Optocoupler LED O11 is driven when Power is on (GO). When power is off (STOP) no booster output transistor is driven. This is achieved by forcing data input to booster high with U1D. The base voltage to Q2 and Q4 is forced to nearly the same as Q2 + Q4 emitter voltage, by saturating Q5, and neither Q2 or Q4, nor Q6 + Q7 will be driven.
The booster is unregulated. This means that the output voltage will be almost the same as the rectified and smoothed supply voltage. This is done by saturating the output transistors, one at a time. Two LEDs, D12 + D13, monitors the output voltage. If both LEDs are lit or flickers, both output transistors delivers their half of the output voltage. If both LEDs are unlit, booster is off and output voltage is near zero.
When running normal, the voltage over C2, 1uF capacitor will be about -4V (-20V+15V+1V=-4V), as every negative output part of the output cycle can sink a lot of current through the zener diode Z1 and the diode D4. To prevent over current, R23 100R limits the current through the diodes. The positive parts of the cycle can only charge through a 10k resistor, R16, and that current is not enough to rise the voltage over the capacitor. When short circuited to ground, then the zener diode and the diode can no longer sink current to negative cycles anymore, instead voltage over the capacitor will rise and when high enough, D5 + R17 will drive ch7 output low of U7, ULN2803A. This will make LED D17 and opto-coupler O12 signal short circuit detection (SC). If booster bus pin 5 is driven high, then ch8 of U7, ULN2803A, will be active and signal SC. The filter D21 + C27 ensures that noise from open booster bus port will not trigger SC detection.
When the loco do an ack it rises its own power consumption for a short period. The increased current gives a increased voltage over R51. OP U4 is configured as a comparator with different time constants for positive and negative input. This detects this quickly raised voltage and drives the ack opto coupler O13 for a short period (6-10ms).
Four S88 signals is read in parallel. Some model train software can only use channel 1. Signals are buffered with U2 and U3. One LED on ch 1 provides monitoring.
If you are unsure how to connect your ORD-1, take a look at the connections drawing:
If you are unsure how to connect after reading the drawing feel free to ask the Forum.