Page 1 of 1

Lua reference links

Posted: Thu Jun 12, 2008 2:20 pm
by RobertBell
From our manual:
Advanced scripting in Palette uses the Lua programming language and can be constructed to execute very complex routines that access the Processor's operating system, file system or other external non-lighting related devices. Lua is a full featured programming language that offers IF THEN ELSE type routines as well as user definable functions, string manipulation and local and global variable storage.
found on page ... cripts.htm where there are 3 examples including file access and timeofday routines

The defacto on-line manual for Lua

A user group

Re: Lua reference links

Posted: Fri Jun 13, 2008 6:08 pm
by JohnGrimshaw
And this is a great place to get started, learning about Lua...

Re: Lua reference links

Posted: Tue Sep 30, 2008 1:00 pm
by RobertBell
or directly to search some sample code:

Today I found this one and stole it outright. Can't believe Lua doesn't have a clean way of doing this direclty

Code: Select all

function round(val, decimal)
  if (decimal) then
    return math.floor( (val * 10^decimal) + 0.5) / (10^decimal)
    return math.floor(val+0.5)