Author Topic: Sensors, am i doing some thing wrongly?  (Read 3239 times)

0 Members and 1 Guest are viewing this topic.

Offline karlisTopic starter

  • Full Member
  • ***
  • Posts: 79
  • Helpful? 0
Sensors, am i doing some thing wrongly?
« on: October 06, 2008, 01:10:19 PM »
Hi mates, i have started to build my robots sensors

shematics which i use are from 50$ robot tutorial, in the begining i built simple sensor with IR led and 2 resisotrs, but i couldnt read anthing much when i draged it over black line .. so i decided to build other amplified sensor..

so i bought 5 LM385 amplifiers and put all to gather

ir what i`m using is similar whats in this photo..
http://akamai.globalsources.com.edgesuite.net/f/593/3445/5d/pdt.static.globalsources.com/IMAGES/PDT/SMALL/763/S1001325763.jpg

problem is with mesurements, i again drag it over my black line (white background) and my reading are prety poor, if i could say so..


ps sorry for my english mistakes :(
in 1 case i got 0.01 to 0.00 or 0.02 volts in output, but in second case from 6.3 to 6.6 volts in output
but thing that is making me mad is that output changes "randomly"
i have changed hights used aluminum foil with duck tape, on IR, but it still was exposed to room lights, chould i make something like closed box where inside are led and covered sensor, to get stable mesurements ?

btw have any suggestion on displacement of sensors? should i bether put them like /\ or bether in 1 line ?
« Last Edit: October 06, 2008, 01:14:24 PM by karlis »

Offline paulstreats

  • Supreme Robot
  • *****
  • Posts: 1,381
  • Helpful? 21
Re: Sensors, am i doing some thing wrongly?
« Reply #1 on: October 06, 2008, 01:47:35 PM »
Hi,

First I presume you are using an ir led and an infrared photodiode. (one is an emitter and one is a detector).

Looking up the LM385 it seems that they are voltage reference diodes or 2 wire voltage regulators, I dont think these are going to help.

You need to attach the photodiode(detector) to a transistor in order to amplify the signal, and then do the voltage divider circuit with the resistors. (you might be able to just do it without the transistor).

    +5v--------------IR Photodiode----------resistor--------------resistor---------------GND
                                                                     |
                                                                     |
                                                                     |
                          Microcontroller a/d pin--------------
                          or voltage detector

Offline karlisTopic starter

  • Full Member
  • ***
  • Posts: 79
  • Helpful? 0
Re: Sensors, am i doing some thing wrongly?
« Reply #2 on: October 06, 2008, 01:56:26 PM »
i have an emiter, thats what i should not use huh? ^_^

so i just should get IR detector and put all togather like in first circruit?
http://www.societyofrobots.com/schematics_infraredemitdet.shtml

or much bether use second circruit for more precise mesurrements ?


Offline Trumpkin

  • Supreme Robot
  • *****
  • Posts: 1,177
  • Helpful? 5
Re: Sensors, am i doing some thing wrongly?
« Reply #3 on: October 06, 2008, 06:13:30 PM »
You need an IR emitter and detector.
Robots are awesome!

Offline karlisTopic starter

  • Full Member
  • ***
  • Posts: 79
  • Helpful? 0
Re: Sensors, am i doing some thing wrongly?
« Reply #4 on: October 07, 2008, 12:24:52 AM »
doh >.< and i though it was led and IR emiter  :-\

Offline karlisTopic starter

  • Full Member
  • ***
  • Posts: 79
  • Helpful? 0
Re: Sensors, am i doing some thing wrongly?
« Reply #5 on: October 07, 2008, 10:13:14 AM »
well i have ironed 1 more sheme up, this time i used same IR emiter, and detector from old tv..

amplified out was changing from 5.22 to 5.27 volts only when i stoped moving over black line it stayd for a while on constant voltage 5.24

i have few questions..

1) how much output voltage should i get if my input is ~7v is any constant output what should i get ?
2) could give me some names of IR emiters detectors, which i should search in internet shops ?

Offline Trumpkin

  • Supreme Robot
  • *****
  • Posts: 1,177
  • Helpful? 5
Re: Sensors, am i doing some thing wrongly?
« Reply #6 on: October 07, 2008, 11:09:28 AM »
Robots are awesome!

Offline karlisTopic starter

  • Full Member
  • ***
  • Posts: 79
  • Helpful? 0
Re: Sensors, am i doing some thing wrongly?
« Reply #7 on: October 07, 2008, 12:38:58 PM »
which one ? first or second ?

btw i`m allredy using second amplified shematic !

