nxa.ExecuteXCommand
This function is used to execute an XLogic command within LUA.
Signature
nxa.ExecuteXCommand (string, ...)
Parameters
Name | Type | Mandatory/Optional | Description |
---|---|---|---|
XCommandName | string | M | Name of XCommand. The variable scope is encoded as " : " . If no scope is needed only the XCommand name shall be given. |
InputsParametersOutputs | ... | O | Inputs, Parameters and Outputs |
Provide a function call argument for each input, parameter, and output.
Refer to this table to choose the correct format for passing arguments:
XLogic type | LUA type | notes |
---|---|---|
BOOL | boolean, number, string | valid expressions for true are: true, "T", "TRUE", 1 valid expressions for false are: false, "F", "FALSE", 0 String expressions are non-case-sensitive. |
ITEM ID | string | A backslash inside the string has to be escaped by a backslash: "NETx\\XIO\\KNX\\172.16.1.3\\05/8/012" |
NUMBER | number | |
STRING | string | |
ANY | string | A type indicator prefix is required in the string: "{<type indicator>}:<value>" Type indicators:
|
Example
Following XCommand is to be called:
XCommand argument | XLogic type | Value |
---|---|---|
Input | ITEM ID | NETx\XIO\KNX\172.16.1.3\05/8/012 |
Input | NUMBER | 123 |
Input | BOOL | TRUE |
Parameter | ANY | number: 987 |
Parameter | ANY | boolean: true |
Output | ITEM ID | NETx\XIO\KNX\172.16.1.3\05/8/013 |
The respective call from LUA is
nxa.ExecuteXCommand ("NETx\\XIO\\KNX\\172.16.1.3\\05/8/012", 123, true, "{N}:987", "{B}:T", "NETx\\XIO\\KNX\\172.16.1.3\\05/8/013")
Return
None.