Timeout command not working!

Can anyone help with the vex code blocks?
The driving motors LMotor and RMotor should stop spinning after 2 seconds, and go to next command. In my understanding, that is how timeout command works. However, it just not working even I tried many ways.
Thanks in advance.

1 Like

Timeout is only applicable to motor commands that block, that is commands like spinFor that have the optional “and don’t wait” parameter. So it depends on how you are using the motor commands inside the GoStraight block.

4 Likes

Thank you for your reply.
Do you mean that I need to put Timeout inside of GoStraight command?
I tried this way, but it still not working.
Am I understanding right?

I mean that the timeout has no meaning for commands like “ set velocity” and “spin”, only commands like “spin for”.

1 Like

Thank you so much for your help. One of my kid figured it out. Have a blessed day.