# Supporting eGauge in Apple Home
Last September we installed solar on our house. The installer added a LAN accessible realtime monitor from [eGauge Systems](https://www.egauge.net). The device and it's embedded software doesn't have the most intuitive UX but it's very hackable and includes a full, well documented, [REST API](https://webapi.redoc.ly).

Inspired by Ryan Seddon's blog [post](https://lnkd.in/grcsBZ4N), earlier this year I wrote a Homebridge Plugin that surfaces the data from the eGauge device into Apple Home. 

HomeKit doesn't (yet) support energy monitoring devices natively so I implemented as a light bulb and light sensor. 

In the picture below, the solar is generating just over 5kW (expressed as lux) and providing 93% of the energy for the home. 

![Apple Home Screenshot](appleHome.jpg)

Configuration is pretty simple. You'll need a username & password to your eGauge. I recommend creating a separate read only credential so your write credentials aren't stored in the clear in homebridge. To do that, click settings/access control:

![Settings Screenshot](settings.png)

Rest of configuration is done in homebridge, including the registers to read:

![Homebridge Settings Screenshot](homebridgeSettings.png)

Hopefully one day Apple will natively support energy sensors. When they do, I'll update the package to support them. If you have an eGauge & [homebridge](https://homebridge.io), you can download the plugin from [NPM](https://www.npmjs.com/package/homebridge-egauge) or install directly from your homebridge instance. Feel free to post any bug reports on [GitHub](https://github.com/nonodename/homebridge-egauge).