## 如何安装node-red安装到orangepi Zero3 ### 操作系统 基于ubuntu的操作系统的orangepizero3定制版 ### 安装步骤 #### 1. 更新系统 在终端执行以下命令,确保系统为最新: ```bash sudo apt-get update && sudo apt-get upgrade -y ``` #### 2. 安装Node-RED Node-RED官方提供了一键安装脚本,适用于Debian/Ubuntu系统: ```bash bash <(curl -sL https://raw.githubusercontent.com/node-red/linux-installers/master/deb/update-nodejs-and-nodered) ``` 安装过程中可根据提示选择“y”继续。 #### 3. 启动与停止Node-RED - 启动: ```bash node-red-start ``` - 停止: ```bash node-red-stop ``` - 查看日志: ```bash node-red-log ``` #### 4. 设置开机自启 通常安装脚本会自动设置开机自启,如需手动设置: ```bash sudo systemctl enable nodered.service ``` #### 5. 访问Node-RED 在浏览器访问: ``` http://<你的OrangePi的IP地址>:1880 ``` 可用 `hostname -I` 或 `ip a` 命令查询IP地址 sudo systemctl status nodered.service sudo systemctl start nodered.service sudo systemctl stop nodered.service sudo systemctl restart nodered.service