About Me

Pilani, Rajasthan, India
I am an engineering student currently pursuing an undergraduate degree in Electronics & Instrumentation from BITS Pilani, Pilani campus. My hobbies are reading novels- fiction and non-fiction alike, playing and watching football, dabbling with new software and going through blogs. I love reading Electronics For You. It has helped me a lot in my college life. And sometimes, people around me.

Hope you find this blog useful. Thank you.
Showing posts with label robotics. Show all posts
Showing posts with label robotics. Show all posts

Sunday, July 17, 2011

About Robotics and Techfests

Hello everyone. In this post, I will be sharing basic generalized information for robotics events in major technical festivals and also a list of some of the major technical festivals (more popularly, “techfest”) in Indian engineering colleges.

Technical festival – briefest info 

One of the parameters on which an engineering college is judged by people is the quality of its technical festival. You will notice that the technical festivals of the top engineering colleges in India are very reputed. The IITian techfests are all very well known and well-attended by colleges from all over India. The major features of a good techfest are the quality of their workshops, guest lectures and the diversity in events. Events range from technical to non-technical and further, the events may be multi-disciplinary which cranks up the participation.

Robotics in techfests

All the major techfests feature robotics events which generally have a pre-declared problem statement. The teams or individuals are supposed to register for the event online. Some techfests also require the teams to submit a Team Description Paper (TDP) or some other similar document, at least a month before the event. In the TDP, apart from the team description, the teams also have to let the organisers know as to how they are going to tackle the problem statement, a photograph/video of the robot progress, the brief list of inventory used etc. The TDP deadline also acts as a wake-up call to the teams that had conveniently registered in full enthusiasm and forgotten all about it on-campus (Talking from experience :P).

General problem statements

Generally the problem statements require the team to make a manual robot or/and an autonomous robot

The manual robot problem statements generally revolve around picking up objects and storing it on the bot itself. Generally, there are restrictions in terms of the bot dimensions apart from others. Other types of manual robot statements are also possible – like building a ‘climbing robot’ that climbs up a flight of stairs or a vertical stack of rods. It depends from event to event and techfest to techfest.

As far as the autonomous robots statements are concerned, generally the teams are supposed to build an obstacle-avoiding robot or a line-follower robot. An obstacle-avoider is supposed to go from one point on the arena to another without colliding with any obstacle placed purposefully by the organisers. The line-follower robots are supposed to do the same but instead of obstacle-avoidance, the constraint here is that the robot has to move on a given circuit without stepping outside the track. These are the general cases. The other variety of autonomous robot very commonly a part of robotics events is the ‘IP-based robots’. IP is Image Processing. The task generally involves either number-recognition, character-recongnition or simply color recognition. And once this is done, the robot moves according to the required movements. Here too, there are restrictions based on dimensions generally.

The events that involve both manual and autonomous robot generally involve the transfer of contents lifted/collected by the manual robot to the autonomous robot following which the autonomous bot has to start moving. Such events are considered quite tough and also carry a large prize money.

One important restriction – many techfests require you to solder the circuits yourself or if you are getting the circuits printed, you are required to provide the Gerber files (they are like the blueprint of your PCB) of that circuit to the concerned organisers.

Links to technical festivals

Given below are major technical festivals, their organizing colleges and links to their websites.

Note:
      a)      The order of the under-mentioned fests is random and does not indicate ranking or anything else.
      b)      The source of the following information is Shubham Sharmathis is his e-pensieve J - I have just formatted the data and presented.

