-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathAutonomous Test.c
37 lines (34 loc) · 1.18 KB
/
Autonomous Test.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#pragma config(Motor, port3, right_wheels, tmotorVex393HighSpeed_MC29, openLoop)
#pragma config(Motor, port4, left_wheels, tmotorVex393HighSpeed_MC29, openLoop)
#pragma config(Motor, port5, arm1, tmotorVex393HighSpeed_MC29, openLoop)
#pragma config(Motor, port6, arm2, tmotorVex393HighSpeed_MC29, openLoop, reversed)
#pragma config(Motor, port7, arm3, tmotorVex393HighSpeed_MC29, openLoop)
#pragma config(Motor, port8, arm4, tmotorVex393HighSpeed_MC29, openLoop, reversed)
#pragma config(Motor, port9, arm5, tmotorVex393HighSpeed_MC29, openLoop)
//*!!Code automatically generated by 'ROBOTC' configuration wizard !!*//
task main()
{
while(true){
if(vexRT[Btn7U] == 1){
break;
wait1Msec(1);
}
}
motor[left_wheels] = -22;
motor[right_wheels] = 22;
wait1Msec(8000);
motor[left_wheels] = 0;
motor[right_wheels] = 0;
wait1Msec(300);
motor[arm1] = -100;
motor[arm2] = -100;
motor[arm3] = -100;
motor[arm4] = -100;
motor[arm5] = -100;
wait1Msec(2000);
motor[arm1] = 0;
motor[arm2] = 0;
motor[arm3] = 0;
motor[arm4] = 0;
motor[arm5] = 0;
}