Page 5 of 18

Re: Sharing : Afval kalendar in text sensor

Posted: Thursday 04 October 2018 10:05
by jvdz
Reley wrote: Thursday 04 October 2018 8:13 I am sorry guys, but i'm not able to get this to work.
-snip-
any ideas?
I would need to see the whole script to see what you have done with the settings and to be able to test it.
You can also PM it or Email it (jvdzande at yahoo dot com) in case you don't want to share it here publicly.

Jos

Re: Sharing : Afval kalendar in text sensor

Posted: Thursday 04 October 2018 23:07
by jvdz
I have committed an update to https:github to fix an issue encountered while testing with the script for @Reley.
The information for his area had an issue where the afval type description contained 2 spaces between two words creating an issue that it looks like there is only one space and thus not matches with the description in the table. The script will now replace multiple spaces with only one to fix this.

Jos

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 10 December 2018 21:55
by BarryT
Since last week the script isnt working anymore?

The log shows:

Code: Select all

2018-12-10 21:54:00.200 Status: LUA: afvalWijzer module start check
2018-12-10 21:54:00.200 Status: LUA: @AFW:=== web update ================================
2018-12-10 21:54:01.151 Status: LUA: os.capture needed more than 1 call: 5
2018-12-10 21:54:01.151 Status: LUA: afvalWijzer: Empty result from curl command
2018-12-10 21:54:01.156 Status: LUA: Lampen Garage UIT, 2 minuten geen beweging
2018-12-10 21:55:00.215 Status: LUA: @AFW:afvaltype_cfg :Restafval;21;55
2018-12-10 21:55:00.215 Status: LUA: @AFW:afvaltype_cfg :dummy;21;54
2018-12-10 21:55:00.215 Status: LUA: @AFW:afvaltype_cfg :Klein chemisch afval;21;55
2018-12-10 21:55:00.215 Status: LUA: @AFW:afvaltype_cfg :Papier en karton;21;55
2018-12-10 21:55:00.215 Status: LUA: @AFW:afvaltype_cfg :Groente, Fruit en Tuinafval;21;55
2018-12-10 21:55:00.215 Status: LUA: @AFW:afvaltype_cfg :Plastic, Metalen en Drankkartons;21;55
2018-12-10 21:55:00.215 Status: LUA: afvalWijzer module start check
2018-12-10 21:55:00.216 Status: LUA: @AFW:=== web update ================================
2018-12-10 21:55:00.864 Status: LUA: os.capture needed more than 1 call: 5
2018-12-10 21:55:00.864 Status: LUA: afvalWijzer: Empty result from curl command
2018-12-10 21:56:00.219 Status: LUA: @AFW:afvaltype_cfg :Groente, Fruit en Tuinafval;21;55
2018-12-10 21:56:00.219 Status: LUA: @AFW:afvaltype_cfg :Klein chemisch afval;21;55
2018-12-10 21:56:00.220 Status: LUA: @AFW:afvaltype_cfg :Plastic, Metalen en Drankkartons;21;55
2018-12-10 21:56:00.220 Status: LUA: @AFW:afvaltype_cfg :Restafval;21;55
2018-12-10 21:56:00.220 Status: LUA: @AFW:afvaltype_cfg :Papier en karton;21;55
2018-12-10 21:56:00.220 Status: LUA: @AFW:afvaltype_cfg :dummy;21;54
2018-12-10 21:56:00.220 Status: LUA: @AFW:Nog geen tijd om te updaten!

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 10 December 2018 22:17
by jvdz
There was an pullrequest 2 days ago since the website changed from http:// to https://
https://github.com/jvanderzande/mijnafvalwijzer/pull/1

Think that will fix it for you too.

Jos

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 10 December 2018 22:23
by BarryT
jvdz wrote: Monday 10 December 2018 22:17 There was an pullrequest 2 days ago since the website changed from http:// to https://
https://github.com/jvanderzande/mijnafvalwijzer/pull/1

Think that will fix it for you too.

Jos
What a hero..
I didn't see that one, thanks Jos!!

Ps, check your msgs :)

Re: Sharing : Afval kalendar in text sensor

Posted: Tuesday 18 December 2018 10:34
by snellejellep
in the latest beta the script does not run anymore, anyone else having this problem?

Re: Sharing : Afval kalendar in text sensor

Posted: Thursday 03 January 2019 22:53
by Martijn85
Can someone can help me out to get this to work with:
I have tried to edit the scripts on the github with this adres but it seems not getting any information...

Re: Sharing : Afval kalendar in text sensor

