The UK Home Automation Archive

Archive Home
Group Home
Search Archive


Advanced Search

The UKHA-ARCHIVE IS CEASING OPERATIONS 31 DEC 2024


[Message Prev][Message Next][Thread Prev][Thread Next][Message Index][Thread Index]

Re: Using Multiple Conditions in Determinators



Hi Frank,

> > One way around this is to store the details of the last infra red
signal
> that was received in a global variable.
>
> Had a quick look but not sure how to do this ???

The example below should take the value from the "keys=" body
parameter, and place it into a global called IR_KEYPRESS...

In the Edit Determinator dialog, click on the Actions tab, and click Add to
add a new action.
Enter a name for the action, and select "Set the value of a global
variable" from the action type dropdown list.

In the Global Name box, enter the name of the global where you want the key
code to be stored, e.g. IR_KEYPRESS
In the Value box, enter
{XPL::KEYS}

(I think this needs to be all in uppercase)
Basically, you can use a number of special keywords, enclosed in curly
brackets.
The XPL:: prefix allows you to do things with any of the body parameters in
the message that caused this determinator to fire.

So, as it is a remote.basic message that has caused the determinator to
fire, we can extract the value from the keys parameter by using
{XPL::KEYS}.

Hope that helps,

Regards,

John




xPL Main Index | xPL Thread Index | xPL Home | Archives Home

Comments to the Webmaster are always welcomed, please use this contact form . Note that as this site is a mailing list archive, the Webmaster has no control over the contents of the messages. Comments about message content should be directed to the relevant mailing list.