> For the complete documentation index, see [llms.txt](https://sumokit.buildingblockrobotics.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://sumokit.buildingblockrobotics.com/tips/arduino/adjust-motor-direction.md).

# Adjust Motor Direction

If you find that the motors are spinning in the wrong direction, take a look at the code in Sumo.h and update the following code:

```cpp

 Motor _motor1 = Motor(MOTOR_1B,MOTOR_1A);
 Motor _motor2 = Motor(MOTOR_2A,MOTOR_2B);
```

Swapping the pins around will make the motor spin in the opposite direction.
