Skip to content
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

Delay on slow CPU #4

Open
fab1an opened this issue Mar 29, 2024 · 4 comments
Open

Delay on slow CPU #4

fab1an opened this issue Mar 29, 2024 · 4 comments
Assignees
Labels
help wanted Extra attention is needed

Comments

@fab1an
Copy link

fab1an commented Mar 29, 2024

There's a large delay on my raspberrypi-zero.

When pressing a button it takes about a second to register with my python-script.

Is there some kind of busy-cpu loop that is blocking the CPU? could this be worked around to be event-driven?

@einspunktnull einspunktnull self-assigned this Apr 1, 2024
@einspunktnull
Copy link
Contributor

Interesting. We've never tried this lib on slow CPU machines. There is a separate thread, which polls the incoming HID data bytes, then it detect changes of values like button up or down, and then, on change, it executes your callback. is your callback doing hard work which blocks execution?

@einspunktnull einspunktnull added the help wanted Extra attention is needed label Apr 1, 2024
@fab1an
Copy link
Author

fab1an commented Apr 1, 2024 via email

@einspunktnull
Copy link
Contributor

Unfortunately i can't test with your setup right now to find out if it's a general problem with python on slow CPU devices or if it's a problem with this library itself. Maybe you could help me by trying the pydualsense library from flok and let me know if it runs better with it. the core structure is very similar. this could provide us with valuable conclusions and give us a starting point for further problem analysis.

@einspunktnull
Copy link
Contributor

have you tried flok's library? do you have any insights you can share?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants