Saturday, April 28, 2012

Electronics Project: Basics for doing it yourself - 1

In this post I will discuss about some essential things you need in order to do electronics project. Electronics has always been my hobby and I spent most of my college time doing electronics projects. At the beginning of my college I learnt how to use bread-boards and knew about resistor, capacitors, diodes and transistors. When I learnt digital electronics and micro-controllers I was fascinated by them and kept on playing with them. I was regular subscriber of EFY magazine and I used to try DIY circuits in my home. Now, the time has come; I have to share my experience with you.

An electronic circuit is composed of individual electronic components, such as resistors, transistors, capacitors, inductors and diodes, connected by conductive wires through which electric current can flow. The different combination of these components when done properly is used to perform different operations such as signal amplification, computation of data, and so many things. The motherboard of your computer itself is an example of a complex electronic circuit which consists of different ICs. Whereas, inside your battery charger you can find a simple electronic circuit. So, the complexity is based on the application of the circuit. To be able to make an electronic circuit you must first know behaviour of each components when current flows through them. The components such as resistor, capacitor and inductors are passive components; meaning that the current flowing through them is directly governed by voltage applied to them. The other components such as diodes and transistors are active components. I would like to briefly introduce you about these components. You can go through your course book or find more information in the Internet about these component so, I will be more focused on their application in electronics projects.


Resistors offers a resistance to the flow of current. It is characterized by  resistance values measured in ohms and their power ratings measured in Watts.   Resistance is the ratio of potential difference (V) between the two terminals and the current (I) flowing through it i.e. Resistance (R)= V/I ohms. Resistances range from 10 ohm to 56Mohm(or more) and power ratings from 1/8W to 20W. We mostly use resistance in this range even though more power rating high value resistors are available. So, when you select a resistor its value and power rating should be the deciding parameter. Normally available resistors are 1/8W, you can see this type of resistors in the resistance box which contain resistances from 10 ohm to around 56Mohm, costs around Rs.30. But this resistor leads are flexible such that it will get bend easily. These 1/8W resistors are used in low power devices. The one which available in shops are of 1/4W which we mainly use. P= (I^2) * R, heat dissipation on resistor depends on the current flowing through it. Therefore for high current operations we use resistance of higher current ratings. The size of the resistor determines its power rating. Suppose if you put a resistor series with a motor which have a rating of 250mA(DC motor) -600mA(Stepper motor), then you can see that P= (I^2)*R = 0.25^2*R= 0.0625R. Assume R=10 ohm then P= 0.625W>1/2W. In this case you have to use a resistor of about 1W or more.There are two types of resistors - fixed and variable.

Now let's see how you can measure the resistance of a resistor. This is done by color coding over the resistor or you can use multimeter to measure resistance. As a beginner you should use color coding. See the following diagrams carefully, you can see that 4-band code, 5--band code and 6--band code (see next diagram). But we mainly get resistors of 4-band code.You can get a 1/4W resistor for Ps.20 irrespective of the value of its resistance. Due to the aging and other temperature effects, value of a resistor will change. That change is indicated using tolerance. The following figure show how to bend a resistor so that you can insert it in a breadboard. Don't bend too much close to the body of the resistor because it will leads to the breaking of the leads. So bend carefully. Sometimes you have to cut the leads of the resistor by some amount so that it can easily inserted properly.

Remember that all the values of fixed resistances are not available. Suppose if you want a 2Kohm resistor in your circuit, you can use a variable resistor (potentiometer) or two 1Kohm resistor in series. 

If you are interested in programming then I can send you the link to download a program with source code that calculates resistance of a resistor according to its colour code or by a value. This program was written using C#.NET with Framework  version of 3.5 so, you need .NET Framework 3.5 installed in your OS to run this program. If you are using Windows Vista or later you can enjoy using it as .NET Framework is pre-installed. Screenshot of this program is shown here. You have to be follower of this blog if want to get download link. I hope you will  do this by clicking follow at right sidebar of this blog.

Variable Resistor (Potentiometer):
Potentiometer is a variable resistor which is used to vary the resistance by rotating the shaft. Potentiometers are available from 100 ohm to 470Kohm (or more). Cost depends on the size of potentiometer, vary from Rs. 4 onwards. It is sometimes used as a voltage divider. If we connect  Lead A to Vcc and Lead B to ground then you can get voltages from 0 to Vcc by taking voltage at Lead A and Lead B.

Above figure shows different types of potentiometers available in market. Second and third potentiometers are mainly used when you want to change the value of resistance rarely and first one used when you had to vary resistance frequently. Second and third one are easy to be inserted in breadboard and they remain fixed. Resistance is varied by rotating the shaft in the body of the potentiometer.

