HomeArticlesProjectsBlogContact
Articles
Point Motor Controller for Solenoid
Colin Mitchell
Colin Mitchell
March 26, 2014
Make sure to subscribe to our newsletter and be the first to know the news.

Table Of Contents

01
CAPACITOR DISCHARGE UNIT
02
ON-BOARD LED INDICATORS
03
"MICRO" CONTROLLED
04
DETECTING THE TRAIN
05
IR Point Motor Controller MkI Parts List

See more projects using micros:
Pic A PIC Project


IR Point Motor Controller MkI - drives solenoid
IR Point Motor Controller MkII - drives Servo

This is a project you will want to add to your layout.
It detects a train and produces a pulse to alter the points to alternately divert the train to the left track or allow it to continue straight-ahead.
The POINT MOTOR used in this project is a SOLENOID (called a LINEAR ACTUATOR) made up of two coils. One coil pulls the core in a direction to move the points to the “ahead” direction and the other coil moves the points to the “siding.”
If you have one of these (called ELECTRIFIED SET OF POINTS) you can convert it to automatic operation with this project.
If you have a set of non-electrified points (manual operation) you can connect a SERVO as shown in our project: IR POINT MOTOR CONTROLLER MKII and for $5.00 extra, you can convert it to automatic operation.
Both projects solve the problem of operating points and preventing them “burning-out” and the special feature of the circuit causes the train to alternately travel forward or into the “siding.” This creates added interest to your layout and with our COPYCAT MkI project, you can make your train travel around the layout AUTOMATICALLY, while you are observing it from a different part of the layout.

The microcontroller we are using has 6 input/output lines and all these lines are used in the IR POINT MOTOR CONTROLLER MKI project.
Two outputs from the micro are used to operate the driver transistors connected to the point motor.
The PC board also contains two LEDs to indicate the position of the points so you know how the train will travel. This requires one output from the micro, with a HIGH indicating “straight-ahead” or a LOW indicating “siding.”
One output is needed to activate the Infra-Red LEDs and two for the IR receivers. This covers all 6 in/out lines of our 8-pin microcontroller.


POINT MOTOR CONTROLLER for SOLENOID

The diagram above shows where the two sets of IR detectors are located on the layout.
A train coming from left to right will trip the first detector and the points will change.
The circuit is designed to alternatively allow the train to travel ahead or divert to the siding.
If the train is diverted to the siding, it may have to be shunted out and the detector must be distant from the point to prevent the train operating the point.
You will then need to shunt the train down the track to operate the point to “straight ahead.”
The second detector will not operate the point due to a 10 second delay in the program. The second detector will not operate the point due to a 10 second delay in the program.
A train coming from right to left will operate the point to allow the train to pass over the point.

But the interesting feature of the IR Point Motor Controller project is the pulsed Infrared LED of the IR beam.
The transmitter LED is activated at a frequency of 30kHz and the receiving transistor is “looked at” for a period of 1 millisecond. This will result in 30 “counts”. turned ON for 10 milliseconds and this is done 4 times a second. During this time the receiving LED detects a pulse of IR light and it compares the high illumination with the low illumination from the surrounding conditions. xxxxx(or maybe 10kHz pulses)
In this way the circuit eliminates any background light and only reacts when the beam is broken.

The circuit accepts AC or DC from your “controller” transformer or from a plug-pack (wall wort) and converts it to DC via an on-board diode rectifier and 100u electrolytic. The smoothing does not have to be perfect as the 5v regulator converts the DC (can be from 12v DC to 18v DC) to 5v DC for the microcontroller and the poorly rectified DC is used to charge the two 1,000u electrolytics.
The electrolytics are used to create a LOW-IMPEDANCE POWER SUPPLY, capable of delivering a high current to the point motor via a transistor “switch.” There are two transistor switches to do this. One transistor switches the point “to the left” and the other switches the point “straight-ahead.” Point motors have 3 connections, with a common as the centre wire.
Only the energy from the two electrolytics is passed to the point motor and this activates one of the coils for a short period of time.
The point-motor cannot be re-activated for 5 seconds (due to a delay produced by the micro) after the train has passed so it is important to keep two trains some distance apart so the point can be re-activated.
If you don’t want the second train to take the “siding rail” simply bring the train up to the sensor and this will activate the point. Reverse the train and wait. The point will be activated again and the second time the point will be “straight-ahead.”

CAPACITOR DISCHARGE UNIT

