Optoisolator Type Block Occupancy Detectors

  This page is about a block occupancy detector that uses optoisolators to electrically separate the track from the detector output. Three versions of the detector are shown: Basic, Time Delayed and Direction Indicating.

  There is nothing special about these circuits and there are other versions of this type of detector on the web and other places. The circuits have simplified outputs that use a minimum number of parts and can be configured to control just about any load device from LED's to relays.

  With the track isolated from the detector output there can be a great deal more flexibility in building control circuitry for a layout as there is no concerns about connecting systems with different power supplies.

  The circuits are built around the LM339 Quad Voltage Comparator chip and the H11AA4QT or 4N35 optoisolators.


Basic Detector

  The following schematic shows the basic detector circuit. this circuit will indicate an occupied block for a train traveling in either direction.

  This circuit could be used with DCC control systems.

Basic Optoisolator Block Occupancy Detector Schematic


Time Delay Detector

  The next diagram shows the basic detector but with a built-in time delay via C1 and IC 1B to prevent the indicating LED from flickering during brief drops in current flow. In this circuit the output will turn on instantly by will not turn off until approximately 2 second after a train is no longer detected.

  The circuit would be used to prevent relays from "chattering" during brief losses of current flow due to poor current pick-up for example.

Time Delay Optoisolator Block Occupancy Detector Schematic


Direction Indicating Detector

  The next schematic shows a direction indicating version of the basic detector circuit. This circuit will indicate not only an occupied block also the direction of the trains travel.

  The circuit uses two optoisolators and detector circuits, one for each direction, to determine which way the current is flowing through the bridge and thus the direction of the train. Dual and quad optoisolator packages could be used for this circuit to reduce the number of devices in the circuit.

  This detector will only be operate properly with reversible current type direction control such as conventional power packs.

Optoisolator Type Block Occupancy Detector - Direction Indicating Schematic

  Only one resistor (R7) is needed for the direction LED's as only one of them can be at a time.


Detector Circuit Operation

  1. When a large enough current flows through R1, the optoisolators LED will turn ON.
  2. When the LED is ON the optoisolator's output transistor will conduct and the voltage across it will drop below 6 Volts.

  3. This will cause the output of IC 1A to go LOW and the LED will turn ON or the voltage from C1 will be drained off.

    In the Time Delay version, when the voltage across C1 drops below 6 volts the output of IC 1B will go LOW and D1 will turn ON and indicate the presence of a train in the block.

  4. When sufficient current no longer flows through R1 and the optoisolators LED the transistor will turn off and the voltage across it will go above 6 Volts. The output of IC 1A to go HIGH and the LED will turn OFF.

    In the time delayed circuit the C1 will charge and approximately 2 seconds after the train leaves the block the LED will turn OFF.

  5. In the direction indicating circuit the the operation is the same as in the Basic version except that two isolators are used to sense which way the current is flowing through R1. The two optoisolators drive corresponding comparators that have their own LED's to indicate the direction.


Optoisolator Type Detector With A LM555 Timer Output

  The following circuit uses an LM555 timer to provide both an open collector and bipolar outputs. The LM555 timer is used as an output device for some of the other block occupancy detectors on this site.

Optoisolator Type Block Occupancy Detector - LM555 Timer Output Schematic

Optoisolator Type Block Occupancy Detector - With Crossing Flahsers


Optoisolator Type Detector Notes


Return to the Main Page


Please Read Before Using These Circuit Ideas

  The explanations for the circuits on these pages cannot hope to cover every situation on every layout. For this reason be prepared to do some experimenting to get the results you want. This is especially true of circuits such as the "Across Track Infrared Detection" circuits and any other circuit that relies on other than direct electronic inputs, such as switches.

  If you use any of these circuit ideas, ask your parts supplier for a copy of the manufacturers data sheets for any components that you have not used before. These sheets contain a wealth of data and circuit design information that no electronic or print article could approach and will save time and perhaps damage to the components themselves. These data sheets can often be found on the web site of the device manufacturers.

  Although the circuits are functional the pages are not meant to be full descriptions of each circuit but rather as guides for adapting them for use by others. If you have any questions or comments please send them to the email address on the Circuit Index page.

Return to the Main Page

17 December, 2008