Programming v5 please help

Hmmmmm, I take that back. I was trying to reinstall RobotC, but the download is blocked by the school’s wifi. I’ll do it after school today.

ok ill be on periodicaly tonight

Wait. Are you trying to program V5 or Cortex?

V5:

Cortex:

In the event you are using cortex, this code should work as what you ALREADY have completed. I did not do the new stuff you asked for.

#pragma config(Motor,  port2,           Left1,         tmotorVex393_MC29, openLoop, reversed)
#pragma config(Motor,  port3,           Left2,         tmotorVex393_MC29, openLoop, reversed)
#pragma config(Motor,  port4,           Right1,        tmotorVex393_MC29, openLoop)
#pragma config(Motor,  port5,           Right2,        tmotorVex393_MC29, openLoop)
#pragma config(Motor,  port6,           Claw,          tmotorVex393_MC29, openLoop)
#pragma config(Motor,  port7,           Arm,           tmotorVex393_MC29, openLoop)
//*!!Code automatically generated by 'ROBOTC' configuration wizard               !!*//

task main()
{
	while(true){
		motor[Left1]= vexRT(Ch3); //Takes the value from the joystick, on a scale from -127 to 127, and sets the Left1 motor to that value.
		motor[Left2]= vexRT(Ch3); //Motors are on the same -127 to 127 scale as the joysticks are
		motor[Right1]= vexRT(Ch2); //Same for the 3 other motors, but reversed for the Right side
		motor[Right2]= vexRT(Ch2);
	}
}

This should help get you started. Try yourself to complete the remainder of your code. You will need to use at least 2 if/else if/else statements, and take the value of a digital controller button.

If you have a question, feel free to ask it, but I will NOT give you the answers. The code above only matches what you said you had yet completed.

2 Likes

the cortex thank you

1 Like

thank you so much i really appreciate it

1 Like

i am receiving an error message when trying to download my program to the robot any suggestions

Could you post screenshots from your computer and pictures of your robot/download cable attached to it?

1 Like

that is the error message

that is it connected to the computer

Could you show a picture of the cable plugged into the controller/brain?

1 Like

connected to the controller this is how i was told to do it one that part in the controller and the USB end into the computer

Is the cortex on? Is the controller on? Is the controller paired to the cortex?

1 Like

yes, yes and yes, i had one of our best programmers try to help he changed the com ports connected everything everyway possible and even hit the configure pin

First follow the instructions on the error message, then:
I would recommend you to change the usb to a usb slot that the computer has, not a mere extension cord. Second of all make sure that the USB is plugged into the orange adapter and its snugly in place. If both doesnt work, click “firmware download” on the top of the tab and see if that will connect and reinstall the firmware as it may be a firmware issue.

What’s the number of the COM port it’s installing itself as in Windows? i.e. COM1, COM8, etc.?

1 Like

com port 5
i believe

I agree with Connor. Definitely use the actual USB port on your computer, not a USB hub.

2 Likes

i put the usb directly into the computer and uploaded it but now the robot is going crazy and moving on its own im not quite sure why