How to code the robot to move in PROS

Simple as that. What function do I put it under, what should I write, please help, videos aren’t helping.

I just want to get it to move forward and backwards.

You need to write your code in the opcontrol() function.

Look at the Programming the Clawbot section in the PROS API. It goes through the basics of coding a clawbot, including the drivetrain, and is a great start to learning PROS.

Also, pros::Motors has a move() method that takes in a value from -127 to 127.
Just take in the value of your controller axis and put it as a parameter for the move() method.

1 Like

I know you said that videos haven’t been helping, however this youtube series put together by 4411S is great in explaining general PROS structure and eventually talks about specifically drive functions. I highly recommend checking it out if you haven’t already.

1 Like