Configurable 'KNMI Weerlive' script

In this subforum you can show projects you have made, or you are busy with. Please create your own topic.

Moderator: leecollings

User avatar
andrehj
Posts: 76
Joined: Sunday 06 January 2019 14:26
Target OS: Raspberry Pi / ODroid
Domoticz version: 2026.4
Location: NL
Contact:

Re: Configurable 'KNMI Weerlive' script

Post by andrehj »

I updated all icons via the Domoticz Icon Generator and attached them to this post.
Finding the correct index numbers worked fine with this link: http://pi-ip:8080/json.htm?type=command ... tomiconset (add 100 to the index number shown).

In the script I had to remove some HTML formatting to make the line breaks work in the text devices in the utility tab.
I manually added the "Weersverwachting" icon to the Extensive forecast text device. Couldn't find a way for that to happen automatically.
Now only the text devices in the old Default Dashboard still have a line break issue: If there are no hard line breaks in the script, only the first part of the line is visible, it does not automatically word wrap.
But that is not a big issue, since I do not use that dashboard anymore, I switched to text devices in the Dynamic Dashboard, and there the word wrap works fine.
Attachments
Icons 2026.zip
(92.11 KiB) Downloaded 9 times
janpep
Posts: 323
Joined: Thursday 14 March 2024 10:11
Target OS: Linux
Domoticz version: v2026.3
Location: Netherlands
Contact:

Re: Configurable 'KNMI Weerlive' script

Post by janpep »

andrehj wrote: Sunday 30 August 2026 13:00 In the script I had to remove some HTML formatting to make the line breaks work in the text devices in the utility tab.
In the script there are a few '<br>' which are working here for a long time.
Wordwrap in Dashboard was a problem for me (In the past I fixed this in the corresponding css file), but that was resolved a few updates ago.
Since then, I have not experienced any further problems with the display of the content.
Dz on Ubuntu VM on Proxmox behind FRITZ!Box.
EvoHome; MELCloud; P1 meter; Z-Stick GEN5; Z-Wave-js-ui; Sonoff USB-Dongle Plus-E; Zigbee2Mqtt; MQTT; Greenwave powernodes 1+6; Fibaro switch, plugs, smoke; FRITZ!DECT 200. Scripts listed in profile interests.
User avatar
andrehj
Posts: 76
Joined: Sunday 06 January 2019 14:26
Target OS: Raspberry Pi / ODroid
Domoticz version: 2026.4
Location: NL
Contact:

Re: Configurable 'KNMI Weerlive' script

Post by andrehj »

Today I found out that the line

Code: Select all

dz.devices(wl_rain_idx).setIcon(iconNumber)
which get executed twice every script run, is causing the following lines to appear in the log:

Code: Select all

2026-10-24 06:00:02.508  Status: EventSystem: reset all device statuses...
2026-10-24 06:00:03.176  Status: EventSystem: reset all device statuses...
2026-10-24 06:15:02.577  Status: EventSystem: reset all device statuses...
2026-10-24 06:15:03.191  Status: EventSystem: reset all device statuses...
2026-10-24 06:30:02.241  Status: EventSystem: reset all device statuses...
2026-10-24 06:30:02.894  Status: EventSystem: reset all device statuses...
2026-10-24 06:45:02.804  Status: EventSystem: reset all device statuses...
2026-10-24 06:45:03.394  Status: EventSystem: reset all device statuses...
2026-10-24 07:00:02.939  Status: EventSystem: reset all device statuses...
2026-10-24 07:00:03.537  Status: EventSystem: reset all device statuses...
@janpep Do you have any idea why that happens or what can be done to fix this?
As a workaround I've now set

Code: Select all

wl_icons_installed = 0
but that made me loose the custom icons...

The strange thing is that although I get all these status lines in the log, the script does update the icons (as long as I set wl_icons_installed to 1 of course).
janpep
Posts: 323
Joined: Thursday 14 March 2024 10:11
Target OS: Linux
Domoticz version: v2026.3
Location: Netherlands
Contact:

Re: Configurable 'KNMI Weerlive' script

Post by janpep »

I will have a look if I can see this also on my side and let you know.
For now I turned the debug log on. I will try to look into it tomorrow.
Dz on Ubuntu VM on Proxmox behind FRITZ!Box.
EvoHome; MELCloud; P1 meter; Z-Stick GEN5; Z-Wave-js-ui; Sonoff USB-Dongle Plus-E; Zigbee2Mqtt; MQTT; Greenwave powernodes 1+6; Fibaro switch, plugs, smoke; FRITZ!DECT 200. Scripts listed in profile interests.
janpep
Posts: 323
Joined: Thursday 14 March 2024 10:11
Target OS: Linux
Domoticz version: v2026.3
Location: Netherlands
Contact:

Re: Configurable 'KNMI Weerlive' script

Post by janpep »

I can confirm your findings. That said, the further significance of the log entry remains unclear to me.
Dz on Ubuntu VM on Proxmox behind FRITZ!Box.
EvoHome; MELCloud; P1 meter; Z-Stick GEN5; Z-Wave-js-ui; Sonoff USB-Dongle Plus-E; Zigbee2Mqtt; MQTT; Greenwave powernodes 1+6; Fibaro switch, plugs, smoke; FRITZ!DECT 200. Scripts listed in profile interests.
Post Reply