For people who are starting to get into vex robotics

This website is to help you get started with vex robotis coding by giving you a template that will work for the robot.

This gives you the code needed for the robot and the places you will need to get this on your robot are the offical extensions for vex robotics like in VS code or Vexcode V5

The Quiz

The drivetrain

What is the number of motors for the drivetrain?


For each left motor add a motor

For each right motor add a motor

Other Robot Motors

For each motor you have add another by the ports that they are in eg port motor 16 add 16

Adding controls

The controller button, The motor that spins, the direction the motor spins

This is the code

In robot-config.cpp

#inclue "vex.h"

using namespace vex;

using signature = vision::signature;

using code = vision::code;

brain Brain;

controller Controller1 = controller(primary);

motor_group LeftDriveSmart = motor_group(

);

motor_group RightDriveSmart = motor_group(

);

drivetrain Drivetrain = drivetrain(LeftDriveSmart, RightDriveSmart, 319.19, 295, 40, mm, 1);

bool RemoteControlCodeEnabled = true;

bool DrivetrainLNeedsToBeStopped_Controller1 = true;

bool DrivetrainRNeedsToBeStopped_Controller1 = true;

int rc_auto_loop_function_Controller1() {

while(true) {

    if(RemoteControlCodeEnabled) {

   }

 wait(20, msec);

 }

 return 0;

}

In robot-config.h

using namespace vex;

extern brain Brain;

extern controller Contoller1;

extern drivetrain Drivetrain;

void vexcodeInit(void);