[APP][Pro] Trashcan Reminder 2.0

Yes thnx. Problem solved.

1 Like

Yes, thnx, problem solved here too :slight_smile:

1 Like

helaas is hier het probleem niet opgelost. Regio waar Blink het afval ophaalt werkt niet. gebruik versie 5.1.14

Misschien een handig homeyscript als je wil weten wanneer de volgende datum is dat er iets opgehaald wordt:

Je moet alleen de datums voor jouw regio invullen op de plek waar nu die van mij staan.

// Hieronder je eigen data invullen

let data = \[

  {"type":"PAPIER","localText":"Papier en karton","dates":\["2025-01-07T00:00:00.000Z","2025-01-21T00:00:00.000Z","2025-02-04T00:00:00.000Z","2025-02-18T00:00:00.000Z","2025-03-04T00:00:00.000Z","2025-03-18T00:00:00.000Z","2025-04-01T00:00:00.000Z","2025-04-15T00:00:00.000Z","2025-04-29T00:00:00.000Z","2025-05-13T00:00:00.000Z","2025-05-27T00:00:00.000Z","2025-06-10T00:00:00.000Z","2025-06-24T00:00:00.000Z","2025-07-08T00:00:00.000Z","2025-07-22T00:00:00.000Z","2025-08-05T00:00:00.000Z","2025-08-19T00:00:00.000Z","2025-09-02T00:00:00.000Z","2025-09-16T00:00:00.000Z","2025-09-30T00:00:00.000Z","2025-10-14T00:00:00.000Z","2025-10-28T00:00:00.000Z","2025-11-11T00:00:00.000Z","2025-11-25T00:00:00.000Z","2025-12-09T00:00:00.000Z","2025-12-23T00:00:00.000Z"\]},

  {"type":"PMD","localText":"Plastic, drankkartons en blik","dates":\["2025-01-07T00:00:00.000Z","2025-02-04T00:00:00.000Z","2025-03-04T00:00:00.000Z","2025-04-01T00:00:00.000Z","2025-04-29T00:00:00.000Z","2025-05-27T00:00:00.000Z","2025-06-24T00:00:00.000Z","2025-07-22T00:00:00.000Z","2025-08-19T00:00:00.000Z","2025-09-16T00:00:00.000Z","2025-10-14T00:00:00.000Z","2025-11-11T00:00:00.000Z","2025-12-09T00:00:00.000Z"\]},

  {"type":"GFT","localText":"Groente, Fruit en Tuinafval (minicontainers)","dates":\["2025-01-10T00:00:00.000Z","2025-01-24T00:00:00.000Z","2025-02-07T00:00:00.000Z","2025-02-21T00:00:00.000Z","2025-03-07T00:00:00.000Z","2025-03-21T00:00:00.000Z","2025-04-04T00:00:00.000Z","2025-04-10T00:00:00.000Z","2025-04-18T00:00:00.000Z","2025-04-24T00:00:00.000Z","2025-05-02T00:00:00.000Z","2025-05-08T00:00:00.000Z","2025-05-16T00:00:00.000Z","2025-05-22T00:00:00.000Z","2025-05-30T00:00:00.000Z","2025-06-05T00:00:00.000Z","2025-06-13T00:00:00.000Z","2025-06-19T00:00:00.000Z","2025-06-27T00:00:00.000Z","2025-07-03T00:00:00.000Z","2025-07-11T00:00:00.000Z","2025-07-17T00:00:00.000Z","2025-07-25T00:00:00.000Z","2025-07-31T00:00:00.000Z","2025-08-08T00:00:00.000Z","2025-08-14T00:00:00.000Z","2025-08-22T00:00:00.000Z","2025-08-28T00:00:00.000Z","2025-09-05T00:00:00.000Z","2025-09-11T00:00:00.000Z","2025-09-19T00:00:00.000Z","2025-09-25T00:00:00.000Z","2025-10-03T00:00:00.000Z","2025-10-17T00:00:00.000Z","2025-10-31T00:00:00.000Z","2025-11-14T00:00:00.000Z","2025-11-28T00:00:00.000Z","2025-12-12T00:00:00.000Z","2025-12-24T00:00:00.000Z"\]},

  {"type":"GROF","localText":"Grofvuil","dates":\["2025-01-22T00:00:00.000Z","2025-02-19T00:00:00.000Z","2025-03-19T00:00:00.000Z","2025-04-16T00:00:00.000Z","2025-05-14T00:00:00.000Z","2025-06-11T00:00:00.000Z","2025-07-09T00:00:00.000Z","2025-08-06T00:00:00.000Z","2025-09-03T00:00:00.000Z","2025-10-01T00:00:00.000Z","2025-10-29T00:00:00.000Z","2025-11-26T00:00:00.000Z","2025-12-24T00:00:00.000Z"\]},

  {"type":"REST","localText":"Restafval","dates":\["2025-01-28T00:00:00.000Z","2025-02-25T00:00:00.000Z","2025-03-25T00:00:00.000Z","2025-04-22T00:00:00.000Z","2025-05-20T00:00:00.000Z","2025-06-17T00:00:00.000Z","2025-07-15T00:00:00.000Z","2025-08-12T00:00:00.000Z","2025-09-09T00:00:00.000Z","2025-10-07T00:00:00.000Z","2025-11-04T00:00:00.000Z","2025-12-02T00:00:00.000Z","2025-12-30T00:00:00.000Z"\]}

\];



