58
Example
1.
-- log function accepts Lua nil, boolean, number and table (up to 5 nested levels) type
variables
2.
a
={
key1
=
'value1'
, key2
=
2
}
3.
b
=
'test'
4.
c
=
123.45
5.
-- logs all passed variables
6.
log
(
a, b, c
)
1.2.15.
Scheduled scripting date/time format
Scheduled scripting uses standard
cron
format for date/time parameters. Valid values are:
*
— execute script every minute, hour or day.
*/N
— execute script every N minutes, hours or days. N is an integer, script is executed
when current value divided by N gives 0 in modulo. For example, script with hour
parameter set to
*/8
will be executed when hour is 0, 8 and 16.
N
— execute script exactly at N minute, hour or day.
N-K
— execute script when minute, hour or day is between N-K range (inclusive).
N,K
— it is possible to specify several
N
and
N-K
type parameters separated by comma.
For example, script with minute parameter set to 15,50-52 will get executed when minute is
15, 50, 51 and 52
1.2.16.
Time function
os.sleep(delay)
Delay the next command execution for the
delay
seconds.
os.microtime ()
Returns two values: current timestamp in seconds and timestamp fraction in nanoseconds
os.udifftime (sec, usec)
Returns time difference as floating point value between now and timestamp components passed
to this function (seconds, nanoseconds)
1.2.17.
Data Serialization
serialize.encode (value)
Generates a storable representation of a value.
serialize.decode (value)
Creates a Lua value from a stored representation.
Summary of Contents for LogicMachine3 Re:actor
Page 10: ...10 Terminal connection schemes KNX TP...
Page 12: ...12 24V power supply...
Page 13: ...13 Analog inputs e g reed contact...
Page 14: ...14 Analog inputs 0 10V...
Page 15: ...15 Digital output...
Page 16: ...16 Resistive sensor input...
Page 17: ...17 Analog output...
Page 26: ...26 Make sure that bus status is Online press button in ETS...
Page 35: ...35 o Then minimize side bar by pressing on left arrow icon to make the map more visible...
Page 83: ...83 66 if err then 67 alert FTP upload failed s err 68 end...
Page 107: ...107...
Page 108: ...108 1 14 Help Documentation for scripting syntaxes is displayed in Help tab...
Page 126: ...126 Datapoints can be shown also in a way of table which can be later exported as CSV file...
Page 141: ...141...