siclark wrote:Trying to replicate this myself with simple schedule and using Grafana.
One question, by taking the last in your examples below, is your script aggregating the values rather than just writing the current energy usage, otherwise you would be getting last reading in that period and not actual total?
# -*- coding: utf-8 -*-
import indigo
import requests
import math
import urllib
import re
import xml.etree.ElementTree as ET
#TED Dashboard GET - It is very messy, but works
response = requests.get('http://192.168.20.90/api/DashData.xml')
requestURL = 'http://192.168.20.90/api/DashData.xml'
root = ET.fromstring(response.content)
now = response.content.split('\n')[1]
now = re.sub("<Now>","",now)
energyNow = float(now.split('<')[0])
energyNow = energyNow/1000
indigo.variable.updateValue(108813449, u"{0:.3f}".format(energyNow))
#! /usr/bin/env python
# -*- coding: utf-8 -*-
kwh = float(indigo.variables[108813449].value)
rate = float(indigo.variables[1271206538].value)
cost = kwh * rate
indigo.variable.updateValue(1493589605, u"{0:.2f}".format(cost)) # variables must be stored as strings / 1 decimal
#! /usr/bin/env python
currentElectricityUsage = indigo.variables[108813449]
tedRunningTotalUsage = indigo.variables[1283246615]
newValue = currentElectricityUsage.getValue(float) + tedRunningTotalUsage.getValue(float)
# Stuff the new value back into one of the variables (tedRunningTotalUsage in this example):
indigo.variable.updateValue(tedRunningTotalUsage, u"{0:.4f}".format(newValue))
#! /usr/bin/env python
tedRunningTotalUsage = indigo.variables[1283246615]
tedRunningTotalUsage2 = indigo.variables[113926384]
newValue = tedRunningTotalUsage.getValue(float) / 3600
indigo.variable.updateValue(tedRunningTotalUsage2, u"{0:.4f}".format(newValue))
#! /usr/bin/env python
currentElectricityCost = indigo.variables[1493589605]
tedRunningTotalCost = indigo.variables[163627038]
newValue = currentElectricityCost.getValue(float) + tedRunningTotalCost.getValue(float)
# Stuff the new value back into one of the variables (tedRunningTotalCost in this example):
indigo.variable.updateValue(tedRunningTotalCost, u"{0:.2f}".format(newValue))
#! /usr/bin/env python
tedRunningTotalCost = indigo.variables[163627038]
tedRunningTotalCost2 = indigo.variables[1726430330]
newValue = tedRunningTotalCost.getValue(float) / 3600
indigo.variable.updateValue(tedRunningTotalCost2, u"{0:.4f}".format(newValue))
siclark wrote:Cheers Neil.. Yes this is where I want to get to with the logging, ideally before I switch to their smart tariff so I can compare current cost vs cost on their smart tariff. However for now I am on Aeon local power sensor (every 30 seconds) rather than SMETS2 and with new lockdown it will be a while before I get one.
However I also want to drill into drivers of the usage. so Chris's detial is also very useful. Ideally I want to take those total cost bars and split them into known (ie underfloor heating, lights etc) where I have accurate use, and unknown and by time of day so I can look for areas to reduce.
I already know my standing use is too high (which is why I am interested in Octopus smart as I should pay less for that over night than I do now.
The Go tariff sounds interesting too but probably I dont use enough in those hours without an electric car. .
sumocomputers wrote:ust one note on the Go tariff, which sounds like an EV Time of Use plan similar to what we have here in California, though ours seems fairly generous, since my specific plan is not limited to just the EV charging port, but includes the wholehouse.
neilk wrote:
Back to the main topic, I am considering joining the beta programme for https://octopus.voltaware.com which looks really interesting and frankly sounds too good to be true, they basically measure the electrical noise across your supply and then "disaggregate" this to identify individual appliances without having to energy monitor them independently (at least for certain load types). Tempted to just order one and have a play, and potential for another plugin !
neilk wrote:Back to the main topic, I am considering joining the beta programme for https://octopus.voltaware.com which looks really interesting and frankly sounds too good to be true, they basically measure the electrical noise across your supply and then "disaggregate" this to identify individual appliances without having to energy monitor them independently (at least for certain load types). Tempted to just order one and have a play, and potential for another plugin !
siclark wrote:Shame your own Electrcian can’t install it. Got a mate that could do it for a lot less than their installer would charge.
sumocomputers wrote:
I am very curious how well this works. Sense promises something similar (not sure if it uses electrical noise), but is largely disappointing when it comes to identifying appliances (as in it doesn't really work for much other than things like Refrigerators that have a steady and repeatable pattern).
I ended up using those little TP-Link smart power outlets that also monitor energy, and plug them into things I know have the potential to use large amounts of energy. In my case Fridge, Furnace Blower, Mac Mini, Washer & Dryer. At less than $20 a piece, they started as a throw away experiment, and I have come to love them.
siclark wrote:Maybe it was Sense that I read about a while ago. I heard the same.
I use those smart power outlets too for a lot of my devices, and the virtual energy plugin for devices that I know are on, ie electric underfloor heating, and smart bulbs, with known electricity usage,but where they dont report power.
However, be careful, I had a smart power outlet melt on me a little while ago which was connected to my drier. Now it might have been that the weight of the plug cord meant it wasnt quite seated correctly, so some gaffer tape might have helped, and the socket to be fair did cut out immediately, the damage was made worse by my not realising why the socket had turned off and my repeatedly turning it back on, but be careful on using these on appliances with high current requirements. .
Users browsing this forum: No registered users and 2 guests