Society of Robots - Robot Forum

Electronics => Electronics => Topic started by: shaduwz on January 10, 2010, 10:01:52 PM

Title: 50$ robot servo problems
Post by: shaduwz on January 10, 2010, 10:01:52 PM
I just finished making the 50$ robot's circuit on the breadboard that I got, and then I tried to upload the hex for servo modifying on the tutorial. After 30 mins of "writing" and "verifying" on ponyprog, it gave this message "Write Failed." I'm sure it recognizes the robot, the power is on and everything (I am using the 4.8v battery holder and 9v battery method with the slightly modified schematics). I tried again with the same result. Thin I plugged in my servos anyway, and they wiggled a little bit, but when I removed the big gear the the protruding piece of plastic (stop) they did not continuously rotate. Now I am confused on what to do.

EDIT--- I unplugged the 9v battery (this shutsdown the program I think) and directly plugged the servo to the 4.8 volt battery and it still wiggled. This means (I think) that the program wasn't written on the robot. Still confused...
Title: Re: 50$ robot servo problems
Post by: Joker94 on January 10, 2010, 10:33:01 PM
Well the wiggle is the pulse of power the servo recieves form the battery when firsted plugged in. A continuous series of controlled pulses is what makes a servo rotate. Pulse with modulation (PWM).

If it said write failed it means the program could nit be written  to the MCU.

What sort of programmer are you using, usb or serial.

If you have USB you can programm it through AVR studio which will test it as when i fist tried to program pony prong didnt work so i have  been going through avr studio ever since.

when we know what programmer you have we can help more.

Joker94
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 12, 2010, 07:16:59 PM
I am using the exact same programmer (cheaper one) as mentioned in the 50$ robot tutorial. I think its called the Pocket AVR Programmer from sparkfun.com. I used a USB to Serial converter for it to connect to my laptop.
Title: Re: 50$ robot servo problems
Post by: Joker94 on January 12, 2010, 10:13:43 PM
Well i have never had any luck with Pony Prong so i have alwaysed used a USB programmer so i have no idea what your problem is.

The only problem i can think of is in the circuitry as when i was having circuitry problems i got the programmed failed message as well.

I suppose there is 2 steps.

1)Check all your circuitry and connections of shorts and lose connections
2)Check that you have selected all of the correct settings in pony Prong as if they are not it will not recgonise the circuitry as programmerable.

Good luck( and remember trouble shooting is a big and important part with robotics).

Joker94
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 12, 2010, 10:45:01 PM
I'll check the breadboard as soon as I can tomarow. What settings do you think I need to use on ponyprog? I have the COM Port right by the way.
Title: Re: 50$ robot servo problems
Post by: dfoley23 on January 12, 2010, 11:47:27 PM
I have had similar problems with the programming of the $50 robot, it ended up being a circuitry problem eventually i got a succesful write on ponyprog and was able to run the holdservo.hex script then move on from there, check the power circuits and also the programmer circuits thats where i had some problems.
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 13, 2010, 07:59:47 PM
I've rebuilt the circuit several times, but I'll keep trying. Thanks for the help. By the way, is the power supposed to be on when programing? thats what I did
Title: Re: 50$ robot servo problems
Post by: Joker94 on January 14, 2010, 03:57:07 AM
Yeah you need the power on when you try to program.
Title: Re: 50$ robot servo problems
Post by: z.s.tar.gz on January 14, 2010, 04:48:50 PM
Make sure you're writing to flash not eeprom. I thought my mcu was defective one time but it was just a human-keyboard-interface error.
Title: Re: 50$ robot servo problems
Post by: GearMotion on January 14, 2010, 06:47:57 PM
it was just a human-keyboard-interface error.

Those are the most intractable and insipid.
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 17, 2010, 04:37:03 PM
Actually, mistake on my part, it is the AVR STK Serial Port Dongle Programmer. Still doesen't program by the way, no luck whatsoever. On the programmer, which hole does PIN 17 go into? The first hole I know is marked by that arrow and the red wire, but I'm still a little confused.
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 18, 2010, 01:05:57 PM
also, I am using serial to usb converter, if that changes anything
Title: Re: 50$ robot servo problems
Post by: Razor Concepts on January 18, 2010, 01:39:28 PM
Not sure if this is related, but when I programmed PICAXE microcontrollers, you couldn't use a USB to serial cable since the serial used some special commands that couldn't be decoded by the converter. Might be the same case here.
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 18, 2010, 01:56:18 PM
Well, on the tutorial it said that you could use USB to SERIAL converters, and one was even used for it. I'm pretty sure this will work for the servo.hex as well.
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 20, 2010, 05:33:25 PM
Alright, I'm pretty sure the whole thing is correctly circuited, I am using the 6V battery method now, I am writing to flash (although the tutorial says to write all) and it is still not working. The only other thing that could be wrong is that I am putting the pins in the wrong holes on the programmer or a part of my robot is broken.
Title: Re: 50$ robot servo problems
Post by: Razor Concepts on January 20, 2010, 05:56:52 PM
http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=76555 (http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=76555)

I am betting it is your usb>serial
Title: Re: 50$ robot servo problems
Post by: Pratheek on January 21, 2010, 09:16:40 AM
Not sure if this is related, but when I programmed PICAXE microcontrollers, you couldn't use a USB to serial cable since the serial used some special commands that couldn't be decoded by the converter.
Thats right.

