send value from one OSP to OLED of another ESP
Moderators: grovkillen, Stuntteam, TD-er
send value from one OSP to OLED of another ESP
Hello
I'm trying toi send some values from one ESP mesauring temperature etc... to the oled screen of another ESP
The command http://192.168.0.63/control?cmd=OLEDFRAMEDCMD,1,'Hello World'
is working well
now, I want to update temperature from another ESP
I create the following rule
on Temperature#Temperature do
SendToHTTP,192.168.0.63,80,/control?cmd=OLEDFRAMEDCMD,2,Sauna=[Temperature#Temperature]
endon
I suppose that for any change of Temperature, the SentToHTTP will be called to send the temperature. but nothing happen
I tried by using a dummy variable in ESP_OLED and TaskValueSet command
SendTo,13,'TaskValueSet,10,1,Sauna=[Temperature#Temperature]'
My problem is to add a measurement in the command to send
Thomas
I'm trying toi send some values from one ESP mesauring temperature etc... to the oled screen of another ESP
The command http://192.168.0.63/control?cmd=OLEDFRAMEDCMD,1,'Hello World'
is working well
now, I want to update temperature from another ESP
I create the following rule
on Temperature#Temperature do
SendToHTTP,192.168.0.63,80,/control?cmd=OLEDFRAMEDCMD,2,Sauna=[Temperature#Temperature]
endon
I suppose that for any change of Temperature, the SentToHTTP will be called to send the temperature. but nothing happen
I tried by using a dummy variable in ESP_OLED and TaskValueSet command
SendTo,13,'TaskValueSet,10,1,Sauna=[Temperature#Temperature]'
My problem is to add a measurement in the command to send
Thomas
Re: send value from one OSP to OLED of another ESP
You need to quote arguments containing commas or spaces paased to SendToHTTP or SendTo, as it sees those as separators, and won't glue them together itself. Quotes can be ", " or `, just use one pair that is not used in the list of arguments you're quoting.
/Ton (PayPal.me)
Re: send value from one OSP to OLED of another ESP
Yep.
See also: https://github.com/letscontrolit/ESPEasy/issues/2724
Code: Select all
SendToHTTP,192.168.0.63,80,"/control?cmd=OLEDFRAMEDCMD,2,Sauna=[Temperature#Temperature]"
Re: send value from one OSP to OLED of another ESP
Hello, can someone help me ?
i have this rule, but it doesn't work... where 'fumo' is the device's name.
On [fumo]#State do
If [fumo]#State=0
SendToHTTP,192.168.1.129,80,"/control?cmd=NEXTION,sleep=1"
Else
SendToHTTP,192.168.1.129,80,"/control?cmd=NEXTION,sleep=0"
Endif
Endon
Thankyou for your help
namxcap
i have this rule, but it doesn't work... where 'fumo' is the device's name.
On [fumo]#State do
If [fumo]#State=0
SendToHTTP,192.168.1.129,80,"/control?cmd=NEXTION,sleep=1"
Else
SendToHTTP,192.168.1.129,80,"/control?cmd=NEXTION,sleep=0"
Endif
Endon
Thankyou for your help
namxcap
Re: send value from one OSP to OLED of another ESP
The syntax should be [taskname#varname], not [taskname]#varnamenamxcap wrote: ↑07 May 2021, 00:14 Hello, can someone help me ?
i have this rule, but it doesn't work... where 'fumo' is the device's name.
On [fumo]#State do
If [fumo]#State=0
SendToHTTP,192.168.1.129,80,"/control?cmd=NEXTION,sleep=1"
Else
SendToHTTP,192.168.1.129,80,"/control?cmd=NEXTION,sleep=0"
Endif
Endon
Thankyou for your help
namxcap
Re: send value from one OSP to OLED of another ESP
I don't know why but it's no working ......
Re: send value from one OSP to OLED of another ESP
This is the correct syntax:
Code: Select all
On fumo#State do
If [fumo#State]=0
SendToHTTP,192.168.1.129,80,"/control?cmd=NEXTION,sleep=1"
Else
SendToHTTP,192.168.1.129,80,"/control?cmd=NEXTION,sleep=0"
Endif
Endon
- the line "if [fumo#state]=0" should have [] included, now it is the value that needs to be checked; when having these [] it is replaced by the value (if that taskname/value is available)
/Ton (PayPal.me)
Re: send value from one OSP to OLED of another ESP
YES !!! Now it works .... i learned one more thing !!!
Thankyou very much
Thankyou very much
Who is online
Users browsing this forum: Ahrefs [Bot] and 134 guests