A capacitor is a passive component that is used to store energy in an electric field. It is characterized its capacitance, measured in Farads (F). This is the ratio of electric charge (E), measured in Coulombs (C) on each conductor to the potential difference (V) between them i.e. Capacitance (C)= E/V Farad. Like resistor there is fixed as well as variable capacitor also. But, we mostly use fixed capacitor and variable capacitor is used in application such as radio frequency tuning. The capacitor may or may not have polarity. Ceramic and Mica capacitors available in the market have no polarity, but electrolytic capacitors have polarity. The capacitors have different symbols.
In the above figure, we can see that different symbols are used for capacitors. The non-polar capacitor can be placed in a circuit in either way but, when polarized (electrolytic) capacitor is to be placed we have to be careful in placing them in the circuit. We can differentiate negative and positive leads of electrolytic capacitor by their length however, it is best to differentiate them by looking at capacitor itself. The negative lead is indicated by black band imprinted in the body of capacitor, which contains - sign as you can see in the above figure. Also, the electrolytic capacitors have voltage ratings; which indicates the maximum potential difference the capacitor can tolerate between its terminals. It is a very important factor in choosing the capacitor for you circuit. If your circuit is operating in say 25V and you are placing 16V capacitor then you may damage the capacitor. So, you have to be very careful when choosing the capacitor in your circuit.

Ceramic capacitors in general have the rated values in pico-Farad (pF) and electrolytic capacitors have the values in micro-Farad (uF). Ceramic capacitors have many marking specification. Capacitance, tolerance, working voltage and temperature coefficient may be seen imprinted on the capacitor with black colour text. Capacitance values are found to be written as whole numbers without any identification as to units (uF, nF, pF). Whole numbers usually indicate pF and decimal numbers such as 0.1 or 0.47 are micro-farads. Larger whole numbers (>100) such as 473 means 47*10^3 pF = 0.047 uF.

Here, the capacitor rated as 22 has a capacitance of 22pF. The capacitance of capacitor rated 104 can be found as; the first two digit are significant digits and last digit indicate number of zeros after the significant digits. So, 104 means capacitance(C)= 10*10^4 pF= 100000 pF= 100nF= 0.1uF. Similarly, 103 means C= 10*10^3 pF= 10nF= 0.01uF. You may also find values such as 104K, 103M, 102J etc. where the last alphabet denotes tolerance of the capacitor i.e. how much the capacitance is varied from rated value. K indicates 10%, M indicates 20% and J indicates 5%.

Capacitors are widely used in electronic circuits for blocking direct current while allowing alternating current to pass, in filter networks, for smoothing the output of power supplies, in the resonant circuits that tune radios to particular frequencies and for many other purpose.

A diode is a two terminal semi-conductor device used for conducting current flowing through it only in one direction called forward direction. It has asymmetrical transfer characteristic, with low resistance to current flow in one direction, and high resistance in the other. A semiconductor diode is a crystalline piece of semiconductor material with P-N junction connected to the terminals. The unidirectional behaviour of diode is used to convert alternating current (AC) to direct current (DC), including extraction of  modulation from radio signals in radio receivers. There are different types of diode which has specific purpose such as; Zener diode is used for voltage regulation, Avalanche diode are used to protect the circuit from high voltage surges, Varactor diode is used to electronically tune radio and TV receivers, Tunnel diode is used to generate radio frequency oscillations and Light Emitting Diode (LED) is used to produce light. You can find more information about these diodes in the Internet so, we will only  focus on generic semiconductor diode and LED which are the most used diodes.

You can see a white ring close to one of the terminal which indicates N terminal of the diode and the other  is P terminal. You can see white text in black background in the form of 1Nxxxx, this represents model number of the diode that has charactersitics defined in its datasheet. You can Google the part number and find out its power rating, threshold voltage, and other required parameters. To determine whether a diode is working or not we need a multimeter with diode checking function. Then, we determine its forward voltage by connecting positive terminal and  negative terminal  of multimeter to the P-terminal and N-terminal (Forward Bias) of the diode  respectively. For 1N4001, it is about 1.2V and for 1N4007 it is about 1.4V. You can go through datasheet of the diode and find out their forward threshold parameter to check any diode. In the figure alongside, you can also see LED and from there you can determine P terminal and N terminal of a LED. The length of terminals as well as the shape of bottom view is used to determine them. The method to check a LED is similar to diode; we have to forward bias it and check to see whether it glows or not. Also, you have to note the voltage reading shown in multimeter because it is used to determine a series resistor connected to it's one of the terminals. Generally, you need to connect a series resistor to prevent excessive current flow in the LED otherwise, that current could damage the LED. The resistance is usually between 200 ohm to 2.2Kohm according to current being applied in the circuit.

Now, you can connect the circuit as shown below and use it as AC line indicator. Plug the P-terminal of diode to one of the terminal of AC line and plug one of the terminal of resistor in other terminal of AC line. This works because the diode rectifies positive half cycles of AC to DC and 100K ohm resistor is used here as series resistance to drop excessive voltage and block excessive current flow to LED. When positive half cycles reach P-terminal of LED the negative half cycles appear at N-terminal and the LED is forward biased and turns on and, when negative half cycles of AC appear at P-terminal of diode, it gets blocked (reverse biased) allowing no current to pass through it and the LED turns off. So, there is turning on and off of LED at every 0.02 second however, we cannot notice it. Thus, this circuit can be used as AC line indicator.

I hope this post has helped you understand as well as review some of the important terms you encounter while doing projects. If you like this post or you have comments please do not forget to write it. I like to hear from you.

Thank you.

1 comment:

  1. Hi, great article. May I ask why you have included a Diode in the above circuit/picture? What is its purpose?