Skip to content

Extend image handling, improve device checks, and fix signals#8

Open
ArthurLuciani2 wants to merge 3 commits intodevelopfrom
fix/check-alive-fail-loop
Open

Extend image handling, improve device checks, and fix signals#8
ArthurLuciani2 wants to merge 3 commits intodevelopfrom
fix/check-alive-fail-loop

Conversation

@ArthurLuciani2
Copy link
Collaborator

  • Image Handling Enhancements:

    • Added PNG support in ImageProvider.py, including transformations and rotations.
    • Increased API token expiration in scan.py from 600 to 1800 seconds.
    • Removed unnecessary BGR-to-RGB conversion in RPCCamera.py for PNG encoding.
  • Device Checks:

    • Enhanced send_alive_check in RPC.py to return detailed statuses: ok, unreachable, and unknown.
    • Added re-registration logic for devices responding as unregistered.
    • Introduced _type attribute to track device types during registration and re-registration.
    • Adjusted logging and timeout handling for better device status clarity.
  • Signal Fix:

    • Corrected variable unpacking in the resolutionChanged signal connection by using *res in the lambda function.

These changes improve image processing, device management, and fix a bug in signal handling.

- Added `_type` attribute to track device type during registration and re-registration processes.
- Implemented re-registration logic for devices if alive check fails with an `unregistered` response.
- Updated `send_alive_check` function to return more detailed statuses: `ok`, `unreachable`, and `unknown`.
- Adjusted logging to improve error and warning messages during device timeout and removal in `deviceregistry.py`.
- Improved timeout handling in `send_alive_check` to differentiate between unreachable and unknown devices.
- Corrected the lambda function for `resolutionChanged` to unpack `res` properly using `*res`.
- Increased API token expiration in `scan.py` from `600` to `1800` seconds because 10 minutes is not enough when the format is png.
- Added support for processing PNG images in `ImageProvider.py`, including handling rotations and transformations.
- Removed image BGR to RGB conversion logic in `RPCCamera.py` for PNG encoding because it seems it already is in RGB
@ArthurLuciani2 ArthurLuciani2 self-assigned this Mar 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant