This is the forum archive of Homey. For more information about Homey, visit the Official Homey website.

The Homey Community has been moved to https://community.athom.com.

This forum is now read-only for archive purposes.
Official CommunityApp SDK2

[APP] Trashcan Reminder 2.0

edited February 2018 in Apps
Hi all,

This is the official app thread of the Trashcan Reminder 2.0 app. The app got some improvements like support for SDK v2 and support for a dynamically global tag. 

Homey will remind you to put the trash out! You can do this by providing a postal code, house number and country (NL/BE) or enter the collection pattern manually on the settings page of the app.

Supported Cities

Unfortunately not all cities work with the Trashcan Reminder, if you can find your house with one of the links below your house is supported:

If your city is not supported you can always add your schedule manually. You can add new cities yourself, but requests to add new cities aren't honoured. If you wish to contribute to the project (for example by adding support for a city). I would advise you to take a look at this explanation.

Supported Cards

There is one card that you can place in the "then" column. The card let's you check if trash type X is collected << today, tomorrow, day after tomorrow >> or if any type of trash is collected << today, tomorrow, day after tomorrow >>.

Supported Speech

You can ask Homey four type of questions regarding your waste collection:

  • When is the green container collected?
  • What is collected next monday?
  • Is the residual waste collected this friday?
  • Which type of trash is collected next?

App impressions


This flow is triggered when the first person is coming downstairs in the morning. If any type of trash is collected it Greats that person and tells him what type of trash is collected today based on the global tag.



