This project will teach you how to make a Xmas door chime that will play Jingle Bells whenever a door is opened. A great way to get into the festive season!
You’ll learn how to use the accelerometer on the micro:bit and the music modules to create and trigger a tune.

 

1. Programme the micro:bit

We’ll be using Makecode to programme the micro:bit.

micro:bit xmas chime

  • Connect the micro:bit to your computer using the micro USB cable.
  • Upload the code to the micro:bit.

 

2. Set up the chime.

  • Disconnect the micro:bit from your computer and power it with the battery pack.
  • Attach the battery pack to the micro:bit using some Blu tack.

microbit-and-battery-pack

  • Place it on the door. We used Blu Tack but you can also use double-sided tape etc..

microbit-xmas-chime

That’s it! You should now have a festive moment every time you open or close the door.

 

3. Do more

  • You can adjust the sensitivity of the accelerometer by changing the number on the if statement of the code. The closer the number is to 1024 the more sensitive the accelerometer trigger will be.
  • You can load your own tune by entering the appropriate notes.

 

You can find more information and resources for your micro:bit here: https://microbit.org/

 

Like what you read? Why not show your appreciation by giving some love.

From a quick tap to smashing that love button and show how much you enjoyed this project.

Privacy

Our website uses cookies and similar technologies to provide you with a better service while searching or placing an order, for analytical purposes and to personalise our advertising. You can change your cookie settings by reading our cookie policy. Otherwise, we’ll assume you’re OK with our use of cookies.

Location

Please select an option to see content specific to your location and shop online.

Browse the US site