Delay in programming while using "broadcast" block

Hello,

I’m having a problem with a delay when running my programming and was hoping to get some help from someone here.

I’m currently using a class set of the VEX IQ robots, where students run their built programs to complete a maze with multiple challenges. I taught my students about the “broadcast” block and how they could use it when completing each challenge within the program.

Unfortunately, when running the program, there seems to be a long delay when using the “broadcast” option. The delay seems to occur whenever one part of the program is finished and the broadcast function is activated to begin the next part. Am I doing something wrong here to cause a delay?

I’ve included two different pics of my program, and a screen shot of the software showing it’s up to date.

Thanks in advance for your response,





Broadcast delay.JPG

Broadcast delay 2.JPG

I suspect that the delay is occurring before the broadcast. The spin command is trying to move the claw motor to a specific position, but probably isn’t getting all the way there. The delay occurs as it continues to try to close, until it finally times out. Perhaps you are trying to move the claw past the fully closed position.

You could test this by using a “spin Rev” command (replacing the “spin Rev 90 deg”) and waiting for a couple seconds, then stopping the motor, and then issuing the broadcast. You would have to adjust the wait time to get the claw fully closed.

jzeilenga,

I am sure that jrp62 is correct. ModKit has a “Set Timeout to ___ Seconds” block, however all of the testing my teams have done has found that the timeout value is always 5 seconds (despite that block being set to a shorter time).

If you really want to rotate a motor to a certain degrees of rotation, and can not use a “Wait” time delay as jrp62 suggested, you can do this:

Paul