-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Launching issue on Ubuntu 21.04 #16
Comments
Hiya, Yep I'm still looking after Raspiled, though as it is behaving for me I've not pushed that many updates recently. I'd originally written it for Python 2.7, but with Python 3 compatibility to 3.5 at least. This bug is probably is a change to the way the Twisted library behaves in Python 3. The error looks like Twisted is passing along whatever port got set in the user settings without casting it into an integer first. The settings file is essentially parsed internally as text. It's a bit daft because our config file does verify that you've stored something integer compatible, but I guess it fails to convert it into integer when it goes to actually use the value. Does this commit fix it? d7c2553 |
Looks like the new code allows me to progress further, but there's still an issue: (ubuntu) ubuntu@revox-kala:~/raspiled$ python ./src/raspiled_listener.py
Traceback (most recent call last):
File "/home/ubuntu/raspiled/./src/raspiled_listener.py", line 19, in <module>
from src.config import CONFIG, get_setting, DEBUG
File "/home/ubuntu/raspiled/src/__init__.py", line 10, in <module>
from ledstrip import LEDStrip
File "/home/ubuntu/raspiled/src/ledstrip.py", line 84, in <module>
pigpiod_process()
File "/home/ubuntu/raspiled/src/ledstrip.py", line 81, in pigpiod_process
logging.info('PIGPIOD is running! PID: %s' % output.split('\n')[0])
TypeError: a bytes-like object is required, not 'str' Manually editing that line removes that error, but a new one shows up: (ubuntu) ubuntu@revox-kala:~/raspiled$ python ./src/raspiled_listener.py
[16:13:59 RASPILED] PIGPIOD is running!
[16:13:59 RASPILED] Using config file: /home/ubuntu/raspiled/src/raspiled.conf
Traceback (most recent call last):
File "/home/ubuntu/raspiled/./src/raspiled_listener.py", line 19, in <module>
from src.config import CONFIG, get_setting, DEBUG
File "/home/ubuntu/raspiled/src/config.py", line 68, in <module>
params = ordereddict_to_int(parser.defaults())
File "/home/ubuntu/raspiled/src/config.py", line 22, in ordereddict_to_int
if u"." in unicode(value):
NameError: name 'unicode' is not defined Since strings in python 3 are unicode by default, I changed unicode() to str(), but there's a new issue: ubuntu@revox-kala:~/raspiled$ python ./src/raspiled_listener.py
[20:34:33 RASPILED] PIGPIOD is running!
[20:34:33 RASPILED] Using config file: /home/ubuntu/raspiled/src/raspiled.conf
[20:34:33 RASPILED] Raspiled Listener already running with PID
(program exits) After editing the file temporarily, I'm able to progress, and the app starts, but it can't read PWMs for some reason: [20:40:32 RASPILED] PIGPIOD is running!
[20:40:32 RASPILED] Using config file: /home/ubuntu/raspiled/src/raspiled.conf
[20:40:33 RASPILED] [STARTING] Raspiled Listener with PID 95260
[20:40:33 RASPILED] Cannot read PWM of pin #17
[20:40:33 RASPILED] Cannot read PWM of pin #22
[20:40:33 RASPILED] Cannot read PWM of pin #24 |
The issues you describe look a lot like what I encountered when trying to run raspiled in Debian 11 (Python 3.9). I got it to work with the changes in #18 |
Hey there, I'm not sure if this project is still maintained, but I was using Raspiled before for half a year on Ubuntu Server 18.04, and all worked fine.
Problems stared appearing when I updated my pi to Ubuntu Server 21.04, that's the issue I'm facing:
I'm not sure what's the issue here, maybe the repository or some dependencies don't work on Python 3.10?
I'll keep looking myself, but any help will be greatly appreciated.
The text was updated successfully, but these errors were encountered: