Author Topic: User Interface - joystick / pad / etc  (Read 7185 times)

Louis L

  • Administrator
  • Hero Member
  • *****
  • Posts: 564
User Interface - joystick / pad / etc
« on: January 19, 2016, 10:37:19 PM »
There are 2 things to consider here.
  • What do we use for controls. In the past we've used 2 joysticks for driving and USB game controller for operating. This year we should consider using a game controller for driving. There are several advantages to using a game controller - they are smaller & lighter to transport, and your playing posture is more flexible. The real question is whether the user interaction with the robot will be better/worse/the same.
  • What is the layout of the controls for the operator. UI layout is very important but in the past it's been at the mercy of the software designer. That's not a good way to design UI. If you've ever bought a product only to ask why it was made to work in such an awkward way, it's probably because the designers never asked real users for their input. For something as simple as an FRC robot, this still applies. Let's do it right.

Louis L

  • Administrator
  • Hero Member
  • *****
  • Posts: 564
Re: User Interface - joystick / pad / etc
« Reply #1 on: January 22, 2016, 02:21:34 PM »
Driver control
  • 2 joysticks - tank drive using independent left & right joysticks
  • Right Joystick Buttons 1 & 3 - Engage auto climber.
  • Right Joystick Buttons 1 & 6 - Cancel auto climber. This function should only be used when there is danger to the robot and it should abort the auto-climb. The strange button sequence is intentional - to prevent an accidental cancellation.
Operator game controller - this is a Microsoft Xbox360 controller. Button numbers are the interface numbers as seen by the software.
  • Button 1 (A) - Activate lower intake roller to bring Boulder from the ground to the Hold. Roller continues to turn for some duration after the Hold sensor says we have a ball. 'Flush' has priority over this button.
  • Button 2 (B) - Activate the Low Shot. This ejects the Bounder between the upper and lower rollers. The rollers continue to turn until some duration after the Hold sensor says there's no ball in the Hold. 'Flush', 'A' and 'X' have priority over this button.
  • Button 3 (X) - Load the Bounder from Hold to the Cradle of the shooter. The Cradle and Hold sensors will indicate the transfer of the Boulder. 'Flush' and 'A' have priority over this button.
  • Button 7 - This button manually shoots the ball. It is the trigger. It operates only when Auto-Shot is disabled and only when the Auto-Shot button is also not pressed at the same time. As a manual function, it does not check the Cradle sensor for the presence of a Boulder.
  • Button 8 - This button is active only when it remains pressed. When pressed, the lower roller reverses direction. If a Boulder is in the Hold, it will hopefully exit the way it came. This function will not check the Hold sensor for a ball. This button is meant as manual intervention in the event of issues with the intake. This button is priority over 'A', 'B', and 'X'
  • Button 9 & 10 - Global Cancel operation. Reset all state machines. This cancels an operation in process that we may want to not do.
« Last Edit: February 18, 2016, 08:28:34 PM by Louis L »

Chris P

  • Guest
Re: User Interface - joystick / pad / etc
« Reply #2 on: January 22, 2016, 08:20:05 PM »
From what I've noticed so far in my experience with driving the robot (which is not much), I think that the traditional 2 joystick design is the best option.

Here's why:
     1) The handheld controller joysticks are much too sensitive (even for amazing gamers like myself ;))
     2) The joysticks are large and easy to manipulate, especially for newer drivers

Overall, I think that our old controller layout works pretty great. The issue I think we should address is the aesthetic look of our drive station.

Here's what I think we should do:
     1) Simply create a new board that we can mount our laptop and joysticks on
     2) Add some cool led lights
     3) Add some dedicated arcade buttons to control stuff

Jason C

  • Guest
Re: User Interface - joystick / pad / etc
« Reply #3 on: January 30, 2016, 03:33:04 PM »
Today I have started laying out the controls for the operator, and have gotten the opinions of some of the past operators.

Louis L

  • Administrator
  • Hero Member
  • *****
  • Posts: 564
