17.05.2016, 21:57
Hello Matt,
I did som more testing and found out the following: I managed to get the station data through api.netatmo.com/api/getstationsdata?access_token=.... and I got this for the wind gauge:
{
"_id":"....",
"type":"NAModule2",
"last_message":1463517535,
"last_seen":1463517535,
"dashboard_data":{
"WindAngle":239,
"WindStrength":2,
"GustAngle":237,
"GustStrength":3,
"time_utc":1463517522,
"WindHistoric":[{"WindStrength":2,"WindAngle":242,"time_utc":1463514196},{"WindStrength":2,"WindAngle":242,"time_utc":1463514497},{"WindStrength":2,"WindAngle":244,"time_utc":1463514805},{"WindStrength":2,"WindAngle":239,"time_utc":1463515106},{"WindStrength":2,"WindAngle":246,"time_utc":1463515407},{"WindStrength":2,"WindAngle":244,"time_utc":1463515709},{"WindStrength":2,"WindAngle":236,"time_utc":1463516010},{"WindStrength":2,"WindAngle":244,"time_utc":1463516311},{"WindStrength":2,"WindAngle":246,"time_utc":1463516619},{"WindStrength":2,"WindAngle":244,"time_utc":1463516920},{"WindStrength":2,"WindAngle":237,"time_utc":1463517221},{"WindStrength":2,"WindAngle":239,"time_utc":1463517522}
],
"date_max_wind_str":1463470072,
"date_max_temp":1463436297,
"date_min_temp":1463436297,
"min_temp":0,
"max_temp":0,
"max_wind_angle":273,
"max_wind_str":10
},
"data_type":["Wind"],
"module_name":"WIND GAUGE",
"last_setup":1462201564,
"battery_vp":6210,
"battery_percent":100,
"rf_status":75,"firmware":14}
],
in my library script I added these lines:
-- Module Wind
if (netatmo_debug) then
alert("netatmo module 2")
end
grp.update("Netatmo Wind",response_decode.body.modules[2].dashboard_data.WindStrength,dt.float16)
grp.update("Netatmo Wind Angle",response_decode.body.modules[2].dashboard_data.WindAngle,dt.float16)
grp.update("Netatmo Gust",response_decode.body.modules[2].dashboard_data.GustStrength,dt.float16)
grp.update("Netatmo Gust Angle",response_decode.body.modules[2].dashboard_data.GustAngle,dt.float16)
grp.update("Netatmo Wind_max",response_decode.body.modules[2].dashboard_data.max_wind_str,dt.float16)
grp.update("Netatmo Wind module battery",response_decode.body.modules[2].dashboard_data.battery_percent,dt.float16)
but everytime I call refresh_netatmo() function I do not get any data except from the main indoor and outdoor module. Can you please help me out here? I also do not get any data from your premade script for the rain sensor. I used it like you posted it here, except that I changed the number, because in Netatmo's documentation it is stated, that the rain module has number 3.
Thank you veru much for your help.
Peter
I did som more testing and found out the following: I managed to get the station data through api.netatmo.com/api/getstationsdata?access_token=.... and I got this for the wind gauge:
{
"_id":"....",
"type":"NAModule2",
"last_message":1463517535,
"last_seen":1463517535,
"dashboard_data":{
"WindAngle":239,
"WindStrength":2,
"GustAngle":237,
"GustStrength":3,
"time_utc":1463517522,
"WindHistoric":[{"WindStrength":2,"WindAngle":242,"time_utc":1463514196},{"WindStrength":2,"WindAngle":242,"time_utc":1463514497},{"WindStrength":2,"WindAngle":244,"time_utc":1463514805},{"WindStrength":2,"WindAngle":239,"time_utc":1463515106},{"WindStrength":2,"WindAngle":246,"time_utc":1463515407},{"WindStrength":2,"WindAngle":244,"time_utc":1463515709},{"WindStrength":2,"WindAngle":236,"time_utc":1463516010},{"WindStrength":2,"WindAngle":244,"time_utc":1463516311},{"WindStrength":2,"WindAngle":246,"time_utc":1463516619},{"WindStrength":2,"WindAngle":244,"time_utc":1463516920},{"WindStrength":2,"WindAngle":237,"time_utc":1463517221},{"WindStrength":2,"WindAngle":239,"time_utc":1463517522}
],
"date_max_wind_str":1463470072,
"date_max_temp":1463436297,
"date_min_temp":1463436297,
"min_temp":0,
"max_temp":0,
"max_wind_angle":273,
"max_wind_str":10
},
"data_type":["Wind"],
"module_name":"WIND GAUGE",
"last_setup":1462201564,
"battery_vp":6210,
"battery_percent":100,
"rf_status":75,"firmware":14}
],
in my library script I added these lines:
-- Module Wind
if (netatmo_debug) then
alert("netatmo module 2")
end
grp.update("Netatmo Wind",response_decode.body.modules[2].dashboard_data.WindStrength,dt.float16)
grp.update("Netatmo Wind Angle",response_decode.body.modules[2].dashboard_data.WindAngle,dt.float16)
grp.update("Netatmo Gust",response_decode.body.modules[2].dashboard_data.GustStrength,dt.float16)
grp.update("Netatmo Gust Angle",response_decode.body.modules[2].dashboard_data.GustAngle,dt.float16)
grp.update("Netatmo Wind_max",response_decode.body.modules[2].dashboard_data.max_wind_str,dt.float16)
grp.update("Netatmo Wind module battery",response_decode.body.modules[2].dashboard_data.battery_percent,dt.float16)
but everytime I call refresh_netatmo() function I do not get any data except from the main indoor and outdoor module. Can you please help me out here? I also do not get any data from your premade script for the rain sensor. I used it like you posted it here, except that I changed the number, because in Netatmo's documentation it is stated, that the rain module has number 3.
Thank you veru much for your help.
Peter