The SCRIPT resource allows to run Lua scripts together with CPX standard behaviour and functionality. The Lua programming language has been chosen for this purpose because it's simple, stable, and powerful.
Add the resource to the Abilis system with the following command:
[15:43:30] ABILIS_CPX:a res:script
RES:Script ALREADY EXISTSThe SCRIPT resource may already exist in the system, but may not yet be active: set it active with the command:
[16:02:48] ABILIS_CPX:s act res:scriptCOMMAND EXECUTED
![]() | Caution |
|---|---|
After adding or setting the SCRIPT active, you must restart the Abilis to make the resource running (use the command warm start to reboot the Abilis). |
[16:51:53] ABILIS_CPX:s p script act:yesCOMMAND EXECUTED [16:52:04] ABILIS_CPX:d p scriptRES:Script - Not Saved (SAVE CONF), Not Refreshed (INIT) ---------------------- ------------------------------------------------------------------------ Run DESCR:Lua_scripting_service LOG:NO ACT:YES bg-sesnum:5 tcp-sockets:10 udp-sockets:10 wdir:C:\APP\SCRIPT\ - Background scripts --------------------------------------------------- id:0 startup:NO file: id:1 startup:NO file: id:2 startup:NO file: id:3 startup:NO file: id:4 startup:NO file:
Use the following command to display the parameters of the resource; by typing d p script ? command it's possible to display the meaning of all parameters.
[16:52:04] ABILIS_CPX:d p script
RES:Script --------------------------------------------------------------------
Run DESCR:Lua_scripting_service
LOG:NO ACT:YES bg-sesnum:5 tcp-sockets:10 udp-sockets:10
wdir:C:\APP\SCRIPT\
- Background scripts ---------------------------------------------------
id:0 startup:YES file:
id:1 startup:NO file:
id:2 startup:NO file:
id:3 startup:NO file:
id:4 startup:NO file:Meaning of the parameters:
LOGLogging functionalities activation/deactivation.
ACTOperation activation [NO, YES].
bg-sesnumMaximum number of background sessions [0..50].
tcp-socketsMaximum number of TCP sockets that can be opened by all LUA scripts [0..100].
udp-socketsMaximum number of UDP sockets that can be opened by all LUA scripts [0..100].
wdirDirectory containing script files. Full path with drive letter ['C'..'Z'] terminated by '\'. Max 128 chars. Spaces require double quotes (E.g. "C:\My dir\").
idScript index [0..(bg-sesnum - 1)] or A or ALL.
startupEnable/disable the script execution at system startup [NO, YES].
fileScript file name. Max 32 chars. Spaces require double quotes (E.g. "my script").
The following command allows the administrator to change the configuration of the resource:
s p script parameter:value...
![]() | Caution |
|---|---|
To activate the changes made on the upper case parameters, execute the initialization command init res:script; while to set act the changes made on the lowercase parameters a save conf and an Abilis restart are required (i.e. With warm start command). |