thekief / s1t-ledcontrol

GNU General Public License v3.0
7 stars 0 forks source link

Home Assistant #4

Open DjMayone opened 6 months ago

DjMayone commented 6 months ago

I Have a T9 Pro with HomeAssistant OS. Do you tihink it's possible to make an integration?

thekief commented 6 months ago

I can definitiely look into that. What do you expect the scope of the plugin to be? I would just expose the flags as options in HA.

Before I can start I want to point out that I am currently blocked by https://github.com/serialport/serialport-rs/issues/156. As soon as it is resolved I will look into it.

DjMayone commented 6 months ago

Thank you! I think will be used by a lot of people using T9 Plus as HA host! My request is so simple: make an on/off button for LEDs inside HA but in the future could be used maybe as notification (different colours triggered to different notification). I've seen that in Acemagic forum lot of people are looking for LEDs control in Linux, maybe could interest you...

DjMayone commented 3 months ago

I have a news: a user compiled a script to control RGBs onboard. Could you take a look? https://www.rigacci.org/wiki/doku.php/doc/appunti/hardware/t9plus_mini_pc_rgb_led_control Thank you!

thekief commented 3 months ago

Your code looks good :)

I am also quite sorry for my late reply. I looked into creating a Home Assistant extension. I created a custom light entity that accesses the serial device and write the new values to them. It is a bit hacky, as I think I am misusing certain attributes. I couldn't finish it though yet, as I was quite busy with life

DjMayone commented 1 month ago

Hello, anyone that could help about this iussue? Thank you!

thekief commented 1 month ago

I'm really sorry for my late reply, I somehow overlooked the issue.

I looked into it a few months ago but couldn't finish it, due to other things going on. Creating an add-on for HomeAssistant is quite doable. I had some code that extends HA's LightEntity. I'll check if I find it, and maybe get it even properly running.