I have the problem that the keyboard node (from the package "node-red-node-pi-gpio") won't consume the key presses and they still get recognised (e.g capslock led turns on if i press capslock). I noticed the issue after i have re-installed my pi 4 b's OS, and installed node-red with the official install script ("bash <(curl -sL https://raw.githubusercontent.com/node-red/linux-installers/master/deb/update-nodejs-and-nodered)")
How can i make node-red consume the keypresses so the application running (console i guess, the pi is headless and i never attached a monitor to it since i got it, only used ssh) won't recognize the press?
If you are using this node, it expects the keyboard to be attached to the pi that is running node-red.
I have the keyboard attached and working, but i want to "consume" the input events so that eg. The capslock led doesn't go on if i press the capslock key
I believe the led in the keyboard is activated by a ‘mechanical’ switch I.e. the keyboard itself is turning on the light and there would be no way for node-red to change that.
No, i can change when it is on or off and i also do this as an indicator for other things, but to be usable as an indicator light, the capslock light should not go on on capslock press
(I can control it and the other leds built into my rpi (power/act led) and all the keyboard leds via /sys/class/leds/led_name/brightness
My issue is how to "take" the input events so that no other app than NR can see it
What make/model keyboard is it?
Are you saying that prior to the latest install node-red prevented the caps light on the keyboard from going on?
If so, what version of NR were you running?
What OS were you using? And which are you using now?
I fixed the issue by disabling the desktop environment (
sudo apt purge xserver* lightdm* raspberrypi-ui-mods), setting the rpi to boot to console autologin (via
raspi-config) and rebooting it. I guess that having the desktop running without monitor on my headless pi caused the problem
Thanks for your help
For a headless system it may be best to install the Lite version of the OS so there is no GUI.
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.