updateWeatherSensors (yet another buienradar script)  [SOLVED]

Moderator: leecollings

User avatar
EdwinK
Posts: 1820
Joined: Sunday 22 January 2017 21:46
Target OS: Raspberry Pi / ODroid
Domoticz version: BETA
Location: Rhoon
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by EdwinK »

waaren wrote: Sunday 13 May 2018 13:39
EdwinK wrote: Sunday 13 May 2018 12:50 [For 'pollen' I use https://www.weeronline.nl/Europa/Nederl ... on/4057944 as an iframe within Dashticz. Not sure if it has a json or other output.
@Edwink,

thx but I don't know how to process the information from that site given the format it is presented in. For now I only process data that is presented in JSON or plain text format. If required I probably could also add some functions to process XML but processing HTML to get the required information is more than 1 bridge too far for my programming skills.
Too bad, but understandable. Will keep using it the way it is now. Who knows, someone else can work this.
Running latest BETA on a Pi-3 | Toon® Thermostat (rooted) | Hue | Tuya | IKEA tradfri | Dashticz V3 on Lenovo Huawei Tablet | Conbee
patzzz

Re: updateWeatherSensors (yet another buienradar script)

Post by patzzz »

Feature request:
It would be nice if the script created a virtual device or environment variable which contains the amount of rain fallen in the last 12 hours.
So I can use that to decide whether or not my garden irrigation should turn on today or not.
Then I would combine that information with the amount of sunhours of (say) 25+ degrees celcius and I can water my garden only when needed.
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by waaren »

patzzz wrote: Sunday 08 July 2018 11:31 Feature request:
It would be nice if the script created a virtual device or environment variable which contains the amount of rain fallen in the last 12 hours.
So I can use that to decide whether or not my garden irrigation should turn on today or not.
Then I would combine that information with the amount of sunhours of (say) 25+ degrees celcius and I can water my garden only when needed.
My preference is to do this with this (separate) script that can also be used by anyone who updates their rainsensors by other scripts / hardware.

moved to new topic http://www.domoticz.com/forum/viewtopic ... 72&t=24113
Last edited by waaren on Monday 09 July 2018 7:25, edited 2 times in total.
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
User avatar
EdwinK
Posts: 1820
Joined: Sunday 22 January 2017 21:46
Target OS: Raspberry Pi / ODroid
Domoticz version: BETA
Location: Rhoon
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by EdwinK »

waaren wrote: Sunday 08 July 2018 15:09
patzzz wrote: Sunday 08 July 2018 11:31 Feature request:
It would be nice if the script created a virtual device or environment variable which contains the amount of rain fallen in the last 12 hours.
So I can use that to decide whether or not my garden irrigation should turn on today or not.
Then I would combine that information with the amount of sunhours of (say) 25+ degrees celcius and I can water my garden only when needed.
My preference is to do this with this (separate) script that can also be used by anyone who updates their rainsensors by other scripts / hardware.
Spoiler: show

Code: Select all

-- setRainVar.lua for [ dzVents >= 2.4 ] 
-- Before first execution create var "amountOfRainDuringLastHours" as type float

return {
    on      =   {   timer           =   { "every hour" },                       -- Triggers the getJsonPart
                    httpResponses   =   { "setRainVar" }                        -- Trigger the handle Json part
                },
                
    logging =   {   level     =   domoticz.LOG_DEBUG,
                    marker    =   "setRainVar"    },

    execute = function(dz,trigger)

        local rainDevice    = dz.devices(128)                                 -- name enclosed in quotes or number without quotes
        local rainVar       = dz.variables("amountOfRainDuringLastHours")     -- name enclosed in quotes or number without quotes 
        local relevantHours = 12                                              -- below 24 we get the (graph) values for a day, above 23 we use year  
        local range         = "day"
        if relevantHours > 23 then range = "year" end 
        
        local function triggerJSON()
            local  URLString   = dz.settings['Domoticz url'] .. "/json.htm?type=graph&sensor=rain&idx=" .. rainDevice.idx .. "&range=" .. range 
            dz.openURL({    url = URLString,
                            method = "GET",
                            callback = "setRainVar" })                      
        end

        local function setVar()
            local Time = require('Time')
            local now  = Time()
            local relevantAmount = 0 
            local delta,t

            rt = trigger.json.result
            if range == "year" then timeCompletion = " 00:00:00" else timeCompletion = ":00" end
                
            for i=1,#rt do                                 -- Loop through the result
                t = Time(rt[i].d .. timeCompletion)        -- get time and prepare for compare
                delta = (t.compare(now).hours)             -- diff in hours between json record and now

                if delta <= relevantHours then
                    relevantAmount = relevantAmount + tonumber(rt[i].mm) 
                    dz.log(     "Date/time: " .. rt[i].d .. " ===>> Value in mm " .. 
                                rt[i].mm .. " ===>> Delta hours: "  .. delta .. 
                                " ===>> Total until now: " .. relevantAmount
                                ,dz.LOG_DEBUG)
                end    
            end
            rainVar.set(relevantAmount)   -- Store value in uservariable
        end
        
        if trigger.isTimer or trigger.isDevice then
            triggerJSON()
        elseif trigger.ok then                                      -- statusCode == 2xx
            setVar()
        else
            dz.log("No valid response from domoticz",dz.LOG_ERROR)
        end
    end
}
Spoiler: show

Code: Select all

 setRainVar: An error occured when calling event handler Neerslag
2018-07-08 20:06:02.256 Status: dzVents: Error (2.4.6): setRainVar: .../domoticz/scripts/dzVents/generated_scripts/Neerslag.lua:36: attempt to get length of global 'rt' (a nil value)
What am I doing wrong, or is this because we didn't have rain for some time now?
Running latest BETA on a Pi-3 | Toon® Thermostat (rooted) | Hue | Tuya | IKEA tradfri | Dashticz V3 on Lenovo Huawei Tablet | Conbee
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by waaren »

EdwinK wrote: Sunday 08 July 2018 20:08

Code: Select all

 setRainVar: An error occured when calling event handler Neerslag
2018-07-08 20:06:02.256 Status: dzVents: Error (2.4.6): setRainVar: .../domoticz/scripts/dzVents/generated_scripts/Neerslag.lua:36: attempt to get length of global 'rt' (a nil value)
What am I doing wrong, or is this because we didn't have rain for some time now?
@EdwinK, No rain should not cause this error.
Could it be that the deviceName or IDX for rainDevice you are using is not of the type rain or that it is just created and /or no values are in the history in the hours to be reported (yet) ?

If it is of type rain and already in use for > 1 hour can you check the result of

http://domoticzIP:domoticzPort/json.htm?type=graph&sensor=rain&idx=nnn&range=day

Updated script at http://www.domoticz.com/forum/viewtopic ... 72&t=24113
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
User avatar
EdwinK
Posts: 1820
Joined: Sunday 22 January 2017 21:46
Target OS: Raspberry Pi / ODroid
Domoticz version: BETA
Location: Rhoon
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by EdwinK »

Will reply in the new topic ;), to keep this clean
Running latest BETA on a Pi-3 | Toon® Thermostat (rooted) | Hue | Tuya | IKEA tradfri | Dashticz V3 on Lenovo Huawei Tablet | Conbee
schulpr
Posts: 137
Joined: Thursday 01 January 2015 9:10
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by schulpr »

