若您覺得文章寫得不錯,請點選文章上的廣告,來支持小編,謝謝。
If you like this post, please click the ads on the blog or buy me a coffee. Thank you very much.What you need:
- LED x 1 (LED x 1)
- 220 ohm resistor x 1 (200歐姆電阻 x 1)
- Breadboard 300 holes x 1 (300孔麵包板 x 1)
- Male-to-female jumper x 2 (公對母杜邦線 x 2)
步驟一:(若是使用 NOOBS v2.1.0版本的話,可略過此步驟)
Step 1: (You can skip this step if you are using NOOBS v2.1.0 or above)
更新Raspbian系統
Updating Raspbian OS
sudo apt-get update
sudo apt-get dist-upgrade
步驟二:從選單-->軟體開發-->Scratch,來開啟 Scratch 1.4 (Linux),之後在Scratch中點選編輯-->Start GPIO server。
Step 2: Open Scratch by clicking on Menu --> Programming --> Scratch. Then, click on Edit --> Start GPIO server.
步驟三:接線
Step 3: The circuit.
Led 正極接 RPI3 的 GPIO17 ( Led anode --> RPI3 GPIO17 )
Led 負極接 RPI3 的 GND ( Led cathode --> RPI3 GND)
樹莓派的針腳說明:
Pin Mapping for Raspberry Pi 3:
圖片來源(Image Source):https://developer.microsoft.com/en-us/windows/iot/docs/pinmappingsrpi
步驟四:使用廣播積木來設定GPIO17的on與off,訊息分別為 config17output、gpio17on、gpio17off。
Step 4: Using broadcast block to configure GPIO17 and the messages are config17output、gpio17on、gpio17off.
示範影片:
Demo video:
參考資料:
Reference:
[1] https://www.raspberrypi.org/learning/robot-antenna/
沒有留言:
張貼留言