pxt-ev3/docs/maker/security-gadget.md
2017-10-26 23:58:34 -07:00

247 B

Security Gadget

This program will activate an alarm when an object is lifted from the Touch Sensor.

input.touchSensor1.onEvent(TouchSensorEvent.Released, function () {
    music.playSoundUntilDone(music.sounds(Sounds.PowerUp))
})