Go to Post This easy world of friends, of people that you can talk to for hours on end without knowing one another? That's FIRST. - Keith Chester [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 04-01-2013, 23:54
Spencer Gomez Spencer Gomez is offline
Registered User
FRC #3145 (Teraviks)
Team Role: Programmer
 
Join Date: Jan 2012
Rookie Year: 2010
Location: Coeur d' Alene Idaho
Posts: 1
Spencer Gomez is an unknown quantity at this point
Drive motors spin wrong way

We were using a basic simple template code to deploy to an old bot for practice a while ago, but when we tried to drive the robot using our joystick the bot span in a circle when you pushed the joystick forward. However, if you pushed the joystick sideways, then the bot would drive forward. I we tired fixing this by code but couldn't find the culprit. we ended up switching a jaguar hook-up in order to fix it and that seemed to work. I was wondering how to code to switch the direction of drive motors through jaguars.
Reply With Quote
  #2   Spotlight this post!  
Unread 05-01-2013, 02:16
nathan_hui nathan_hui is offline
Registered User
AKA: Nathan Hui
FRC #2473 (CHS Robotics)
Team Role: Alumni
 
Join Date: Feb 2012
Rookie Year: 2009
Location: Cupertino, CA
Posts: 228
nathan_hui will become famous soon enoughnathan_hui will become famous soon enough
Send a message via AIM to nathan_hui
Re: Drive motors spin wrong way

I believe your culprit is that the axis on the joystick were switched (in the code). If your joystick is sideways, pushing the stick to the side would be "forward" and pushing the stick forward would be "spin this side". If you flip the jag, I think you'll find left and right backwards.
Reply With Quote
  #3   Spotlight this post!  
Unread 05-01-2013, 09:24
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: Drive motors spin wrong way

I think you're looking for the SetInvertedMotor() method.
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 18:23.

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