This describes the simplest way of controlling the motors connected to the cortex, the equivalent of the motor[] intrinsic in ROBOTC or the SetMotor function in EasyC. For more comprehensive motor control see the SetMotor function that is part of the smartMotor optional code.
Motors are controlled using vexMotorSet
vexMotorSet( int16_t index, int16_t value )
The motor addressed by index is immediately set to the speed contained in the variable value.
index should be in the range 0 through 9, shortcuts are defined in the enumerated type tVexMotor
The current motor speed can be found by using
This returbs the current motor speed in the range -127 to +127.