How to make Alex go faster?

I’m struggling to make the encoder motors spin fast enough for my intended application. I’m a beginner in robotics and have made attempts to modify my local copy of the pi-top-Python-SDK ( MAX_DC_MOTOR_RPM in EncoderMotor class ), to speed up the motor, but to no avail.

What is the max speed one can expect the pi-top “Alex” build to travel at, assuming no additional load?
How can I modify the SDK code, or my device safely to achieve that maximum speed?

The theoretical maximum RPM of the DC motor is 6000 RPM, however with the gearbox attached and all the associated losses this brings the maximum will be lower than this. We set it to 4800 RPM to ensure that one motor didn’t become torque limited earlier than another motor, which would cause one to go faster than the other at max speed.

The gear ratio is fixed at 41.8 which means that the absolute max wheel RPM is 6000 / 41.8 = 143.5 - if you don’t care about different motors peaking at different speeds you can change MAX_DC_MOTOR_RPM to 6000 but it’s not going to increase your speed that much. Example code for driving forward at max speed:

from pitop import DriveController
drive = DriveController(left_motor_port="M3", right_motor_port="M0")

drive.forward(1)  # this will set the wheel's RPM to MAX_DC_MOTOR_RPM / 41.8

You can increase MAX_DC_MOTOR_RPM but you’ll notice eventualy that instead of driving forward the robot will start veering off to one side due to the motor imbalance.

If you want a faster robot put larger wheels on it - this will get you more forward speed per wheel rotation assuming the motor torque can handle it. I’ve tested 100mm diameter wheels and found noticable speed improvements :grin:

Thread with photos of the 100mm mecanum wheels and how to build:

@duwudi Thanks so much for this clear break down. I will try with bigger wheels!
I had read the compatible motors thread prior and investigated the n20 gear motor prior to asking here, but failed to make the connection. :see_no_evil:

1 Like

No worries! What are you planning on building by the way?