Hi,

A few times per day I get the following error message:
2018-07-17 14:48:05.367 Error: Error opening url: https://gadgets.buienradar.nl/data/rain ... 2&lon=5.47
2018-07-17 14:48:05.730 Error: dzVents: Error (2.4.7): WUS: [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956
I assume that certain data is not available when the script runs. Is there a way to prevent this. Perhaps use the old data if the new is not available?

Kind regards, Rob
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by waaren »

schulpr wrote: Tuesday 17 July 2018 17:53 Hi,

A few times per day I get the following error message:
2018-07-17 14:48:05.367 Error: Error opening url: https://gadgets.buienradar.nl/data/rain ... 2&lon=5.47
2018-07-17 14:48:05.730 Error: dzVents: Error (2.4.7): WUS: [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956
I assume that certain data is not available when the script runs. Is there a way to prevent this. Perhaps use the old data if the new is not available?

Kind regards, Rob
@schulpr

Rob, the first errormessage is from the main domoticz process telling us that the url could not be reached. I see this a couple of times a day. dzVents cannot check before firing the openURL that it will be successful so I cannot think of a way to prevent this.
The second errormessage is from dzVents telling that the return from the openURL contains no valid data and could not be processed. The design choice for this script is to ignore this and leave all values in the virtual sensors and switched as they were set in the previous run.
I assume that this is relative safe choice if we don't see these error messages flooding the logs.
Hope this clarifies
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
schulpr
Posts: 137
Joined: Thursday 01 January 2015 9:10
Target OS: Raspberry Pi / ODroid
Domoticz version: Beta
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by schulpr »

Hi @waaren,

Thanks for clarifying this. It's no problem but I like a clean error log .

Kind regards,

Rob


Verzonden vanaf mijn iPad met Tapatalk
poudenes
Posts: 667
Joined: Wednesday 08 March 2017 9:42
Target OS: Linux
Domoticz version: 3.8993
Location: Amsterdam
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by poudenes »

Hi All,

@Waaren Maybe a idea to have a option to disable all error logs? Because script is running perfect only sometimes no feedback from Buienradar:

Code: Select all

2018-08-05 21:24:04.833 Error: Error opening url: https://gadgets.buienradar.nl/data/raintext?lat=52.37&lon=4.90
2018-08-05 21:24:05.113 Error: dzVents: Error (2.4.7): [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956
2018-08-05 23:00:09.531 Error: Error opening url: https://gadgets.buienradar.nl/data/raintext?lat=52.37&lon=4.90
2018-08-05 23:00:09.776 Error: dzVents: Error (2.4.7): [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956
2018-08-06 01:24:04.696 Error: Error opening url: https://gadgets.buienradar.nl/data/raintext?lat=52.37&lon=4.90
2018-08-06 01:24:05.165 Error: dzVents: Error (2.4.7): [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956
2018-08-06 05:00:22.172 Error: Error opening url: https://gadgets.buienradar.nl/data/raintext?lat=52.37&lon=4.90
2018-08-06 05:00:22.483 Error: dzVents: Error (2.4.7): [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956
2018-08-06 05:48:04.152 Error: Error opening url: https://gadgets.buienradar.nl/data/raintext?lat=52.37&lon=4.90
2018-08-06 05:48:04.400 Error: dzVents: Error (2.4.7): [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956
2018-08-06 06:12:04.141 Error: Error opening url: https://gadgets.buienradar.nl/data/raintext?lat=52.37&lon=4.90
2018-08-06 06:12:04.535 Error: dzVents: Error (2.4.7): [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956
2018-08-06 09:00:23.044 Error: Error opening url: https://gadgets.buienradar.nl/data/raintext?lat=52.37&lon=4.90
2018-08-06 09:00:23.348 Error: dzVents: Error (2.4.7): [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956
For a no issue and if i can disable this error then my Domoticz won't show any errors at all anymore :D
RPi3 B+, Debain Stretch, Domoticz, Homebridge, Dashticz, RFLink, Milight, Z-Wave, Fibaro, Nanoleaf, Nest, Harmony Hub, Now try to understand pass2php
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by waaren »

poudenes wrote: Monday 06 August 2018 11:10 Hi All,

@Waaren Maybe a idea to have a option to disable all error logs? Because script is running perfect only sometimes no feedback from Buienradar:

2018-08-05 21:24:04.833 Error: Error opening url: https://gadgets.buienradar.nl/data/rain ... 7&lon=4.90
2018-08-05 21:24:05.113 Error: dzVents: Error (2.4.7): [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956

For a no issue and if i can disable this error then my Domoticz won't show any errors at all anymore :D
As explained two posts before this. dzVents cannot prevent the "Error opening url:" message.

You can prevent the [0006] errormessage in the log by changing the lines starting with "dz.log(ERR.TRIGGERERROR" to commentlines by adding -- at the beginning of those lines.
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
User avatar
mAiden88
Posts: 56
Joined: Friday 14 October 2016 22:15
Target OS: Raspberry Pi / ODroid
Domoticz version: 3.7286
Location: Almelo
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by mAiden88 »

Will try this script tomorrow.. Thanks for share. 😉

When its working, i will try to add "pollen" in this script. Can't promise it, i will try it.
Anyone can build a fast processor. The trick is to build a fast system.
poudenes
Posts: 667
Joined: Wednesday 08 March 2017 9:42
Target OS: Linux
Domoticz version: 3.8993
Location: Amsterdam
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by poudenes »

waaren wrote: Tuesday 07 August 2018 21:18
poudenes wrote: Monday 06 August 2018 11:10 Hi All,

@Waaren Maybe a idea to have a option to disable all error logs? Because script is running perfect only sometimes no feedback from Buienradar:

2018-08-05 21:24:04.833 Error: Error opening url: https://gadgets.buienradar.nl/data/rain ... 7&lon=4.90
2018-08-05 21:24:05.113 Error: dzVents: Error (2.4.7): [0006] Er is een probleem met inlezen van de data; controleer wat er fout is gegaan. in:WUS_rainForecastResponse, Error: 11699956

For a no issue and if i can disable this error then my Domoticz won't show any errors at all anymore :D
As explained two posts before this. dzVents cannot prevent the "Error opening url:" message.

You can prevent the [0006] errormessage in the log by changing the lines starting with "dz.log(ERR.TRIGGERERROR" to commentlines by adding -- at the beginning of those lines.
SORRY didn't saw the post. but thanks anyway !!
RPi3 B+, Debain Stretch, Domoticz, Homebridge, Dashticz, RFLink, Milight, Z-Wave, Fibaro, Nanoleaf, Nest, Harmony Hub, Now try to understand pass2php
ArieKanarie
Posts: 41
Joined: Saturday 12 December 2015 13:25
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by ArieKanarie »

The first update works, but after that I get the following error:

Code: Select all

2018-08-09 14:07:01.569 Status: dzVents: Info: Handling httpResponse-events for: "WUS_addressResponse
2018-08-09 14:07:01.569 Status: dzVents: Info: WUS: ------ Start external script: updateWeatherSensors.lua: HTTPResponse: "WUS_addressResponse"
2018-08-09 14:07:01.685 Status: dzVents: Error (2.4.6): WUS: An error occured when calling event handler updateWeatherSensors
2018-08-09 14:07:01.685 Status: dzVents: Error (2.4.6): WUS: ...omoticz/scripts/dzVents/scripts/updateWeatherSensors.lua:1195: attempt to index field '?' (a nil value)
2018-08-09 14:07:01.685 Status: dzVents: Info: WUS: ------ Finished updateWeatherSensors.lua
Any idea?
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by waaren »

ArieKanarie wrote: Thursday 09 August 2018 14:08 The first update works, but after that I get the following error:

Code: Select all

2018-08-09 14:07:01.569 Status: dzVents: Info: Handling httpResponse-events for: "WUS_addressResponse
2018-08-09 14:07:01.569 Status: dzVents: Info: WUS: ------ Start external script: updateWeatherSensors.lua: HTTPResponse: "WUS_addressResponse"
2018-08-09 14:07:01.685 Status: dzVents: Error (2.4.6): WUS: An error occured when calling event handler updateWeatherSensors
2018-08-09 14:07:01.685 Status: dzVents: Error (2.4.6): WUS: ...omoticz/scripts/dzVents/scripts/updateWeatherSensors.lua:1195: attempt to index field '?' (a nil value)
2018-08-09 14:07:01.685 Status: dzVents: Info: WUS: ------ Finished updateWeatherSensors.lua
Any idea?
Have you entered your location in the domoticz settings ?
If so what do see if you enter

Code: Select all

http://maps.googleapis.com/maps/api/geocode/json?latlng=LATITUDE,LONGITUDE&sensor=true 
(replace LATITUDE.LONGITUDE with actual values) in your browser ?
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
ArieKanarie
Posts: 41
Joined: Saturday 12 December 2015 13:25
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by ArieKanarie »

To answer your questions, yes I specified location in domoticz, and I got a correct result when I tried the googleapis url.

But a night sleep did miracles, error is gone now.
Domoticz gets more human every day :D
User avatar
felix63
Posts: 244
Joined: Monday 07 December 2015 9:30
Target OS: Raspberry Pi / ODroid
Domoticz version: 2020.1
Location: Gouda
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by felix63 »

With no changes I now getting error from this script.

Code: Select all

2018-10-19 10:02:00.606 Status: dzVents: Info: ------ Finished status meteo
2018-10-19 10:02:01.009 Status: dzVents: Error (2.4.7): An error occured when calling event handler status meteo
2018-10-19 10:02:01.009 Status: dzVents: Error (2.4.7): ...oticz/scripts/dzVents/generated_scripts/status meteo.lua:1196: attempt to index field '?' (a nil value)
2018-10-19 10:02:01.009 Status: dzVents: Info: ------ Finished status meteo
Any idea what could cause this?
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by waaren »

felix63 wrote: Friday 19 October 2018 10:06 With no changes I now getting error from this script.

Code: Select all

2018-10-19 10:02:00.606 Status: dzVents: Info: ------ Finished status meteo
2018-10-19 10:02:01.009 Status: dzVents: Error (2.4.7): An error occured when calling event handler status meteo
2018-10-19 10:02:01.009 Status: dzVents: Error (2.4.7): ...oticz/scripts/dzVents/generated_scripts/status meteo.lua:1196: attempt to index field '?' (a nil value)
2018-10-19 10:02:01.009 Status: dzVents: Info: ------ Finished status meteo
Any idea what could cause this?
Thanks for reporting !
In that area, the script tries to obtain your address from Google based on longitude / latitude.
The message return is now:

Code: Select all

"error_message": "Keyless access to Google Maps Platform is deprecated. Please use an API key with all your API calls to avoid service interruption. For further details please refer to http://g.co/dev/maps-no-account",
as a workaround change line 912 from

Code: Select all

if var.useDomoticzLocation then 
to

Code: Select all

if not(var.useDomoticzLocation) then
I will have to look into that how to solve this. Will do over the weekend
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
ronaldbro
Posts: 327
Joined: Thursday 15 November 2018 21:38
Target OS: Raspberry Pi / ODroid
Domoticz version: 2020.2
Location: Netherlands
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by ronaldbro »

Hi waaren,

first of all thanks for this script. This is very cool and helpful :)

Do you have an update of the previous post? I'm having the same error.

Code: Select all

2018-11-18 14:17:00.308 Status: dzVents: Info: WUS: ------ Start external script: updateWeatherSensors.lua:, trigger: every minute 
2018-11-18 14:17:00.450 Status: EventSystem: Script event triggered: /home/pi/domoticz/dzVents/runtime/dzVents.lua 
2018-11-18 14:17:00.679 Status: dzVents: Info: Handling httpResponse-events for: "WUS_addressResponse 
2018-11-18 14:17:00.679 Status: dzVents: Info: WUS: ------ Start external script: updateWeatherSensors.lua: HTTPResponse: "WUS_addressResponse" 
2018-11-18 14:17:00.717 Status: dzVents: Error (2.4.8): WUS: An error occured when calling event handler updateWeatherSensors 
2018-11-18 14:17:00.717 Status: dzVents: Error (2.4.8): WUS: ...omoticz/scripts/dzVents/scripts/updateWeatherSensors.lua:1195: attempt to index field '?' (a nil value) 
Unfortunatly I'm still in the beginning of the learning curve to lua and dzVents, so I'm not a big help yet ;)

Thanks for your help.

regards, Ronald
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: updateWeatherSensors (yet another buienradar script)

Post by waaren »

ronaldbro wrote: Sunday 18 November 2018 14:20 Hi waaren,

first of all thanks for this script. This is very cool and helpful :)

Do you have an update of the previous post? I'm having the same error.

Code: Select all

2018-11-18 14:17:00.308 Status: dzVents: Info: WUS: ------ Start external script: updateWeatherSensors.lua:, trigger: every minute 
2018-11-18 14:17:00.450 Status: EventSystem: Script event triggered: /home/pi/domoticz/dzVents/runtime/dzVents.lua 
2018-11-18 14:17:00.679 Status: dzVents: Info: Handling httpResponse-events for: "WUS_addressResponse 
2018-11-18 14:17:00.679 Status: dzVents: Info: WUS: ------ Start external script: updateWeatherSensors.lua: HTTPResponse: "WUS_addressResponse" 
2018-11-18 14:17:00.717 Status: dzVents: Error (2.4.8): WUS: An error occured when calling event handler updateWeatherSensors 
2018-11-18 14:17:00.717 Status: dzVents: Error (2.4.8): WUS: ...omoticz/scripts/dzVents/scripts/updateWeatherSensors.lua:1195: attempt to index field '?' (a nil value) 
Unfortunatly I'm still in the beginning of the learning curve to lua and dzVents, so I'm not a big help yet ;)

Thanks for your help.

regards, Ronald
Sorry missed this one until now.
The only way to solve this is by getting a google API key. If you have one I will explain how to use it.
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest