探索 micro:bit 更多功能!
從跳舞機器人到香蕉鍵盤,micro:bit 擁有很多功能,你可以用這些寫出極棒的東西 - 無限可能!
概觀
micro:bit 提供了這些硬體功能:
- 25 個可程式化 LED
- 2 個可程式化按鈕
- 電路連接 pin 腳
- 光 和 溫度 感測器
- 動作感測器 (加速儀 和 羅盤)
- 無線通訊,透過 Radio 和 藍牙
- USB 界面
讓我們來看這些元件可以做什麼並且如何運用!
LEDs
這是什麼? LED為發光二極體。micro:bit 有25個可程式化 LED,可供你作為顯示文字、數字及圖示。
How do I code it? Learn more about coding the LEDs, or use the code references below.
按鈕
接腳
這是什麼? 0> micro:bit 板子邊緣有25個連接點作為外部接腳用。 可以透過這些接腳來控制馬達、LED等其他電子元件,或者額外的感測器!
How do I code it? Learn more about the hardware of the pins, or use the code references below.
範例 - 使用JavaScript編寫程式碼 香蕉鍵盤,入侵你的耳機,創建一個 牛奶盒卡通機器人! 或者,看一下這個 發怒的 micro:bit Python專案!
光感測器
溫度計
What is it? This sensor allows the micro:bit to detect the current temperature of the device, in degrees and Celsius.
如何使用? 請參考下面的範例程式。
Examples - discover how the temperature sensor works.
加速計
指南針
What is it? The compass detects the earth's magnetic field, allowing you to detect which direction the micro:bit is facing. The compass has to be calibrated before it can be used.
'Calibrating' the compass ensures the compass results are accurate. 在 MakeCode 編輯器上可使用電子羅盤校準積木。 To calibrate the compass in Python use compass.calibrate().
When the calibration begins, the micro:bit will scroll the instruction "Tilt to fill screen". To calibrate the compass, tilt the micro:bit to move the dot in the centre of the screen around until you have filled up the whole screen.
How do I code it? Use the code references below.
範例 - 用 JavaScript 或 Python 寫個電子指北針。
Radio
What is it? The radio feature allows you to communicate wirelessly between micro:bits. Use the radio to send messages to other micro:bits, build multiplayer games, and much more!
How do I code it? Discover how to code the radio:
範例 - 創作多玩家猜拳遊戲,或是用 JavaScript 和 Python 做個有趣的的電子螢火蟲!
藍牙
這是什麼? 0> BLE (Bluetooth Low Energy) allows the micro:bit to control phones and tablets over Bluetooth. This communication works both ways, so you can also send code to your micro:bit wirelessly from your phone using one of our apps. Other apps, such as Swift Playgrounds and Scratch, use Bluetooth to talk to the micro:bit.
Before using the Bluetooth feature you will need to pair your micro:bit with another device. Once paired, you can send programs wirelessly to your micro:bit. When you're using Radio, Bluetooth can still be used to update the code on your micro:bit, if you enter pairing mode - learn about the differences between radio and bluetooth in this support article.
The Python Editor doesn't currently support bluetooth.
What can I do with it? Send code to your micro:bit wirelessly.
USB Interface
這是什麼? 0> The USB interface allows you to connect the micro:bit to your computer via a micro-USB cable, which will power the device and allow you to download programs onto the micro:bit.