Gyro Heading Correction in Operator Mode

If you set up 4 wheel tank drive in Operator Mode as shown:

void OperatorControl(void)
{

Arcade4(PORT_1, X_AXIS, PORT_1, Y_AXIS, 0, 2, 1, 3, 0, 0, 0, 0); 

}

Is there (1) anymore that you have to do if you are just trying to simply drive the robot with one joystick as defined?,(2) can you embed the gyro heading correction?, (3) and is there more information or guidance that you can give for pneumatic control. Thank you

That’s close to it. Each time Arcard4 (or any of those functions) is called it gets one set of joystick data and passes it to the motors. So you need to put your code into a loop to repeatedly read the joysticks and set the motors.

void OperatorControl(void)
{
     while (1)
     {
           Arcade4(...);
           // put other motor/OI control code here
     }
}

On the gyro subject, it depends on exactly what you want the robot to do. This code is driving based on the joystick. What sort of heading correction did you have in mind?

And last, pneumatics is actually control is not too bad. Look at the InitPressureSwitch function. It will automatically turn the compressor on and off based on the currrent pressure value from the pressure sensor.

For operating solonoids, look at the SetRelay function.

These are all described in the documentation on the web site.