I am new to robot mesh
How do i solve this problem on my code
The API is here Vex IQ C++ API
Here is the code so you can modify it
// VEX IQ C++ Project
#include “vex.h”
using namespace vex;
//#region config_globals
vex::brain Brain;
vex::motor driveRightFront(vex::PORT1);
vex::motor driveRightBack(vex::PORT2);
vex::motor driveLeftFront(vex::PORT5);
vex::motor driveLeftBack(vex::PORT6);
//#endregion config_globals
//HELPER FUNCTIONS
void setDrive(int left, int right) {
driveLeftBack = left;
driveLeftFront = left;
driveRightBack = right;
driveRightFront = right;
}
void resetDriveEncoders() {
vex::motor::resetRotation(vex::motor driveRightFront);
vex::motor::resetRotation(driveRightBack);
vex::motor::resetRotation(driveLeftFront);
vex::motor::resetRotation(driveRightFront);
}
double avgDriveEncoderValue() {
return (fabs(float vex::motor::rotation(driveRightFronts)) +
fabs(float vex::motor::rotation(driveRightBack)) +
fabs(float vex::motor::rotation(driveLeftFront)) +
fabs(float vex::motor::rotation(driveRightFront)) / 4;