Autonomous Potentiometer

We are having fun with RobotC programming, stumped on one item: “We would like our Potentiometer to run motors while in autonomous control” Any simple ideas to make this work?

I don’t believe that pots can function as a cortex and send motor power values to the motors, but what you could do is something like

 
while (SensorValue[Pot] > 0) {
        //run motors
}

so the value of the pot can control the movement of the motors.

Definitely not… What would power the motor?

In a custom circuit it would be pretty trivial to do that, but yeah, not really viable in vex. I’m guessing the op wanted something in code like you posted anyway. or motor[1] = sensorValue(pot);