let now = new Date();



// Datum formatteren

function formatDate(d) {

  let dag = String(d.getDate()).padStart(2, '0');

  let maand = String(d.getMonth() + 1).padStart(2, '0');

  let jaar = d.getFullYear();

  return \`${dag}-${maand}-${jaar}\`;

}



// Eerstvolgende datum per afvalsoort bepalen

let resultaten = data.map(item => {

  let toekomst = item.dates

    .map(d => new Date(d))

    .filter(d => d >= now)

    .sort((a, b) => a - b);



  if (toekomst.length > 0) {

    return {

      localText: item.localText,

      date: toekomst\[0\],

      formatted: formatDate(toekomst\[0\])

    };

  } else {

    return {

      localText: item.localText,

      date: null,

      formatted: "Geen datum meer"

    };

  }

});



// Sorteren op eerstvolgende datum

resultaten.sort((a, b) => a.date - b.date);



// Samenvattende tekst maken

let samenvatting = resultaten

  .filter(r => r.date !== null)

  .map(r => \`${r.localText}: ${r.formatted}\`)

  .join(" | ");



// Voor logging

console.log("Samenvatting:", samenvatting);



// Deze string kun je gebruiken in je Flow

return samenvatting;

komt er ook een ondersteuning voor de gemeente tytsjerksteradiel? de app is Omrin afval. en Omrin haalt het op.

1 Like

Something wrong with Twente Milieu ?

it skips the orange plastic container

Hi, the problem seems to be back again. No widgetinfo in the homey-app. Could you please check whether it’s an issue with Blink again? thnx.

Can you send me a PB with your zipcode? I have ran a test with a trial zipcode I found on maps, and that is setting the PMD just fine for Twente Milieu.

Results for: twm - 7641BR:19
[
  {
    type: 'REST',
    localText: 'GREY',
    dates: [ '2025-08-27T00:00:00', '2025-09-17T00:00:00' ]
  },
  {
    type: 'GFT',
    localText: 'GREEN',
    dates: [
      '2025-09-01T00:00:00',
      '2025-09-15T00:00:00',
      '2025-09-29T00:00:00'
    ]
  },
  {
    type: 'PMD',
    localText: 'PACKAGES',
    dates: [ '2025-09-10T00:00:00', '2025-10-01T00:00:00' ]
  }
]

I don’t know, they have this message on their site

Inwoners van Helmond gaan naar een aparte kalender, download DeAfvalApp (Helmond) in de Play Store of Apple Store.

So maybe some cities are moving to another provider? The test zipcode I have for Mijn Blink is still not giving any calendar data. I have used this address (found on maps): Ten Bleek 9, 5741WT Beek en Donk.

You can send me a PB with your postalcode & number and then I can check that specific one. But seems that Mijn Blink is not a very active information provider at the moment.

Since the latest version (5.1.15) I now have an empty widget and no debug information available. Address not recognized anymore.

Using the ā€œInzamelkalender HVC NLā€.

Already tried restarting both Homey and the app.

Have you checked if your data is still available on the website of your trash provider itself? And if it is still available there, can you share a example zipcode + number so I can check?

HVC trash calander is still available

Have sent you my zip code and number via PM

Trashcan app does not work anymore for the Circulus Berkel region.
The adres is unknown.
First i did not get a reminder of the app. Then i have updated their app today and then the adres was unknown.
Tis is a link were you can add a adres

https://mijn.circulus.nl/uw-adres?returnUrl=https%3A%2F%2Fmijn.circulus.nl%2Fafvalkalender%2F
A zip code and a number can be 7425PE 40

Thanks.

Hi @Mike1233,

When I enter the postalcode + housenumber you provided it works fine. Can you see what error you are getting? Maybe restart the app, then after entering the data send a diagnostics report of the app.

I have some troubles when using this app in Groningen.

Before they used the afvalwijzer but now they have their own database. I can select Groningen, but not my address.

Can you have a look why it is not working?

@MrDutchfighter I did restart the app, enterd the zip code and number.
Dit adres word niet ondersteund. It is on a Homey 2019.
My Homey 2023 is accepting the zip code without any problems.
There is no update for the 2019. I also did a restart of Homey 2019.

Hm, strange. Saw the crash report, it has to do something with a self-signed certificate. Will check and see if I can find anything in the Homey docs on how to deal with this.

Error: self signed certificate in certificate chain at TLSSocket.onConnectSecure at TLSSocket.emit at TLSSocket._finishInit at TLSWrap.ssl.onhandshakedone { code: ā€˜SELF_SIGNED_CERT_IN_CHAIN’

1 Like

I’ve been using this app for a while now and I’m completely satisfied. The only thing I’m not getting is the notifications for Plastic. When I check the debug settings, I see it’s searching for ā€œPlastic+ā€ while it should be ā€œPlastic.ā€ Is there a minor adjustment to the app?

What do you mean ā€˜it’s searching for plastic+’? You can change the label of the notification yourself in the settings per trash type. Depending on provider, it either labels plastic as plastic category or as PMD category. Which basically can be both plastic.

Thanks!