Thank you for your donation!


Cloudsmith graciously provides open-source package management and distribution for our project.


Solved: Issue with Rotary Encoder Device in Moode 9
#9
(05-20-2024, 08:38 AM)the_bertrum Wrote: The rotary encoder for volume is working fine for me (Pi3A+).  I've changed the default parameters though, not sure if that might be relevant.  The scripts attached to my GPIO buttons are not firing however, also not sure if that's relevant.  Investigating...

The change that was made to prevent python scripts that use GPIO from crashing was to install python3-rpi.lgpio lib instead of python3-rpi.gpio.

The scripts affected are:

/var/www/daemon/gpio_buttons.py
/var/www/daemon/rotenc.py
/opt/boss2_oled_p3/boss2_oled.py

There is some sort of typeerror bug in the gpio_button.py script causing it to crash.

Code:
pi@moode9:~ $ sudo /var/www/daemon/gpio_buttons.py
2024-05-20 07:44:17 bounce_time=1000
Traceback (most recent call last):
 File "/var/www/daemon/gpio_buttons.py", line 43, in <module>
   print(str(datetime.datetime.now())[:19] +
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: can only concatenate str (not "NoneType") to str
Enjoy the Music!
moodeaudio.org | Mastodon Feed | GitHub
Reply


Messages In This Thread
RE: Issue with Rotary Encoder Device in Moode 9 - by Tim Curtis - 05-20-2024, 11:50 AM

Forum Jump: