I'm looking for a way to display my mouse's battery level in Home Assistant. Currently, I use a 2.4GHz USB dongle since my PC and Home Assistant don't support Bluetooth. I discovered that I can utilize Hass.Agent, a desktop app for Home Assistant, to get data through PowerShell and expose it as a sensor. My main question is: can I extract the battery level from SignalRGB using PowerShell, given that I won't use Synapse due to its issues?
3 Answers
It seems like Razer doesn't provide an API for checking battery levels, just color adjustments through their Chroma SDK. You might need to directly interact with the USB buffer and reverse-engineer the firmware, which sounds like a major headache.
This is an interesting challenge! While I can't help much without the hardware, searching online might yield some answers. I also asked Google AI for help, and it suggested that SignalRGB doesn't provide battery data via PowerShell. However, you can try using the `Win32_Battery` WMI class for other device battery info.
Check out WMI (Windows Management Instrumentation) to see if the Razer software adds any namespaces or classes you can use. WMI Explorer could help you find what you're looking for, and if you find relevant namespaces, PowerShell can access those easily.

I found that the Win32_Battery only refers to actual machine battery info. I'm trying `powercfg` next to see if that gives me what I need.