Recent Posts

Introduction to Relays

RELAYS

What are relays?


Relays are electromechanical devices that use an electromagnet to operate a pair of movable contacts from an open position to a closed position. The advantage of relays is that it takes a relatively small amount of power to operate the relay coil, but the relay itself can be used to control motors, heaters, lamps or AC circuits which themselves can draw a lot more electrical power.


different types of Relays

How relays Work:-
Here are two simple animations illustrating how relays use one circuit to switch on a second circuit.
When power flows through the first circuit (1), it activates the electromagnet (brown), generating a magnetic field (blue) that attracts a contact (red) and activates the second circuit (2). When the power is switched off, a spring pulls the contact back up to its original position, switching the second circuit off again.
This is an example of a "normally open" (NO) relay: the contacts in the second circuit are not connected by default, and switch on only when a current flows through the magnet. Other relays are "normally closed" (NC; the contacts are connected so a current flows through them by default) and switch off only when the magnet is activated, pulling or pushing the contacts apart. Normally open relays are the most common.
Here's another animation showing how a relay links two circuits together. It's essentially the same thing drawn in a slightly different way. On the left side, there's an input circuit powered by a switch or a sensor of some kind. When this circuit is activated, it feeds current to an electromagnet that pulls a metal switch closed and activates the second, output circuit (on the right side). The relatively small current in the input circuit thus activates the larger current in the output circuit:

(IMAGE explainthatstuff.com)


  1. The input circuit (black loop) is switched off and no current flows through it until something (either a sensor or a switch closing) turns it on. The output circuit (blue loop) is also switched off.
  2. When a small current flows in the input circuit, it activates the electromagnet (shown here as a red coil), which produces a magnetic field all around it.
  3. The energized electromagnet pulls the metal bar in the output circuit toward it, closing the switch and allowing a much bigger current to flow through the output circuit.
  4. The output circuit operates a high-current appliance such as a Lamp or an electric motor.

(IMAGE explainthatstuff.com)



Factor for Selecting an Appropriate Relay:-
1. The voltage and current needed to energize the coil.
2. The maximum voltage which we will get at output.
3. Number of armature.
4. Number of contacts for the armature.
5. Number of electrical contracts (N/O and N/C).



Automatic Water-Level Indicator

Here’s a simple water-level indicator for overhead tanks that uses three LEDs (LED1, LED2, and LED3) to indicate minimum, middle, and maximum water levels in the tank.

The sensor probes comprise A, B, C, and D, where A is the common probe and B, C, and D are meant for sensing the minimum, middle, and maximum levels, respectively. When water in the tank touches sensor wires A and B both, a small current passes from A to B through water and to the base of transistor T1 via resistor R1. As a result, transistor T1 conducts, causing LED1 to glow. Similarly, when water touches sensor C, LED2 glows to indicate that the water has reached the middle level. Finally, when water touches sensor D, LED3 glows to indicate the maximum level of water. Thus all the three LEDs glow when the tank is full. At this stage, the motor should be switched off manually.



The circuit can be easily assembled on a general-purpose PCB and enclosed in a wooden box. The three LEDs should be mounted on the front panel of the box with a spacing of about 4 cm between them. Short lengths of four 18 SWG copper wires may be used for sensor probes. For the common sensor A, a bare copper wire of 18 SWG should be used. For sensors B, C, and D three single-core PVC wires should be used, with their insulation removed to a length of one centimetre towards the ends. All the four wires may be tied around a 12.5mm dia. PVC tube with nylon thread at different heights, without touching each other (not shown in figure).

The sensor probes should be kept in the tank vertically and connected to the main circuit using four flexible PVC wires of different colours.

The circuit is powered by a battery eliminator or a 6V battery and kept near the motor switchboard. The current drawn by the circuit, when all the LEDs glow, is up to 50 mA, which is less than the current drawn by a 6V bed-lamp.

ELECTRONIC MOSQUITO REPELLER

