Navigasi Materi

Makecode Micro:bit 3# - Kipas Otomatis

🌡️ MakeCode micro:bit Lab

Simulator 03 — Automatic Fan
Kipas Otomatis Berdasarkan Suhu
🧠 Learning Goal / Tujuan Pembelajaran

🇬🇧 Learn how a micro:bit can read temperature and automatically control an output.

🇮🇩 Memahami bagaimana micro:bit membaca suhu dan secara otomatis mengendalikan sebuah output.

Temperature → Decision → Fan

🖥️ Simulator

☁️
🌀
Temperature / Suhu
25°C
0°C 20°C 40°C
😊 COMFORTABLE
Fan Threshold / Batas Kipas: 30°C
Tekan RUN, lalu atur suhu.

🧩 Program

English:
If the temperature is above 30°C, turn the fan ON. Otherwise, turn the fan OFF.

Indonesia:
Jika suhu lebih dari 30°C, nyalakan kipas. Jika tidak, matikan kipas.

forever
if temperature > 30
set FAN to ON
else
set FAN to OFF
🌡️ Think about it!

The micro:bit does not need someone to press a button. It can read the temperature and make a decision automatically.

Micro:bit tidak perlu menunggu seseorang menekan tombol. Micro:bit dapat membaca suhu dan mengambil keputusan secara otomatis.

🎯 Practice — Latihan

The temperature is 35°C. What should the automatic fan do?

Jika suhu adalah 35°C, apa yang harus dilakukan kipas otomatis?

🏆 Challenges — Tantangan

Challenge 1 — Make the Fan Turn ON

Press RUN and set the temperature above 30°C. Observe the fan.

Tekan RUN dan atur suhu di atas 30°C. Amati kipas.

Challenge belum selesai.

Challenge 2 — Find the Condition

Which condition makes the fan turn ON?

Kondisi mana yang membuat kipas menyala?

Challenge 3 — Change the Threshold

Suppose the fan should turn ON when the temperature is above 35°C. What threshold should you use?

Jika kipas harus menyala ketika suhu lebih dari 35°C, berapa threshold yang digunakan?

🔌🌡️

Now Try It with a Real micro:bit!

English
You've practiced with the simulator. Now create an automatic temperature-controlled fan using the real Microsoft MakeCode editor.

Indonesia
Kamu sudah berlatih menggunakan simulator. Sekarang buat kipas otomatis berdasarkan suhu menggunakan Microsoft MakeCode yang sesungguhnya.

🌡️ Your Mission
  1. Open Microsoft MakeCode for micro:bit.
  2. Create a new project.
  3. Read the temperature using the micro:bit.
  4. Use an if...then...else block.
  5. If the temperature is above 30°C, turn the fan ON.
  6. If the temperature is 30°C or lower, turn the fan OFF.
🚀 Open Microsoft MakeCode

Official Microsoft MakeCode for micro:bit

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