Offline Trumpkin

  • Supreme Robot
  • *****
  • Posts: 1,177
  • Helpful? 5
Re: Sensors, am i doing some thing wrongly?
« Reply #8 on: October 07, 2008, 12:44:44 PM »
You can probably just use the first one.
Robots are awesome!

Offline karlisTopic starter

  • Full Member
  • ***
  • Posts: 79
  • Helpful? 0
Re: Sensors, am i doing some thing wrongly?
« Reply #9 on: October 07, 2008, 01:55:23 PM »
but is that ok if my mesurements (with multimeter) are jumping from 5.22 to 5.27volts ?

Offline paulstreats

  • Supreme Robot
  • *****
  • Posts: 1,381
  • Helpful? 21
Re: Sensors, am i doing some thing wrongly?
« Reply #10 on: October 07, 2008, 06:03:25 PM »
I personally like these: http://www.sparkfun.com/commerce/product_info.php?products_id=246 They are an infrared emitter and a detector rolled into 1 package. They are designed so the detector doesnt pick up any direct light from the emitter. They only pick up light that gets reflected from a surface which is really what you are wanting to do.

 Remeber that when using ir led's or emitters then you will also need to limit the current using a resistor to stop them burning out. In the product above, the detector is a phototransistor meaning that you dont need to add another transistor.

 From a supply of 5v, i register a change of 0v on a completely black line through to around 4.3 v for a white line with other colours and shades reflecting in between. (obviously this depends on the brightness of the emitter but you have to get a potentiometer to be able to adjust the brightness to the correct level). You still need to do the voltage dividing circuit with the resistors but resistors are cheap enough you just need the right ones for the job. Its all about trying and testing, changing components then trying and testing again. If you get a range of potentiometers you can change the values to be just right (they are like resistors that you can change the resistance by turning a dial) then when you hit the sweet spot measure the resistance with a multimeter and exchange them for solid resistors.

edit---------

Also, the sensor posted above says that they are usful between 0.5 and 1cm of a detected surface. I have personally used them to detect changes up to around 30cm on a device that has been used for over 8 months now, so though they seem limited at first when it says their detection range is below 1 cm, I can vouch for their efficiency at around 30cm detection range. I know it sounds like i make them but i dont, I just think they are a great product for robotics in a neat package....
« Last Edit: October 07, 2008, 06:15:19 PM by paulstreats »

Offline karlisTopic starter

  • Full Member
  • ***
  • Posts: 79
  • Helpful? 0
Re: Sensors, am i doing some thing wrongly?
« Reply #11 on: October 07, 2008, 11:20:29 PM »
sweet, it seems so that i`ll just buy from sparkfun them :)


how much sensors do you think is use full to use for line folowing robot ? i`m thinking about 5 in line or in /\ shape, what do you think ? or bether use just 3 of them ? stright left right ?