Comments

  • Would be nice to import a iCal file..
  • Just installed this version.
    When i enter postcode and number it stays on 'adres checken', we have Cyclus here and on their website the address is known.
    Do you know what can be the problem.
  • ispaapen said:
    Just installed this version.
    When i enter postcode and number it stays on 'adres checken', we have Cyclus here and on their website the address is known.
    Do you know what can be the problem.
    I did get some errors in my mailbox, the app crashes somewhere when trying to do the API calls. Will look into it soon

    jovink said:
    Would be nice to import a iCal file..
    There's an app for that: https://apps.athom.com/app/nl.netactive.homey.ical2voice
  • jovink said:
    Would be nice to import a iCal file..
    There's an app for that: https://apps.athom.com/app/nl.netactive.homey.ical2voice
    I know but I prefer your app :) 
  • Installed the new version, now the address check is working.
    It's not recognizing my address although it's recognized by the cyclus calendar
    So i entered the data manually.
    This morning i received a push message that the blue container (paper starting next month) will be emptied, but i was expecting the green one. These are my settings and flow




  • @ispaapen, are there two types of trash collected on the same day?
    What it does, it calculates all the possibilities. The term 'startend op' is not entirely correct. It is just a date used to calculate the possibilities. So it's now 4 weeks before the date, the trash is collected every four weeks, so that's also today.
    According to the term it should be indeed starting over four weeks, but I couldn't find a better term then this.
  • Yes, once every 4 weeks GFT and Papier are collected on Fridays.
    I will let it run for a while and see what happens next week. Maybe i have to create a flow per trash event instead of using "iets".

    Must say, it's a very useful app, thank for creating it.
  • ispaapen said:



    What happens if you use the flow above and nothing is scheduled? Do you get a message to say that there is nothing? Or do you just get no message?

    I only want to get a notification IF there is something, not every day.
  • Then nothing is happening. If you test the flow then there will be a red X in the OR column
  • There is a new version available on github, will submit it to the store after this weekend.
    While looking to fix an already supported API (Cyclus NV), I found that most Dutch websites use the same construction. So I also included RMN in the new version ;)
    This might give some possibility for other trash websites in the Netherlands (that use iCal files, @jovink, cause Cyclus and RMN are using iCal files as well).
  • Cyclus is working fine now
  • There is a new version available on github, will submit it to the store after this weekend.
    While looking to fix an already supported API (Cyclus NV), I found that most Dutch websites use the same construction. So I also included RMN in the new version ;)
    This might give some possibility for other trash websites in the Netherlands (that use iCal files, @jovink, cause Cyclus and RMN are using iCal files as well).
    Okay thank you I try it tomorrow!
  • The app is crashing every day now, anyone else has this problem?
  • Every night around 12? And is there a stack trace in the app available (app page of Homey)?
    Still got to make some fixes in this version. Some data is lost, and often the labels aren't set.
    The problems are quite diverse so I will try to organize them and find some time somewhere
  • Yes exact at 24.00
    I only have a screenshot of the error because the app is restarted by Candy when it crashes.

  • Just pushed a new version to the store. For some it might be necessary to reset their settings (if you are using an API). This is because in the last version some settings got messed up due to new API's that were implemented.

    To do this, go to Settings --> Trashcan Reminder 2.0 --> Update your postal & zipcode, set the API to "Unknown" --> Press Save. 

    If this shows unsupported, then update to a random working postal or zipcode (e.g. 3436 HT 11, 13, 15). And after that update back to your own zipcode (remember to set the API to Unknown every time).
  • After installing the latest updates, the app doesn't crash anymore. I now have to wait until next friday to see if it actually works. So far so good.
  • edited October 2017
    No reminder here this morning.. last friday also failed.. I'm wondering why it's this hard with the API retrieval while the manual function has never failed me.
  • It worked for me last Thursday. Will check again this week. 
  • Hi @MrDutchfighter , the 2.0 app is recently crashing at startup. This is the error I get:
    Stack trace:
    /app.js:591
    result['execute'](postcode,homenumber,country,
    ^
    TypeError: Cannot read property 'execute' of undefined
    at TrashcanReminder.updateAPI (/app.js:591:10)
    at TrashcanReminder.onUpdateData (/app.js:408:9)
    at TrashcanReminder.onInit (/app.js:42:8)
    at fs.stat.i (/opt/homey-client/system/manager/ManagerApps/bootstrap/sdk/v2/lib/SDK.js:1:3295)
    at FSReqWrap.oncomplete (fs.js:153:5)
    Exit code: 1
    Exit signal: null

  • Yes, some API's are removed because they aren't supported by the API provider anymore (Afvalwijzer I thought it was). Still have to find a work-around to empty the settings before the (non-existing) API is called.

    I think an uninstall of the app and re-install should clear the settings (as a work around for now).
  • So if I understand you right, I can not use the app anymore for Utrecht (http://www.mijnafvalwijzer.nl/)?
  • synegicsynegic Member
    edited January 2018
    Yes, some API's are removed because they aren't supported by the API provider anymore (Afvalwijzer I thought it was). Still have to find a work-around to empty the settings before the (non-existing) API is called.

    I think an uninstall of the app and re-install should clear the settings (as a work around for now).
    Interesting. Can you share what the issue is here? I made an implementation some time ago that implements the REST interface for the Afvalwijzer based calendars. This API is also used by their mobile apps (I reverse engineered it from that). Is this API also affected? For DAR (Nijmegen) it still works as it seems. Maybe my implementation also works for the other cities? It should be drop-in compatible if you feed it the correct domain name.

    https://github.com/robertraaijmakers/com.trashchecker/pull/9
  • edited January 2018
    Yes, I can elaborate on that. Afvalwijzer wasn't showing any data for the past couple of weeks (during december & first week of January). I guess that they needed to update all their collection schema's from all the gemeentes. I got some bugs and complains about Afvalwijzer not showing data and reporting that the trash was collected. So when I figured out there wasn't any data on the Afvalwijzer itself I decided to remove the support for the API since I was sick of telling everyone that Afvalwijzer themself wasn't working properly. 

    I see that for some addresses they do have data online again, so I uncommented it and submit the new version to Athom for approval. Will be online soon.
  • Gerco90Gerco90 Member
    edited March 2018
    Hello @MrDutchfighter,

    The app is working good for my gemeente, it uses 'MijnAfvalwijzer'. When some trahs is collected, Homey sends a push notification to my phone the evening before. But yesterday, I don't get a push notification.
    Normally, the PMD afval in my city is colletced on a monday. But beceause of easter monday, the PMD trahs was collected today. If I look on the website 'MijnAfvalwijzer', it says PMD is collected on the 31st of march, so that is ok. If I look at the tag in the flowmanager, the tag contains 'No trash collected today'. Is this a bug or is this due the API?


  • Do you have an idea about this @MrDutchfighter?
  •     but i think iets goes wrong while picking up the info bij mijnafvalwijzer.. 
    All my garbage meldingen works fine,  exeped  PMD.
    What ever i tried, It does not work .
    I thougt it was my mistake so i never reported. 
    @MrDutchfighter wil jou please look at this? Rest of the app is perfect fine. 
    @Gerco90
  • jovinkjovink Member
    Can you create a flow card with the  type of trash that is collected next? 
Sign In or Register to comment.