Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,15 @@ public AbstractOperatorInterface() {
public abstract LogitechF310 driverJoystick();

public abstract LogitechF310 gunnerJoystick();

public LogitechF310 getJoystick(String joystickName) {
switch (joystickName) {
case "driver":
return driverJoystick();
case "gunner":
return gunnerJoystick();
default:
throw new IllegalArgumentException("Invalid joystick '" + joystickName + "' requested");
}
}
}