Saturday, 30 November 2013

Speed Checker for Highways

While driving on highways, motorists should not exceed the maximum speed limit permitted for their vehicle. However, accidents keep occurring due to speed violations since the drivers tend to ignore their speedometers.

This speed checker will come handy for the highway traffic police as it will not only provide a digital display in accordance with a vehicle’s speed but also sound an alarm if the vehicle exceeds the permissible speed for the highway.

The system basically comprises two laser transmitter-LDR sensor pairs, which are installed on the highway 100 metres apart, with the transmitter and the LDR sensor of each pair on the opposite sides of the road. The installation of lasers and LDRs is shown in Fig. 1. The system displays the time taken by the vehicle in crossing this 100m distance from one pair to the other with a resolution of 0.01 second, from which the speed of the vehicle can be calculated as follows:


As per the above equation, for a speed of 40 kmph the display will read 900 (or 9 seconds), and for a speed of 60 kmph the display will read 600 (or 6 seconds). Note that the LSB of the display equals 0.01 second and each succeeding digit is ten times the preceding digit. You can similarly calculate the other readings (or time).

Fig. 1: Installation of lasers and LDRs on highway
Circuit description
Fig. 2 shows the circuit of the speed checker. It has been designed assuming that the maximum permissible speed for highways is either 40 kmph or 60 kmph as per the traffic rule.

The circuit is built around five NE555 timer ICs (IC1 through IC5), four CD4026 counter ICs (IC6 through IC9) and four 7-segment displays (DIS1 through DIS4). IC1 through IC3 function as monostables, with IC1 serving as count-start mono, IC2 as count-stop mono and IC3 as speed-limit detector mono, controlled by IC1 and IC2 outputs. Bistable set-reset IC4 is also controlled by the outputs of IC1 and IC2 and it (IC4), in turn, controls switching on/off of the 100Hz (period = 0.01 second) astable timer IC5.

The time period of timer NE555 (IC1) count-start monostable multivibrator is adjusted using preset VR1 or VR2 and capacitor C1. For 40kmph limit the time period is set for 9 seconds using preset VR1, while for 60kmph limit the time period is set for 6 seconds using preset VR2. Slide switch S1 is used to select the time period as per the speed limit (40 kmph and 60 kmph, respectively). The junction of LDR1 and resistor R1 is coupled to pin 2 of IC1.

Normally, light from the laser keeps falling on the LDR sensor continuously and thus the LDR offers a low resistance and pin 2 of IC1 is high. Whenever light falling on the LDR is interrupted by any vehicle, the LDR resistance goes high and hence pin 2 of IC1 goes low to trigger the monostable. As a result, output pin 3 goes high for the preset period (9 or 6 seconds) and LED1 glows to indicate it. Reset pin 4 is controlled by the output of NAND gate N3 at power-on or whenever reset switch S2 is pushed.
For IC2, the monostable is triggered in the same way as IC1 when the vehicle intersects the laser beam incident on LDR2 to generate a small pulse for stopping the count and for use in the speed detection. LED2 glows for the duration for which pin 3 of IC2 is high.

The outputs of IC1 and IC2 are fed to input pins 2 and 1 of NAND gate N1, respectively. When the outputs of IC1 and IC2 go high simultaneously (meaning that the vehicle has crossed the preset speed limit), output pin 3 of gate N1 goes low to trigger monostable timer IC3. The output of IC3 is used for driving piezobuzzer PZ1, which alerts the operator of speed-limit violation. Resistor R9 and capacitor C5 decide the time period for which the piezobuzzer sounds.

The output of IC1 triggers the bistable (IC4) through gate N2 at the leading edge of the count-start pulse. When pin 2 of IC4 goes low, the high output at its pin 3 enables astable clock generator IC5. Since the count-stop pulse output of IC2 is connected to pin 6 of IC4 via diode D1, it resets clock generator IC5.  IC5 can also be reset via diode D2 at power-on as well as when reset switch S2 is pressed.

