Free graphs for your temp/power sensors

Sounds right in principle, but since I don’t use hundredgraphs, I can’t vouch for syntax. Service iD is urn:toggledbits-com:serviceId:ReactorValues, by the way; if hundredgraphs doesn’t require service ID as part of its configuration, that’s something the author needs to fix–state variable names alone are not unique, must use the combination of service ID and name.

Have you created you model for AI yet, ipstas? I have done work with building models for Machine learning. :wink:

I even built a Machine Learner and trained it based on Vera API data. Kept feeding it json data for weeks and weeks.

It ended up not being very smart. LOL!

But I did let it control everything in my house for about three days during the week. It was easy for it to learn our habits because everyday is the same during the week. get up, go to work, come home, go to bed repeat. LOL!

We have just released the beta version of the plugin for HundredGraphs and looking for testers.
Previously you have to install the lua file yourself and that created a lot of confusion.

The plugin finds energy reporting devices by itself. You would only need to update the API KEY in Variables and change the reporting interval if desired.

The version 1.4 is published on Alt App store in ALTUI

Please check it out and let me know if you have any issues (pretty much sure there will be)

Should be a bug. The idea was exactly the opposite, so you can have different sites reporting same key

Not yet, we need to get more raw data before it can be anything useful. But I would love to start earlier even if the AI model would not be so smart.

So if you want to play with that, I really appreciate it

Since HVAC is a big deal in energy consumption we surely should have that one reporting. I will look into adding it to the plugin

unfortunately serviceVar in that case would be ModeStatus and the value it reports is CoolOn/CoolOff, however the calculate function can be used for that.

It would be something like:

local function cCool( dev1, svc, var )
    local data = luup.variable_get( svc, var, dev1 )
    local mode = 0
    if (data == 'CoolOn') then
        mode = 1
    end
	return mode
end

-- replace 001 with your thermostat id and urn:HVAC with real serviceId
VARIABLES = {
    { key='HVAC_Mode', calculate=function() return cCool(001,  "urn:HVAC", "ModeStatus") end, serviceVar="Mode" } 
}

Now you have key HVAC_Mode with the value 1/0

local function cCool( dev1, svc, var )
local data = luup.variable_get( svc, var, dev1 )
local mode = 0
if (data == ‘CoolOn’) then
mode = 1
elseif (data == ‘Off’) then
mode = 0
elseif (data == ‘HeatOn’) then
mode = -1
elseif (data == ‘Auto’) then
mode = 10
end
return mode
end

{ key=‘HVAC_Mode’, calculate=function() return cCool(487, “urn:upnp-org:serviceId:HVAC_UserOperatingMode1”, “ModeStatus”) end, serviceVar=“Mode” },

does it ever report “Auto” in the Operating Mode? I don’t think so. My previous thermostat would not. Auto was reported by the Mode Target

The service file lists AutoChangeOver as a possible value for both ModeTarget and ModeStatus, but I think it’s just a carry-over from the UPnP.org original file, I’ve never seen ModeStatus use it in the Vera world.

so i need more help

my outdoor Ac unit uses 3,300 Watts it doesnt always run when the unit “urn:upnp-org:serviceId:HVAC_UserOperatingMode1”, “ModeStatus”, = Cool

but it does when urn:micasaverde-com:serviceId:HVAC_OperatingState1
-[ModeState] = Cooling
(Moodestate has thus far 2 states - Idle and Cooling)
I need to incorporate that in total as watts and also be able to calculate a kWh usage from that
so idle = 0
cooling = 1 (meaning the unit outside is on) so for every hr its on it uses 3.3 kW or 3300 watts

yes i could just get an Aeotec HEM and pop on it but ill do that later

should be simple enough

local function cCoolWt( dev1, svc, var )
    local data = luup.variable_get( svc, var, dev1 )
    local mode = 0
    if (data == 'Cooling') then
        mode = 3300
    end
	return mode
end

VARIABLES = {
    { key='HVAC_Wts', calculate=function() return cCoolWt(001,  "urn:micasaverde-com:serviceId:HVAC_OperatingState1", "ModeState") end, serviceVar="Watts" } 
}

That’s it, 3300 is reported on the HG side when AC is running

{ key=‘HVAC_Wts’, calculate=function() return cCoolWt(001, “urn:micasaverde-com:serviceId:HVAC_OperatingState1”, “ModeState”) end, serviceVar=“mode*” }

thanks

Thanks ipstas, your interrface is perfect- Simple enough I got it working with several sensors in 30 mins and I don’t know anything about lua yet. That is a good design-- usable by users that don’t know the details of what you did.

Temp and Hum sensors are working perfectly. I also added a couple door sensors which I currently monitor via Prowl. I’d like to have hundredgraphs show time history plots of the door sensors, with a baseline of say value=0 and a blip of say value=1 for any minute a door was opened so activity could be monitored. In non-averaging mode, I have tried both countTotal=false and countTotal=true, but even with true the sum remains at 0 I presume because the door was never polled while open. My guess is that what is needed is that a door-opening event would push an update to get counted in your Moniton.lua but I have no Idea what is actually needed. Has anybody set up door sensors in a way that works well?

key=“DoorGarageSide”, deviceId = 419, serviceId=‘urn:micasaverde-com:serviceId:SecuritySensor1’, serviceVar=“ArmedTripped”, countTotal=true },

Cheers!

Site and plugin were both updated.
The new version of plugin 2.1 is available on Alt App Store. It is highly recommended that you would update to it.
TL;DR Now you can rename the device on a Vera side anytime, it sill would report the right device based by ID. Also, you can rename the device on HG side too, make it shorter, longer, fancier, easy to remember

Tech stuff
The improvements were done in sending results over the Post instead of Get, this allowed to send devices IDs and units (Watts, Temp, etc) as well. It also would allow HundredGraphs.com finally move closer to release the Energy DashBoard
We still accept over the data over the old API with the old lua file, however it is going to be phased out in the future.

1 Like

Installed the plugin (was using the LUA file before). But i can’t seem to enable the plugin. It enables for a short time then goes back to the disabled state. Any idea what i am doing wrong?

Also with the plugin i can’t seem to use the data coming from the system monitor plugin. They don’t show up in the devices list. With the LUA file no problem in using this serviceid.

Thanks by the way for the work on this!

It came out 2.0 had a bug that prevented enabling it. Can you try to get 2.1?

I am sorry, did not realise you published in the AltUi store. I downloaded from the Mios app store which is on version 1.8 at the moment.
Maybe possible to post the pugin files so i can manually update?

It will be added to the official store as well. As for updating files separately I would strongly advise against that as it might mess the setup.

Announcement:
We will be applying to couple startup accelerators with HyndredGraphs and if you like it, we would like to ask you for your recommendation at F6S.com (email is required)