Society of Robots - Robot Forum

Software => Software => Topic started by: HDL_CinC_Dragon on October 27, 2007, 09:50:36 AM

Title: $50 robot + IR scans only once and drives constantly after
Post by: HDL_CinC_Dragon on October 27, 2007, 09:50:36 AM
When i turn my robot on after uploading the robotIR code into it, it scans ~45? in front of it and then just keeps trying to turn constantly. It never stops and scans again... any idea what might be causing this?
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: Admin on October 27, 2007, 06:29:44 PM
Try putting something in front of the IR as it turns - it will spin until it finds something (search mode).
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: HDL_CinC_Dragon on October 27, 2007, 11:50:57 PM
well that got a little bit of a reaction out of it but it only lasts about 1 second and then it continues driving again no matter what I put in front of it and how far away... the IR is rated 10cm to 80cm. would this cause a problem? Perhaps it can see too far?
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: Admin on October 28, 2007, 10:03:06 AM
hmmmm hold it up so it isnt spinning then put something in front and see what happens . . .

there is also the chance you plugged the sensor into the wrong port? sometimes the signal from one port can interfere with other ports that are close by, causing it to sometimes work and sometimes not . . .
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: HDL_CinC_Dragon on October 28, 2007, 10:18:59 AM
well right now it doesnt actually have wheels :P so it never actually moves but I have alternated between starting it looking at things and moving the things around in front of it.

... well ill be a monkeys uncle.... all the sudden it just started working normally for like a minute.... then it just went back to being a jerk.... ill post a video of my efforts: gimmie a minute
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: Admin on October 28, 2007, 10:35:25 AM
to be honest, it really sounds like one of these:

- plugged into the wrong port
- low voltage (check batteries - maybe time for a recharge?)
- loose connection

and you are doing this inside away from a bright sunny window, right? :P
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: Steve Joblin on October 28, 2007, 10:43:28 AM
I agree with Admin in that it sounds like if it justed worked for a bit, it sounds like your battery supply is not sufficient... what is the total output voltage from your battery supply?  How many, and what types of batteries are you using?
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: HDL_CinC_Dragon on October 28, 2007, 08:17:36 PM
Im using the exact NiMH battery that was suggested in the tutorial. Checking it with my DMM, its pretty much fully charged... ill tinker around with it a little bit tomorrow if I find time... Thanks for the suggestions
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: Admin on October 28, 2007, 09:04:57 PM
use your multimeter on your rangefinder too to see if it changes values properly or not (just to make sure it isnt damaged or bad wiring)

i once had a loose wire connection on my hypersquirrel robot rangefinder, took me forever to figure out why it only sometimes worked . . . apparently the wire connection on the sensor was damaged
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: HDL_CinC_Dragon on October 29, 2007, 08:58:55 PM
ok, where should I be testing from? data to GND?
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: Admin on October 30, 2007, 04:43:39 AM
power to ground (to check that its ~5V), and signal to ground
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: HDL_CinC_Dragon on November 03, 2007, 10:05:18 AM
heres a small video of what my robot does...
http://img532.imageshack.us/img532/8317/11307stateofthebot1jb4.flv (http://img532.imageshack.us/my.php?image=11307stateofthebot1jb4.flv)
Sorry for the low resolution. I had to use my webcam to film it which also has a faulty microphone >_< so the audio sucks big time too. lots of feedback noise.

But at least now you can kinda see what my robot is doing.



-EDIT-
I just realized how much that video really sucks.... Ill figure something out to get better quality all around lol. I just realized that you need to see what the wheels are doing too heh... yeah... I have to go to work soon so Ill get on that when I get home if I have time >_<
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: Admin on November 03, 2007, 10:16:39 AM
Just a note for others - notice the "blue" light coming from his sensor . . . his webcam can see infrared light ;D
Title: Re: $50 robot + IR scans only once and drives constantly after
Post by: HDL_CinC_Dragon on November 03, 2007, 10:24:02 AM
lol thats pretty much the only reason I got a straight on shot of the IR sensor TBH hahaha =)