Hi,
I have a little problem with #all and rules
when i set this it doesn't work because %eventvalue1% has no value.
i think %eventvalue1% will be the name of the value apparently not.
How i can call a name from a group of value ?
on GROUPE1#ALL do
let,temp1,%eventvalue1%
let,temp2,%eventvalue2%
let,temp3,%eventvalue3%
LogEntry,"Valeur Temp1: %temp1%"
LogEntry,"Passage LED"
if temp1 > 27
LogEntry, "LED ON"
gpio,15,1
SendToSerial "page0.t6.txt=\"TEMPERATURE CRITIQUE\""
NEXTION,'page0.t0.txt= "TEMPERATURE CRITIQUE"'
else
LogEntry,"LED OFF"
LogEntry,"Valeur Temp1: %temp1%"
gpio,15,0
SendToSerial "page0.t6.txt=\"Normal\""
NEXTION,'page0.t0.txt= "TEMPERATURE NORMALE"'
endif
endon
Thanks.
Rules and #ALL
Moderators: grovkillen, Stuntteam, TD-er
Re: Rules and #ALL
This will not work: "let,temp1,%eventvalue1%"
You need to use a numerical index instead of 'temp1'.
So more something like this:
You need to use a numerical index instead of 'temp1'.
So more something like this:
Code: Select all
on GROUPE1#ALL do
let,1,%eventvalue1%
let,2,%eventvalue2%
let,3,%eventvalue3%
LogEntry,"Valeur Temp1: [var#1] Temp2: [var#2] Temp3: [var#3]"
endon
Re: Rules and #ALL
Furthermore, the proper syntax for this:
Will be:
More details:
viewtopic.php?t=6288
Code: Select all
if temp1 > 27
Code: Select all
if %v1% > 27
viewtopic.php?t=6288
Who is online
Users browsing this forum: No registered users and 27 guests