Commit graph

20 commits

Author SHA1 Message Date
8a6fb77de3
Enhance command execution with error handling and return codes 2025-03-09 20:06:36 +01:00
e54223e361
feat: Add cover art support for user client
This commit adds support for displaying cover art from the currently playing media in the Home Assistant user client.

- The `HassUserClient` now publishes cover art to the `user/image/cover` MQTT topic.
- The `publish_cover` method uses `playerctl` to retrieve the art URL and `pillow` to convert the image to WebP format before publishing.
- The `components` property now includes an `image` component for cover art.
- The `cover` attribute on `HassUserClient` is used to avoid resending the same cover multiple times.
- The `publish_state` method has been extended to spawn a thread for updating the cover.
2025-03-09 18:51:38 +01:00
45f7fc4741
Enhance MQTT client configuration with improved naming, icons, and additional URL 2025-03-09 17:31:16 +01:00
204e0a1fbc
Add volume control and state publishing to HassUserClient 2025-03-09 14:41:11 +01:00
b5a3846cc5
Simplify service execution command in hasspy.service 2025-03-09 13:00:22 +01:00
fad234ad00
Refactor main entry point and command handling in HassSystemClient and HassUserClient 2025-03-09 12:59:30 +01:00
9b3df6416e
Update power state representation in HassSystemClient to use string literals 2025-03-09 12:34:14 +01:00
2137378f07
Add play/pause command support to HassUserClient with button component 2025-03-09 12:29:14 +01:00
77aa8b5b92
Add user mode support with separate client classes for system and user modes 2025-03-09 12:26:57 +01:00
cbb6c71f09
Add log level configuration and improve logging in MQTT client 2025-03-09 11:54:33 +01:00
be2381429f
Refactor power control logic in MQTT client to use pattern matching for improved readability 2025-03-09 11:40:53 +01:00
98e1e970c1
Refactor configuration file loading to check multiple paths and raise error if not found 2025-03-09 11:40:40 +01:00
2042c413c7
Fix config file installation path in PKGBUILD and update main application to load config from new path 2025-03-09 11:27:57 +01:00
0d23d6ef56
Add systemd service file installation to PKGBUILD 2025-03-09 11:25:48 +01:00
bf58ad1d04
Update config file path to /etc/config.toml in main application 2025-03-09 11:24:09 +01:00
802213b709
Update systemd service file to use Python module execution 2025-03-09 11:22:58 +01:00
e8558af260
Update package version and fix backup path in PKGBUILD 2025-03-09 11:17:46 +01:00
b46e0dbad1
Refactor main application structure; move main logic to __main__.py and add example configuration file 2025-03-09 10:29:23 +01:00
d827788da1
Add logging to MQTT client and main application; create systemd service file 2025-03-08 23:50:43 +01:00
fa8bb1d8a9
Initialize hasspy project with basic structure and MQTT client implementation 2025-03-08 23:39:33 +01:00