Author Topic: opposite rotations of my 50$ robot servos  (Read 1803 times)

0 Members and 1 Guest are viewing this topic.

Offline manutTopic starter

  • Jr. Member
  • **
  • Posts: 38
  • Helpful? 0
opposite rotations of my 50$ robot servos
« on: December 04, 2009, 09:15:50 PM »
hi, I have a little problem with my 50$ robot: the servos turns in opposite directions, does anybody knows what I did wrong..I guess I just inverted something, but don't know what.. (I used photoresistors of different values, could come from that?)
thanx
manu

Offline Joker94

  • Supreme Robot
  • *****
  • Posts: 1,119
  • Helpful? 26
Re: opposite rotations of my 50$ robot servos
« Reply #1 on: December 05, 2009, 02:37:57 AM »
It could be the photo resistors, or it could be that if you swap the pins the servos are plugged into it will work.

Have you got it all mounted yet

Offline ozbot

  • Jr. Member
  • **
  • Posts: 28
  • Helpful? 1
Re: opposite rotations of my 50$ robot servos
« Reply #2 on: December 05, 2009, 06:21:01 AM »
It depends how you mount your servo's, once you are happy with construction, alter you code to account for this.  In the code you should have 3 PWM values (assuming you are using the photovore zip file).  One is one direction, the middle value should be stop and the other is the opposite direction.  Try reversing one set to see the difference.

Code: [Select]
{
//go straight
servo_left(25);
servo_right(44);
}

See, if I swapped both around, it would go backward, see?
I was so disappointed to learn that half the people I know are under average........but the other half more than make up for it.

Offline manutTopic starter

  • Jr. Member
  • **
  • Posts: 38
  • Helpful? 0
Re: opposite rotations of my 50$ robot servos
« Reply #3 on: December 05, 2009, 08:12:03 AM »
thanks guys,
I will try to modify the code, but first I'd like to be sure that this problem doesn't comme from electronic...because I mounted the servos exactly like in the tutorial, ...but both turn in the clockwork sense in the light and opposite sense in the dark.

Offline Soeren

  • Supreme Robot
  • *****
  • Posts: 4,672
  • Helpful? 227
  • Mind Reading: 0.0
Re: opposite rotations of my 50$ robot servos
« Reply #4 on: December 05, 2009, 08:20:01 AM »
Hi,

It's because you mount the servos back to back, sort of speaking, so one will go opposite the other if both get either a short or a long pulse (relative to 1.5ms). Either mod the code as suggested or swap the leads on the motor inside one of the servos, whatever you find easier.
Regards,
Søren

A rather fast and fairly heavy robot with quite large wheels needs what? A lot of power?
Please remember...
Engineering is based on numbers - not adjectives

Offline manutTopic starter

  • Jr. Member
  • **
  • Posts: 38
  • Helpful? 0
Re: opposite rotations of my 50$ robot servos
« Reply #5 on: December 05, 2009, 09:11:33 AM »
hi,
by swapping the leads inside the motor, you mean I've to swap the negative and the positive? I used the 2.2Kohm resistor method to modify the servos.
thanx
manu

Offline Soeren

  • Supreme Robot
  • *****
  • Posts: 4,672
  • Helpful? 227
  • Mind Reading: 0.0
Re: opposite rotations of my 50$ robot servos
« Reply #6 on: December 06, 2009, 08:33:13 AM »
Hi,

I mean to swap the leads soldered to the motor _inside_ the servo - the terminals on the motor itself.
There might be from 1 to 3 caps mounted there (for electric noise removal) and you don't need to swap them, just the leads.

You SHOULD NOT swap the leads going outside, as that would most likely render the servo seriously dead.
Regards,
Søren

A rather fast and fairly heavy robot with quite large wheels needs what? A lot of power?
Please remember...
Engineering is based on numbers - not adjectives

Offline manutTopic starter

  • Jr. Member
  • **
  • Posts: 38
  • Helpful? 0
Re: opposite rotations of my 50$ robot servos
« Reply #7 on: December 06, 2009, 04:27:27 PM »
thanx guys! :) 'M going to work on that....I let you know..

Offline blackbeard

  • Supreme Robot
  • *****
  • Posts: 575
  • Helpful? 4
Re: opposite rotations of my 50$ robot servos
« Reply #8 on: December 06, 2009, 06:11:25 PM »
put them on backwards?
"sure, you can test your combat robot on kittens... But all your going to do is make kitten juice"

First step: Build androids with AI
Next step: Give them vaginas

Offline manutTopic starter

  • Jr. Member
  • **
  • Posts: 38
  • Helpful? 0
Re: opposite rotations of my 50$ robot servos
« Reply #9 on: December 06, 2009, 07:36:43 PM »
hmmm...that's an idea but I'd like to keep them in symetry..

Offline ozbot

  • Jr. Member
  • **
  • Posts: 28
  • Helpful? 1
Re: opposite rotations of my 50$ robot servos
« Reply #10 on: December 07, 2009, 05:48:47 AM »
It be a lot easier and safer to just edit your code.  If you cannot change the directions of your servo's with code, you will need to learn sooner or later.
I was so disappointed to learn that half the people I know are under average........but the other half more than make up for it.

Offline manutTopic starter

  • Jr. Member
  • **
  • Posts: 38
  • Helpful? 0
Re: opposite rotations of my 50$ robot servos
« Reply #11 on: December 07, 2009, 08:20:56 AM »
I read a few things about it, and you're right, modifying the code seems to be the easiest way to make the modif..

 


Get Your Ad Here

data_list