Author Topic: Axon II Problem  (Read 2291 times)

0 Members and 1 Guest are viewing this topic.

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Axon II Problem
« on: October 14, 2010, 07:42:23 AM »
I have a weird little something going on with my Axon II microcontroller.

I have three Hitec servos plugged into B5, B6, and B7 with a 6v NiMH battery for power. While I was typing some code in AVRStudio, the servos suddenly started making a very high-pitched buzzing/whining noise and moved slightly but noticeably off center. The servos also stopped responding to commands I was sending through RealTerm which was connected via Bluetooth.

I did try changing the battery (to no avail) because I have seen the servos do funny things when the battery starts to get low.

I believe the Axon II is the culprit more than anything else because:
1) different servos plugged into the same ports did produce the same results
2) the same servos plugged into a different microcontroller did not produce the same result.
3) the same servos plugged into different pins (B4,H6,H5) did not produce the same results

With me having moved the servos to other pins, everything seems to be okay for now, but I would like to have some clue as to what might be happening and what can be done to fix this problems or prevent it from happening again.

I am hoping this is not going to be a continuing trend.

Any advice or suggestions?

Offline knossos

  • Robot Overlord
  • ****
  • Posts: 278
  • Helpful? 14
Re: Axon II Problem
« Reply #1 on: October 14, 2010, 10:13:17 AM »
My first guess would be to check the code.
"Never regret thy fall,
O Icarus of the fearless flight
For the greatest tragedy of them all
Is never to feel the burning light."
 
Oscar Wilde

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #2 on: October 14, 2010, 10:36:56 AM »
I'm not sure why that would be the problem. The program was running and I was not doing anything to manipulate servo positions at the time. Plus, the same program was later running with the servos plugged into different pins and nothing weird happened.

Offline KurtEck

  • Robot Overlord
  • ****
  • Posts: 217
  • Helpful? 12
Re: Axon II Problem
« Reply #3 on: October 14, 2010, 11:30:19 AM »
Something going on with the timer?  What are you using to drive the servos?  Webbotlib?  which driver...

Kurt

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #4 on: October 14, 2010, 12:14:22 PM »
I'm not sure about the timer. I am using Webbotlib including the Project Designer.
« Last Edit: October 14, 2010, 12:16:22 PM by tzankoff »

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #5 on: October 14, 2010, 12:38:35 PM »
Are you using the software or hardware servo controller?

Do pins B5, B6, and B7 still work for other tasks?

What other tasks were you asking the Axon II to do in your code?

What other hardware do you have hooked up to the Axon II?

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #6 on: October 14, 2010, 02:35:26 PM »
Here is a pic of the setup:


Quote
Are you using the software or hardware servo controller?

Hardware.

Quote
Do pins B5, B6, and B7 still work for other tasks?

As far as I can tell, no. The only other thing I have to plug in is a spare servo. When I do that, the strange noise is replicated.

Quote
What other tasks were you asking the Axon II to do in your code?

At the time the weirdness occurred, it was not doing anything. It was sitting idle with all servos centered while I was doing something else. When in use, you can tell it to move the arm or neck and neck up or down a little at a time or all the way at once. You can also send commands to the MP3 Trigger.

Quote
What other hardware do you have hooked up to the Axon II?

1. UART0 is hooked up to MP3 Trigger
2. UART2 is hooked up to a wireless antenna
3. Regulated power is provided to the antenna, the MP3 Trigger, and the jaw servo card (which moves the jaw when MP3 Trigger is active).


Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #7 on: October 14, 2010, 02:47:43 PM »
Quote
What other tasks were you asking the Axon II to do in your code?
At the time the weirdness occurred, it was not doing anything. It was sitting idle with all servos centered while I was doing something else. When in use, you can tell it to move the arm or neck and neck up or down a little at a time or all the way at once. You can also send commands to the MP3 Trigger.
So the Axon II was programmed and commanding the servos to stay centered, right?

So no interrupts were set, or anything that could possibly have caused a pin attached to the servo to hold a high voltage, right? For example, applying a constant 5V to the servo signal line could cause the servo to 'freak out' as you described.

Quote
Quote
Do pins B5, B6, and B7 still work for other tasks?

As far as I can tell, no. The only other thing I have to plug in is a spare servo. When I do that, the strange noise is replicated.
So if you use those pins again, you get the screeching servos and frozen code problem again? Or do the servos in those pins just don't work any more?

Using those problem pins, does the problem only occur when the servos are attached, or does it still have the problem without servos attached?

And when you use the new pins, you keep the rest of the code exactly the same?

Program those pins as basic digital I/O, and just have them pulse off/on. With a multi-meter, see if those pins still work.

Which Hitec servos are you using?

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #8 on: October 14, 2010, 03:11:46 PM »
Quote
So the Axon II was programmed and commanding the servos to stay centered, right?
Yes.

Quote
So no interrupts were set or anything that could possibly have caused a pin attached to the servo to hold a high voltage, right?
Not that I am aware of.