Sr. No. - Name – College - Link
1) Techfest - IIT Bombay – www.techfest.org
2) Tryst – IIT Delhi – www.tryst2011.com
3) Techniche – IIT Guwahati – www.techniche.org    
4) Techkriti – IIT Kanpur – www.techkriti.org
5) Kshitij – IIT Kharagpur – www.ktj.in
6) Shaastra – IIT Madras – www.shaastra.org
7) Technozion – NIT Warangal – www.technozion.org
8) Mindbend – NIT Surat – www.mindbend.in
9) Tathva – NIT Calicut – www.tathva.org  
10) Pragyan – NIT Trichy – www.pragyan.org
11) Engineer – NIT Surathkal – www.engineer.org.in
12) Renaissance – DCE, Delhi – www.rentech.in
13) Kurukshetra – COE Guindy, Anna University – www.kurukshetra.org.in
14) Felicity - IIIT Hyderabad – www.felicity.iiit.ac.in
15) Neuron – MNIT, Jaipur - www.neuronmnit.in
16) APOGEE - BITS Pilani, Pilani campus - www.bits-apogee.org
17) Quark - BITS Pilani, Goa campus - www.bits-quark.org 

Mind you all, the list is not comprehensive or restrictive or suggestive. It is only indicative. :P 

So what are you waiting for? Search for the event of your choice and start preparing!

Saturday, July 16, 2011

A very simple ATmega32 project

Hello everyone. In the last post, Atmega32 explained his I/O operations and how to address its ports and pins. In this post, I will be discussing the interfacing of a simple IR sensor (digital output) and a DC motor to Atmega32. But before that I want to tell you that before trying to implement this one, make sure you have blinked a few LEDs and LED patterns so that you are quite familiar with mu-c coding in C. So, the problem statement at hand is:

Design a microcontroller based circuit that enables a DC motor to rotate for 5 seconds whenever an obstacle is detected by an IR sensor. Also, during the motion of the DC motor, an LED should glow and switch off as soon as the DC motor shaft stops rotation.

Simple enough? Let us start with the basics.

Requirements:

      1)      An IR sensor – already discussed in an earlier post  
      2)      A DC motor driver circuit – already discussed in an earlier post
      3)      An LED and a resistor
      4)      A microcontroller – let us assume we are using Atmega32

Flow chart:


Circuit schematic:

The circuit schematic has been drawn using EAGLE.


Choice of I/O pins:

We have chosen:
      1) PB0 as the sensor input pins
      2)      PB1 and PB2 as the input pins to the motor driver circuit
      3)      PB3 as the LED driving pin

Alternate problem statements:

Done with this much?
Now try to tweak the problem statement by changing: 
      1)      The duration of the motor rotation
      2)      The direction of motor rotation
      3)      The on-off behaviour of the LED (switching off when obstacle detected and vice versa)
      4)      The range of your IR sensor by changing the potentiometer resistance
      5)      The I/O pins involved

Note:

      1)      The number of pins required for this circuit is only 4 whereas the available number of I/O pins is 32. You can go for a smaller controller like any one of the AVR Attiny series. The code won’t change. But the project settings in your development IDE will.
      2)      This circuit or a modified form is a basic component of almost any autonomous robot. Eg: Obstacle avoider, line-follower, micromouse etc.
3)      The IR sensor output is a function of the colour of the obstacle. Try it out yourself J
Later posts will also cover some more helpful microcontroller projects. Cheers!

Sunday, June 26, 2011

Atmega32 from AVR - a beginner's guide to microcontrollers

Hello everyone. My name is Atmega32. I belong to the AVR family of Atmel’s microcontrollers. We are a very well-cultured and user-friendly family. I am the most commonly used controller for beginner robots along with Microchip’s PIC microcontrollers (though I don’t like it...it is cheap!). The reason why people so commonly use me is that a variety of development tools are available for working with me and for exploiting my features to the best. Over the years, my manufacturers have been increasing my flash memory, so that you can stuff me with bulkier and bulkier codes and hence, I can do more for you. Please learn to use me well. Some time ago, beginners tried to use me without properly reading the datasheets and learning to use the programmer. I was so angry that I just blew up in their face and got all heated up! I deserve respect and care because I am a good servant.

