Timer in code studio?


#1

Is there a timer function in code studio? Thanks! JR


#2

You might need to bust out into the free play mode of app lab to see it - but in the “Control” toolbox you’ll see a function called “timedLoop”. That’s probably what you want.

But there are two kinds of timers. A “timeout” which waits some amount of time before calling a function - does this once. Or the “timedLoop” which repeatedly calls a function based on some interval. You can stop it with stopTimedLoop()

Students can still use these functions in a code studio level even if they are not present in the toolbox.

Does that help?

–B


#3

Perfect, thanks… JR