Hello my team and I have found a problem. We have a x-drive and were trying to program it to move during driver control. We have tried many programs to try to move it. Out of all our attempts only one wheel moves. It is in port one. So in our failed attempts we had asked our other teams at our school. They have the same program and x-drives. Except theirs works. We have tested the motor controllers and motors they work. So, we decided to get a new cortex but it too has the same problem. Please help us. And Thank you. Here is our code:
#pragma config(Motor, port1, leftfront, tmotorVex393_HBridge, openLoop)
#pragma config(Motor, port7, rightfront, tmotorVex393_MC29, openLoop)
#pragma config(Motor, port8, leftrear, tmotorVex393_MC29, openLoop)
#pragma config(Motor, port9, rightrear, tmotorVex393_MC29, openLoop)
//!!Code automatically generated by ‘ROBOTC’ configuration wizard !!//
task main()
{
//x-drive
while (1==1)
motor[leftfront] = vexRT[Ch3] + vexRT[Ch1] - vexRT[Ch4];
motor[rightfront] = vexRT[Ch3] - vexRT[Ch1] + vexRT[Ch4];
motor[leftrear] = vexRT[Ch3] + vexRT[Ch1] + vexRT[Ch4];
motor[rightrear] = vexRT[Ch3] - vexRT[Ch1] - vexRT[Ch4];
}