Should this code work as designed?

Hello,
Assuming that I understood the “Set Speed” blockly instruction, the following instructions should move the XRP 10 cm in one second:

Set Speed Left 10 cm/s Right 10 cm/s
Sleep 1

I tried the code with a couple of XRP betas and one XRP V1.0 but the XRPs move more than 40+ cm and before stopping.

Am I doing something wrong or not understanding the instruction?
Thanks.

I haven’t tested your code. My first thought is to add the following block to your program:
Set Speed Left 0 cm/s Right 0 cm/s

There is no instruction to turn off the drive motors. Yes, you set the speed and yes you have it stop processing for 1 second. After that one second is complete, there is no new instruction for the drive motors. They continue using their last instruction (speed 10 cm/s).

By adding the new block, after the 1 second sleep, the motors are commanded to stop moving. I predict this will give you the 10 cm drive that you’re expecting.

Hello,
Thanks for your great suggestion. I figured that would solve the problem. Unfortunately, it didn’t help. Here are the instructions:

I tried the instructions on both XRP Beta and the new XRP V1 and they behave the same, the robot goes almost 35 cm and stops.
Thanks.