Quote
For example, applying a constant 5V to the servo signal line could cause the servo to 'freak out' as you described.
As far as I know, the only way I could accomplish that would be to plug something into the Axon incorrectly (i.e.: missing a pin; backwards plug). The servos are plugged in the way they should be. Keep in mind this whole thing happened on the fly. Things were running smoothly and while sitting idle, the buzzing started.

Quote
So if you use those pins again, you get the screeching servos and frozen code problem again?
Yes. Using a spare servo I had lying around in all three sets of pins had the same result.

Quote
Or do the servos in those pins just don't work any more?
The affected servos seem to work just fine. I didn't let them stick around long enough to find out if they were going to overheat or anything.

Quote
Using those problem pins, does the problem only occur when the servos are attached, or does it still have the problem without servos attached?
The buzzing noise is coming from inside the servo. I put my ear up to the servo and I hear the noise. When I unplug the servo, the noise stops.

Quote
And when you use the new pins, you keep the rest of the code exactly the same?
Yes.

Quote
Program those pins as basic digital I/O, and just have them pulse off/on. With a multi-meter, see if those pins still work.
Yikes! How do I do that? Remember, I'm a newbie. I know a few things, but don't assume too much.

Quote
Which Hitec servos are you using?
I have that information written down at home. I'll answer this one a little bit later.

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #9 on: October 14, 2010, 03:58:16 PM »
Quote
Quote
Using those problem pins, does the problem only occur when the servos are attached, or does it still have the problem without servos attached?
The buzzing noise is coming from inside the servo. I put my ear up to the servo and I hear the noise. When I unplug the servo, the noise stops.
What I meant was, does the code still freeze when the servos aren't plugged in?

Also, measure the pin voltages without the servos plugged in.

Quote
Quote
Program those pins as basic digital I/O, and just have them pulse off/on. With a multi-meter, see if those pins still work.
Yikes! How do I do that? Remember, I'm a newbie. I know a few things, but don't assume too much.
In Project Designer, click Basic in the device window, then drag over Digital output. When code is generated, look at the example.txt file with example code. You just tell the pin to go high, call a delay, then go low, and another delay. That will go in a while loop:

pseudocode:
Code: [Select]
while(1)
{
pin_high();
delay_ms(2000);
pin_low();
delay_ms(2000);
}

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #10 on: October 14, 2010, 04:55:45 PM »
Quote
What I meant was, does the code still freeze when the servos aren't plugged in?
The terminal program returns valid data, but the servos do not move like they're supposed to.

Quote
Also, measure the pin voltages without the servos plugged in.
The pins are returning 8.8v and the regulated section returns 6.6v.

...and to answer an earlier question:
Quote
Which Hitec servos are you using?
I am using an HS-485HB for the neck, HS-985MG in a gearbox for the arm, and another HS-485HB as the spare.

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #11 on: October 14, 2010, 05:19:27 PM »
Oh, and to follow up on knossos's post regarding checking my code, I did upload a copy of the barebone code generated by Project Designer (without any of my programming) to the Axon and it yielded the same result.

Drat!

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #12 on: October 14, 2010, 06:24:07 PM »
The pins are returning 8.8v and the regulated section returns 6.6v.

Just an FYI, both the pins and the regulated section should *never* return more than 5V.

Sounds like you have power plugged into the wrong spot, and you are seriously frying your Axon :P

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #13 on: October 14, 2010, 07:01:54 PM »
Not a chance!

