View Single Post
  #4   Spotlight this post!  
Unread 10-04-2005, 09:42
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: Dual Joystick Code

Direct mapping of joystick to motor is the easiest and most intuitive way to use two joysticks to control two motors. This year's TechnoKat robot does it the long way around, though, taking the average of the two sticks to control an internal "velocity" value, with the sticks' difference becoming a "turn" value. It essentially computes the equivalent of a single joystick. The output code remixes the velocity and turn values into two motor control numbers.

This complexity has its rewards. It makes navigating under autonomous control a wee bit simpler to implement, and it provides a straightforward way to implement speed-sensitive steering if desired. There are deadbands applied to the computed values, so it also theoretically makes driving straight at high speed slightly easier.