Fig. 2: Circuit of speed checker for highway
IC5 is configured as an astable multivibrator whose time period is decided by preset VR3, resistor R12 and capacitor C10. Using preset VR1, the frequency of the astable multivibrator is set as 100 Hz. The output of IC5 is fed to clock pin 1 of decade counter/7-segment decoder IC6 CD4026.

IC CD4026 is a 5-stage Johnson decade counter and an output decoder that converts the Johnson code into a 7-segment decoded output for driving DIS1 display. The counter advances by one count at the positive clock signal transition.

The carry-out (Cout) signal from CD4026 provides one clock after every ten clock inputs to clock the succeeding decade counter in a multidecade counting chain. This is achieved by connecting pin 5 of each CD4026 to pin 1 of the next CD4026.

A high reset signal clears the decade counter to its zero count. Pressing switch S2 provides a reset signal to pin 15 of all CD4026 ICs and also IC1 and IC4. Capacitor C12 and resistor R14 generate the power-on-reset signal.

Fig. 3: Power supply
The seven decoded outputs ‘a’ through ‘g’ of CD4026s illuminate the proper segment of the 7-segment displays (DIS1 through DIS4) used for representing the decimal digits ‘0’ through ‘9.’ Resistors R16 through R19 limit the current across DIS1 through DIS4, respectively.

Fig. 3 shows the circuit of the power supply. The AC mains is stepped down by transformer X1 to deliver the secondary output of 15 volts, 500 mA. The transformer output is rectified by a bridge rectifier comprising diodes D3 through D6, filtered by capacitor C14 and regulated by IC11 to provide regulated 12V supply. Capacitor C15 bypasses any ripple in the regulated output. Switch S3 is used as the ‘on’/‘off’ switch. In mobile application of the circuit, where mains 230V AC is not available, it is advisable to use an external 12V battery. For activating the lasers used in conjunction with LDR1 and LDR2, separate batteries may be used.

Construction and working
Assemble the circuit on a PCB. An actual-size, single-side PCB layout for the speed checker is shown in Fig. 4 and its component layout in Fig. 5.

Fig. 4: Actual-size, single-side PCB layout for the speed checker

Fig. 5: Component layout for the PCB

Download File

Before operation, using a multimeter check whether the power supply output is correct. If yes, apply power supply to the circuit by flipping switch S3 to ‘on.’ In the circuit, use long wires for connecting the two LDRs, so that you can take them out of the PCB and install on one side of the highway, 100 metres apart. Install the two laser transmitters (such as laser torches) on the other side of the highway exactly opposite to the LDRs such that laser light falls directly on the LDRs. Reset the circuit by pressing switch S2, so the display shows ‘0000.’ Using switch S1, select the speed limit (say, 60 kmph) for the highway. When any vehicle crosses the first laser light, LDR1 will trigger IC1. The output of IC1 goes high for the time set to cross 100 metres with the selected speed (60 kmph) and LED1 glows during for period. When the vehicle crosses the second laser light, the output of IC2 goes high and LED2 glows for this period.

Piezobuzzer PZ1 sounds an alarm if the vehicle crosses the distance between the laser set-ups at more than the selected speed (lesser period than preset period). The counter starts counting when the first laser beam is intercepted and stops when the second laser beam is intercepted. The time taken by the vehicle to cross both the laser beams is displayed on the 7-segment display. For 60kmph speed setting, with timer frequency set at 100 Hz, if the display count is less than ‘600,’ it means that the vehicle has crossed the speed limit (and simultaneously the buzzer sounds). Reset the circuit for monitoring the speed of the next vehicle.

Note. This speed checker can check the speed of only one vehicle at a time.

Automatic Washbasin Tap Controller

Make your washbasin tap work automatically when you put your hands just below the water tap outlet. This infrared-based system detects any interruption of the IR rays by your hands or utensil and water automatically starts flowing out of the tap.

The circuit is built around 555 timers and comprises transmitter and receiver sections. Both the transmitter and the receiver work off 5V DC. The IR rays continuously emitted by the transmitter fall on the receiver. As soon as an obstacle comes in between the receiver and the transmitter, interrupting the IR rays, the output of the IR sensor goes low momentarily to trigger the timer circuit in the receiver and water comes out for eleven seconds through the tap.

