Which global modules are installed in your case?
ls -l /usr/local/lib/node_modules/
Does this help?
As said, any module you installed via palette manager would need to be reinstalled.
systemctl stop node-red
cd /mnt/dietpi_userdata/node-red
mv node_modules node_modules.bak
sudo -u nodered npm i --no-audit node-red
systemctl start node-red
When I install the node-red-node-serialport
from palette manager, I get serialport
v11.0.0 added, so indeed a much newer version.
Another question: What is the actual Node.js version?
node -v
Latest is v20.3.1. This can be updated as well via reinstall:
dietpi-software reinstall 9
Afterwards, it it was a significant update, this might not only allow but even require to update Node-RED and its dependencies to function.