I am trying to code my X - Drive base with voltage control… I’m not sure if I’m doing it right or wrong. These errors keep coming up, IDK what to do anymore.
#include "main.h"
// Helper Functions
// Driver Control Functions
void setDrive() {
int leftJoystickX = controller.get_analog (pros::E_CONTROLLER_ANALOG_X);
int leftJoystickY = controller.get_analog (pros::E_CONTROLLER_ANALOG_Y);
int rightJoystickX = controller.get_analog (pros::E_CONTROLLER_ANALOG_X);
int lateral = leftJoystickX(1, 4);
int linear = leftJoystickY(1, 3);
int rotation = rightJoystickX(1, 1);
// Y component, X component, Rotation
topLeftDrive.motorSet( -linear - lateral - rotation);
topRightDrive.motorSet( linear - lateral - rotation);
backLeftDrive.motorSet( linear + lateral - rotation);
backRightDrive.motorSet( -linear + lateral - rotation);
}
// Autonomous Functions
Here are the errors