Go to Post You see the learning experience doesn't stop during construction. It goes on to competition or to everyone who looks at a picture on delphi, who studies the bot and says I like how they did this or I woulda changed this a bit. - Dan Richardson [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
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 08-02-2011, 18:40
Joel Johnson's Avatar
Joel Johnson Joel Johnson is offline
zeleathos
FRC #3536 (ElectroEagles)
Team Role: Programmer
 
Join Date: Feb 2011
Rookie Year: 2011
Location: Hartland Michigan
Posts: 9
Joel Johnson is an unknown quantity at this point
Exclamation Weird Joystick controls

Hi I'm Joel Johnson from the HartlandElectroeagles team 3536, and i am having trouble with the the joystick controls. To go forward you have to tilt the joystick to the left, to go backwards right, ect... We are using the arcade drive code. I was wondering how to change it.


Thank You,
Joel Johnson
Reply With Quote
  #2   Spotlight this post!  
Unread 08-02-2011, 19:49
kgzak's Avatar
kgzak kgzak is online now
Registered User
AKA: Kris
FRC #4392 (Decievers) FRC #2075 (Enigma)
Team Role: College Student
 
Join Date: Dec 2008
Rookie Year: 2008
Location: Grand Rapids, Michigan
Posts: 418
kgzak is a splendid one to beholdkgzak is a splendid one to beholdkgzak is a splendid one to beholdkgzak is a splendid one to beholdkgzak is a splendid one to beholdkgzak is a splendid one to beholdkgzak is a splendid one to behold
Re: Weird Joystick controls

Flip the axises. The x axis is left and right the y axis is Forward backward. You probably are trying to use the x axis for forward backward and y as left right.
Reply With Quote
  #3   Spotlight this post!  
Unread 08-02-2011, 20:42
Joel Johnson's Avatar
Joel Johnson Joel Johnson is offline
zeleathos
FRC #3536 (ElectroEagles)
Team Role: Programmer
 
Join Date: Feb 2011
Rookie Year: 2011
Location: Hartland Michigan
Posts: 9
Joel Johnson is an unknown quantity at this point
Re: Weird Joystick controls

Ok il try that i think i may have flipped it i changed the axis input. we are a rookie team and i am a rookie coder so how would I change the X- axis to go left and right and the Y-axis to go forward and backward?
Reply With Quote
  #4   Spotlight this post!  
Unread 08-02-2011, 21:04
Egg 3141592654's Avatar
Egg 3141592654 Egg 3141592654 is offline
Now a mentor, always a student
FRC #0810 (Mechanical Bulls)
Team Role: Programmer
 
Join Date: Feb 2010
Rookie Year: 2008
Location: Long Island
Posts: 53
Egg 3141592654 is on a distinguished road
Re: Weird Joystick controls

If you are using the arcade drive, on the left of the arcade drive box, there should be 3 possible wire inputs. The top (you know this already) is where your drive reference (pink) goes. The next two wires below that are your axis inputs. I believe top is x and bottom is y (if not, right click the arcade drive box and click help. This outlines each input in more detail). To switch them, you only need to place the x axis in the other slot and move the y axis into the now empty slot you just moved x from. I was once there, so good luck with the programming!
__________________
"The answers to the book of life are not found in the back." Charlie Brown

Software Mentor - Team Apex Robotics 5803

Lead Programmer - Team 810 Mechanical Bulls '09-'11
Reply With Quote
  #5   Spotlight this post!  
Unread 08-02-2011, 23:26
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,113
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: Weird Joystick controls

If you are using the unmodified Arcade Drive in the default project, there's nothing wrong with your joystick axes. What needs to be fixed is the direction your motors are turning. Specifically, your left motor is going the way opposite the way the code expects it to.

You can fix that either by switching the actual wires coming from the speed controller to the motor, or by changing the "LeftMotorInverted" constant on the 2 Motor Open from True to False in the Begin vi.
Reply With Quote
  #6   Spotlight this post!  
Unread 09-02-2011, 05:17
Joel Johnson's Avatar
Joel Johnson Joel Johnson is offline
zeleathos
FRC #3536 (ElectroEagles)
Team Role: Programmer
 
Join Date: Feb 2011
Rookie Year: 2011
Location: Hartland Michigan
Posts: 9
Joel Johnson is an unknown quantity at this point
Re: Weird Joystick controls

Ok thanks alot guys il do that
Reply With Quote
  #7   Spotlight this post!  
Unread 12-02-2011, 13:23
Gmzcarlos Gmzcarlos is offline
Registered User
FRC #3583
 
Join Date: Feb 2011
Location: Texas
Posts: 8
Gmzcarlos is an unknown quantity at this point
Re: Weird Joystick controls

where is the "LeftMotorInverted" constant setting? or the begin vi ?

Thank you

-- OK I didn't realize this is for LabView --

How do you this if we are using C++ ?

Last edited by Gmzcarlos : 12-02-2011 at 13:49.
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 20:31.

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