Applications:
So let me tell you more about how you can use me. You build a wonderfully working obstacle sensor and an oh-so-precise motor driver circuit. But what will you do, if you want your motor to rotate for precisely five seconds once an obstacle is detected. The brightest person will use a number of logic gates and a clock. His best friend will use an analogue clock and design the hardware such that as soon as five seconds pass, a switching action takes place and the complex circuitry gets an input. The dumbest person will try to cheat by keeping a button pressed on his remote for five seconds. The average person...well...he is reading this post, so you know what he will do.
Almost each embedded application – be it your cell phone, be it your printer, be it the latest iPod Touch, be it the Salmoiraghi – has some or the other controller. Robotics is just another drop in the ocean. 

Prerequisites:
1) Very basic knowledge of C/C++/Java/any programming high level language.
2) Knowledge of concepts like binary numbers, hexadecimal numbers, inter-conversion of number types, Boolean algebra.
3) Desire to practically try out what is written.

Basics:
If you are a beginner and going through my datasheet for the first time, you won’t understand much and it is OK. Just have a look at my pinout diagram. You will see that most of the pins are named like this: PXY where X=A,B,C,D and Y=0 to 7. These are known as the I/O pins of the microcontroller. The other pins Vcc, GND, Reset, XTAL1, XTAL2, AVcc, AREF. You don’t need to care about the last four as of now. As for Vcc, that’s my mouth. If you want me to survive, you have to feed me. Just feed me a 5 Volt supply and a bit of current and I will be your genie! The GND pin SHOULD be connected to the circuit ground for best results.
I will now tell you about my various parts..err..ports.As for the PXY pins – I have 4 ‘ports’ – A,B,C and D (These will replace X). Each port has 8 pins – 0 to 7 (These will replace Y).

But what does I/O mean? I belong to the digital civilization and I follow TTL logic. In simple terms, I can’t differentiate between 0.2 Volts and 0.9 Volts because both are same for me – LOW. Similarly, I can’t differentiate between 3.6 Volts and 4.9 Volts because both are same for me – HIGH.
Practically,
0 to 1.4 Volts – LOW
3.4 to 5 Volts – HIGH
My inputs and outputs are always either HIGH or LOW. If any input or output is outside these ranges, well, don’t trust me. It is not my specialty!

Basic I/O configuration:
As I mentioned, 4 ports * 8 pins each = 32 I/O pins. But how do you tell me which pin you want to use? You do it using three ‘registers’. A ‘register’, in very simple terms, is nothing but a ‘group’ of 8 bits serving a similar purpose, generally. And this ‘group’ is given a name so that you can use it in your program to convey your desire to me.
The I/O registers commonly used are:

DDRX – DDR stands for Data Direction Register. This allows you to configure your pin as Input or Output. Now let me show you how to configure. Writing the following instruction (given inside single quotes):
‘DDRA = 0b11001001;’ – binary representation of port or ‘DDRA = 0xC9;’ – hexadecimal representation of Port. (Note: The pin order is 0b76543210)
Means that you want to set the pins 7,6,3 and 0 of Port A i.e Pins PA7, PA6, PA3 and PA0 as Output pins and the other pins of Port A as Input. By default all my 32 I/O pins are configured as Input i.e DDRX = 0b00000000.

PORTX – When you want to write either HIGH or LOW to a pin, you have to use my PORTX register. There are two cases:

      1)      Pin configured as Output
Let us continue with the above configuration i.e. DDRA = 0b11001001. If you now write the instruction,
‘PORTA = 0b01000001;’
Focus only on Pins 7,6,3 and 0 which are configured as OUTPUT. A ‘0’ has been written to Pin 7 and 3 and a ‘1’ has been written to Pin 6 and 0. This means that if you connect your multimeter probes between Pin 7 and GND, the voltage will read ~0 Volts i.e. Pin 7 has been set to LOW. Same is the case with Pin 3. On the other hand, connection of probes between Pin 6 and GND results in a reading of ~5 Volts i.e. Pin 6 has been set to HIGH. Same is the case with Pin 0.

Basically, writing 1 to an OUTPUT pin sets it HIGH and writing 0 to an OUTPUT pin sets it LOW.
      
      2)      Pin configured as Input