Fig. 1: Transmitter circuit
The transmitter is built around timer IC 555, which is used as an astable multivibrator to generate around 38 kHz frequency (see Fig. 1). The timer output is fed to transistor T1, which drives the IR LED (LED1). Note that IR LED1 must be properly oriented towards the IR sensor module of the receiver circuit. Its transmission wavelength of 900 to 1100 nm lies in the peak receptivity range of TSOP1738 receiver module.

The receiver circuit comprises the sensor module, monostable timer and relay driver circuit (see Fig. 2). The sensor module TSOP1738 is sensitive to IR radiation modulated at 38 kHz. Its normally high output goes momentarily low when any IR radiation is detected or interrupted.

Fig. 2: Receiver circuit
When IR rays falling on the receiver are interrupted, the sensor output goes low momentarily to trigger timer IC2. The output of the timer goes high for eleven seconds and the relay drives the solenoid. During this time period, energisation of the solenoid lifts up the valve fitted in the pipe to let water flow out of the tap. Solenoid valves used specifically for this purpose are shown in Fig. 3.

The relay driver circuit consists of resistor R8, transistor BC548 (T2) and free-wheeling diode D1. Diode D1 protects the relay from damage by high voltages generated by the back emf when the relay is de-energised.

The time period for which the timer goes high can be calculated as follows:
Ton=1.1 R6C5=1.1×100×103×100×10–6=11 seconds

Fig. 3: Mains 230V AC 2/2-way semi-pilot,diaphragm type, solenoid valves
Use shielded wires or leads for installing the IR LED and the IR sensor at opposite sides of the washbasin. Install the IR LED and IR sensor around half a metre apart such that the IR rays transmitted by the IR LED directly fall on the IR sensor. Now switch on the power supply to the circuit.

When you put your hands between the IR LED and IR sensor, the relay energises to make the solenoid open up the valve and water flows out of the tap.

Battery-Low Indicator

Rechargeable batteries should not be discharged below a certain voltage level. This lower voltage limit depends upon the type of the battery. This simple circuit can be used for 12V batteries to give an indication of the battery voltage falling below the preset value. The indication is in the form of a flickering LED.

At the heart of the circuit is voltage comparator IC LM319 (IC1). It is a dual comparator with a TTL-compatible output. We have used only one comparator here. A reference voltage of 1.2 volts generated by band-gap reference diode D1 (LM385) is applied to the non-inverting input (pin 4) of the comparator. The inverting input (pin 5) of the comparator is fed a voltage generated from the potential divider arrangement built around resistors R2 and R3 and preset VR1. That means, if you are using a 12V battery and want an indication as soon as the battery voltage goes below 10.5V, adjust the voltage at the inverting input using reset VR1 so as to get a voltage of 1.2 volts (with battery voltage at 10.5V).

Initially, when the battery is fully charged, the voltage at the inverting input of IC1 is higher than the non-inverting input and output pin 12 of IC1 remains low. The reset pin (pin 4) of IC2 connected to pin 12 of IC1 also remains low and the astable multivibrator built around IC2 does not oscillate. As a result, LED1 does not flicker.

When the battery voltage falls below 10.5V, the voltage at the inverting input of IC1 becomes lower than the non-inverting input and the output of IC1 goes high. The reset pin of IC2 connected to pin 12 of IC1 also goes high and the astable multivibrator built around IC2 starts oscillating. LED1 flickers to indicate that the battery voltage is low and the battery needs to be charged before further use. Both IC1 and IC2 operate off regulated +5V DC generated by voltage regulator IC 7805 (IC3).

Assemble the circuit on a general-purpose PCB and enclose in a suitable cabinet. Mount LED1 and switch S1 on the front side of the case. Connect a 12V battery to check its voltage level. 


Solar Battery Charging Indicator

Here is the circuit of a simple charging monitor that indicates whether the storage battery of a solar power unit is being charged or not. It, however, does not tell the state of the solar panel.


 Block diagram of solar battery charging indicator

