Lesson 8: Controller
We are going to connect a controller to our robot. There are many ways to do this, but we will write our own custom code so that we can make each setting exactly what we want.
Add your controller in the DEVICES menu.
Click DONE.
There are three ways that we can set up our controller:
- Tank Control
- Arcade Control
- Split Arcade Control
Each design has advantages and disadvantages.
TANK DRIVE
This design allows the left joystick to control the left side of the chassis and the right joystick to control the right side of the chassis. Gamers may struggle, but this format can provide more turning options than an Arcade Drive.
PROS: Better control, more turning options
CONS: Always requires both joysticks, less intuitive for gamers
ARCADE DRIVE
This is the most like a video game controller. One joystick will control both the forward-backward AND the turning movement. (You can program either the left or the right stick.)
PROS: Smooth movement, only uses one stick
CONS: Less motor control, less maneuverability
SPLIT ARCADE DRIVE
This takes the functions of an Arcade Drive and splits it over both sticks. The left stick moves forward-backward while the right stick turns left and right. (You can reverse the sides if you want.)
PROS: Smooth movement
CONS: Always requires both joysticks
Task 1:
Create a program for each of the three types of controllers. Test them out on the field to see which one you prefer.