This is a Makey Makey virtual example of an alarm that will sound only while the up arrow is pressed. Check out this class on designing your own alarms with Makey Makey! https://makeymakey.com/blogs/how-to-instructions/maker-class-lesson-three-alarms
I initially created this to help a teacher with the code for music that only plays while a key is pressed. As part of the Getting Unstuck Challenge, I'm adding broadcast to show how you can use one block to broadcast a message to multiple sprites. I want to thank my 11 YO for the door alarm idea (she shared her idea with me on a Jam board) and Jay Silver for the light up animation! I am also inspired by Ali Adil Ali to include a virtual Makey Makey into my project to share how you would connect it!