Again, we will continue with the same pin configuration i.e. DDRA = 0b11001001. If you now write the instruction,
‘PORTA = 0b00100010;’
Focus only on pins 5,4,2,1 which are configured as INPUT. A ‘0’ has been written to Pin 4 and 2 and a ‘1’ has been written to Pin 5 and 3. There is something called a pull-up resistor. The function of this is to simply pull the potential of the pin to HIGH. And writing a ‘1’ to the input-configured pin enables this resistor. Writing a ‘0’ to an input-configured pin does not do so and hence the pin is said to be ‘floating’. This is an undesirable condition as it can pick up stray potentials from the surroundings or the breadboard and can lead to erroneous results which are hard to debug if you don’t know about this concept (Trust me!). So the good habit is to always pull HIGH an input-configured pin by writing ‘1’ to it. Or alternatively, ground the input-configured pin, when not in use.

PINX – This is the register that stores the current status of each and every pin. So, if you want to read a particular pin, say 4th pin of Port B, all you have to do is: 
      1) Write the following instruction: ‘char c = PINB;’ – This will transfer the contents of the 8 bit register PINB into the 8 bit character instance ‘c’.
      2) Since you want only the status of the 4th pin, perform a logical AND of ‘c’ with 0b00010000. What this will do is, it will clear all the bits except the 4th. If the 4th pin is HIGH, ANDing it with the above will give the result 0b00010000 (let us call it ‘g’) and 0b00000000 (let us call it ‘h’), if not. 
      3) Check the value of the ANDed result – if value is ‘g’, then the 4th pin was HIGH, if the value is ‘h’, the 4th pin was LOW.

NOTE: Some IDEs like Code Vision AVR also allow direct access of pins by commands like DDRB.1, PORTC.4, PINA.4 etc. which simplify my user’s life!

Coding:
Besides the knowledge of these registers for I/O, you also need to include some header files (if you are working in, say, AVR Studio). Code Vision AVR has a code wizard that performs all these formalities for you so that you can directly write your code!
Given below is a sample code for AVR Studio that shows you what all header files you should include and other things you need to initialize. Also the code includes the usage of a delay function (parameter in milliseconds) that introduces a delay in your program giving you time to observe your results. The result of burning this code into me will result in my pin PB0 going high and low alternatively at a 1 second interval.

#define F_CPU 1000000UL           // CPU counts from o to 999999 in 1 second!
#include <avr/io.h>
#include <util/delay.h>

int main()
{
DDRB = 0b00000001;
while(1)
    {
        PORTB = 0b00000000;
        _delay_ms(1000);          // the parameter is 1000 ms = 1 second
        PORTB = 0b00000001;
        _delay_ms(1000);
    }
}

Important links and references:
1) http://www.atmel.com/dyn/resources/prod_documents/doc2503.pdf - detailed datasheet with sample codes for each and every feature
2) http://iamsuhasm.wordpress.com/tutsproj/avr-gcc-tutorial/ - a very good I/O tutorial with graphics, but please note, there are mistakes in this tutorial
4) http://www.avrfreaks.net/ - THE BEST site to learn more about AVR microcontrollers and their features and tutorials and discussions and lots more!


Thank you for reading my post. I wish you luck and hope you are able to use me well for your robot!

Tuesday, June 14, 2011

Dukaan-e-datasheets


Hi all. I am back with a new post after an extremely refreshing trip and in this post I will be covering some very commonly used ICs and components in beginner and techfest level robotics. This is NOT an exhaustive list. It is just an indicative compilation. Also, along with the brief function and purpose of each IC, I have also provided the links to various datasheets. I hope you will benefit from this.

Common application: If you plan to use the AC power available through the commonly seen 3-point connections to power your robot/application, you will need a step-down transformer. These transformers are easily available at any electrical shop. After stepping down the 220 Volts to say, 25 Volts by using a suitable transformer, you need to rectify the AC voltage to get DC voltage. Diodes are used for this purpose. This schematic shows how it is done.
The question that immediately comes to mind is, why do I need a transformer? Why not directly use the diodes for rectification? The answer lies in the datasheet, which states that the peak reverse voltage across the diode should not exceed 100 Volts. Practically, it should not exceed 60-70 Volts. Now again you will ask, why not use a diode of a higher rating? Well, they are costly and bulky. So, peace out.
   
