---
# System prepended metadata

title: Node-RED on Raspberry Pi

---

# Node-RED on Raspberry Pi

* Raspberry Pi environment

https://www.raspberrypi.com/software/operating-systems/

下載安裝 [Raspberry Pi OS with desktop and recommended software](https://downloads.raspberrypi.org/raspios_full_armhf/images/raspios_full_armhf-2021-05-28/2021-05-07-raspios-buster-armhf-full.zip)，已經包含Thonny Python IDE & Node-RED


**更新Rapberry Pi**
```
    $ sudo apt update
    $ sudo apt upgrade
```
**安裝npm (Node PAckage Manager)**
```
    $ sudo apt install npm
```
**確認 Node.js & npm安裝的版本**
```
    $ node -v
    $ npm -v
```
**設定Raspberry Pi 開機時自動啟動 Node-RED**
```
    $ sudo systemctl enable nodered.service
```
**安裝 Node-RED Dashboard**
```
    $ node-red-stop
    $ cd ~/.node-red
    $ npm install node-red-dashboard
```


* 參考：
    1. https://atceiling.blogspot.com/2019/07/raspberry-pi-51node-reddashboard.html
    2. 