Some AVR serial programmers do not work with USB to serial converters. I am not sure about the programmer you are using though.

Title: Re: 50$ robot servo problems
Post by: shaduwz on January 21, 2010, 06:43:53 PM
It is the same programmer that the tutorial uses and he used a usb to serial converter as well.
Title: Re: 50$ robot servo problems
Post by: z.s.tar.gz on January 21, 2010, 06:45:34 PM
I can confirm that that programmer works with even the lowest quality of adapters.
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 23, 2010, 12:06:56 PM
That brings me back to my original problem... I'll keep testing while I wait for answers.
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 24, 2010, 11:58:26 AM
I think that the programmer is my problem or more specifically, I don't which wire goes to which hole. I will post a diagram and I'll see if someone can fill it in for me:
(http://i292.photobucket.com/albums/mm22/alonzosmash/Programmer.png)

As you can probably tell, the red line marks the first hole.
Title: Re: 50$ robot servo problems
Post by: junaidp on January 24, 2010, 12:28:38 PM
hi
I am starting of with this 50$ robot ,i am a beginner need your help with the parts things,I need to know the parts numbers ,like resistor ,capacitor values ,micro controller number and other stuff values used in this robot as you have already made this ,because the electronic shopkeer is asking thesew values from me .please help
thanks
regards
junaid
[email protected]
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 24, 2010, 12:57:54 PM
hi
I am starting of with this 50$ robot ,i am a beginner need your help with the parts things,I need to know the parts numbers ,like resistor ,capacitor values ,micro controller number and other stuff values used in this robot as you have already made this ,because the electronic shopkeer is asking thesew values from me .please help
thanks
regards
junaid
[email protected]

It is pretty easy to look at the part numbers on the tutorial (at the bottom of this page: http://www.societyofrobots.com/step_by_step_robot_step1.shtml (http://www.societyofrobots.com/step_by_step_robot_step1.shtml)) and then look them up online. When you find them online the description on the website you find them on usually has the values.
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 25, 2010, 08:41:22 AM
I think that the programmer is my problem or more specifically, I don't which wire goes to which hole. I will post a diagram and I'll see if someone can fill it in for me:
(http://i292.photobucket.com/albums/mm22/alonzosmash/Programmer.png)

As you can probably tell, the red line marks the first hole.


Just put the place the pins go into. For example, above the red wire fill in PIN 7 (just as an example I don't know pin 7 actually goes there). Could someone please help?
Title: Re: 50$ robot servo problems
Post by: junaidp on January 25, 2010, 12:31:58 PM


hey thanks alot for this info,its really work,but the photoresistor value not mentioned here if u know please do let me know.. secondly i wanna know whats the diff between a servo and a simple motor,can i use a motor for this.
and if i want to use a sensor will it be a must to use a complete circuit,can i use a sensor (like a robot will move left if an obstacle is there) without using this complete sensor.

my location is islamabad pakistan .
thanks

hi
I am starting of with this 50$ robot ,i am a beginner need your help with the parts things,I need to know the parts numbers ,like resistor ,capacitor values ,micro controller number and other stuff values used in this robot as you have already made this ,because the electronic shopkeer is asking thesew values from me .please help
thanks
regards
junaid
[email protected]

It is pretty easy to look at the part numbers on the tutorial (at the bottom of this page: http://www.societyofrobots.com/step_by_step_robot_step1.shtml (http://www.societyofrobots.com/step_by_step_robot_step1.shtml)) and then look them up online. When you find them online the description on the website you find them on usually has the values.


Title: Re: 50$ robot servo problems
Post by: shaduwz on January 25, 2010, 05:26:27 PM


hey thanks alot for this info,its really work,but the photoresistor value not mentioned here if u know please do let me know.. secondly i wanna know whats the diff between a servo and a simple motor,can i use a motor for this.
and if i want to use a sensor will it be a must to use a complete circuit,can i use a sensor (like a robot will move left if an obstacle is there) without using this complete sensor.

my location is islamabad pakistan .
thanks

hi
I am starting of with this 50$ robot ,i am a beginner need your help with the parts things,I need to know the parts numbers ,like resistor ,capacitor values ,micro controller number and other stuff values used in this robot as you have already made this ,because the electronic shopkeer is asking thesew values from me .please help
thanks
regards
junaid
[email protected]

It is pretty easy to look at the part numbers on the tutorial (at the bottom of this page: http://www.societyofrobots.com/step_by_step_robot_step1.shtml (http://www.societyofrobots.com/step_by_step_robot_step1.shtml)) and then look them up online. When you find them online the description on the website you find them on usually has the values.




I see you made your own post on the forum so I will leave you to it. Back the the original problem, can someone fill in the picture that I made, or at least tell me where the holes are supposed to be plugged in to?
Title: Re: 50$ robot servo problems
Post by: z.s.tar.gz on January 25, 2010, 07:45:40 PM
(http://img43.imageshack.us/img43/5051/helpjm.png)

Of Course:
Red box represents pin 1
"na" doesn't connect to anything
"G" connects to ground (Pins 8 and/or 22 if you must)
Title: Re: 50$ robot servo problems
Post by: shaduwz on January 26, 2010, 08:32:25 PM
No good. Opening servo.hex from ponyprog, writing to flash, turning on power, and it stays at 0% for 5 mins then says UNKNOWN DEVICE. Any other tips? :(