Go to Post Team newb: To expect any average group of high schoolers to build and develop a robot in less than six weeks is...madness! Me: Madness? THIS IS FIRST! - MishraArtificer [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 21-01-2014, 22:52
Team3993Tom Team3993Tom is offline
Registered User
FRC #3993
 
Join Date: Feb 2013
Location: Newhall
Posts: 35
Team3993Tom is an unknown quantity at this point
mecanum drive and joystick

Ok our idea was to use a 4 wheel mecanum drive set up. The issue is its our first time using them so we have no idea how to program it in labview. Problem number 2 is that we want to use the logitech extreme 3d pro controller because of the fact that you can turn the stick. We wanted to use one controller to do all the driving,so forward and backward and to go right and left but to use the twist to spin (or turn the bot left and right). Again we have no idea how to do this or implement it into the code.

So if any one could help and explain it (to beginners) wile having pictures for examples it would be really appreciated .
Reply With Quote
  #2   Spotlight this post!  
Unread 21-01-2014, 22:56
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,100
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: mecanum drive and joystick

Quote:
Originally Posted by Team3993Tom View Post
Ok our idea was to use a 4 wheel mecanum drive set up. The issue is its our first time using them so we have no idea how to program it in labview. Problem number 2 is that we want to use the logitech extreme 3d pro controller because of the fact that you can turn the stick. We wanted to use one controller to do all the driving,so forward and backward and to go right and left but to use the twist to spin (or turn the bot left and right). Again we have no idea how to do this or implement it into the code.

So if any one could help and explain it (to beginners) wile having pictures for examples it would be really appreciated .
There's a vi for that in LabVIEW.


Reply With Quote
  #3   Spotlight this post!  
Unread 22-01-2014, 22:09
DonRotolo's Avatar
DonRotolo DonRotolo is offline
Back to humble
FRC #0832
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Atlanta GA
Posts: 7,011
DonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond repute
Re: mecanum drive and joystick

I feel badly posting this, because I don't like to discourage teams from trying things. But:

Meccanum is not trivial to implement, and perhaps you might consider getting some off-season experience with it before committing to it during build season.
__________________

I am N2IRZ - What's your callsign?
Reply With Quote
  #4   Spotlight this post!  
Unread 22-01-2014, 22:22
Team3993Tom Team3993Tom is offline
Registered User
FRC #3993
 
Join Date: Feb 2013
Location: Newhall
Posts: 35
Team3993Tom is an unknown quantity at this point
Re: mecanum drive and joystick

This is our code but the problem is that (twist right= forward) (twist left= back) (stick forward= spin right) (stick back= spin left'ish) (stick left= right wheel error) (stick right= right wheel error).
Attached Thumbnails
Click image for larger version

Name:	drive help pic.png
Views:	50
Size:	68.2 KB
ID:	15929  
Reply With Quote
  #5   Spotlight this post!  
Unread 22-01-2014, 22:34
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: mecanum drive and joystick

Quote:
Originally Posted by Team3993Tom View Post
This is our code but the problem is that (twist right= forward) (twist left= back) (stick forward= spin right) (stick back= spin left'ish) (stick left= right wheel error) (stick right= right wheel error).
My first thought is that your right wheels are simply spinning in the wrong direction. In the 4 Motor Open function in Begin, there is a place to invert those motors.
Reply With Quote
  #6   Spotlight this post!  
Unread 22-01-2014, 22:35
Cecil's Avatar
Cecil Cecil is offline
Registered User
AKA: Alex Hummel
FRC #2010 (Lightning Bots)
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2006
Location: Champion
Posts: 343
Cecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to behold
Re: mecanum drive and joystick

Check your motor controllers to make sure they are plugged into the correct spots on the Digital Sidecar. If that doesn't help, remember that 2 of the motors must be inverted in Begin.vi for it to work correctly (I generally invert both left motors. If they all function correctly, but the joystick is backwards, then invert the other two instead.) Hover over the Open 4 Motors.vi and you will see 4 green dots (2 on top and 2 on bottom) that reference the inversions.
__________________
I'm right 90% of the time, so why worry about the other 3%?
Reply With Quote
  #7   Spotlight this post!  
Unread 22-01-2014, 23:35
Team3993Tom Team3993Tom is offline
Registered User
FRC #3993
 
Join Date: Feb 2013
Location: Newhall
Posts: 35
Team3993Tom is an unknown quantity at this point
Re: mecanum drive and joystick

Ok ill try that out thank you, also this is my begin if you think there can be any changes.
Attached Thumbnails
Click image for larger version

Name:	begin.png
Views:	41
Size:	64.2 KB
ID:	15931  
Reply With Quote
  #8   Spotlight this post!  
Unread 25-01-2014, 22:06
Team3993Tom Team3993Tom is offline
Registered User
FRC #3993
 
Join Date: Feb 2013
Location: Newhall
Posts: 35
Team3993Tom is an unknown quantity at this point
Re: mecanum drive and joystick

Quote:
Originally Posted by Cecil View Post
Check your motor controllers to make sure they are plugged into the correct spots on the Digital Sidecar. If that doesn't help, remember that 2 of the motors must be inverted in Begin.vi for it to work correctly (I generally invert both left motors. If they all function correctly, but the joystick is backwards, then invert the other two instead.) Hover over the Open 4 Motors.vi and you will see 4 green dots (2 on top and 2 on bottom) that reference the inversions.
do they have to be set to true or false for to be inverted?
Reply With Quote
  #9   Spotlight this post!  
Unread 25-01-2014, 23:50
Cecil's Avatar
Cecil Cecil is offline
Registered User
AKA: Alex Hummel
FRC #2010 (Lightning Bots)
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2006
Location: Champion
Posts: 343
Cecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to behold
Re: mecanum drive and joystick

Quote:
Originally Posted by Team3993Tom View Post
do they have to be set to true or false for to be inverted?
True means it is inverted. Basically, you have to do this because motors face the opposite direction on different sides of the robot. The same concept can be achieved by setting all motor inversions to False and swapping the leads of the motor around at the motor controllers on one side of the robot. (Note: Do NOT swap the power leads leading from the Power Distribution board. If you decide to go this route, only swap the leads on the motor side of the speed controller.)

If you are going the code route, two of them should be inverted. Just make sure they are both from the same side (either right or left), not front and back inverted from each other.
__________________
I'm right 90% of the time, so why worry about the other 3%?
Reply With Quote
  #10   Spotlight this post!  
Unread 27-01-2014, 00:23
Mark McLeod's Avatar
Mark McLeod Mark McLeod is offline
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,833
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: mecanum drive and joystick

Another thing to check on is the mapping of your joystick axes.
They may not match what LabVIEW is calling axis 1,2, & 3 and it's easy to verify with Joystick Explorer or your own front panel.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle
Reply With Quote
  #11   Spotlight this post!  
Unread 27-01-2014, 20:14
Team3993Tom Team3993Tom is offline
Registered User
FRC #3993
 
Join Date: Feb 2013
Location: Newhall
Posts: 35
Team3993Tom is an unknown quantity at this point
Re: mecanum drive and joystick

Quote:
Originally Posted by Cecil View Post
True means it is inverted. Basically, you have to do this because motors face the opposite direction on different sides of the robot. The same concept can be achieved by setting all motor inversions to False and swapping the leads of the motor around at the motor controllers on one side of the robot. (Note: Do NOT swap the power leads leading from the Power Distribution board. If you decide to go this route, only swap the leads on the motor side of the speed controller.)

If you are going the code route, two of them should be inverted. Just make sure they are both from the same side (either right or left), not front and back inverted from each other.
ok so it now works but how do I get it to go diagonally?
Reply With Quote
  #12   Spotlight this post!  
Unread 27-01-2014, 20:33
Cecil's Avatar
Cecil Cecil is offline
Registered User
AKA: Alex Hummel
FRC #2010 (Lightning Bots)
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2006
Location: Champion
Posts: 343
Cecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to behold
Re: mecanum drive and joystick

Diagonal movement is a combination of left/right and forward/back motion. Try pushing your joystick to the upper left or right corner. It should move diagonally in that direction.
__________________
I'm right 90% of the time, so why worry about the other 3%?
Reply With Quote
  #13   Spotlight this post!  
Unread 27-01-2014, 23:02
Team3993Tom Team3993Tom is offline
Registered User
FRC #3993
 
Join Date: Feb 2013
Location: Newhall
Posts: 35
Team3993Tom is an unknown quantity at this point
Re: mecanum drive and joystick

lol yah we found that out. Thank you for all the help and thank you for dealing with my stupid questions.
Reply With Quote
  #14   Spotlight this post!  
Unread 27-01-2014, 23:17
Cecil's Avatar
Cecil Cecil is offline
Registered User
AKA: Alex Hummel
FRC #2010 (Lightning Bots)
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2006
Location: Champion
Posts: 343
Cecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to beholdCecil is a splendid one to behold
Re: mecanum drive and joystick

Quote:
Originally Posted by Team3993Tom View Post
lol yah we found that out. Thank you for all the help and thank you for dealing with my stupid questions.
No problem. That's what we are here for.
__________________
I'm right 90% of the time, so why worry about the other 3%?
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 21:02.

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