We have moved at community.getvera.com

Author Topic: ST814 Humidity calibration  (Read 12657 times)

Offline dgold21

  • Sr. Newbie
  • *
  • Posts: 23
  • Karma: +1/-0
ST814 Humidity calibration
« on: July 21, 2013, 01:56:06 pm »
The humidity reading on my ST814 is way off, by >10% on average...is there a way to configure an offset in the VeraLite so that it displays and operates on a correct reading?

Offline akbooer

  • Beta Testers
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +291/-70
  • "Less is more"
Re: ST814 Humidity calibration
« Reply #1 on: July 21, 2013, 04:18:42 pm »
Others have expressed the same desire with the temperature calibration.  A simple approach I've used is to make a dummy (humidity) device and have a scene which is regularly scheduled (say every 5 minutes) and reads your sensor device sensor, applies the required calibration, and writes it to the dummy device for display.  Forget about the original hardware and just use the corrected device to display in whatever way you wish.
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline TheAce

  • Sr. Newbie
  • *
  • Posts: 46
  • Karma: +0/-0
Re: ST814 Humidity calibration
« Reply #2 on: July 21, 2013, 05:44:35 pm »
@akbooer - I see by your sig that you're running both the Eversprings and the Aeon 4:1s, by your own experience how is the temp & humidity accuracy on them compared to each other (and compared to reality)?  Thanks!

Offline dgold21

  • Sr. Newbie
  • *
  • Posts: 23
  • Karma: +1/-0
Re: ST814 Humidity calibration
« Reply #3 on: July 24, 2013, 12:33:53 am »
A simple approach I've used is to make a dummy (humidity) device and have a scene which is regularly scheduled (say every 5 minutes) and reads your sensor device sensor, applies the required calibration, and writes it to the dummy device for display.  Forget about the original hardware and just use the corrected device to display in whatever way you wish.

Thanks! I hate to ask, but I've been looking for some definitive info on exactly how to do this, but am not having any luck, or I'm so green that I don't know what I'm searching for. I've had the Vera for only a couple months and only have a few devices added so far, so I'm a rookie.  ;)

Offline akbooer

  • Beta Testers
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +291/-70
  • "Less is more"
Re: ST814 Humidity calibration
« Reply #4 on: July 29, 2013, 06:31:17 am »
Quote
A simple approach I've used is to make a dummy (humidity) device ...

Thanks! I hate to ask, but I've been looking for some definitive info on exactly how to do this, but am not having any luck, or I'm so green that I don't know what I'm searching for. I've had the Vera for only a couple months and only have a few devices added so far, so I'm a rookie.  ;)

Sorry for the delay - busy week!  We're on the forum to share knowledge, so don't hesitate to ask...

From the UI5 interface, follow the tree: APPS > Develop Apps > Create device

This will create an empty 'shell' for a generic device.  You have to tell it a few things to customise it to your needs.  The key boxes to fill in are:

  • Device type:  urn:schemas-micasaverde-com:device:HumiditySensor:1
  • Description: choose a name for your device eg. Calibrated Humidity
  • Upnp Device Filename: D_HumiditySensor1.xml
  • Room: pick one from the drop-down menu if you want to

