Search found 8 matches

by Marv21
17 Jan 2024, 23:44
Forum: ESP Easy: Software
Topic: Send values to MQTT only when changed
Replies: 13
Views: 2570

Re: Send values to MQTT only when changed

Can you show all your rules, here, so we can see if there is something incorrect in there? on ADS1115_0x49_erste#Serverraum_Fenster do if [var#1]!=%eventvalue1% let,1,%eventvalue1% publish,esp/Espeasy_EG_Alarmanlage/ADS1115_0x49_erste/Serverraum_Fenster,%eventvalue1% endif endon on ADS1115_0x49_ers...
by Marv21
17 Jan 2024, 12:35
Forum: ESP Easy: Software
Topic: Send values to MQTT only when changed
Replies: 13
Views: 2570

Re: Send values to MQTT only when changed

Great! You found it yourself, meaning you really understand what's happening. That's the best way. Maybe I should rephrase my description of the %...% syntax. It is more like "not task specific". "Global" is perhaps not the best description as it is indeed only referring to the ...
by Marv21
17 Jan 2024, 02:11
Forum: ESP Easy: Software
Topic: Send values to MQTT only when changed
Replies: 13
Views: 2570

Re: Send values to MQTT only when changed

one more problem. If the Value is greater 0, they are refreshing every second...


EDIT: Found it, int is ofc an integer, values with decimal dont work. Changed it to var. ;)
by Marv21
17 Jan 2024, 01:47
Forum: ESP Easy: Software
Topic: Send values to MQTT only when changed
Replies: 13
Views: 2570

Re: Send values to MQTT only when changed

on ADS1115_0x4B_dritte#Arbeitszimmer_Fenster_links do if [int#2]!=%eventvalue1% // Arbeitszimmer_Fenster_links has changed let,2,%eventvalue1% publish,esp/Espeasy_EG_Alarmanlage/ADS1115_0x4B_dritte/Arbeitszimmer_Fenster_links,%eventvalue1% endif endon on ADS1115_0x4B_dritte#Arbeitszimmer_Fenster_re...
by Marv21
17 Jan 2024, 01:19
Forum: ESP Easy: Software
Topic: Send values to MQTT only when changed
Replies: 13
Views: 2570

Re: Send values to MQTT only when changed

Sorry, could you help me out once more. I wanted to add the other sensors. But that seems to crash the ESP (100% Load). on ADS1115_0x49_erste#Serverraum_Fenster do if [int#1]!=%eventvalue1% // Serverraum_Fenster has changed let,1,%eventvalue1%% publish,esp/Espeasy_EG_Alarmanlage/ADS1115_0x49_erste/S...
by Marv21
17 Jan 2024, 00:48
Forum: ESP Easy: Software
Topic: Send values to MQTT only when changed
Replies: 13
Views: 2570

Re: Send values to MQTT only when changed

variables wrapped in percent chars like this are 'system variables' or 'global variables' (or variables in the scope of an event handling block) %...% To refer to a task value, you need square brackets like this: [...#...] where the # is used to separate a task name and task value name. For example...
by Marv21
17 Jan 2024, 00:06
Forum: ESP Easy: Software
Topic: Send values to MQTT only when changed
Replies: 13
Views: 2570

Re: Send values to MQTT only when changed

You can try to detect changes in the rules and then call publish from the rules instead of via the controller. So you need to uncheck sending to the controller from the task. Assuming your task is called "Analog" and the task value is "value" (change the rules accordingly when t...
by Marv21
16 Jan 2024, 02:06
Forum: ESP Easy: Software
Topic: Send values to MQTT only when changed
Replies: 13
Views: 2570

Send values to MQTT only when changed

Hello, I try to watch contacts if they are closed or not. If they are they have 5V, if not 0V. (Analog input - ADS1115) I need to use a voltage messurement. This works pretty well, but the values are transmitted every second - even if they didnt change. I dont want to set the "interval" op...