Re: User Interface - joystick / pad / etc
« Reply #4 on: February 01, 2016, 10:16:23 PM »
In a few minutes, I will update the UI to reflect the decisions made for the manual shooter and intake controls. This will also include the behavior of the controls.

Louis L

  • Administrator
  • Hero Member
  • *****
  • Posts: 564
Re: User Interface - joystick / pad / etc
« Reply #5 on: February 14, 2016, 10:20:35 AM »
Removed shot strength / direction adjustment via 'hat'

Louis L

  • Administrator
  • Hero Member
  • *****
  • Posts: 564
Re: User Interface - joystick / pad / etc
« Reply #6 on: February 14, 2016, 02:03:32 PM »
We had a game play/strategy meeting yesterday. From that discussion, we added some buttons. Here's the latest info.

Driver joystick controls
  • 2 joysticks - tank drive using independent left & right joysticks
  • Right Joystick Buttons 1 & 3 - Engage auto climber.
  • Right Joystick Buttons 1 & 6 - Cancel auto climber. This function should only be used when there is danger to the robot and it should abort the auto-climb. The strange button sequence is intentional - to prevent an accidental cancellation.
  • Left Joystick Button 6 - swap front and back on robot. Invoke rear-facing camera. Also swap left and right wheel and direction. This lets the driver drive as if the back of the robot is now the front. This button is a toggle switch.
Operator game controller - this is a Microsoft Xbox360 controller. Button numbers are the interface numbers as seen by the software.
  • Button 1 (A) - Activate lower intake roller to bring Boulder from the ground to the Hold. Roller continues to turn for some duration after the Hold sensor says we have a ball. 'Flush' has priority over this button.
  • Button 2 (B) - Activate the Low Shot. This ejects the Bounder between the upper and lower rollers. The rollers continue to turn until some duration after the Hold sensor says there's no ball in the Hold. 'Flush', 'A' and 'X' have priority over this button.
  • Button 3 (X) - Load the Bounder from Hold to the Cradle of the shooter. The Cradle and Hold sensors will indicate the transfer of the Boulder. 'Flush' and 'A' have priority over this button.
  • Button 5 (left trigger) - Lower Shooter. This primes the shooter to accept a Boulder. If we're already lowered, then don't do anything. A limit switch tells the software when to stop the motor. Pick a motor speed that will give the software enough time to respond to the switch.
  • Button 6 (right trigger) - Manual Fire. Shoots the Boulder. Do not check for Boulder but do check that the shooting winch is down.
  • Button 7. Do-it-all. This button performs functions Button 5, Button 3, and Button 6 in a row. It can bypass Button 5 and Button 3 functionality if the shooter is down and ball is already in the cradle respectively.
  • Button 8 - This button is active only when it remains pressed. When pressed, the lower roller reverses direction. If a Boulder is in the Hold, it will hopefully exit the way it came. This function will not check the Hold sensor for a ball. This button is meant as manual intervention in the event of issues with the intake.
  • Buttons 9 & 10 - Cancel operation. For emergency use only; this resets the state machines that operate various functions.
We need to make sure that the user is not allowed to press more than one function button at a time. If more than one is pressed a priority ordering is enforced. Caveat - the "flush" operation is different from the others. All buttons are latching (press-once) but "flush" is non-latching (press-and-hold) - keep this in mind for implementation.  Here is the ordering from highest to lowest.
  • Buttons 9 & 10 (Cancel)
  • Button 7 (Do-it-all)
  • Button 6 (Manual shot)
  • Button 5 (lower shooter)
  • Button 3 (move ball from Hold to Cradle
  • Button 8 (Flush)
  • Button 2 (low shot)
  • Button 1 (intake ball to Hold)
« Last Edit: February 25, 2016, 01:32:59 PM by Louis L »

Louis L

  • Administrator
  • Hero Member
  • *****
  • Posts: 564
Re: User Interface - joystick / pad / etc
« Reply #7 on: February 25, 2016, 01:33:59 PM »
Added left joystick button 6 to swap front/rear of robot. This had been game controller Y (button 4) but it made more sense to give it to the driver instead of the operator.