You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As mentioned in #help on Discord, I ran into the known issue about the failed edge detection, using the latest version of the Raspberry OS installed via the Raspberry imager default.
I used a few google searches with ensuing cut-and-paste my awesome brain power to solve the issue...
I am really not a linux/gpio expert : the steps below worked for me, I can't go beyond that...
Maybe it is a reliable fix/workaround : throwing it to this community for tests and comments !
(Installing an older OS or installing 3 arcane libraries using hard-coded links/versions : not sure which is more satisfying...)
I copied the style of the main doc to document the fix.
happy Inkycaling !
--Philippe
Failed to add edge detection error : using the latest version of the Raspberry OS.
Using the latest version of the Raspberry OS can lead to the "Failed to add edge detection" error when trying to run InkyCal.
(The latest version of the OS is the one you will get by default from the Raspberry Imager application)
This is a known Waveshare library issue, which can not be solved in the InkyCal code itself.
The error will trigger the error message below.
File "/home/johndoe/Inkycal/venv/lib/python3.11/site-packages/gpiozero/pins/pi.py", line 636, in _set_when_changed
self._enable_event_detect()
File "/home/johndoe/Inkycal/venv/lib/python3.11/site-packages/gpiozero/pins/rpigpio.py", line 220, in _enable_event_detect
GPIO.add_event_detect(
RuntimeError: Failed to add edge detection
Keep the latest OS and use a GPIO library called lgpio (l for Legacy) which manages the issue
installing LGPIO instead of GPIO
If you choose the second option, expect a simple but somewhat lengthy installation.
The steps are detailed below :
# follow the installation procedure up to (included) "pip install RPi.GPIO==0.7.1 spidev==3.5 gpiozero==2.0"# do execute the pip install above# first, let's uninstall the GPIO library
pip uninstall RPi.GPIO
# the other gpio library requires three libraries, let's install them
wget https://github.com/PCRE2Project/pcre2/releases/download/pcre2-10.44/pcre2-10.44.tar.bz2
bzip2 -d pcre2-10.44.tar.bz2
tar -xf pcre2-10.44.tar
cd pcre2-10.44/
./configure && make && sudo make install && make clean
# grab a coffee... or two ...cd ..
wget https://sourceforge.net/projects/swig/files/swig/swig-4.3.0/swig-4.3.0.tar.gz
tar zxvf swig-4.3.0.tar.gz
cd swig-4.3.0/
./configure && make && sudo make install && make clean
# enough coffee, go for a walk ...cd ..
wget http://abyz.me.uk/lg/lg.zip
unzip lg.zip
cd lg
make && sudo make install && make clean
cd ..
# and we are ready to install the other GPIO librarycd Inkycal/
pip install rpi-lgpio
# and there we go
python3 inky_run.py
The text was updated successfully, but these errors were encountered:
Hi there and welcome to Inkycal. Thanks for opening this issue. As this is your first issue in this repository, please read through the contributing guidelines
Hello,
As mentioned in #help on Discord, I ran into the known issue about the failed edge detection, using the latest version of the Raspberry OS installed via the Raspberry imager default.
I used
a few google searches with ensuing cut-and-pastemy awesome brain power to solve the issue...I am really not a linux/gpio expert : the steps below worked for me, I can't go beyond that...
Maybe it is a reliable fix/workaround : throwing it to this community for tests and comments !
(Installing an older OS or installing 3 arcane libraries using hard-coded links/versions : not sure which is more satisfying...)
I copied the style of the main doc to document the fix.
happy Inkycaling !
--Philippe
Failed to add edge detection
error : using the latest version of the Raspberry OS.Using the latest version of the Raspberry OS can lead to the "Failed to add edge detection" error when trying to run InkyCal.
(The latest version of the OS is the one you will get by default from the Raspberry Imager application)
This is a known Waveshare library issue, which can not be solved in the InkyCal code itself.
The error will trigger the error message below.
What can I do to fix the error ?
Reinstall an older version of the Raspberry OS (bullseye from 2023-05-03 ) as noted at the top of the configuring-the-raspberry-pi section.
Keep the latest OS and use a GPIO library called lgpio (l for Legacy) which manages the issue
installing LGPIO instead of GPIO
If you choose the second option, expect a simple but somewhat lengthy installation.
The steps are detailed below :
The text was updated successfully, but these errors were encountered: