-
Notifications
You must be signed in to change notification settings - Fork 11
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
Error linking to light NEEWER-RGB660 #46
Comments
Interesting - it looks like something may have changed with Bleak since the version I wrote the program with, because of the DeprecationWarning. It actually looks like it's more of an issue with Python versions > 3.10, as I see other projects that use asyncio with the same error - I'll check more into this... |
I think I have a lead on a fix for this - the verbiage seems to have changed since the Python version I'm using (3.8 - I need to upgrade 😅) - so I'll work on a fix for the DeprecationWarning error. |
OK @yodatak - I've released a new version (0.12b) which should fix this issue - or at least creates the event loop in a more Python > 3.10 way, so it should fix the issue. I tested it on both Python 3.9 and 3.10.7 on Windows, Mac and Ubuntu and it worked on all of those setups, so it should theoretically also work on Fedora. Let me know if you have any issues! |
Thanks i got this error now and i canot see the bluetooth device
|
I try to build it in a flatpak and i got the same problem if you are interested in testing the flatpak and publish the app in flathub don't hesitate i will made a PR but i'm not sure if its works because of my light that don't connect |
I might take you up on that, although I don't know what flatpak is :) I need to do some research on that. I do see the light did manage to connect once in your "more testing" picture - I'm not sure where the light physically is in relation to your PC, but it might be a weak connection from the Bluetooth to the light. I'd say if it's possible to, just to try, move the light closer to the PC and see if you get the same results. I was going to say for your first post "are you sure Bluetooth is turned on?", but I see that it wasn't - ha, but... I'm confused what the QSocketNotifier error is referring to, I don't use QSocketNotifier in my program at all (I do use threading, but not specifically a QThread, Qt must be using the QSocketNotifier in the background - this one's also going to need some more research.) I did look the error up on Google and came up with a few other errors of the same type, also using Fedora, with both C++ and Python, so it may be how Fedora uses Qt. |
I try closer same error for me. Flatpak is a way to package a desktop application a universal way it can be install on all system with flatpak and published on the store https://flathub.org |
Got you - that might be a good thing to look into! OK, I've downloaded Fedora myself and installed it into a Virtual Machine running on Oracle VirtualBox - Fedora 36, Python 3.10.4, and these packages from pip, in a venv Python virtual machine: I do get the QSocketNotifier error on launching NeewerLite-Python (as well as an error that I'm not using Wayland - my Fedora installation uses Gnome instead apparently), but the program still seems to control the lights on my end without an issue - I'm sorry you're having so many issues with it :( This other screenshot you sent yesterday also indicated that you did get a successful connection to the light in another instance, but it looks like it might not have kept that connection alive for some reason [??] - |
Hello i just test with another computer it works i think its my bluetooth usb key that is not good |
Ah, excellent - it might be an older Bluetooth dongle that doesn't fully support BLE (Bluetooth Low Energy), but I'm not sure... thanks! |
With
hci0: Type: Primary Bus: USB So the bluetooth usb stick is only blueetooth 4.0 |
I'm going to try to check out all the Flatpak stuff in the next few days @yodatak - but I am closing this issue now, as it seems to be resolved with the other Bluetooth adapter - let me know if you have any other connection issues otherwise! |
Hi thanks for your app , i cannot make it works with Fedora 36 with Python 3.10.6, python3-pyside2-1:5.15.2.1-4, bleak 0.16.0
Have you got any idea how to make it works ?
Thanks again !
yodatak@fedora ~/Projets/NeewerLite-Python main ± pip3 install bleak
Defaulting to user installation because normal site-packages is not writeable
Requirement already satisfied: bleak in /home/yodatak/.local/lib/python3.10/site-packages (0.16.0)
Requirement already satisfied: async-timeout>=4.0.1 in /usr/lib/python3.10/site-packages (from bleak) (4.0.2)
Requirement already satisfied: typing-extensions>=4.2.0 in /home/yodatak/.local/lib/python3.10/site-packages (from bleak) (4.3.0)
Requirement already satisfied: dbus-next in /home/yodatak/.local/lib/python3.10/site-packages (from bleak) (0.2.3)
python3 NeewerLite-Python.py
/home/yodatak/Projets/NeewerLite-Python/NeewerLite-Python.py:2883: DeprecationWarning: There is no current event loop
loop = asyncio.get_event_loop()
/home/yodatak/Projets/NeewerLite-Python/NeewerLite-Python.py:3275: DeprecationWarning: There is no current event loop
loop = asyncio.get_event_loop() # get the current asyncio loop
QSocketNotifier: Can only be used with threads started with QThread
[01:48:48] - Searching for new lights
[01:48:56] - Background Thread Running
[01:48:58] - Searching for new lights
[01:49:03] - Found new light! [NEEWER-RGB660] MAC Address: FD:18:68:CD:42:20 RSSI: -79 dBm
[01:49:04] - Attempting to link to light [NEEWER-RGB660] MAC Address: FD:18:68:CD:42:20 (Attempt 1 of 6)
[01:49:14] - Error linking to light [NEEWER-RGB660] MAC Address: FD:18:68:CD:42:20
The text was updated successfully, but these errors were encountered: