Go to Post As an adult who has spent years working with youth in Boy Scouts and FIRST, and on behalf of all other adults at the event: deodorant. - Rick TYler [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
 
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 09-02-2011, 12:11
Trump Trump is offline
Registered User
FRC #2053
 
Join Date: Feb 2010
Location: New York
Posts: 18
Trump is an unknown quantity at this point
Re: WPILib Mecanum Function Not Strafing Properly

Are the rollers on your wheels making an X or an O from the top. The need to make an X from the top (O form the bottom).

Two of your motors should be inverted (in code, or by switching the pos and ground). This is because the motors on one side will spin in the oposite direction on one side of the bot when they are given the same signal.

Are you Using C++, Java, or LabView?
Reply With Quote
  #2   Spotlight this post!  
Unread 10-02-2011, 21:04
CodeMonkeyMatt CodeMonkeyMatt is offline
Registered User
FRC #2605
 
Join Date: Jan 2011
Rookie Year: 2008
Location: WA
Posts: 46
CodeMonkeyMatt is on a distinguished road
Re: WPILib Mecanum Function Not Strafing Properly

Quote:
Originally Posted by Trump View Post
Are the rollers on your wheels making an X or an O from the top. The need to make an X from the top (O form the bottom).

Two of your motors should be inverted (in code, or by switching the pos and ground). This is because the motors on one side will spin in the oposite direction on one side of the bot when they are given the same signal.

Are you Using C++, Java, or LabView?
They are making the X on top.

I'm pretty sure they're properly inverted because forward and rotation worked, just not strafe. I figure that since we'd be using the RobotDrive class (I thought it went without saying due to the forum I'm in, we're using C++) it was naturally set up for the inverted motors and did it automatically.
Reply With Quote
  #3   Spotlight this post!  
Unread 10-02-2011, 23:07
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,112
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: WPILib Mecanum Function Not Strafing Properly

Quote:
Originally Posted by CodeMonkeyMatt View Post
I'm pretty sure they're properly inverted because forward and rotation worked, just not strafe.
If you had control of the front motor on one side swapped with the rear motor on that side, you'd probably get the results you're seeing. Start by verifying that the motors you're telling the code about are actually on the corners you're telling it they're on.
Reply With Quote
  #4   Spotlight this post!  
Unread 12-02-2011, 02:48
CodeMonkeyMatt CodeMonkeyMatt is offline
Registered User
FRC #2605
 
Join Date: Jan 2011
Rookie Year: 2008
Location: WA
Posts: 46
CodeMonkeyMatt is on a distinguished road
Re: WPILib Mecanum Function Not Strafing Properly

Quote:
Originally Posted by Alan Anderson View Post
If you had control of the front motor on one side swapped with the rear motor on that side, you'd probably get the results you're seeing. Start by verifying that the motors you're telling the code about are actually on the corners you're telling it they're on.
That sounds promising now that you mention it. Unfortunately, I'm not working on the robot for a bit, so I'll have to look into that and get back to you guys in a couple days.
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 17:48.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi