Autonomous Feature without Orange USB Cable

How do I trigger the autonomous feature without having the robot connected to the laptop?

We were hoping to have a bump sensor to start the program but when disconnect it from the laptop it stops the program.

We are doing a non-vex competition and we are trying to figure out how to trigger the program (we have the VEX EDR Legacy programming and mechatronic kits).

We’ve been using Mindstorm EV3s and Botball robotics before and now we feel like we aren’t sure what to do.

Any help would be great!

Could you post some relevant code? what software do you use?

I’m assuming you are using ROBOTC. Go to the Robot menu then VEX Cortex Communication Mode. Choose “USB only”.
If you have a different mode selected, the robot will try to connect to VEXnet first (i.e. link with a paired controller). “VEXnet or USB” mode will timeout eventually and run your code (I think) but Competition Mode will need VEXnet to connect before it will do anything.


Agree w/ calvc01 if you do not have a (VEXNet) controller. You may also want to forgo using the competition template.

You should be able to start you code by function from a button. Usually this is in a infinite loop within main()

         if button .....  //this would be your code - (sorry can't remember RobotC syntax)
       wait1Ms(10);    //a pause to prevent CPU hogging
  }//end while
}//end main

Good luck!!!

My students are not using RobotC. We’re using the VEX Coding Studio (we were originally trying to do it on Macs, as we are a Mac school, but it didn’t work so we’ve got PCs but they have already become familiar with the VCS).

We have the microcontrollers. But didn’t know how to run the program with the controllers. We can plug the USB into the bot and it will run the program the kids created. Our problem is if we unplug the USB, it won’t run the program. It’s like the brain doesn’t store code, it has to be connected to the computer to run the code.

I’m a bit confused- are you using the legacy Cortex system (which generally downloads via an orange male-male USB A cable) or the new V5 system (which comes with a standard micro-usb cable)? VCS does not work on Cortex, so I would assume you are using V5, but your original question leads me to believe you are using the old system.

1 Like

Hi Zach,

My students are using the legacy Cortex system. We’re using RobotC now but when we unplug the USB cable (the orange male-male) the program stops.

We want to run it autonomously without being plugged by the USB or the microcontroller.

Do this then the robot should run the code when it is unplugged from the computer after you turn the cortex off then back on. You can also write code to activate when a button is pressed like shown above. Just put the code you want to run inside the if statement.