10 likes | 118 Views
HID Joystick Control for K10 Series Rover Gregg Carpenter, University of Vermont, Burlington Vermont Mentor: Dr. Terry Fong, Intelligent Robotics Group, NASA Ames. BACKGROUND:
E N D
HID Joystick Control for K10 Series Rover Gregg Carpenter, University of Vermont, Burlington Vermont Mentor: Dr. Terry Fong, Intelligent Robotics Group, NASA Ames BACKGROUND: In order to more precisely control the position and orientation of the K10 series rover during field testing, a dynamic Human Interface Device, or HID, was implemented using a Universal Serial Bus, or USB, compliant joystick. The motivation behind this interface is that it could be easily utilized in the field either connected directly to the local “brain” of the rover, or connected via a base control terminal on the wireless communications network at the test site, using a standard protocol which is well supported on most operating system platforms; thus being consistent with the decision to maintain platform portability for the development source code instruction set for the K10 series. METHODS: In order to implement the software client for the HID, the software language C++ was used to develop the source code instruction set. The Simple Direct media Layer, or SDL, libraries were utilized as they offered both USB and joystick functionalities in an easy to use tool set for the C++ language. Mappings were developed in order to translate the movements of the joystick, by the operator, to software commands which interfaced with the K10 locomotion control software. START USB Joystick NO JOYSTICK? END YES LAST_TRIGGER = FALSE CHECK FOR PRESSED BUTTONS & ASSIGN BUTTON STATES INCREMENT COMMAND COUNTER COMMAND COUNTER = ISSUE COUNT? YES TRIGGER PRESSED? YES K10 “Blue” NO NO CURVATURE = X3 VELOCITY = Y*(LOW_MAX+THROTTLE*HIGH_MAX) YES Two distinct modes of operation were devised and executed for joystick control: point-turn mode, in which the rover rotates in-place either clockwise or counter clockwise, and continuous drive mode, in which the rover moves either forward or backward while being able to execute a turn in either direction. Both modes of operation utilized a unique mapping of the joystick motion, while using existent software, already utilized by the K10 navigation and locomotion systems, to execute the joystick commands. LAST_TRIGGER = TRUE & TRIGGER = FALSE? ISSUE STOP COMMAND ISSUE VELOCITY & CURVATURE COMMANDS NO EMERGENCY STOP BUTTON PRESSED? YES ISSUE EMERGENCY STOP COMMAND NO POINT_TURN BUTTON PRESSED? YES STOP COMMAND ISSUED NO RESULTS: The result of the project has been a robust joystick client for the K10 rover that has native support for three separate specific HID USB joysticks and generic support for any USB joystick with at least basic functionality. This client has been used successfully both for the control, and testing, of the rover, as well as its locomotion control subsystems, at both the “marscape” test site at NASA Ames research center, and at the Haughton Crater field survey site in Devon Island, Nunavut, in the Canadian arctic. X=0 & POINT_TURN BUTTON PRESSED> TRIGGER PRESSED? YES LAST_TRIGGER =TRUE YES NO NO NO POINT_TURN BUTTON PRESSED? LAST_TRIGGER = FALSE YES X>0? YES POINT_TURN RIGHT COMMAND NO YES X>0? CONCLUSIONS: The usefulness of the joystick interface was most apparent in its ability to provide high-speed, real-time testing of the locomotor control and coordination of motor commands in a way that was more dynamic and flexible than the commands that would be sent from the rovers internal navigation software. The ability to also maneuver easily and quickly in test environments, in cases where current navigation software would be impractical, also played to the strengths of the joystick HID. POINT_TURN LEFT COMMAND NO YES NO STOP COMMAND ISSUED X>0? ACKNOWLEDGEMENTS: Special thanks to Terry Fong, Matt Deans, Hans Utz, and Joel Croteau, as well as the Exploration Systems Mission Directorate, Maricela Varma, the Education Associates Office, and the entire Intelligent Robotics Group and The Vermont Space Grant Consortium.