The project contains a CAPACITOR DISCHARGE UNIT, made up of two 1,000u electrolytics. This creates a separate low-impedance power supply to operate the point motor without putting a heavy load on the plug pack.
The two electrolytics are charged via a 330R resistor and this means they will take a fairly long time to fully charge. But this does not matter as the circuit has a delay of at least 10 seconds before the points can be changed. This is to prevent them changing when the train is over them.

ON-BOARD LED INDICATORS

A red LED on the PC board indicates the points are set for “ahead” and a green LED shows the points are set for “siding.” An oncoming train will set the points “ahead.”

“MICRO” CONTROLLED

This project uses an 8-pin microcontroller because it produces the simplest and cheapest design. All the timing and controlling is contained in a program instead of dozens of individual components and anything can be changed by simply going to the program and changing the instructions.
This project would normally need 2 - 4 chips. A micro is cheaper and takes up less board space.
It is also quicker to write the program than build a discrete circuit because many of the sub-routines are already available on Talking Electronics website as “cut and paste.”

DETECTING THE TRAIN

The secret to detecting the train is INFRA-RED PULSES.
The micro can really on perform one task at a time and the train detection circuit consists of an IR LED and receiving transistor.
The circuit must be able to automatically be able to detect the presence of a train over a range of lighting conditions so the detecting circuit doesn’t have to be adjusted for different lighting levels. To do this the IR LED is pulsed and these pulses are picked by the IR receiving transistor.
When a train is NOT present, the reflected IR pulses are not picked up by the receiver, but if they are, the ambient light does not allow the receiver to produce a HIGH/LOW output. It simply produces a LOW then an extra-low output.
However when a train passes over the detection-pair, the surrounding ambient light is removed and the pulses for the LED are reflected on the underside of the engine and passed to the receiver to produce a definite High-LOW output.
The program is designed to go to a “counting loop” for a short period of time and if it detects 20 pulses, the program has detected the train.
The program alternately selects one IR pair then the other and this takes up most of the processing-time when the project is waiting to detect a train. The Spectral Response for the IR transistor is shown in the following diagram.


THE INFRA-RED SPECTRUM OF THE IR DETECTORS

There are two different types of Infra red receivers. One type is quite dark and has a coating to reduce room light. The other is clear and has a higher gain at about 900nm, but as you can see from the graph above, it will still detect light in the visible spectrum.
That’s why our circuit has been designed to work when covered by the train and detect IR illumination to produce a guaranteed HIGH-LOW output.

These features are contained in our simple design and can be built in an evening on Matrix Board. A kit of components is available from Talking Electronics as well as a pre-programmed microcontroller.

Features:

  • Operates point motor with 0.25 sec pulse
  • Operates point motor alternatively “ahead” or “siding”
  • Operates point motor for oncoming train to prevent “point-derailment”
  • On-board LEDs indicate “ahead” or “siding”

RUNNN

IR Point Motor Controller MkI Parts List

Cost: au$20.00 plus postage
[Kits are available](mailto:colin@elechelp.com?Subject=Buying LED FX kit&Body=Please e-mail the cost LED FX kit by air mail to my country:****___**** and send details of how I can pay for it. My name is:____)

  • 1 - 180R

  • 2 - 220R

  • 1 - 330R

  • 2 - 2k2 resistors

  • 2 - 22k

  • 1 - 100n SM capacitor

  • 1 - 100u electrolytic

  • 2 - 1,000u 25v electrolytics

  • 1 - 1N4004 diode

  • 1 - LM78L05 voltage regulator

  • 1 - 3mm red LED

  • 1 - 3mm green LED

  • 2 - IR emitter LEDs

  • 2 - IR receiver transistors

  • 2 - BD679 Darlington transistors

  • 1 - PIC12F629 chip (with routine)

  • 1 - 8 pin IC socket

  • 1 - 2m fine screened lead (for testing)

  • 3 - 20cm hookup wire (for testing)

  • 3 - 2-way terminal blocks

  • 1 - 20cm very fine solder

  • 2 - Surface Mount PC boards (for train detector pair)

  • 1 - IR Point Motor Controller MkI PC board


Colin Mitchell

Colin Mitchell

Expertise

electronics
writing
PIC-Chips

Social Media

instagramtwitterwebsite

Related Posts

TODO
Transistor Test
© 2021, All Rights Reserved.

Quick Links

Advertise with usAbout UsContact Us

Social Media