Sharing : Afval kalendar in text sensor
Moderator: leecollings
Re: Sharing : Afval kalendar in text sensor
Tnx, at the end you left a "needupdate = true" to many.
-
- Posts: 1601
- Joined: Friday 18 October 2013 23:33
- Target OS: Raspberry Pi / ODroid
- Domoticz version: BETA
- Location: Arnhem/Nijmegen Nederland
- Contact:
Re: Sharing : Afval kalendar in text sensor
Sorry removed ..
see something on github...
GREAT work Jos
Edit:
Only here is dombo71 again....
I mis in the github codee the local part etc.[ like the script i use before ]
Do i need to replace your new config precisely or do i need to edit so it is like on the old part?
The new:
So just only replace the the whole old config part for the new one?
see something on github...
GREAT work Jos
Edit:
Only here is dombo71 again....
I mis in the github codee the local part etc.[ like the script i use before ]
Do i need to replace your new config precisely or do i need to edit so it is like on the old part?
Code: Select all
local myAfvalDevice='D.M.:fval'
local Postcode='6AW'
local Huisnummer='9'
local Notificat
Code: Select all
myAfvalDevice='Container' -- The Text devicename in Domoticz
ShowNextEvents = 3 -- indicate the next x events to show in the TEXT Sensor in Domoticz
Postcode='your-zip-here' -- Your postalcode
Huisnummer='your-housenr-here' -- Your housnr
NotificationEmailAdress = "your-email-address(es)-here" -- Specify your Email Address for the notifications
-- uncoment any of the b
Xu4: Beta Extreme antenna RFXcomE,WU Fi Ping ip P1 Gen5 PVOutput Harmony HUE SolarmanPv OTG Winddelen Alive ESP Buienradar MySensors WOL Winddelen counting RPi: Beta SMAspot RFlinkTest Domoticz ...Different backups
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: Sharing : Afval kalendar in text sensor
Sorry about that, will fix it later this evening.
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: Sharing : Afval kalendar in text sensor
It will work with and without local, but only when changed in the main script. When you use the separate config file it has to be without local or else it won't work.
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: Sharing : Afval kalendar in text sensor
Fixed in Github.
This will fix the update running each minute!
I have used that while testing/debugging and forgot to remove it before commiting to Github ... but fixed now.
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: Sharing : Afval kalendar in text sensor
Just committed some updates to script_time_afvalwijzer.lua:
Jos
- Added the option to use the different Notification systems configured in Domoticz:
Code: Select all
NotificationEmailAdress = "" -- Specify your Email Address for the notifications. Leave empty to skip email notification Notificationsystem = "" -- Specify notification system eg "telegram/pushover/.." leave empty to skip
- added a commented line to use the JSON.lua distributed with Domoticz for those that haven't installed the generic version. Just comment the first line and uncomment the second line in case you get errors for the first.
Code: Select all
-- load JSON lib JSON = require "JSON" -- use generic JSON.lua --~ JSON = (loadfile "/home/pi/domoticz/scripts/lua/JSON.lua")() -- Use default Domoticz JSON.lua
- Added versionnumber and start logmessage when update starts.
- Renamed alvalwijzerconfig.lua to alvalwijzerconfig.lua.example to avoid messing up any local version.
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 497
- Joined: Friday 22 May 2015 12:21
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.11083
- Location: Asten NB Nederland
- Contact:
Re: Sharing : Afval kalendar in text sensor
Hi Folks,
Just to let you know:
I have been struggeling with the program from Jos for a couple of days and I could not got it working.
I PM-ed Jos and in 1 hour he fixed the problem for me!!!
Now I can collect the data for Blink in the Helmond area.
Many thanks to Jos!!
Just to let you know:
I have been struggeling with the program from Jos for a couple of days and I could not got it working.
I PM-ed Jos and in 1 hour he fixed the problem for me!!!
Now I can collect the data for Blink in the Helmond area.
Many thanks to Jos!!
Your mind is like a parachute,
It only works when it is opened!
RPI4 several Fibaro, KaKu, Neocoolcam switches, Z-Wave, Zigbee2Mqtt, Ikea bulbs and remote, Zigbee temp nodes
It only works when it is opened!
RPI4 several Fibaro, KaKu, Neocoolcam switches, Z-Wave, Zigbee2Mqtt, Ikea bulbs and remote, Zigbee temp nodes
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: Sharing : Afval kalendar in text sensor
You're welcome.
The script is also added to my github: https://github.com/jvanderzande/mijnafvalwijzer
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 497
- Joined: Friday 22 May 2015 12:21
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.11083
- Location: Asten NB Nederland
- Contact:
Re: Sharing : Afval kalendar in text sensor
Just one more question:
The program keeps checking every minute if there is an update.
I sroke out the dummy 1 and changed the dummy 2 time but it keeps checking every minute.
The program keeps checking every minute if there is an update.
I sroke out the dummy 1 and changed the dummy 2 time but it keeps checking every minute.
Your mind is like a parachute,
It only works when it is opened!
RPI4 several Fibaro, KaKu, Neocoolcam switches, Z-Wave, Zigbee2Mqtt, Ikea bulbs and remote, Zigbee temp nodes
It only works when it is opened!
RPI4 several Fibaro, KaKu, Neocoolcam switches, Z-Wave, Zigbee2Mqtt, Ikea bulbs and remote, Zigbee temp nodes
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: Sharing : Afval kalendar in text sensor
Oops ... did it again.
Just remove line 218:
I add that line while testing/debugging to force the update each run.
Updated it also in Github.
Jos
Just remove line 218:
Code: Select all
needupdate = true
Updated it also in Github.
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 497
- Joined: Friday 22 May 2015 12:21
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.11083
- Location: Asten NB Nederland
- Contact:
Re: Sharing : Afval kalendar in text sensor
Thnx Jos,
that did the trick!!
that did the trick!!
Your mind is like a parachute,
It only works when it is opened!
RPI4 several Fibaro, KaKu, Neocoolcam switches, Z-Wave, Zigbee2Mqtt, Ikea bulbs and remote, Zigbee temp nodes
It only works when it is opened!
RPI4 several Fibaro, KaKu, Neocoolcam switches, Z-Wave, Zigbee2Mqtt, Ikea bulbs and remote, Zigbee temp nodes
-
- Posts: 536
- Joined: Friday 23 December 2016 16:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Stable
- Location: Netherlands Purmerend
- Contact:
Re: Sharing : Afval kalendar in text sensor
Hi Jos,
Found an issue in the logfile :
Line 145:
My afvaltypes:
local afvaltype_cfg = {
Any clue why tmp is empty?
Found an issue in the logfile :
Code: Select all
2019-01-14 02:11:00.729 Error: EventSystem: in AfvalAlarm: [string "-- AF-PUR module to get the Afval schedule fo..."]:145: bad argument #1 to 'gmatch' (string expected, got nil)
Code: Select all
for web_afvaldate, web_afvaltype in string.gmatch(tmp, '<td>(.-)</td>[\r\n%s]-<td>(.-)</td>[\r\n%s]-<td>.-</td>') do
local afvaltype_cfg = {
Code: Select all
["Rest"] ={hour=19,min=22,daysbefore=1,text="Grijze Container met Restafval"},
["GFT"] ={hour=19,min=22,daysbefore=1,text="Bruine Container met Tuinfval"},
["Papier"] ={hour=12,min=00,daysbefore=0,text="Blauwe Container met Oud papier"},
["Dummy"] ={hour=02,min=11,daysbefore=1,text="dummy"}}
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: Sharing : Afval kalendar in text sensor
Het lijkt erop dat de gemeente Purmerend een andere Website is gaan gebruiken: https://afvalkalender.purmerend.nl/freijn wrote: ↑Monday 14 January 2019 8:45 Hi Jos,
Found an issue in the logfile :
-snip-Code: Select all
2019-01-14 02:11:00.729 Error: EventSystem: in AfvalAlarm: [string "-- AF-PUR module to get the Afval schedule fo..."]:145: bad argument #1 to 'gmatch' (string expected, got nil)
Any clue why tmp is empty?
Klopt dat?
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 536
- Joined: Friday 23 December 2016 16:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Stable
- Location: Netherlands Purmerend
- Contact:
Re: Sharing : Afval kalendar in text sensor
Shit. indeed ... #$%#$^%@% just had the scritping fun for 1 week only
they announced an app last week, so i assume they have moved everything...
they announced an app last week, so i assume they have moved everything...
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: Sharing : Afval kalendar in text sensor
Luckily the new website format is the same as the one for West Friesland, so that makes it easy.
I have adapted that script and made a new Purmerend version available in GitHub.
It now also contains the option for the other notification options available in domoticz.
Let me know if there are issue/questions.
Jos
I have adapted that script and made a new Purmerend version available in GitHub.
It now also contains the option for the other notification options available in domoticz.
Let me know if there are issue/questions.
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 536
- Joined: Friday 23 December 2016 16:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Stable
- Location: Netherlands Purmerend
- Contact:
Re: Sharing : Afval kalendar in text sensor
oohhh wauw !! incredible speed service! I will download and implement.. and let you know.. Thanks !
- jvdz
- Posts: 2189
- Joined: Tuesday 30 December 2014 19:25
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 4.107
- Location: Netherlands
- Contact:
Re: Sharing : Afval kalendar in text sensor
It looks like a lot of gemeentes use the services from http://www.opzet.nl/afvalkalender_digitaal for their garbage collection calendar.
All these sites also have a REST/JSON interface available for the use by the APPs they provide, so I had a look at supporting that process instead of the website scraping I do for some of these currently with:
Anyone interested in this and willing to assist testing?
I would like to get testers for some different gemeentes to test the portability of one script across these "separate" websites.
Jos
All these sites also have a REST/JSON interface available for the use by the APPs they provide, so I had a look at supporting that process instead of the website scraping I do for some of these currently with:
- huisvuil-purmerend
- huisvuil-mijnblink
- huisvuil-zuidwest-friesland
Anyone interested in this and willing to assist testing?
I would like to get testers for some different gemeentes to test the portability of one script across these "separate" websites.
Jos
New Garbage collection scripts: https://github.com/jvanderzande/GarbageCalendar
-
- Posts: 536
- Joined: Friday 23 December 2016 16:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version: Stable
- Location: Netherlands Purmerend
- Contact:
Re: Sharing : Afval kalendar in text sensor
BTW Jos, its working in Purmerend and a few hrs ago I also got my Telegram reminder, Thanks !!
-
- Posts: 223
- Joined: Sunday 30 March 2014 15:24
- Target OS: Linux
- Domoticz version: Beta
- Location: Waterland
- Contact:
Re: Sharing : Afval kalendar in text sensor
Thanks for the quick help.jvdz wrote: ↑Monday 14 January 2019 16:14 It looks like a lot of gemeentes use the services from http://www.opzet.nl/afvalkalender_digitaal for their garbage collection calendar.
All these sites also have a REST/JSON interface available for the use by the APPs they provide, so I had a look at supporting that process instead of the website scraping I do for some of these currently with:I am looking at supporting that approach as that will more reliable, flexible and supporting potentially supporting some 2.5 million households. See the above linked page for a list of supported site, or look at your own calendar website and see whether they refer to "Ontwerp & techniek: Opzet"
- huisvuil-purmerend
- huisvuil-mijnblink
- huisvuil-zuidwest-friesland
Anyone interested in this and willing to assist testing?
I would like to get testers for some different gemeentes to test the portability of one script across these "separate" websites.
Jos
Ronald
Rpi, RFXcom, klikaan klikuit switch,thermosmart, z-wave, espeasy, smartevse
-
- Posts: 7
- Joined: Thursday 10 January 2019 12:09
- Target OS: Raspberry Pi / ODroid
- Domoticz version: BETA
- Location: Netherlands
- Contact:
Re: Sharing : Afval kalendar in text sensor
Finaly, after several PM's, trail and error, I got today the Pushover notifcation of the next garbage run
@JVDZ; many thanks for support and help!!
@JVDZ; many thanks for support and help!!
Who is online
Users browsing this forum: No registered users and 0 guests