Posted: Friday 04 January 2019 9:48
by jvdz
Martijn85 wrote: Thursday 03 January 2019 22:53 Can someone can help me out to get this to work with:
I have tried to edit the scripts on the github with this adres but it seems not getting any information...
PM me a working url with postcode and huisnummer and I will have a look for you when you want by adapting one of the existing versions.

Jos

Re: Sharing : Afval kalendar in text sensor

Posted: Sunday 06 January 2019 17:50
by steef84
anyone got problems with huisvuil-westland? For me its not updating since november I just saw in domoticz. (no time to run update).
Did anything changed?

Re: Sharing : Afval kalendar in text sensor

Posted: Sunday 06 January 2019 18:48
by jvdz
Correct, they have changed the website so I fixed it a couple of weeks ago, but hadn't uploaded the change yet. (it is committed now to github)
Just give that version a try and let me know. :)

Jos

Re: Sharing : Afval kalendar in text sensor

Posted: Sunday 06 January 2019 18:54
by Derik
is there perhaps a how to so i can get the afval device works again..
I come from the option with "dashticz.nl" .... And i try to make some stuff works again..
Afval and calendar etc..

Re: Sharing : Afval kalendar in text sensor

Posted: Sunday 06 January 2019 23:06
by jvdz
This is an description in Dutch how to make the script working for any of the variations I have published in github:
  • Maak een dummy TEKST sensor aan in domoticz (ik heb Heerlen-Afval gebruikt voor het testen)
  • Kopieer juiste versie script voor jouw regio van https://github.com/jvanderzande/mijnafvalwijzer naar directory domoticz\scripts\lua
  • Edit script en:
    • Pas de variable myAfvalDevice aan met de Device naam die jij hebt aangemaakt in Domoticz.
    • Pas de variable NotificationEmailAdress aan naar jouw email adres.
    • Pas de afvaltype_cfg tabel aan met de tijden en daysbefore die jij wilt per afval type en de tekst die je in de notificatie wilt ontvangen.
Nu zou het moeten werken, maar de tekst sensor wordt pas geupdate als een van de tijden uit de tabel gelijk is aan de huidige tijd, want dan alleen gaat hij de website info ophalen. Je kan dus even tijdelijk de dummy regel aanpassen naar huidige tijd plus 1 minute om de update te forceren.

Sorry for the Dutch and let me know in case anybody needs a translation, but these script are only valid for several Dutch areas.

Jos

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 07 January 2019 8:54
by freijn
little bit off topic, sorry...

I am working on my calendar as well ( Purmerend)
Question, how do you test and debug this? As the website is completely different I have to start from scratch.
Now with a few lines of code changes I need to wait for the next 1 min kickoff to see the debug lines in the logfile.
Not the fastest way of developing.. :-(

Is there a clever/better way to do the debugging?

Thanks, Frank

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 07 January 2019 9:33
by jvdz
There is a purmerend version already in in my github you can check. ;)

Jos

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 07 January 2019 10:31
by freijn
jvdz wrote: Monday 07 January 2019 9:33 There is a purmerend version already in in my github you can check. ;)

Jos
AAAhhhhhhhhhh :-)

Copied and installed , now waiting for the update....... if it fails we have a problem tomorrow as tomorrow is "rest afval" collection day....

Many thanks for doing the work !!!

Frank

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 07 January 2019 10:40
by jvdz
Just update the dummy record in the Table to a time 1 minute from Now to force the update to see if it works. ;)

Jos

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 07 January 2019 10:58
by freijn
jvdz wrote: Monday 07 January 2019 10:40 Just update the dummy record in the Table to a time 1 minute from Now to force the update to see if it works. ;)

Jos
Jos I did :

["Dummy"] ={hour=10,min=51,daysbefore=0,text="dummy"}}

now, 10:57, nothing happenend...

Was this what you meant by updating?

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 07 January 2019 11:05
by freijn
2019-01-07 11:03:00.817 Error: EventSystem: in AfvalAlarm: [string "-- AF-PUR module to get the Afval schedule fo..."]:145: bad argument #1 to 'gmatch' (string expected, got nil)

:-(

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 07 January 2019 11:20
by freijn
local MyArea='Weidevenne+en+Hazepolder'

had to put + in between, perhaps a remark in the notes?

Re: Sharing : Afval kalendar in text sensor

Posted: Monday 07 January 2019 13:46
by jvdz
freijn wrote: Monday 07 January 2019 11:20 local MyArea='Weidevenne+en+Hazepolder'
had to put + in between, perhaps a remark in the notes?
Good to see you fixed it and yes you do need to get the MyArea from the URL after you selected the "WIjk". Will make a note in the script in the comment behind the field.

Jos