Common application: Suppose you have managed to somehow get a DC power source- either using the transformer-rectifier circuit or some other source- but you can’t use this source directly because your components requirements, what do you do? Use a voltage regulator. The 78XX series is the most popular series of voltage regulators. These are 3-pin ICs having Input, Common and Output pins. The standard values to which you can bring down the DC voltages is 5,6,8,9,10,12,15 and 24 Volts. The maximum input values for all but 24 Volts regulation is 35 Volts whereas for 24 Volts regulation the maximum input is 40 Volts. Practically, the values should not exceed 30 Volts. Also, note that to achieve regulation, the minimum input should be at least 2 Volts higher than the regulated value. Therefore, to achieve 5 Volts regulation using IC 7805, the input should be at least 7 Volts.

Common application: So you have a problem statement at hand that requires you to measure the temperature and make the robot act accordingly. Here is your solution: AD590 is a temperature transducer IC whose output is a current proportional to the temperature. The output relation is linear with a change of 1uA/K. This output is converted into a voltage by connecting a resistor in series and measuring the potential drop across the resistor. The typical range of input voltage is 5-25 Volts (Maximum: 30 Volts).

Common Application: Don’t have an AD590? Go for this IC then! LM 35 has a linear increase factor of 10 mV/deg C. What’s more? LM35 is cheaper than AD590. But for applications that involve sending temperature measurement data across longer distances, AD590 is better as in LM35, the circuit will suffer from potential drop across the connecting wires.

Common Application: Need to acquire a signal in which noise is the more dominant signal (body signals or voice recognition in a crowded surrounding, for instance)? AD620 is an instrumentation amplifier IC and is a very popular choice among robotics enthusiasts. Very high gain is possible without significant loss in linearity. Supply voltage range is 5 Volts to 18 Volts.

Common application: Enjoy the tilt-based games in your smartphone? Awed by the sheer intelligence of a self balancing vehicle? Here lies the trick! Accelerometer ICs like ADXL330 measure the tilt of the IC in all three axes and provide an analog output proportional to the amount of tilt. Interfacing a sensor to a controller is a tough task and accelerometers are among the toughest to work with. But is sure is fun when you see your interface working successfully J

Common application: This is also an accelerometer IC that provides a digital output corresponding to the tilt. This digital IC is interfaced to the controller using I2C protocol (huh?). More on this later.


Common application: I have already discussed this motor driver IC in a previous post. Check it out.

Common application: Light dependent resistors are a very important class of photodetectors. The resistance of LDRs increases as the luminous intensity decreases and vice versa. One of the disadvantages associated with LDRs is the low speed of response called memory effect. But, a beginner should definitely take its interfacing up as a project.

Common application: LEDs have been used as indicators for a long time now and will be continued to do so for ages. Generally the potential drop across an LED is 1.7-1.8 Volts. The ideal connection involves a resistor in series with the LED so as to limit the current to a value around 10-15 mA. The maximum tolerable current is 30 mA but operation at this current for long reduces the life span of the LED. As we say, LED ‘phook jaayegi’. Going through the datasheet of an LED is suggested.

Common application: Making a line follower or a micromouse? Or working on a project that involves control based on digital input from various sensors? This is the IC to go for. LM324 has 4 comparators that can help you achieve discretization of your analog output. Or simply, switch between ON and OFF states based on value of input.  

Common application: Yes, this is the universal IC. Yes, this IC needs no introduction. Yes, this IC can’t take less than 12 Volts bi-polar supply. Yes, the source and sinking current is restricted to a maximum of 40 mA. Its applications are unlimited. It can be used in designing controllers, filters, comparators etc.

Hope this will help you find your datasheets whenever you need one :) 