Basic principal of this circuit is to connect a such type of buzzer which can produce ultrasonic frequency range. With the help of oscillator in the circuit, buzzer is driven. And in the circuit oscillation is generated by 555 timer which is linked as a astable multivibrator.
The circuit is connected in the closed mode and thus power is received by the 555 timer. In the starting stage voltage in the capacitor is zero volts. So the voltage at the threshold `as well trigger pin is at zero volts. Now the capacitor starts charging via a resistor R1 and R2.There will be one point when the voltage of capacitor will be higher as compared to threshold voltage. At this stage capacitor starts discharging with the help of resistor R2, which is a discharging pin and it keeps of going downward till it reaches to its original state. Thus the signal at the output pin of IC will be an oscillating signal having 38 KHz frequency. With the help of pin 3 of IC which is out pin of IC 38 KHz frequency drives to 38 KHzpiezo buzzer. This buzzer will produce a ultrasound at a regular interval. By altering the value of resistor R2 we can alter the output frequency.

Components Required
IC (IC1)                     NE555
Capacitor (C1, C2)      0.01uF
Resistor (R1  760E),( R2  1.5K)
PiezoBuzzer(B1)          38KHz


Fig 1 circuit Diagram


Fig 2 Circuit on bread board








FAQs


Why use Electronic Mosquito Repellers ?


In addition to being pesky bloodsuckers, mosquitoes are also carriers of various diseases, like dengue, malaria etc. These diseases can even prove to be fatal for the poor, who have little access to medical care.
Methods of repelling mosquitoes have been around for a long time. Most of us are familiar with mosquito repellent creams, wristbands, clothes and plug in devices. Out of these, mosquito repellent wall plug vaporiser devices are the most effective. However, they vaporize chemicals that are not only harmful to mosquitoes, but to humans as well. 

What is the relation between (US) Ultrasound and animals?
Even though human ear cannot sense US, many animals can produce and hear US. Many insects, rodents, bats and small mammals communicate through US. Insects have sensory structures to produce and detect ultrasound. Cockroaches have “Sensory hairs” to sense US. Spiders, Wasps, Beetles, Flies etc have a “Tympanic membrane” to detect US. Fleas communicate using high frequency US . Male Mosquitoes produce US to attract females. Female mosquitoes have sensory structures to receive US. Spiders, lizards also have ability to sense US.

How does US affect animals?
The US sensors are present in the antennae of Mosquitoes and genetalia of Cockroaches. US emitted by the Repeller will scare away the pests and confuse them. Ultrasonic sound will create stress on the nervous system of insects and jam their own US frequency. This will immobilize the insects and they escape from the source of US.

How does Ultrasound repel Mosquitoes?
Male mosquito is the natural enemy of female mosquito after breeding. Both male and female mosquitoes use plant juice as food. But female mosquito requires human blood protein for the maturation of their eggs. Male mosquitoes will not bite human beings. On the first day of emergence, the female mosquito will not bite but after mating with male it starts to bite human beings to get blood. Female mosquito will not allow males to mate again and they avoid the presence of males. Females detect the presence of males by sensing the US produced by the males. If an US generator is used, it will imitate male mosquito by producing 38 kHz US . This will repel Female mosquitoes. Moreover the US will create stress on the US sensillae present on the antenna of female mosquitoes, so the move away from the source of US .

Does the US pass through walls?
No. Ultrasound will not pass through walls like the ordinary sound waves. When the US hits an object,it bends and round the object and spreads.


Is it safe for human beings?
US Pest Repellers are widely used in Homes, Gardens, Farm yards etc. to repel various kinds of pests. Commercial US Pest Repellers are designed to emit US in the frequency range 20 kHz to 100 kHz. US above 20 kHz is inaudible to man but children can hear the US to a certain level up to 30 kHz. Many house hold appliances like Telephone, Computer, Vacuum cleaner etc emit US, but we cannot hear it because it is inaudible. US is considered as the safest method for scanning pregnancy. US scanning is widely used in hospitals. Echocardiogram also uses US to image the heart’s functions. As per the scientific information, US will not cause any health problems.





Tiny Cylinder in Power Cords & Cable. Why?

Ferrite Bead: Tiny Cylinder in Power 

Cords & Cable. Why?

Have you ever noticed a little cylinder in a power cords and cable? Have you ever seen the same in your laptop charger cord, USB cord, Mobile charger cable cord, Printer Cord, Monitor cord, etc. even in Mouse and keyboard cable cords? Today, we are going to tell you the secret story behind it.

Theoretically, this Tiny Cylinder in Power Cords & Cable is ferrite choke or ferrite bead as shown in the below image.
The ferrite choke is an object in the cylindrical shape, which made up of Ferrite material (which is a magnetic material). A typical Ferrite choke (e.g. Solenoid) consists of an insulated wire around a magnetic material. In our case, cable is insulator and ferrite cylinder is magnetic material to make a special kind of lump for the power cable and cords.



Ferrite Bead (or Ferrite choke) playing a very important rule. As we know that, when current passes through the conductors (inside the power cords), it produces EMF (Electromotive Force) or Radio Energy. The power cords and cable transfer this energy outside in the form of noise, which disturb and interfere with other electronics devices such as nearby radio sound would be noisy with improper tuning of channel. In addition, some electrical energy is wasted in the form of radiation, which also reduces the supply power to the battery or other connected devices, which leads to increase the charging time of battery.


Ferrite Bead has the ability to stop and block the emission of radio waves form the power cords and uses electrical energy for charging purpose only without power losses. Due to this important factor, that’s why are there a tiny cylinder in your laptop or mobile charger cords. Now, I think it is enough because you have clear understanding of the purpose of this magical tiny object (ferrite bead or ferrite choke) in the cylindrical shape in power cords and cables.


CELL PHONE OPERATED ROBOT

CELL PHONE OPERATED ROBOT

This project introduces the use of mobile phone for robotic control.  This technology is more controller friendly as it doesn’t interfere with other controllers and can use up to twelve controls.  It also has the advantages of robust control and provides working range as large as the coverage area of the service provider.


The robot is controlled by making a call on the mobile phone attached with the robot. In the course of the call if any button is pressed a ‘dual-tone multiple-frequency’ (DTMF) tone is heard at the other end of the call. The cell phone mounted on the robot perceives this tone and then the robot processes it by the ATmega16 micro-controller with the help of DTMF decoder MT8870.

Mechanical Assembly:

Mechanical Assembly of Land Rover
As shown in above figure four wheels are attached with chassis made up of any metal (like iron). Shaft of two DC motors (around 150 RPM or more) are directly coupled with real wheels. So as both motors rotate CW, the land rover moves forward. And as both motors rotate CCW, it will move backward. to turn it left right DC motor rotates and to turn it right left DC motor rotates. Also it will take forward-left & forward-right turn as well as backward-left & backward-right turn if required. For that, either of the motors (left or right) is rotated CW or CCW. For example if left motor rotates CW, land rover will take forward-right turn and if it rotates CCW then backward-right turn. Similarly for right DC motor.

System Block Diagram :

Land Rover Block Diagram
 Major building blocks are cell phone, DTMF decoder, micro-controller, DC motor driver circuits:
Cell Phone: - First the system is activated by calling the SIM card number inside the phone. Afterwards it will receive DTMF code signals dialed from another cell phone and give it to DTMF decoder.
DTMF decoder: - The function of this block is self understood. It will take DTMF input given by cell phone decode it and gives 4-bit digital output to micro controller. It also generates an interrupt every time when it gives digital output.
Micro-controller: - You can call this block as the heart of entire system because it actually performs all the controlling actions. Depending upon the code given by DTMF decoder it will move the rover forward, backward, left or right by rotating both DC motors.
DC Motor driver: - It receives actuating signals from micro controller in terms of high / low logic, amplifies (current) it and rotates 2 DC motors in both directions.
DTMF decoder: - DTMF Decoder Circuit
As shown in figure it is made up form readily available MT8870 chip that is widely used for DTMF based application. It receives DTMF tones and generates 4-bit digital output corresponding to received DTMF signal of digits 0 - 9 and other signals (like *, # etc) also. It receives input form cell phone to its pin no 2. It amplifies it through internal op-amp amplifier. If it receives valid DTMF tone, it will produce pulse output on StD (pin no 15). This is indicated by green LED connected as shown. The 4-bit digital output is latched on pins 11 - 14 and that is given to micro controller. The StD output is also given to interrupt pin of micro controller through transistor that will generate negative pulse every time when DTMF signal is received. This negative pulse will generate an interrupt. All the movements of robotic arm are controlled by cell phone digit switches 1 to 8. The 4 bit digital output corresponding to these switches form MT8870 are as given here
Keypad switch on cell phone
   4 bit digital output
D
C
B
A
1
0
0
0
1
2
0
0
1
0
3
0
0
1
1
4
0
1
0
0
5
0
1
0
1
6
0
1
1
0
7
0
1
1
1
8
1
0
0
0


























  • Micro-controller:
 -Land rover circuit

Control of the motion of the robot depends upon the code it receives from DTMF decoder as given in table:

      4 bit digital input
Hex code
Movement – controlling action
D
C
B
A
0
0
1
0
F2h
starts moving forward
0
1
0
0
F4h
Take a left turn
0
1
0
1
F5h
Stop moving
0
1
1
0
F6h
Take a right turn
1
0
0
0
F8h
Start moving backward

  • DC Motor driver: -
DC Motor Driver
As shown in figure L293D is quadruple H-Bridge driver chip that is widely used for DC motor and stepper motor driver applications. It receives inputs from micro controller as shown on its input pins 2,7,10 & 15 and rotates two DC motors in either direction
So to move the land rover forward or backward - left or right one has to send following data on port:
Motion
W (P2.0)
X (P2.1)
Y (P2.2)
Z (P2.3)
data
Move forward – rotate both motors  CW
1
0
1
0
05h
Move backward – rotate both motors CCW
0
1
0
1
0Ah
Turn left – rotate right motor CW
0
0
1
0
04h
Turn right – rotate left motor CW
1
0
0
0
01h
  • Source Code :
If you are using AVR then the following source code would work:

#include
void main(void)
{
unsigned int k, h;
DDRA=0x00;
DDRD=0XFF;
while (1)
{
k =~PINA;
h=k & 0x0F;
switch (h)
{
case 0x02: //if I/P is 0x02
{
PORTD=0x89;//O/P 0x89 ie Forward
break;
}
case 0x08: //if I/P is 0x08
{
PORTD=0x86; //O/P 0x86 ie Backward
break;
}
case 0x04:
{
PORTD=0x85; // Left turn
break;
}
case 0x06:
{
PORTD=0x8A; // Right turn
break;
}
case 0x05:
{
PORTD=0x00; // Stop
break;
}
}
}
}
Upload the program and enjoy moving the robot using any cell phone.
Hope you liked and stay connected for more interesting projects like this.
Thank You