pxt-ev3/libs/ev3/startup.ts
Peli de Halleux d128dad3dc
Startup sequence (#696)
* set light, play sound, show eyes, wait, clear screen, light

* play a sound, turn on lights
2018-06-20 13:32:00 -07:00

10 lines
344 B
TypeScript

// This is the last thing executed before user code
// We pause for 100ms to give time to read sensor values, so they work in on_start block
pause(100)
// pulse green, play startup sound, turn off light
brick.setStatusLight(StatusLight.GreenPulse);
music.playSoundEffectUntilDone(sounds.systemStartUp);
brick.setStatusLight(StatusLight.Off);