Tuesday, May 24, 2011

Driving Circuits for DC motors

For a first timer, the rotation of a motor’s shaft, at just a push of a button, is pure thrill! Especially,if he has designed the circuit himself. This post is dedicated to DC motors, their driving circuits and ends with a sample DIY (do it yourself) breadboard circuit.

DC motor

The typical DC motor used in robotics is a 2 wired object having a shaft at its end.  

Typical ratings of DC motors commonly used are given in terms of ‘maximum supply voltage’ for stable operation and no-load speed expressed in ‘rpm’ (revolutions per minute). These motors are generally internally geared to provide increased torque to carry the weight of the robot and the circuitry and the ‘payload’ if any. Another important property of DC motors is that they are current-intensive components. Hence, ‘turning a motor on’ draws a large amount of current  suddenly from the power source.

For more theory on DC motors and their functioning, this is a very good starting point. 

Reversing the polarity of input voltage reverses the direction of rotation of the shaft (WOAH!! REALLY ?!). Also, it is a good practice to be aware of the absolute maximum ratings of your DC motor before using it as they vary from motor to motor.

DC motor driving circuits

1) H bridge circuits: Directional control is achieved by a hardwired circuit with the help of switches. This type of circuit is an example of pure hardware based control. The following diagram illustrates the directional control of a single DC motor using such a circuit.


Disadvantage of such a circuit is that wiring becomes highly complicated by the addition of a single motor to an existing circuit. Also, the switches undergo a lot of wear and tear as the switching action brings about a large change in potential (~12 V) and current (~400-500 mA - varies from motor to motor).

2) IC based circuits : The IC very commonly used for motor control is L293D. All ICs are accompanied by a ‘datasheet’ which all the details that you need to know before using that IC. You can download the datasheet of the L293D IC manufactured by ST Microelectronics here. The most important parts of this datasheet for us would be the pinout diagram (Page 2), the absolute maximum (Page 2) and the typical characteristics (Page 3). Following is the pinout diagram (from the datasheet) of L293D.


The functions of the various pins in simple terms are:

EnableX (X = 1,2) enables that side of the IC. Driving the EnableX pin high (~5 V generally) allows us to use the corresponding side (left or right) of the IC.

InputX (X = 1,2,3,4) is the control input for the IC. Driving InputX high drives the OutputX pins to Vs volts and driving it low (~0 V) makes the OutputX pin go low.

Vs is the voltage you want to apply to the DC motor connected across the output pins.

GND is the common or the reference potential of the circuit.

Vss is the control input for the IC that determines the minimum voltage that can be applied across the motor i.e. the minimum value of Vs.

We can achieve bi-directional control of two motors safely using this IC. For unidirectional control (not generally the case), we can use a single IC for 4 motors, but this is generally not done as a lot of current flows through the IC as all motors run simultaneously (the worst case), which might smoke it up – smoking is injurious for humans and ICs both!


DIY Breadboard schematic

Following bread-board schematic made using Fritzing Alpha illustrates the typical connection. Open the image in a new tab/window and have a close look at the connections.


Please note, in the above circuit, I have used a 5 V regulator IC (7805 or TO-220) to obtain 5V from 9V. All you need to know right now is that, with the named part of the IC facing you, the left most pin is the Input pin (Pin 1), the centre pin is the Common or the Ground (Pin 2) and the last pin is the Output 5 V pin (Pin 3). For proper functioning of this IC, the input voltage should be at least 2 V greater than the regulated voltage (5 V in this case). This diagram should make the connections clearer.
Also, the connections to the input have not been shown. They have to be done using switches between 5 V and GND potentials. Try it out yourself!


Cost breakup


DC Motor – Rs. 150-200
L293D IC – Rs. 60-80 

Hope this post was useful. Trust me, you will find yourself using the same circuit in almost all your motor-driving endeavours.
See ya!






Saturday, May 21, 2011

A Basic Proximity Sensor