I have had the power switch plugged in the right way from day one and have never removed it (to help make sure plugging it in wrong didn't happen). You might say that I plugged in the battery the wrong way. Not likely. At least with the battery, I can clearly see colors and line them up correctly instead of squinting to see tiny little pins.

If the whole thing, or at least those pins, are fried, then why was it working for hours prior before going nuts in the same power cycle? If something was plugged in wrong from the time I turned it on, wouldn't things have gotten screwed up right off the bat?

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #14 on: October 14, 2010, 07:31:43 PM »
The ATmega640 is rated for up to 5.5V. After that, bad things *might* start to happen, but things can still work without a hitch.

I once accidentally plugged 6.3V into the regulated line, and everything worked fine. At least for awhile, then my ISP programmer started complaining the mcu wasn't powered. After realizing my mistake, I fixed the wiring, and nothing seems to have fried. But after 5.5V, you're taking chances. This is probably why your servos worked for a little while with those pins, burning out after awhile from over-voltage.

Now the strange part is, how the heck is 8.8V coming out of your pins when regulated is only 6.6V?!

Looking at your image, its hard to be sure, but there appears to be a coiled red and black wire connecting the bottom power bus (unregulated) directly to the top power bus (regulated). If so, then this would definitely be the cause of your problem!

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #15 on: October 14, 2010, 07:45:01 PM »
Quote
Now the strange part is, how the heck is 8.8V coming out of your pins when regulated is only 6.6V?!
Stranger still is that the battery is 6V.
 ???

Quote
Looking at your image, its hard to be sure, but there appears to be a coiled red and black wire connecting the bottom power bus (unregulated) directly to the top power bus (regulated). If so, then this would definitely be the cause of your problem!
The red/black wire you refer to goes from the F3 to the jaw servo card (green card in photo) which takes 5-24V for power. There is also a red/black/yellow twister (the arm servo) which is connected to H3.


Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #16 on: October 14, 2010, 07:51:34 PM »
A fully charged 6V battery can easily give you 6.6V+.

I'm still convinced your wiring is somehow wrong . . .

Unplug *everything* from your Axon II.

Then with a multimeter, measure the resistance between 5V regulated power and unregulated power. It should be some high value.

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #17 on: October 14, 2010, 08:01:37 PM »
While you were typing your last reply, I typed this...
I'm not sure how this is, but let me run this by you and you tell me what you think.

First of all, here is the battery that I am using.


It clearly says "6.0V", right?

I just put the battery on my voltage meter. The result: 8V+

What the hell?!?!?

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #18 on: October 14, 2010, 08:06:38 PM »
Well, the Axon can handle much higher than 8V, so that isn't the problem . . .

But wow, sounds like you overcharged your battery somehow, lol.

I think the highest I ever got a 6V battery to be was 7.3V.

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #19 on: October 14, 2010, 08:15:56 PM »
Everything is unplugged from everything and tried taking voltage readings again.

Unregulated is showing around 8.8v (+/-.5v)
Regulated is showing a steady 6.87v
Batteries (x2) are each showing 8.8-9.1v. (How the @#$% is that possible?)

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #20 on: October 14, 2010, 08:23:14 PM »
Ummmmm is your voltage meter a chinese brand by any chance? :P

Anyway, I meant also unplug your battery as well - literally every wire - and then use the ohm setting on your multi-meter.

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #21 on: October 14, 2010, 08:33:58 PM »
The meter is an Actron CP7672 and I'm getting zeros all over the place.

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #22 on: October 14, 2010, 08:36:29 PM »
Fantastic! Now I am getting readings that are jumping all over the damn place.

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #23 on: October 14, 2010, 08:43:16 PM »
lol, either you're circuit is insanely messed up, or your multi-meter just fried :-X

or both . . .

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #24 on: October 14, 2010, 08:47:35 PM »
I give up! I am getting tired and I am well beyond frustrated at this point. How about I just plug just the battery into the Axon, turn it on, and let the battery drain that way? Sure, it would take quite a while, but since you say the Axon can handle 8V, there is no reason why that should not work...right?

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #25 on: October 14, 2010, 08:57:20 PM »
you say the Axon can handle 8V, there is no reason why that should not work...right?
The Axon unregulated bus can handle up to 16V, but the ATmega640 and regulated line can't. If more than 5V is applied to the regulated line, you can potentially permanently damage your Axon.

Again, please do the ohm test first :P

You should find another battery to test your multimeter and make sure it isn't broken.

Also, your servos are rated for no higher than 6V. I've used similar servos to 7V without a problem many times . . . but once you reach 8V or more, who knows what will happen - maybe even fry a signal pin or something . . .

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #26 on: October 14, 2010, 09:06:14 PM »
Quote
The Axon unregulated bus can handle up to 16V, but the ATmega640 and regulated line can't. If more than 5V is applied to the regulated line, you can potentially permanently damage your Axon.
@#$%!

Quote
Again, please do the ohm test first
I'm pretty sure I don't know but I'll go ahead and ask...how?

Quote
You should find another battery to test your multimeter and make sure it isn't broken.
I just did a voltage test on a slightly used 9-volt battery. *sigh* Double digit voltage. (11.8...?!?!?) I'm gonna try and find my other meter. brb

Quote
Also, your servos are rated for no higher than 6V. I've used similar servos to 7V without a problem many times . . . but once you reach 8V or more, who knows what will happen - maybe even fry a signal pin or something. . .
been there, done that...without realizing it (faulty servo controller instructions. yes, really. no, not you.)

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #27 on: October 14, 2010, 09:21:27 PM »
Let's try all this crap again with another meter.

The two batteries were 6.5v and 6.6v.
I plugged one of them by itself into the Axon.

The unregulated pins return 6.5v.
The regulated pins return 4.9v.
The 9v batter from earlier came in at 8.5v.
All three sets of the affected pins return 6.5v.
« Last Edit: October 14, 2010, 09:32:14 PM by tzankoff »

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,663
  • Helpful? 169
    • Society of Robots
Re: Axon II Problem
« Reply #28 on: October 14, 2010, 09:30:38 PM »
I plugged the battery by itself into the Axon. The unregulated pins return 6.5v. The regulated pins return 4.9v.

ok, much better! lol

Anyway, go back to this step and see what you get:
http://www.societyofrobots.com/robotforum/index.php?topic=12362.msg92999#msg92999

I'm about to go to sleep, so I'll get back to you tomorrow probably after you have results.

Offline tzankoffTopic starter

  • Robot Overlord
  • ****
  • Posts: 122
  • Helpful? 0
Re: Axon II Problem
« Reply #29 on: October 14, 2010, 09:41:18 PM »
See my last post. I was updating it with that information while you were typing your last post.

 


Get Your Ad Here