btw where can i find out where does sparkfun sends their products ? world wide or only in usa or some where else too? i`m interesting about it because i live in europe ..
« Last Edit: October 07, 2008, 11:34:56 PM by karlis »

Offline Trumpkin

  • Supreme Robot
  • *****
  • Posts: 1,177
  • Helpful? 5
Re: Sensors, am i doing some thing wrongly?
« Reply #12 on: October 08, 2008, 08:47:53 AM »
What's the difference from the sparkfun sensor and this sensor http://parts.digikey.com/1/parts/947142-sensor-reflective-object-50ma-opb706a.html
Robots are awesome!

Offline karlisTopic starter

  • Full Member
  • ***
  • Posts: 79
  • Helpful? 0
Re: Sensors, am i doing some thing wrongly?
« Reply #13 on: October 08, 2008, 09:13:23 AM »
i dont know, you tell me..

i think they are the same.. myb i`m wrong ... anyhow the thing is, that i have never bought @ sparkfun or digikey, and i dont know in which countries they deliver stuffs.. how can i find it in ebay ? i tryd to find via sparkfun codes, but i faild..

Offline paulstreats

  • Supreme Robot
  • *****
  • Posts: 1,381
  • Helpful? 21
Re: Sensors, am i doing some thing wrongly?
« Reply #14 on: October 08, 2008, 10:57:06 AM »
They are a very similar product just produced by a different company. The sparkfun ones are cheaper aswell i think. Also farnell has some of these type of sensors.

How many to use?

You can make an effective line follower with just 3 of them. Some people swear by using 5 and some even 7.

What shape should they be placed in?

Again a personal preference, some people claim a v shape is best. Some people just use a straight line.

if they are in a V shape it is thought that you can detect turns sooner, but im unconvinced that it really makes a difference.
« Last Edit: October 08, 2008, 11:05:19 AM by paulstreats »

Offline karlisTopic starter

  • Full Member
  • ***
  • Posts: 79
  • Helpful? 0
Re: Sensors, am i doing some thing wrongly?
« Reply #15 on: October 08, 2008, 04:18:14 PM »
so paulstreats  you sai i should use just 3 of them and all its left is tweaking to get perfect results ?
allso i want to know in which areas are working bouth sparkfun and digikey.. i have spended ~50$ for robot till now.. i`m not an "money saver" type, i want to build good robot, but wasting money around ain fun, even i as student dont have unlimited money...

untill now i have fully working atmega16 chip, modified servos so they can 360 degree rotate freely, and only problem left are sensors, i thought there will be less problems than they apier

ps sorrt for my language :(

Offline paulstreats

  • Supreme Robot
  • *****
  • Posts: 1,381
  • Helpful? 21
Re: Sensors, am i doing some thing wrongly?
« Reply #16 on: October 08, 2008, 05:34:29 PM »
Using 3 will give you enough to follow a line. Once you get them all you need to do is hook up the led (emitter part) to your power and GND using a suitable resister to stop them burning out. Then the detector part, connect one leg to your power then the other to a resistor which goes to GND. The connection to the atmega should come between the resistor and the detector. You do need to tweak here to get a good resistor value but you'll find that you can get a working set of results with a wide variety of resistors.

Quote
allso i want to know in which areas are working bouth sparkfun and digikey


Im not sure what you meant here? do you mean where in the world they are? If so then they are both in the US somewhere.

If you are outside the US and wanting to cut costs on postage then try http://www.farnell.com and see if they have a distributor in or near your own country. If so choose your flag and search for "QRD1114".

Offline karlisTopic starter

  • Full Member
  • ***
  • Posts: 79
  • Helpful? 0
Re: Sensors, am i doing some thing wrongly?
« Reply #17 on: October 09, 2008, 01:45:45 AM »
[quota]
Im not sure what you meant here? do you mean where in the world they are? If so then they are both in the US somewhere.
[/quota]
yes that was what i wanted to know..

i`m wondering if i will use only 3 sensors, could it be enought relayable to win some competition ? once or twice a year there are robot races... line folowing and sumo

last year i was there(in Riga, capital city of Latvia) and saw some guy from lithuania, and he was wery fast, i would say like F1 racers :D

 


Get Your Ad Here

data_list