Power Arithmetic plugin

I’m not sure why. A Power Arithmetic device is using the same built-in service type (S_EnergyMetering1.xml) as any other power-measuring device.

I don’t use dataMine, so I can’t say how it decides which devices can measure power, but I hope it is going by the list of services that the device type enumerates.

I imagine that the answer is in dataMine’s source code.

It’s exposed as Watts in datamine… see attached screenshot.

Thanks Futzie
Solved it. did a reload of my browser (Chrome), and the energy meter properties became available. Should have known that would be the solution LOL.

I am newbee about z-wave and vera3. Need some help. How can I shut-down a device which connected to fibaro wall plug when reach e.g 1000 watt ?

Thank you for a great plugin :wink:

I have a problem.

Want to calculate my house heating power. It is a water based system and I know the water flow (it?s actually constant) and the temperature of the water before and after the heat exchanger.

The power is calculated by the formula “Power in kW=Flow (l/s) * (temp out - temp in) * 4,18”

But to be able to do this I guess I need a function “temp(device ID)”…

So you’d like to have a function that returns temperature. I can add that.

So you’d like to have a function that returns temperature. I can add that.[/quote]

Yes, that would fulfill my needs. Thank you in advance;-)

Another, thing.

All “Power Arithmetic” and my “CurrentCost EnviR Energy Monitor” devices show power consumption in the Mios web interface as expected.

But in my AutHomationHD Android app the “Power Artihmetic” devices shows up with a questionmark as symbol and I have to click on the device to se the power consumption. But my “CurrentCost EnviR Energy Monitor” shows up with a power icon and shows the power consumption in the “device” view.

Is this something that is possible to address in the plugin or is it something that have to be addressed in the AutHomation app?

Yes, that would fulfill my needs. Thank you in advance;-)[/quote]

Try this attached file, which provides temperature(d) and humidity(d) functions. The temperature() function makes no effort to understand the temperature units.

The plugin uses the standard service ID of “urn:micasaverde-com:serviceId:EnergyMetering1”. Perhaps AutHomationHD needs to recognize the device type (“urn:schemas-futzle-com:device:PowerArithmetic:1”) too. Garrett will know for sure.

Yes, that would fulfill my needs. Thank you in advance;-)[/quote]

Try this attached file, which provides temperature(d) and humidity(d) functions. The temperature() function makes no effort to understand the temperature units.[/quote]

Thanks! It works perfectly and I now have an Power Artihmetic device showing my heating consumption in real time :wink:

The plugin uses the standard service ID of “urn:micasaverde-com:serviceId:EnergyMetering1”. Perhaps AutHomationHD needs to recognize the device type (“urn:schemas-futzle-com:device:PowerArithmetic:1”) too. Garrett will know for sure.[/quote]

I added the device type to the energy meter portion of my app. So it should show up as an energy device and report the watt usage. Currently this will only be available in the alpha builds.

  • Garrett

Hi,

very strange, fews month ago i was saying that the formula was not refreshed every time to use it with datamine. (using ergy plugin)

today the formula power(id) or switch(id) is not recognised ! what could be the issue ? Thanks

(i have already delete the module and create a new one , and restart the box )

in datamine the formula is seen as textTEXT ! return ‘POWER(id)’, id is the id of fibaro wall plug.

i don t use ergy plugin is it the problem ? > say power function not recognised
if ergy plugin created > value is TEXT ?

[quote=“Savonarole, post:33, topic:176302”]…
power(id)

POWER(id)
…[/quote]

I just installed the latest files and created a power arithmetic device with a formula [tt]power(186) + 10[/tt] and it correctly displayed 10 more watts than device 186. The function name must be entered in lower case, so if you’ve written [tt]POWER[/tt], there is no such function.

I don’t use dataMine so I can’t offer any insight there.

No, the Ergy plugin won’t be involved in any way. You are IMO correct to not use it.

power arithmetic is OK now and graph too , i have poor eyesight ::slight_smile:

exact is ‘power(id)’, where ‘id’ is the number of module NOT ‘id module’, (an error in a sum of 5 plug !)

for the draft in datamine not take ‘formula’ but ‘watts’ variable.

and restart the vera UI5 after loading plug to be sure …

THANKS futzle nice job

Great app.
Is there a function to look at the percentage value of a dimmer switch so the wattage can be calculated from the switch % value?

There isn’t, but it’s a good idea. Do you need anything more than the percentage (e.g. sqrt() or exp() or some other algebraic operation)?

I’m not showing any data after an hour…and after reloading like 10 times.

Thought it was simple formula:

power(8) + power(10) + power(12) + power(14) + power(16) + power(18) + power(20) + power(22) + power(24) + power(26) + power(28) + power(30) + power(32) + power(34) + power(36) + power(38) + power(40) + power(42) + power(205) + power(206) + power(214) + power(216) + power(218) + power(219) + power(228) + power(233) + power(242) + power(243) + power(244) + power(252) + power(256) + power(259) + power(265) + power(271) + power(272) + power(276) + power(282) + power(287) + power(289) + power(294) + power(295) + power(362) + power(375) + power(303) + power(446) + power(448) + power(449) + power(465) + power(486) + power(487) + power(363)

Half of these have UserSuppliedWattage providing the watts values, the rest have real power meters (like an Aeon smart switch or smart strip)

It might be the formula length. Try a shorter one and see if it works. Then expand it a bit with another term or two.

This plugin uses a recursive-descent parser so it’s not the most efficient in terms of CPU or memory use. It’s easily possible that your formula overflows a stack.

Edit: you can reduce the depth of the parse tree by using parentheses to halve the length of each bit being added.

((A + B) + (C + D)) + ((E + F) + (G + H))

or just divide it in two