The circuit consists of two common ICs, an npn transistor, ten 5mm red LEDs and a few discrete components. It can be divided into two parts: voltmeter and display controller.

The voltmeter, built around IC LM3914 (IC1), is a low-power, expanded-scale type LED voltmeter that indicates small voltage steps over the 7-16V range for 12V solar panels. The meter saves power by operating in a low-duty-cycle 'flashing' mode where the LED indicators are on (and hence consuming power) briefly. The circuit may be switched to steady mode where the active indicator remains on at all times.
The input for IC1 (LM3914) is derived from the solar panel voltage via a potential divider network comprising preset VR1 and resistors R1 and R2. This variable input is about 3V for a DC potential of 12V. 
The display range depends on the internal voltage reference and resistors R3-VR2-R4. The lowest LED (LED1) glows when the input voltage at pin 5 of IC1 is 1.8V and the top most LED (LED10) glows when the voltage exceeds 4V. as the input signal is divided by 4, the display ranges should be multiplied by this figure. So the actual display range is 7-16V, i.e., 1V per LED.
The display controller is built around IC LM555 (IC2) that is wired in astable (free-running) mode with a narrow-pulse output. The duty-cycle of IC2 is controlled by the ratio of resistors R6 and R7. If you want faster blinking, use a smaller value of resistor R7. A preset may be substituted for R7 if a rate adjustment is desired. Increase the value of resistor R6 to get a longer 'on' time for LED indicators. The frequency of oscillations is determined by the combination of capacitor C4 and resistors R6 and R7. 
The output of timer IC2 is fed (through current-limiting resistor R5) to transistor T1 ,which, in turn, controls the power to IC1. Capacitor C1 filters the control voltage input to IC1 and capacitor C3 provides DC filtering for the entire circuit. When you press switch S1 across capacitor C4, the output of IC2 remains high, and the display switches to steady mode from flashing mode. Switch S2 is the master power-on/off switch.
Assemble the circuit on a small, general-purpose printed-circuit board (PCB) and enclose in a suitable plastic box. After necessary calibration, connect the circuit to the output cable of the charge controller unit with correct polarity.
For calibration, lock preset VR1 at the centre position and then set VR2 to its maximum resistance with the help of a digital multimeter. Now close both the switches (S1 and S2) and connect the circuit to a variable-voltage DC power supply unit with its output level set to 12V (1%). Adjust VR1 until LED6 (at pin 14 of IC1) lights up. Finally, lock presets VR1 and VR2 using glue.  

Multi Cell Charger

Using this charger, you can safely charge up to two pieces of Ni-Cd cells or Ni-MH cells. The circuit is compact, inexpensive and easy-to-use.

The 230V AC mains is down-converted to 12V AC (at 500 mA) by step-down transformer X1, converted into pulsating DC voltage by diodes D1 and D2, and fed to the battery charger terminals via current-limiting resistor R1 and silicon-controlled rectifier SCR1.

SCR1 is at the heart of the charger. Normally, it conducts due to the gate biasing voltage available through resistor R2 and diode D3, and the battery is in charging mode, which is indicated by LED1. Resistor R2 limits the charging current to a safe value. Charging current of this circuit is about 250 mA.
When the battery reaches full charge, SCR2 conducts to pull down the gate of SCR1. This state is indicated by LED2. Now remove the cells from the charger. Normally, Ni-Cd cell with a rating of 500 mAH will take around 2.5 hours to reach full charge, while the charging time for Ni-MH cell with a rating of 1500 mAH will be around 7 hours. Charging time may vary depending on the settings of the charger and input supply line conditions.

After construction, a minor adjustment is required for ensuring proper performance: Power on the circuit without cells and adjust VR1 such that LED2 lights up. Now measure voltage across the charger output terminals, which should be around 5V DC. Now insert the two cells into the holder and connect it to the charger output terminals for charging. LED1 instantly lights up to indicate the charging process. If LED1 glows dimly, readjust VR1 for proper glowing of LED1. Now the circuit is ready for use.

Use of a small heat-sink is recommended for SCR1.