Hit the Create device button and wait (I think it's a restart.)  You should find your new device with the correct icon in the room you assigned (if not, then restart again!).  This doesn't have an implementation file attached to it (or any parent) so it doesn't actually do anything, but it's a place to hang the new calibrated measurement.

All you need to make it 'work' in the way we discussed is to have a separate scene with some Luup code that reads from the actual sensor, does the calibration, and writes the new value to this dummy device.  Ask if you need help with that once you've created the dummy device.

Good luck!
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline akbooer

  • Beta Testers
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +291/-70
  • "Less is more"
Re: ST814 Humidity calibration
« Reply #5 on: July 30, 2013, 06:10:23 am »
@akbooer - I see by your sig that you're running both the Eversprings and the Aeon 4:1s, by your own experience how is the temp & humidity accuracy on them compared to each other (and compared to reality)?  Thanks!

I've started logging temperature and humidity for an Everspring and an Aeon which are sitting side by side.  Not a great test because this is in a rather stable temperature environment, but there are humidity swings.  Qualitatively, I would say that the temperatures are generally +/- 1 degree C, but the humidity seems to differ by about 7 or 8 percentage points.

I have just acquired two more 4-in-1 devices (brave, huh?) so will set up another one there too, and one somewhere else next to another Everspring.  I will post the results in a week or so, once I have a bit of data.  As to absolute accuracy... who knows?!  Compared to other measurements (Owl power meter, room thermostat) temperatures are again +/- 1 degree or so.  I have no independent humidity measurement (a notoriously difficult measurement, especially with cheap sensors.)
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline akbooer

  • Beta Testers
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +291/-70
  • "Less is more"
Re: ST814 Humidity calibration
« Reply #6 on: August 10, 2013, 03:07:24 am »
I have just acquired two more 4-in-1 devices (brave, huh?) so will set up another one there too, and one somewhere else next to another Everspring.  I will post the results in a week or so, once I have a bit of data.

The results are in... and confirm my earlier suspicions.  Two test in separate places with different devices (two each of ST814 and 4-in-1).  I conclude:

  • The ST814 results are, on average, about 7 to 8 percentage points above the 4-in-1
  • The ST814 responds faster to changes - the up and down kicks are genuine (aside from quantisation)
  • By comparison with other measurements, I believe the 4-in-1 to be closer to the truth

For me now, though, this is a moot point.  Since discovering the Netatmo device with its plethora of sensors, build quality, and ease of installation, I shall be migrating to these sensors (but still logging on the Vera).
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline AlanNatsFan

  • Newbie
  • *
  • Posts: 6
  • Karma: +2/-0
Re: ST814 Humidity calibration
« Reply #7 on: August 17, 2013, 03:15:00 pm »
akbooer, I am curious were you able to integrate the Netatmo inot your vera? I tried the AEOTEC 4in1. The humidity sensor never worked correctly (I put it in a bathroom and turned on the shower, the humidity never rose above 23). I tried contacting both AEOTEC and MCV to no avail. My next try is the Everspring. If that doesn't work I may spring for the NetAtmo, but I have never programmed in LUUP or JSON sooo I am not anxious to undertake that project.

Thanks in advance for your response.

Alan

Offline akbooer

  • Beta Testers
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +291/-70
  • "Less is more"
Re: ST814 Humidity calibration
« Reply #8 on: August 17, 2013, 05:27:49 pm »
I am curious were you able to integrate the Netatmo inot your vera? I tried the AEOTEC 4in1.

Yes indeed, had it running for over a week now. Here's a comparison of the outdoor temperature and humidity compared to a local Met Office station from the Wunderground plugin.  Some may say this is not a good match, but actually, it is.  There outdoor sensor is at the back of a block-built car port, not in a Stevenson screen, so well shielded and heavily damped (if I may use that term) from rapid temperature and humidity variations - the average values look about right.

There is lots of discussion in the Netatmo thread http://forum.micasaverde.com/index.php/topic,13489.msg122948.html.  Although the original code from Sebastien Joly works fine, it bears some modification.  I've got routines for authentication, token rotation, device and measurement info working properly over HTTPS POST requests.  Also auto-configuration for any number of stations and modules owned by the specified account. It's currently running in the context of a scene code which is scheduled every 5 minutes.  It could be a plugin, but I'm not really keen on all the extra overhead with JSON files, etc., to make it so.  I just don't use the Vera UI at all, if I can help it.
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline ckonash

  • Newbie
  • *
  • Posts: 7
  • Karma: +0/-0
Re: ST814 Humidity calibration
« Reply #9 on: December 26, 2013, 10:49:58 pm »
Quote
A simple approach I've used is to make a dummy (humidity) device ...

Thanks! I hate to ask, but I've been looking for some definitive info on exactly how to do this, but am not having any luck, or I'm so green that I don't know what I'm searching for. I've had the Vera for only a couple months and only have a few devices added so far, so I'm a rookie.  ;)

Sorry for the delay - busy week!  We're on the forum to share knowledge, so don't hesitate to ask...

From the UI5 interface, follow the tree: APPS > Develop Apps > Create device

This will create an empty 'shell' for a generic device.  You have to tell it a few things to customise it to your needs.  The key boxes to fill in are:

  • Device type:  urn:schemas-micasaverde-com:device:HumiditySensor:1
  • Description: choose a name for your device eg. Calibrated Humidity
  • Upnp Device Filename: D_HumiditySensor1.xml
  • Room: pick one from the drop-down menu if you want to

