nxhack / openwrt-node-packages

OpenWrt Project Node.js packages. v18.x TLS and v20.x LTS
GNU General Public License v2.0
256 stars 99 forks source link

Node-Red on Raspberry pi 4 GPIO & Serial Port Issue #1952

Open Quicksilverzone opened 7 months ago

Quicksilverzone commented 7 months ago

Hi,

I prepared openwrt image including node packets in these repo. But I cannot control GPIO and serial ports over Node-Red, it gives error on debug windows when I deploy the script on Node-Red with the gpio or serial node. Is there any other point I need to change or configure I dont know. I am using raspberry pi CM4. I am a little bit newbie on openwrt platform. I'll be grateful for any help. Thank you.

Image_1

nxhack commented 7 months ago

Hi @Quicksilverzone

Sorry, but I don't know much about it and this may give you a hint. https://nodered.org/docs/faq/interacting-with-pi-gpio

https://www.raspberrypi.com/documentation/computers/configuration.html#serial

https://www.raspberrypi.com/documentation/computers/configuration.html#change-the-default-pin-configuration Oh, the OS is OpenWrt, not raspberry os. I am sorry.

nxhack commented 7 months ago

I saw the error message in the image you attached. Try running this on the target machine.

npm install raspi-io

https://www.npmjs.com/package/raspi-io

nxhack commented 7 months ago

https://openwrt.org/docs/techref/hardware/port.gpio

https://openwrt.org/docs/techref/hardware/port.serial