Has anyone managed to monitor PC hardware (Windows) in Vera?
CPU / Ram usage and HDD temps etc.
Has anyone managed to monitor PC hardware (Windows) in Vera?
CPU / Ram usage and HDD temps etc.
Looks like they have support for Open Hardware Monitor on Home Assistant.
If you have rest api, just use my virtual device plugin and update them via node red. Or use site sensor plugin to do it directly from the plugin itself.
I’ve also been reading about Influxdb and grafana and I see there is a Veraflux plugin to send sensor data from Vera to influxdb.
Gonna have a go and set this up on my Raspberry Pi but had to order a bigger SD card first.
I’ll install Glances on my PC and have a look at node red or site sensor.
I followed this guide here to install Glances on my Windows server. I created a Windows service however for Glances rather than starting the Glances.exe via a scheduled task.
I can access the Glances web page OK via my laptop and it looks similar to this:
Here is the Glances RESTFUL JSON API documentation.
I can enter this command in Chrome Browser and get a response back:
http://192.168.0.100:61208/api/3/mem
{"total": 8454860800, "available": 2304696320, "percent": 72.7, "used": 6150164480, "free": 2304696320}
However when I enter a command like this to focus on to a particular item, I get weird symbols back and I don’t know why?
http://192.168.0.100:61208/api/3/mem/percent
Returns this:
x��V*H-JN�+Q�R07�3��4KU
try the curl version. maybe they’re search for some headers and the browser is not sending them.
curl is available for Windows too.
Hi
Its working OK in Curl using this command:
curl -X GET http://192.168.0.100:61208/api/3/mem/percent
Returns:
{“percent”: 46.0}
Any idea how to update a Vera virtual sensor with this value via Node-Red ?
I am going to install your virtual devices plugin now on my test Vera Edge unit.
Thanks
Having a quick look at your readme here
Is there no Generic Sensor to display a value ?
Similar to this one on my Fibaro Motion Sensor:
device_type = urn:schemas-micasaverde-com:device:GenericSensor:1
device_file = D_GenericSensor1.xml
device_json = D_GenericSensor1.json
No Temperature sensor device either ?
Mate I need your help again with Node-Red !
I’ve just created a HTTP Request to query the Glances server for the Mem % Used.
This works and gives me a value.
I now need to figure out how to pass this value back to a virtual device in Vera.
I’ve manually created a Generic virtual device and added a variable called “CurrentLevel”
I can update this devices variable by using this HTTP command sent to Vera:
http://VERA-IP/port_3480/data_request?id=lu_variableset&DeviceNum=100&serviceId=urn:micasaverde-com:serviceId:GenericSensor1&Variable=CurrentLevel&Value=4.0
This all works fine.
So the only part I am missing is in Node-Red, how to take the value and send it back to Vera and this virtual device.
Thanks.
No need to virtual device for those. Just create a device as the normal one and update their variables.
No need in your plugin you mean? I guess not.
As you can see above I have just manually created a Generic Sensor on Vera using the Apps - Develop Apps - Create Device
You send it back with a http request set to post and the body of the request is in msg.payload
“http://192.168.1.11:3480/data_request”
msg.payload = {"id": "variableset",
"DeviceNum": "24",
"serviceId": "urn:bochicchio-com:serviceId:VeraAlexa1",
"Variable": "OneTimePassCode",
"Value": msg.payload.present};
return msg;
edit for your needed values.
You could also do this in vera with rigpapa site sensor.
Hi
So this would be my code for this virtual device
msg.payload = {"id": "variableset",
"DeviceNum": "100",
"serviceId": "urn:micasaverde-com:serviceId:GenericSensor1",
"Variable": "CurrentLevel",
"Value": msg.payload.present}
Where do I add this code in to a Function node ?
yes in a function node before the http request. Add return msg;
to the end.
you could also use a get request using mustache template
in the http request node use url similar to
http://VERA-IP/port_3480/data_request?id=lu_variableset&DeviceNum=100&serviceId=urn:micasaverde-com:serviceId:GenericSensor1&Variable=CurrentLevel&Value={{{payload.present}}}
Exactly that. Generic level, temp, humidity and light device are just containing a variable. No actions, so no need for virtual devices. Sorry, I was thinking that you’d need some trippable sensor, but that’s not the case.
Don’t think I have it right.
HTTP Request send to Glances Hardware Monitoring Server:
Function with code:
HTTP Request back to Vera:
Its not working LOL.
typo from me it’s msg.payload.percent not present, bad eye sight no reading glasses. lol
My eye sight is going as well I’ve just started wearing reading glasses, old age.
I’ve change it to “Value”: msg.payload.percent} in the code but its still not changing the value on the virtual device in Vera unfortunately.
Best Home Automation shopping experience. Shop at Ezlo!
© 2022 Ezlo Innovation, All Rights Reserved. Terms of Use | Privacy Policy | Forum Rules