Hit the Create device button and wait (I think it's a restart.)  You should find your new device with the correct icon in the room you assigned (if not, then restart again!).  This doesn't have an implementation file attached to it (or any parent) so it doesn't actually do anything, but it's a place to hang the new calibrated measurement.

All you need to make it 'work' in the way we discussed is to have a separate scene with some Luup code that reads from the actual sensor, does the calibration, and writes the new value to this dummy device.  Ask if you need help with that once you've created the dummy device.

Good luck!



Hello,

I am a little new to the Vera systems but after seeing that my ST814 was reading 4 degrees higher than a nearby thermostat I followed your instructions to create a dummy device to display a corrected temperature.  I do not know how to write the code into a scene to have this new dummy device display a calculated/corrected value.  Is there anyone that might be able to walk me through the steps?  Thank you so much in advance. 

Chris

Offline RexBeckett

  • Beta Testers
  • Master Member
  • *****
  • Posts: 3891
  • Karma: +483/-12
Re: ST814 Humidity calibration
« Reply #10 on: December 27, 2013, 03:27:06 am »
Assuming you have created a dummy TemperatureSensor device using the following:

Device type:  urn:schemas-micasaverde-com:device:TemperatureSensor:1
Upnp Device Filename: D_TemperatureSensor1.xml

Create a scene with a schedule that runs it periodically - maybe 5 minutes? Paste this code into the scene's LUUP tab. Change dIDT and dIDD to the device IDs on your system. Change adjust as required.

Code: [Select]
local dIDT = 14     -- Device ID of actual temperature device
local dIDD = 200    -- Device ID of dummy temperature device
local adjust = 4    -- Amount to adjust temperature
local curTemp = tonumber((luup.variable_get("urn:upnp-org:serviceId:TemperatureSensor1","CurrentTemperature",dIDT)))
local newTemp = curTemp + adjust
luup.variable_set("urn:upnp-org:serviceId:TemperatureSensor1",{CurrentTemperature=curTemp},dIDD)


Offline Don Diego

  • Hero Member
  • *****
  • Posts: 534
  • Karma: +300/-3
Re: ST814 Humidity calibration
« Reply #11 on: June 16, 2014, 12:32:15 pm »
Assuming you have created a dummy TemperatureSensor device using the following:

Device type:  urn:schemas-micasaverde-com:device:TemperatureSensor:1
Upnp Device Filename: D_TemperatureSensor1.xml

Create a scene with a schedule that runs it periodically - maybe 5 minutes? Paste this code into the scene's LUUP tab. Change dIDT and dIDD to the device IDs on your system. Change adjust as required.

Code: [Select]
local dIDT = 14     -- Device ID of actual temperature device
local dIDD = 200    -- Device ID of dummy temperature device
local adjust = 4    -- Amount to adjust temperature
local curTemp = tonumber((luup.variable_get("urn:upnp-org:serviceId:TemperatureSensor1","CurrentTemperature",dIDT)))
local newTemp = curTemp + adjust
luup.variable_set("urn:upnp-org:serviceId:TemperatureSensor1",{CurrentTemperature=curTemp},dIDD)

Rex--

  Thanks for your help. Since we are dealing with a humidity sensor shouldn't  the last line above be (I'm note sure it makes a difference):

luup.variable_set("urn:upnp-org:serviceId:HumiditySensor1",{CurrentTemperature=curTemp},dIDD)

Also, is the device id (i.e., diDT) that of the parent or child of the humidity sensor (ST814)?

At this point I'm getting a blank adjusted humidity reading on the GUI (for the new device). I have made sure the scene runs first and have reloaded LUUP.

  Don
Vera 3 (@1.5.622) (3); Vera Plus (2);
Trane/Schlage TStats (1); Schlage Deadbolt (2); Kwikset Lock (3);  GE 45602 Dimmer (14); GE 45603 Dimmer (17); HSM-100 (16); Everspring Siren (8), Everspring Temp/Humidity (4); HSM 200 (1)

Offline akbooer

  • Beta Testers
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +291/-70
  • "Less is more"
Re: ST814 Humidity calibration
« Reply #12 on: June 16, 2014, 12:42:00 pm »
I think you will find that it should be:

Code: [Select]
luup.variable_set("urn:upnp-org:serviceId:HumiditySensor1",{CurrentLevel=curTemp},dIDD)

But, there again, ALL the temperature references should be humidity, if that's what you've created.

[Edit: WRONG syntax... see later post]
« Last Edit: June 16, 2014, 03:08:36 pm by akbooer »
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline Don Diego

  • Hero Member
  • *****
  • Posts: 534
  • Karma: +300/-3
Re: ST814 Humidity calibration
« Reply #13 on: June 16, 2014, 01:49:53 pm »
I think you will find that it should be:

Code: [Select]
luup.variable_set("urn:upnp-org:serviceId:HumiditySensor1",{CurrentLevel=curTemp},dIDD)

But, there again, ALL the temperature references should be humidity, if that's what you've created.

Hi --

  Thanks for the information. The other part of the question is:

Also, is the device id (i.e., diDT) that of the parent or child of the humidity sensor (ST814)?

    Don
Vera 3 (@1.5.622) (3); Vera Plus (2);
Trane/Schlage TStats (1); Schlage Deadbolt (2); Kwikset Lock (3);  GE 45602 Dimmer (14); GE 45603 Dimmer (17); HSM-100 (16); Everspring Siren (8), Everspring Temp/Humidity (4); HSM 200 (1)

Offline akbooer

  • Beta Testers
  • Master Member
  • *****
  • Posts: 6387
  • Karma: +291/-70
  • "Less is more"
Re: ST814 Humidity calibration
« Reply #14 on: June 16, 2014, 02:19:07 pm »
Also, is the device id (i.e., diDT) that of the parent or child of the humidity sensor (ST814)?
If you want the number you are writing to appear on the child device, then it is the id of that device.  Writing directly to the ST814 would simply (temporarily) overwrite that device's reading, until it was refreshed with a real measurement.
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.