Go to Post Experience...you can't buy it, you might be able to get some for free by reading CD a lot, but usually you have to earn it, and it's not always fun. - MrForbes [more]
Home
Go Back   Chief Delphi > Technical > Programming > Java
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 27-01-2015, 09:00
DCRich DCRich is offline
Mentor
FRC #2180 (Zero Gravity)
Team Role: Mentor
 
Join Date: Nov 2008
Rookie Year: 2006
Location: Steinert H.S., Hamilton NJ
Posts: 21
DCRich is an unknown quantity at this point
Javadocs for F310 Gamepad

Where are the Javadocs for using the Logitec F310 Gamepad or the XBox game controller? I find instructions on a 3-axis (X Y Z) Joystick but not for the 2-stick gamepad.

For those whose standard reply is to connect to DriverStation USB display - we did that and the right controller of the game pad showed X and Y motion and the left controller did nothing. since the display was identified as Joystick 1 and Joystick 2 it was not looking for a second control stick on the same port.

So how do we access the second controller?
Reply With Quote
  #2   Spotlight this post!  
Unread 27-01-2015, 09:02
notmattlythgoe's Avatar
notmattlythgoe notmattlythgoe is offline
Flywheel Police
AKA: Matthew Lythgoe
FRC #2363 (Triple Helix)
Team Role: Mentor
 
Join Date: Feb 2010
Rookie Year: 2009
Location: Newport News, VA
Posts: 1,717
notmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond repute
Re: Javadocs for F310 Gamepad

Quote:
Originally Posted by DCRich View Post
Where are the Javadocs for using the Logitec F310 Gamepad or the XBox game controller? I find instructions on a 3-axis (X Y Z) Joystick but not for the 2-stick gamepad.

For those whose standard reply is to connect to DriverStation USB display - we did that and the right controller of the game pad showed X and Y motion and the left controller did nothing. since the display was identified as Joystick 1 and Joystick 2 it was not looking for a second control stick on the same port.

So how do we access the second controller?
You treat it just like a joystick, but use the getRawAxis(int axis) method to access each axis.
Reply With Quote
  #3   Spotlight this post!  
Unread 27-01-2015, 09:54
NWChen's Avatar
NWChen NWChen is offline
Alum
no team
 
Join Date: Oct 2012
Rookie Year: 2012
Location: New York City
Posts: 205
NWChen is a splendid one to beholdNWChen is a splendid one to beholdNWChen is a splendid one to beholdNWChen is a splendid one to beholdNWChen is a splendid one to beholdNWChen is a splendid one to beholdNWChen is a splendid one to behold
Re: Javadocs for F310 Gamepad

Be sure the 'mode' button on the gamepad is not active.

If you're unsure about the mapping of sticks and buttons on the F310, you can refer to this. Alternatively, use the Logitech Profiler to define your mapping.
__________________
2012 - 2015 • Team 2601

Reply With Quote
  #4   Spotlight this post!  
Unread 27-01-2015, 10:54
DCRich DCRich is offline
Mentor
FRC #2180 (Zero Gravity)
Team Role: Mentor
 
Join Date: Nov 2008
Rookie Year: 2006
Location: Steinert H.S., Hamilton NJ
Posts: 21
DCRich is an unknown quantity at this point
Re: Javadocs for F310 Gamepad

You treat it just like a joystick, but use the getRawAxis(int axis) method to access each axis.


So all of the methods for direction and magnitude will not work or have no equivalent?

Which controller is axis 1 and which is axis 4? How is X mapped to an axis and how is Y mapped to axis. There are all kinds of buttons on the gamepad, colored, non-colored, triggers, settings, etc. How are these mapped to the joystick? The older Attack joystick has numbers on the buttons and those numbers correspond Javadoc for Joystick.

One would have expected that the Javadoc for the gamepad should include similar details about the mapping and use.
Reply With Quote
  #5   Spotlight this post!  
Unread 27-01-2015, 10:59
notmattlythgoe's Avatar
notmattlythgoe notmattlythgoe is offline
Flywheel Police
AKA: Matthew Lythgoe
FRC #2363 (Triple Helix)
Team Role: Mentor
 
Join Date: Feb 2010
Rookie Year: 2009
Location: Newport News, VA
Posts: 1,717
notmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond reputenotmattlythgoe has a reputation beyond repute
Re: Javadocs for F310 Gamepad

Quote:
Originally Posted by DCRich View Post
You treat it just like a joystick, but use the getRawAxis(int axis) method to access each axis.


So all of the methods for direction and magnitude will not work or have no equivalent?

Which controller is axis 1 and which is axis 4? How is X mapped to an axis and how is Y mapped to axis. There are all kinds of buttons on the gamepad, colored, non-colored, triggers, settings, etc. How are these mapped to the joystick? The older Attack joystick has numbers on the buttons and those numbers correspond Javadoc for Joystick.

One would have expected that the Javadoc for the gamepad should include similar details about the mapping and use.
Different controllers are mapped differently. An X-Box controller is mapped differently than a PS4 controller. If you plug the controller into the driver station the setup tab will show you the values of the axis and buttons.

Unless the axis map in a similar way that the basic joystick does the get magnitude methods and the like will not work. I know the left joystick of a PS4 controller maps to the first 2 axis, so that would match up to the getMagnitude() method.

There is no Gamepad class as far as I'm aware, so there is no javadoc.

Last edited by notmattlythgoe : 27-01-2015 at 11:01.
Reply With Quote
  #6   Spotlight this post!  
Unread 27-01-2015, 10:59
RufflesRidge RufflesRidge is offline
Registered User
no team
 
Join Date: Jan 2012
Location: USA
Posts: 989
RufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant future
Re: Javadocs for F310 Gamepad

http://wpilib.screenstepslive.com/s/...1881-joysticks
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 22: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