Robotics involves working on sensors at some point of time or other. Also, at college level, students generally make robots that involve some sort of obstacle avoidance or seeking or sometimes both. In any case, detecting an obstacle is the first step. If you are concerned only with the presence (or absence) of some solid material in front of your robot, it makes absolutely no sense to use a camera as it would be a total waste of resources, a needless addition to your costs and most importantly it will also affect the response time of your robot.

What you really need is a 'proximity sensor'. As the name suggests, proximity sensors sense the proximity of an obstacle. (Du-uh ?!)

The most common proximity sensors used are IR LED-Photodiode based. In alternative implementations, Photodiodes can be replaced by Phototransistors, IR LED can be replaced by a LASER source. But, in all these implementations, the principle is the same:

There is a transmitter and a receiver( also called photodetector). The transmitter transmits EM rays all the time...if the receiver receives any of these rays, it can mean two things - either you have an obstacle in front of you reflecting these rays or you have another source of the same type of rays. Thus, this technique may not be the best obstacle-detecting technique around...but yeah..we still use it.

The following schematic made in TinyCAD illustrates the connections for a proximity sensor using IR LED and a Photodiode. Please note, this is a very basic circuit. Generally, the output voltage is first converted to a digital signal for use ( more on this later :) )

Basic Functioning of the Circuit

The IR LED is connected in series with a 330 ohm resistor to provide the correct voltage drop across the LED.
The Photodiode that is used must be sensitive to only that range of frequencies that the IR LED emits, else the purpose is lost - it is like a Chinese man receiving a message in Tamil. A Photodiode is used because it has the property that when reverse biased, the current it allows to pass across itself is a function of the intensity of optical illumination. Hence, it is very important to have the Photodiode reverse-biased i.e. the longer leg should have a lower potential than the shorter leg. Only then, your circuit shall work as desired.
As the robot goes nearer to the obstacle, more the number of reflected rays, more the optical illumination, more the current across the Photodiode and the resistor, more the output voltage..SIMPLE EH ?

Approximate cost break up

IR LED - Rs. 5-7
Photodiode - Rs. 5-10
Resistors - nominal


Alternative implementations

1) In the above circuit you can replace the IR LED by a laser source, so you will have to change your receiver accordingly, since the frequency of the rays has changed.
2) Also, if you want to increase the sensitivity of your sensor, you can replace the Photodiode by a Phototransistor as it provides a reasonable change in current even for a very small change in illumination at the cost of a teeny-weeny change in the circuit.
3) Yet another implementation which is much less complex is that using a Photoresistor or Light Dependent Resistor (LDR). But this type of proximity sensor is not generally used because it provides an appreciable output only after going very close to the obstacle, which is undesirable. Also, owing to memory effect, the response of LDR to changing illumination is very very slow compared to IR LED-Photodiode pair.

Hope this post was useful.
See ya.

Thursday, May 19, 2011

Robotics - A beginner's kit

ROBOTS!!! 2 hands…2 legs… Camera vision…making that weird whirring recoiling sound with every footstep…that is how most of us think of robots…not that ‘they’ are not robots…they are just a class of robots.. rather attractive class called Humanoids. Not to get very technical, a robot is simply a human creation…made with the aim to satisfy his or her( ;) ) master’s needs by performing certain tasks, not necessarily mechanical. Any artificial thing that is capable of reproducing an acceptable performance irrespective of changing conditions can be loosely termed a robot. Anyway, enough of the definition.

College time is the best time to take up robotics as many of us already know or will know. Let us admit it - Robotics attracts a lot of attention mostly because it sounds cool. But with time you realise that this is one of those things in which you get to do and learn a lot of ‘cool’ stuff that you actually come across in real life…for instance, the mobile phone you use. Robotics is very much prevalent in colleges primarily because the components involved don’t cost you a fortune and secondly, because beginner-level robotics is not rocket science. Also, a lot of colleges organise technical festivals that have robotics-centric events which witness a lot of competition and in turn motivates students. Alright, I have blabbered enough.

