Navigasi Materi

Makecode Micro:bit 5# - Digital Doorbell

🎵 MakeCode micro:bit Lab

Simulator 05 — Digital Doorbell
Bel Pintu Digital — Button & Sound
🧠 Learning Goal / Tujuan Pembelajaran

🇬🇧 Learn how a button can trigger a sound using an event-based program.

🇮🇩 Memahami bagaimana sebuah tombol dapat memicu suara menggunakan program berbasis event.

Button Pressed → Play Sound

🖥️ Simulator

🔔
)))
Press the doorbell / Tekan bel
Doorbell Status / Status Bel
🔕 READY
Tekan RUN, kemudian tekan tombol bel.

🧩 Program

English:
When button A is pressed, play a doorbell melody.

Indonesia:
Ketika tombol A ditekan, mainkan melodi bel pintu.

on button A pressed
play melody
pause 1 second
show icon 🔔
💡 Think about it!

The program waits for an event. When the button is pressed, the program responds immediately.

Program menunggu sebuah event. Ketika tombol ditekan, program langsung memberikan respons.

🎯 Practice — Latihan

What should happen when button A is pressed?

Apa yang terjadi ketika tombol A ditekan?

🏆 Challenges — Tantangan

Challenge 1 — Ring the Doorbell

Press RUN, then press the purple doorbell button.

Tekan RUN, kemudian tekan tombol bel berwarna ungu.

Challenge belum selesai.

Challenge 2 — Find the Event

Which block tells the micro:bit to wait for a button press?

Blok mana yang membuat micro:bit menunggu tombol ditekan?

Challenge 3 — Change the Button

Suppose the doorbell should work when button B is pressed. Which event should you use?

Jika bel harus berbunyi ketika tombol B ditekan, event mana yang digunakan?

🔌🎵

Now Try It with a Real micro:bit!

English
You've practiced a digital doorbell. Now create your own doorbell using Microsoft MakeCode.

Indonesia
Kamu sudah berlatih membuat bel pintu digital. Sekarang buat bel pintumu sendiri menggunakan Microsoft MakeCode.

🔔 Your Mission
  1. Open Microsoft MakeCode for micro:bit.
  2. Create a new project.
  3. Choose an event such as on button A pressed.
  4. Add a music or melody block.
  5. Test the doorbell in the MakeCode simulator.
  6. Download the program to your real micro:bit.
🚀 Open Microsoft MakeCode

Official Microsoft MakeCode for micro:bit

Kelas-Matematika Micro:bit Lab
Learn → Simulate → Think → Create