Tuesday, July 12, 2022

Energy Monitoring


I was warned by the installer that my choice of system size might not perfectly offset my usage. I decided to take that as a challenge to reduce my energy usage instead of increasing the size of my solar system. So far I have had two power bills that reflected a full month of solar usage, with an average of $20 due. To address this I have decided look into more closely metering individual devices to better understand my energy usage. 

I know there are several options that could be used to get this data into home assistant. Luckily someone already did a great job of summarizing these options, XtremeOwnage investigated each of the options here. Based on that article I decided to go with the Emporia Vue 2 flashed with ESPHome as described here

Using the documentation flaviut published was pretty straight forward. The first major issues I ran into was with the initial flashing of ESPHome. This was my first attempt at using ESPHome with my Home Assistant ecosystem. I installed ESPHome as an add on to my install of Home Assistant, but due to compilation issues I was unable to use the add on to flash the device. I ended up using my desktop to flash the device, which allowed me to move forward.  

The hardware installation was very straight forward and only took about 45 minutes. I ended up having to reverse the collar on the antenna since my breaker box is flush with the wall in the garage. Luckily my breaker box was just updated when I had my solar installed, so there was ample room for the device and additional wiring for all 18 CT clamps. One of two issues I had was installing the CT clamps for my solar circuit backwards since they all indicate the proper direction as towards breaker, while the solar circuits should be away from the breaker, luckily that could be resolved in software.

Another issue I had was because I was unlucky in my choice of phase to monitor for my dryer. Apparently the motor for the dryer drum is only 120, not  240. The phase I chose monitor is only used for the heating element so I will either have to be clever in any automation I setup to detect when the dryer is done or I will need to adjust which phase has the clamp. 

When I tried to update the initial configuration with ESPHome I learned that the yaml file was actually used as a source file when compiling the program for ESPHome so I still couldn't used the Home Assistant add on to update it. I then installed the ESPHome docker image on my unraid system. One additional change I had to make for the docker install of ESPHome to recognize the Vue was set a static IP on the device. Once that was specified the device was found I was able to remotely update it. 


For a basic installation the only required changes to the base yaml file needed are specifying which phase each input and their multiplier for tracking 240V devices on a single sensor.  Because I have solar power, I had to add some additional sensors to have the correct info exposed for the home energy dashboard. I needed breakout the total power to separately expose data on when energy was being imported and exported. While the total_daily_energy sensor accurately tracks the net usage, Home Assistant does not play well with power sensors that decrease in KWH or report negative values. The below code adds the needed sensor data to home assistant to properly use the energy dashboard.


Now that I have all this info available in home assistant I can take a deeper look into what devices my power is really going too. My AC unit is taking the majority of my power this week. Being a 10 SEER unit I will have to seriously consider upgrading to a modern more energy efficient unit once I have more funds available. 






No comments:

Post a Comment

Server Monitoring

I have a headless Linux server that I have previously written about for ripping media disks.  While I have had MQTT integrated into the bash...