it seems that the cable by clever routing is long enough to connect to the RPi5 directly. After that you shouldn‘t need a script for fan control. It‘s okay if you doesn‘t need the fan control depending on different sources like CPU + HDD/NVMe + GPU at the same time. The argon1.sh script installs a script which observes different temperature sources, if the fan is plugged in the case internal connector.
Without the argon1.sh script, you will have no support for different power button events. This can resulting in, that you don‘t have a graceful shutdown and the power button does nothing or only power cuts (without shutdown initiated)
what I know and can confirm is that the Handle Power Button Events option currently requires a reboot to reflect the changes.
This is specifically noted in the line of text below this option. It’s on my to-do list to try to change that.
But when I start KODI, I can disable the add-on and the fan control + power button detection is turned off. When I activate the add-on again, the power button detection works immediately.
Can you please provide me with an ordered list of the steps you follow until it stops working? Maybe I can reproduce it here then.
Hey @HarryH , thanks for your clarification! I will go for the regular ONE V3 without NVME support because for my use case I will be swapping SD cards quite often.
But the more I think about it, I will probably go for the script after all. Having a functioning pwr button would be neat and since some of the more “modern” retro emulations (PS2, Nintendo Wii) will probably tax CPU & GPU quite a bit it would be nice to have a more granular control over the fan. I´ll see what I’ll do once the case arrives.
currently it looks like an issues with lgpio. But I can‘t differentiate if it happens only in combination with a RPi5. To isolate this, I need a little bit support from you.
Scenario 1:
Please can you check if a pipe file from lgpio is there ? ls -la /tmp/.lgd-nfy*
Check it two times:
after KODI was started with add-on enabled
immediatly after you disabled the add-on
If the pipefile is there after you have disabled the add-on, please try to delete this file. After that, enable the add-on and please look if the button detection works.
Scenario 2:
Please do this during the add-on is disabled, to prevent additional distracting error messages.
Change these lines (44 - 49) in /storage/.kodi/addons/script.service.argonforty-device/resources/lib/argon.py
if pi.model == '5B':
import importlib.util
lgpio_spec = importlib.util.find_spec("lgpio")
if lgpio_spec is not None:
from gpiozero.pins.lgpio import LGPIOFactory
Device.pin_factory = LGPIOFactory(chip=4)
to
#if pi.model == '5B':
# import importlib.util
# lgpio_spec = importlib.util.find_spec("lgpio")
# if lgpio_spec is not None:
# from gpiozero.pins.lgpio import LGPIOFactory
# Device.pin_factory = LGPIOFactory(chip=4)
from gpiozero.pins.lgpio import LGPIOFactory
Device.pin_factory = LGPIOFactory(chip=4)
after KODI was started with add-on enabled
command yielded: /tmp/.lgd-nfy0
immediatly after you disabled the add-on
a. command yielded: /tmp/.lgd-nfy0
b. pipe never went away
If the pipefile is there after you have disabled the add-on, please try to delete this file. After that, enable the add-on and please look if the button detection works.
deleted pipe then enabled the addon.
Button detection did not work
Note: created a new pipe named /tmp/.lgd-nfy3 once enabled after the delete
Scenario 2:
Change argon.py as directed
after KODI was started with add-on enabled
command yielded: /tmp/.lgd-nfy0
immediatly after you disabled the add-on
a. command yielded: /tmp/.lgd-nfy0
b. pipe never went away
If the pipefile is there after you have disabled the add-on, please try to delete this file. After that, enable the add-on and please look if the button detection works.
deleted pipe then enabled the addon.
Button detection did not work
Note: created a new pipe named /tmp/.lgd-nfy6 once enabled after the delete
I can’t promise that it helps, but I changed a lot of things with 0.0.11d. Please try this version. During troubleshooting it now makes sense to switch the protocol to Debug. You will then receive messages from the “Argon40: …” plugin and can see directly in the kodi.log whether the button monitoring is working or not. If not, we may get a clue as to where something is wrong.
Thank you for providing the log. It wasn’t a kodi.log with debug logging enabled like I hoped, but I could see why.
The GPIO pin for power button monitoring cannot be released.
This is a general issue with the gpiozero/lgpio combination, not specific to this add-on or RPi5. It affects all versions so far. I’m currently looking for a solution to this.
please try v.0.0.12. The disable/enable issue should be resolved. What I can’t fix at the moment is that KODI thinks to terminate the thread because it’s running against the 5 second timeout. It’s an internal delay of lgpio.
Now that Raspbery pi OS has updated to use Debian trixie. The script has some new issues. The fans and M.2 drive seems to work fine. However, shutting down the pi does not turn off the power. The script will need an update.