go away spammer

Author Topic: I thought I was done...  (Read 3837 times)

0 Members and 1 Guest are viewing this topic.

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
I thought I was done...
« on: May 17, 2009, 03:22:08 PM »
Been building the $50 robot. Thanks for all the help here. We built the sensors which was the final piece, connected everything and then connected it to the computer to download the software. The computer kept throwing an error -24 (or -25 I can't remember which now). Anyhow, it couldn't find the device. I double and triple checked the port (it was COM1). I tried a different computer and since it couldn't find it either, I can safely assume it is the robot... <sigh>.

What puzzles me is that I connected to the computer before to download the HEX file to center the servos and that seemed to work fine. (At least it said it was successful). We have not changed the board since then except adding the sensors.

I began probing the various headers with the multimeter trying to find issues. I noted that the 9V battery which I bought new for this project seems to be loosing juice fast. The last time I measured it, it was about 8.5 volts. Today it was down to 7.91. I got a fresh one, which had a reading over 9v when I plugged it in. I plugged it in and turned it on. I began probing with the multimeter again when I smelled smoke. I quickly turned off both the 9v and the battery pack. I sniffed around the board and discovered the voltage regulator was very hot! I disconnected the new battery and measured it and it was now down to about 8.5v. (It has since rebounded back over 9, about 20 minutes later).

The only difference between the two batteries was that the first one was from Radio Shack and the second a Duracell. I apparently have wired something wrong with my voltage regulator. I think I know what it is. I think i reversed the two voltage wires. The ground is in the right place, but the other two are flipped from the schematic. Based on my "smoke" I assume this is bad. Can anyone confirm or should i dig deeper. Thanks.

Offline SmAsH

  • Supreme Robot
  • *****
  • Posts: 3,959
  • Helpful? 75
  • SoR's Locale Electronics Nut.
Re: I thought I was done...
« Reply #1 on: May 17, 2009, 03:31:15 PM »
i think your voltage regulator is fried...
you can try desoldering it and testing it with the right polarity but... i don't think its good...
but no matter, voltage regs are cheap as chips! 30c each!
just make sure its facing the same way as in the tutorial, the silver metal part facing the mcu!
Howdy

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
Re: I thought I was done...
« Reply #2 on: May 17, 2009, 03:37:48 PM »
OK. I'll get another one and replace. I have the silver part facing the right way, but i inadvertently soldered the wires to the opposite sides shown in the schematic. I will reverse when and put them correctly when I redo. I think you have answered my question though. This component is polarized and the direction does matter. Thanks.

Offline SmAsH

  • Supreme Robot
  • *****
  • Posts: 3,959
  • Helpful? 75
  • SoR's Locale Electronics Nut.
Re: I thought I was done...
« Reply #3 on: May 17, 2009, 03:40:30 PM »
remember, when the silver side is facing you it goes...
input voltage(7-10v)-----gnd-----output voltage(5V)
always touch the regulator to see if its hot when you turn on a new circuit...
if it is, turn off naow!
Howdy

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
Re: I thought I was done...
« Reply #4 on: May 17, 2009, 03:44:22 PM »
Is this one the same:

http://www.radioshack.com/product/index.jsp?productId=2062599

(I know it is 3x the price of DigiKey, but I can go pick it up right now...)

Thanks

(Yup, I did ir backwards. Output, Grd, Input... Oh well :-)
« Last Edit: May 17, 2009, 03:50:27 PM by jaabot »

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
Re: I thought I was done...
« Reply #5 on: May 18, 2009, 05:10:11 PM »
Grrrrr... So I bought the voltage regulator in the previous post. (Model 276-1770) from Radio Shack. It says it is 5VDC. But, I desoldered the old one, removed it, and resoldered the new one. I reconnected power and tested it out. On the input side I read 9V, but on the output side it reads 8.1V!!! not 5V. Now what? I guess this Radio Shack one was not comparable.

Do you think I have now fried my AVR chip? I didn't unplug it before testing... I know. Bad idea. 

I guess I will have to order another one from DigiKey and wait. Seems so silly to order a $0.50 part through the mail. Have to pay more in shipping than its worth.

paulstreats

  • Guest
Re: I thought I was done...
« Reply #6 on: May 18, 2009, 06:19:00 PM »
I think that if the voltage regulator fried then there is a problem somewhere else. Voltage regulators dont usually fry for no good reason, so just replacing it wont solve the problem it will just fry the new one too and leave the original problem ready for you plugging in a new regulator and so on and so on.

 Is your circuit definately correct?

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
Re: I thought I was done...
« Reply #7 on: May 18, 2009, 09:08:44 PM »
Hello:

Thanks for the reply. Circuit is definitely correct. At least now it is anyway. The problem was what I mentioned at the start of the post. I had the input and output reversed. I put the old voltage regulator on the multimeter and it was actually fine. So I put it back on the board, rewired everything and now I appear to have a working board. I went over to the computer, plugged it in, and downloaded the program and moments later it was complete. Success.... almost...

Now for my newest problem. I appear to have messed up my servo modification. When I turn on the robot, the motors make noise like they are trying to run, but nothing turns. I am guessing I put the crazy glue in the wrong spot... Grrr. Nothing I can do about that except buy new servos right?


Offline Metal Slug 2

  • Supreme Robot
  • *****
  • Posts: 333
  • Helpful? 11
Re: I thought I was done...
« Reply #8 on: May 18, 2009, 09:37:00 PM »
hey man, if your not sure on whether you put the superglue in the right place or not, check out this servo modding tut:

http://www.flickr.com/photos/randomskk/2569969633/#in/set-72157605559564231/

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
Re: I thought I was done...
« Reply #9 on: May 18, 2009, 09:39:37 PM »
That's the one I followed. Thought I was pretty attentive too. On the step with turning the thing till it stopped rotating for example.

Is there anything I can do with the Servos I have? Or do i just need to pitch them and buy new ones?


Offline SmAsH

  • Supreme Robot
  • *****
  • Posts: 3,959
  • Helpful? 75
  • SoR's Locale Electronics Nut.
Re: I thought I was done...
« Reply #10 on: May 19, 2009, 12:45:24 AM »
if you can get the glue off you can send the 1.5ms pulse and turn the pot until the shaft stops rotating.
Howdy

Offline Ro-Bot-X

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,431
  • Helpful? 25
  • Store: RoBotXDesigns.ca
    • Ro-Bot-X Designs
Re: I thought I was done...
« Reply #11 on: May 19, 2009, 05:19:47 AM »
The servo mod will never be quite perfect. So you need to adjust from the program. Try to play around with the delay_cycles for the stopped position. Or delay_ms or whatever you work with. Adjust one unit at the time and see the results. I had to do the same for my servos.
Check out the uBotino robot controller!

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
Re: I thought I was done...
« Reply #12 on: May 19, 2009, 07:24:51 AM »
SmAsH: Yeah, I did do that, but I am wondering if the fact that my board was not correct when I downloaded the HEX file has anything to do with it. Maybe it never actually zeroed out? If you recall at the start of this post, I had the wires reversed on my voltage regulator. Despite this, when I connected the programmer to do the servos it said on screen that I connected successfully. So I thought I was good to go. (This is why I was so puzzled - and started this post - when it would not connect the second time as it had already connected once before).

When I connected the servos after downloading the HEX, they did start spinning, so I assumed that it was OK. I went through with the modification and did rotate the pot until they stopped rotating. That is when I glued. I followed the steps on that Flikr post, so I had good pictures and everything. So I am pretty sure I glued the right thing, I am just reaching for solutions here...


Ro-Bot-X: I am pretty new to all of this, including the programming. I followed Admin's tutorial which really doesn't tell you how to write the code, rather just how to compile the code he provided. Is there a tutorial on modifying the code somewhere?

Thanks to both of you.

BTW, I tried plugging the servos into different ports to see if it mattered. It didn't but I am curious, the board uses five pin headers making five ports, I have them plugged into the first two ports (the ones closest to the voltage regulator and big black capacitor). Does it matter which ports I use? Thanks.

Offline SmAsH

  • Supreme Robot
  • *****
  • Posts: 3,959
  • Helpful? 75
  • SoR's Locale Electronics Nut.
Re: I thought I was done...
« Reply #13 on: May 19, 2009, 02:28:57 PM »
well, the ports dont matter but you do have to define which ones you have each component connected to in your code. for admins code he wrote, the servos are connected to those ports so the pulses controlling the servos will only come out of those ports unless you change it in the software.

just a question, are you giving your servos 9v? direct from the battery?
Howdy

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
Re: I thought I was done...
« Reply #14 on: May 19, 2009, 03:16:04 PM »
Makes sense. The servos are getting the 5V from the voltage regulator output.

Offline Ro-Bot-X

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,431
  • Helpful? 25
  • Store: RoBotXDesigns.ca
    • Ro-Bot-X Designs
Re: I thought I was done...
« Reply #15 on: May 19, 2009, 07:18:36 PM »

Ok, when you modify the servos, allways use the same battery they will use on the robot, so the voltage is consistent. Now on your case, you had almost 9v when you modded them but only 5v when in use on the robot. First, thew servos should have their own power supply, no greater than 7.2v (or 7.4v if you use LiPo), unregulated. It is possible to have only one power supply for both the servos and electronics, but it should not be smaller than 6v (or electronics won't work properly*) and greater than 7.2V (or servos could burn).

* - Actually it all depends on the regulator. If you use a regular 7805, you need 7.2v input, if you use a low drop out regulator, you can go with 6V.

Second, make sure you untie the servo power from 5v and feed it from a different battery, or just before the regulator, if you use a single power source like I said above.


About the code, I can't teach you how to change it since I am using a little different language.
Check out the uBotino robot controller!

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
Re: I thought I was done...
« Reply #16 on: May 19, 2009, 09:48:01 PM »
PROGRESS!!!!

OK, so I went back and re-read a bunch of posts and Admin's original FAQs again. I decided that I needed to open up the servos again and even though I was certain I had followed the steps closely, that I needed to be sure. Turns our that the glue was in the right place, I just closed up the servos too soon - I had glued the gear to the collar surrounding the POT! I figured that I either had to chuck the servos and order new ones and start over, or just try to pry those bad boys off. Well, with a little gentle persuading, the gears came free. I filed down the affected area a bit, spread some of the grease on there and put it all back together.

It works! I now have rotating servos. The robot actually moves.... New problem: It just spins in circles. I am using Admin's Photovore_v1 program.

So, the circuit is working, check. The voltage regulator, check, servos, check. That leaves me with either the sensors or the code. How do I troubleshoot?

As always thanks very much. I think I am very close now...

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
Re: I thought I was done...
« Reply #17 on: May 19, 2009, 10:16:42 PM »
I played around a bit more. The sensors are doing something. If I let it run in full room light, they both turn CCW (opposite one another) make it turn in circles. However, if I put my hand over the sensors to block out the light, then one wheel reverses and the both turn forward. Release my hand and the spin opposite again.

Do I have a bad sensor? I need to reread that chapter...

Oh, one other thing, not sure if it is related. My LED never lights up. Should I be concerned?
« Last Edit: May 19, 2009, 10:21:01 PM by jaabot »

Offline Ro-Bot-X

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,431
  • Helpful? 25
  • Store: RoBotXDesigns.ca
    • Ro-Bot-X Designs
Re: I thought I was done...
« Reply #18 on: May 19, 2009, 10:28:34 PM »
Congrats!

I don't know about the sensor, but the LED probably is connected the other way around. It happened to me also a few times. Or, it may be burnt because excessive voltage when you had the regulator reversed. Get another LED and just touch the leads in paralel with the soldered LED and see wich way lights up. By comparing with the soldered LED connections, you will be able to see if it was reversed or not.
Check out the uBotino robot controller!

Offline Finnik

  • Full Member
  • ***
  • Posts: 59
  • Helpful? 4
Re: I thought I was done...
« Reply #19 on: May 22, 2009, 07:55:42 AM »
About the LED not going on with the provided code..
in the package supplied the LED is set to off, you need to change the code yourself to get the LED to light up.

The supplied code:
Code: [Select]
LED_off();//turn LED on
The way it should be to have the LED turn on:
Code: [Select]
LED_on();//turn LED on
Think outside the box... inside is to crowded.

Offline jaabotTopic starter

  • Full Member
  • ***
  • Posts: 52
  • Helpful? 0
Re: I thought I was done...
« Reply #20 on: May 23, 2009, 08:39:41 AM »
Well, I got excited when I saw your code. Figured that was pretty easy to fix. I made the edit, but alas, still no light. I guess I'll go get another LED and check to see if I installed it backwards after all...

 


Get Your Ad Here