In this post, I will tell you what a beginner’s robotics kit should contain. These components are indispensable because however complicated your task at hand will be, you will need at least one of these around you. It would be good practice to get this kit up and ready ASAP if you are a robotics enthusiast and don’t have one such kit already. All of these are readily available at an electronics components shop near you or you can always order from Indian robotics e-shops like Robokits, Rhydolabz etc.

These are:

Breadboard

This is where you begin your circuit from scratch. Any circuit, however complicated, is almost always implemented on a breadboard. As to why it is called a ‘bread’board, a variety of explanations are available like this one. The following images show a normal breadboard and its internal connections. All points on a line are equipotential.
Cost – depends on the model – generally Rs. 50-75.



Single strand copper wires/jumpers

Breadboard connections are done using these wires as they make life easier than those multi-stranded thin wires that connect the switches to the fans at our homes. But please note, single stranded wires can’t substitute these wires as they have a very low current rating. Jumpers are simple single stranded copper wires with pointed ends to make life even easier.
CostRs. 8-10 per metre.


12 V AC-DC adapter

It is a good substitute for a battery if you are working near a AC supply point. Batteries generally discharge very fast and hence not viable to use them. Also, it is very convenient to draw power from this adapter – a simple loop of two wires gets you a positive and negative terminal.
Cost – varies – a simple 12V/500 mA adapter will cost anywhere between Rs. 80-100.



Wire cutter

If you are not too fond of using your teeth to remove insulation from wires, use this. Besides, it also proves useful for a number of other purposes like cutting a Printed Circuit Board or simply PCB, pulling out components from a soldered circuit etc.
Cost – Rs 40-50.

Solder gun and wire

Extremely important to have this around you all the time. Soldering is an extremely important skill to have because last minute changes are inevitable in any circuit. Also, it is desirable to have a few blank PCBs with you just in case there is an addition to your circuit and you don’t want to solder over an already packed PCB.
Cost – Rs. 80-90 for the solder gun, Rs. 30-40 for the solder wire.

Portable Digital Multimeter (DMM)

Multimeter is the most indispensable tool. Measuring potential, current, resistances, looking for shorts in soldering, checking an LEDs functionality….these are some of the major tasks for which you will use your DMM. You have to have it!
Cost – a decent DMM will cost you Rs. 125-150. Some models with more features cost around Rs. 300. Your choice!

Resistance/Capacitance box

It is always handy to have a box each of resistance and capacitance of assorted standard values. Several robotics components require you to have a particular capacitance in parallel (Crystal clocks) or a resistance of a particular value in series (Normal LEDs) so as to prevent damage, enhance efficiency or remove noise etc.
Cost – Rs 40 maximum for each, depends on the number of values and number of items of each value.

Also, it is desirable that you have a few LEDs with you…LEDs are a good substitute for a variety of things like a motor or a relay or checking if a particular pin in your controller (more on this later :) ) is working as desired.


There you go…you have a beginner’s kit ready!
This kit shall be the basic requirement of almost every circuit to be discussed in this space.
See ya!

Tuesday, May 17, 2011

The Pilot

Hello all. Welcome to my blog.

This space will be all about what I have learnt and/or done at my hostel room, the various laboratories in college or at my home sweet home. The content shall be mostly stuff that the curriculum doesn't cover.
I will try to present the content in an informal manner directly from my experience. References shall be quoted wherever I feel that my post is not enough to understand the topic well.

Please note, I may not have practically done 'each and every thing' that I write about in this space, but I can say with a fair amount of confidence that even if I discuss something that I have not yet undertaken myself, utmost care shall be taken to ensure that the topic is researched to the best of my ability and shall be of help to the reader in his/her endeavors.

Lastly, I do not claim that what I write is the absolute truth and the best content available. I am just a student trying to provide the content - that a beginner to the world of robotics, microcontrollers and virtual instrumentation needs - all at one place. For advanced topics and detailed helps, refer to the references and most importantly - Google!

Also, please feel free to comment, ask questions, answer questions, offer constructive suggestions to make this blog a better effort.