How to make your first robot

Problem with Sharp IR

The IR sensor changes constantly, but there are usually higher numbers when an object is closer to it. The readings are anywhere from 180 to 10.

This is what the area near the input pins look like

robot_back.jpg

and the front looks like this

robot_front.jpg

the rest of the robot works fine.

Your pictures are blurry

Your pictures are blurry where they need to be sharp :wink: But it appears to me that 2 wires on the sharp needs to be the other way around :slight_smile: Hang on, will double checkā€¦

Yes, as far as I can tell,

Yes, as far as I can tell, your green and black needs to be swapped :slight_smile:

**I switched the wires, **

I switched the wires, and now the sensor stays at 60, and sometimes changes to 59 or 61. Here are some sharper pictures.

robot_front_new.jpg

robot_back_new.jpg

thanks

Apparently you deleted the old pictures?

Itā€™s a little confusing to me, because it appears as if you deleted the old pictures, so it is hard to see what you have changed :slight_smile:

But it still appears as if you should swap signal and ground.

Please look carefully at this picture from above, and make sure the wires goes the same way.

Headpins.jpg

Take great care, as the Sharp is easily fried if you switch this the wrong way - I think you have been lucky so far though.

Ā 

I restored the old pictures

Oops. I didnā€™t mean to delete the old pictures. It looks like the wires were correct the first time. It still does not work.

I restored the old pictures

Oops. I didnā€™t mean to delete the old pictures. It looks like the wires were correct the first time. It still does not work.

Yes, you are right, sorry, I

Yes, you are right, sorry, I could not tell from the original pictures.

OK; my next bet is that you have your test setup under ā€œbad lightā€ - try to work under a different light source. IR can be disrupted if the lamps are blinking in the same area. (none of this is visible) It is a well known issue with IR.

I turned all the lights off.

I turned all the lights off. The only device that could IR is a remote controlled speaker which is off, and the computer screen, which is turned the other way. The problem still persists.

I turned all the lights off.

I turned all the lights off. The only device that could IR is a remote controlled speaker which is off, and the computer screen, which is turned the other way. The problem still persists.

I turned all the lights off.

I turned all the lights off. The only device that could IR is a remote controlled speaker which is off, and the computer screen, which is turned the other way. The problem still persists.

From what little info you

From what little info you provided, that may be normal operation.

Read through this post and the many comments on it for some background.

https://www.robotshop.com/letsmakerobots/node/22939

Thanks. I thought the output

Thanks. I thought the output would be in cm.Ā 

Great tutorial :slight_smile:

Great tutorial, thanks!

Made my first robot yesterday with hardly any experience in electronics. You just need to like tinkering :wink:

robotje.jpg

Showing the 'default' behaviour from the example code: www.youtube.com/watch?v=tHNcPkN_cQI

First thing I did after that was add a switch so I can turn off the robot without having to remove a battery :)

Hey, Looking GOOD :DAnd

Hey, Looking GOOD :smiley:

And funny neck too! Any plans for the next project?

Yep, I made a longer neck so

Yep, I made a longer neck so the camera wouldnā€™t touch the wires all the time when looking around. But the higher it is, the more difficult it is to avoid obstacles that are low I think.

If I want a next project beyond this detailed tutorial, I need to really understand what Iā€™m doing, and that might be a problem :wink:

Iā€™ll just improve the programming for this one and maybe the body. And see how long my robot-attention-span lastsā€¦

Sounds like an excellent

Sounds like an excellent plan :slight_smile:

I recommend your next project is to take everything apart, find a speaker and an LED, and see if you can make a simple setup of a blinking LED and a beeping speaker :slight_smile:

Gonna buy butā€¦

I am going to buy your controller but i have a few more questions:

Can i use a CA-53 cable to replace the CA-42 in your " Make your own FTDI cable" tutorial?

And to program the controller, can i program it using the code stated in the ā€œStart Hereā€ robot tutorial or do I have to modify the code to suit the ā€˜ubotino controllerā€™? If so, can u tell me what changes should be made to the code? Or, could you send me a ā€œStart Hereā€ robot code written by yourself?

Thanks! -Aaronsuper1

USB to Serial Adapter (part USB010)

Hi,

i just finished making the hardware part of the robot, and while downloading the codes to the micro-controller, i found out that i donot have the RS232 to usb adapter, (i bought the serial download cable for picaxe), so i wanted to know, will that make any difference if i use any serial to usb adapter? Or do i have to get the ā€œProlific USB adaptersā€.Ā  i dont want to wait long for ordering :(Ā  and its pretty expensive too. Please reply soon.

nik

IR sensor

I am haiving some error with the sensor when using it, i am using the sharp 2Y0A21 F12ā€¦when used in my circuit, when only reading the adc values from the sensor, it gives back a constant reading of 90-100 even if nothing is in front of the sensor!! I tried putting a 10 uF electrolytic and .1 uF non-elec. between GND and VCC right on the sensor, but it only brought the maximum false reading down from 100-115. This is a huge problem, since it reduces the maximum distance into about 1/3 - 1/4 of the normal. As in, when I have the sensor pointed at the ceiling , it gives a reading of ~ 90-100. As such, it has greatly reduced my robot functionality. As Iā€™ve said, when there is a object in rangeā€¦the sensor works just fine, but when nothing is in front, it starts to act weird. Due to which i cannot initiate the programmingā€¦Please reply soonā€¦ Thankx