Does any one have a power monitor piston using a whole house meter? I just picked up a Gen 5 AeoTec HEM. Looking for ideas.
Power Monitor Piston
Like this?
╔══════════════════════════════════╦═══════════════════════════════════════════════╦══════════╦═══════════════════════════════════════════╗
║ ║ Power ON time (d hh:mm) ║ Max. W ║ Energy (kWh) ║
║ Device ║ Today ║ Yesterday ║ This month║ Last month║ Today ║ Today ║ Yesterday║This month║Last month║
╠══════════════════════════════════╬═══════════╬═══════════╬═══════════╬═══════════╬══════════╬══════════╬══════════╬══════════╬══════════╣
║ Garage Battery Charger ║ 00:00 ║ 00:00 ║ -02:01 ║ 00:00 ║ 0.0 ║ 0.0 ║ 0.0 ║ 1.9 ║ 0.0 ║
║ Garage Refrigerator ║ 09:09 ║ 23:59 ║ 21d 06:56 ║ 28d 02:24 ║ 185.0 ║ 0.8 ║ 2.2 ║ 66.0 ║ 81.6 ║
║ Hallway Water Heater ║ 00:04 ║ -02:04 ║ -1d 04:41 ║ 2d 02:40 ║ 4699.0 ║ 0.3 ║ 5.2 ║ 87.5 ║ 87.8 ║
║ Kitchen Beverage Refridgerator ║ 05:34 ║ -17:30 ║ -06:44 ║ -1d 20:23 ║ 106.0 ║ 0.6 ║ 1.3 ║ 39.4 ║ 50.7 ║
║ Kitchen Freezer Outlet ║ 06:05 ║ -01:55 ║ -3d 05:10 ║ -1d 06:30 ║ 173.1 ║ 0.9 ║ 2.6 ║ 68.8 ║ 80.0 ║
║ Kitchen Ice Maker ║ 09:09 ║ 23:59 ║ 23d 23:59 ║ 29d 22:28 ║ 274.0 ║ 1.1 ║ 4.9 ║ 100.0 ║ 86.3 ║
║ Kitchen Nespresso Machine ║ 00:00 ║ 00:14 ║ 03:55 ║ 03:37 ║ 0.0 ║ 0.0 ║ 0.1 ║ 1.8 ║ 1.6 ║
║ Kitchen Refridgerator Outlet ║ 03:54 ║ 00:44 ║ -1d 17:27 ║ -2d 04:37 ║ 174.0 ║ 0.3 ║ 1.2 ║ 33.0 ║ 38.3 ║
║ Kitchen Washing Machine ║ 00:00 ║ 00:37 ║ 06:08 ║ 05:34 ║ 3.4 ║ 0.0 ║ 0.1 ║ -51.1 ║ 3.3 ║
║ Pool Pump ║ 00:00 ║ 07:49 ║ 10d 21:10 ║ 10d 12:13 ║ 0.0 ║ 0.0 ║ 11.6 ║ 319.8 ║ 330.4 ║
╚══════════════════════════════════╩═══════════╩═══════════╩═══════════╩═══════════╩══════════╩══════════╩══════════╩══════════╩══════════╝
I still need to figure out why time is negative sometimes…
Count how long lights are on?
Getting these errors back to back.
11:38:52 AM: error ║ An error occurred while executing the event: groovy.lang.MissingMethodException: No signature of method: script1503518895827397514752.isNumber() is applicable for argument types: () values: [] Possible solutions: resume() @ line 7042
11:38:52 AM: error ║ Error calling comparison comp_is_equal_to: groovy.lang.MissingMethodException: No signature of method: script1503518895827397514752.isNumber() is applicable for argument types: () values: [] Possible solutions: resume() @ line 7042
11:38:27 AM: error ║ An error occurred while executing the event: groovy.lang.MissingMethodException: No signature of method: script1503520711103397514752.isNumber() is applicable for argument types: () values: [] Possible solutions: resume() @ line 7042
11:38:27 AM: error ║ Error calling comparison comp_is_equal_to: groovy.lang.MissingMethodException: No signature of method: script1503520711103397514752.isNumber() is applicable for argument types: () values: [] Possible solutions: resume() @ line 7042
Devices are 2 smartthings outlets and 1 AeoTec HEM Gen 5. Everything else is untouched
Ady’s update today fixed this. Should work now.
08/30/2017 >>> v0.2.0e6.20170830 - BETA M2 - Minor fixes regarding some isNumber() errors and errors with static variables using non-defined variables, also updated installation to check for location/timezone setup
This is close to what I am trying to do…Well…trying in my mind, I haven’t actually tried to attempt to write this Piston.
I have an Electric Car and I would like to do the following with WebCoRE:
Send Notification - "Car is Now Charging"
Easy enough
If Power Stays Above “X” Watts for “X” Minutes
Then
Send Notification - “Car is Now Charging”
I have no idea how to do the following:
Send Notification after Car has stopped Charging - “Car Charged for a Total of {Hours:Minutes} Using {X} kWh Costing Approximately {$.}”
To complicate things, I would like for webCoRE to send me a report every month at the close of the Utility Bill Cycle. This seems more in line with the Piston linked by @ady624 but don’t know where to start to send the Notification Report:
Send Notification - “This Month, Car Charged for a Total of {Hours:Minutes} Using {X} kWh Costing Approximately {$.}”
Finally each month at the end of the billing cycle, I would like to reset the kWh and start all over again.
If Date and Time Happens Every Month on the “X”…Don’t even know if this is possible…
Billing Cycle Ends on the 21st of each Month
Cost per kWh=.0125
I am going to attempt to do this with Simple Event Logger, IFTTT and Google Docs but wanted the challenge of having this all done within the webCoRE environment.
Thoughts?
The problem with determining the amount of kWh used for the charge is that you can’t really figure that out unless you have a dedicated meter for the car only or if your baseline is 100% predictable while charging. Mine isn’t (fridge cycling, lights, AC/heat, lights, …). Obviously you could estimate the amount of kWh based on the time it took to charge and the power your charger supports (typically 3.6kW or 7.2kW for level 2). Calculating the amount of $ from the charging is even trickier if you have seasonal time-of-use rates…
Here is the piston I am using to monitor my EV charging (since we have two cars sharing one charger I use the notification to swap the charger to the other car – obviously only if we’re both home and awake):
Seems if you could log the total kWh used, reported by the Power Meter, prior to the charging starting and then log the kWh after the charging stopped, the amount of time it took is irrelevant as you would only need the difference between the two for the calculation…
Charging Starts-Meter is at 83.8kWh
Charging Stops-Meter is at 89.2kWH
Difference from Start to Stop=5.4kWh
Electric Rate=$0.125 per kWh
Total Cost for Charge-5.4kWh X $0.125=$.675
That works if you have a dedicated meter for your charger. Otherwise you just added your base energy usage as well.
Got this worked out but I really had to start from scratch. You guys are genius and some of the Pistons my little feeble mind just could not follow. Going to steal from you all to continue tweaking this one but my initial objective has been met.
Notify that Charging has Started
Notify that Charging is Complete with Time, Energy and Cost.
WooT!