EasyManuals Logo

Embedded Systems LM5p-GSMC User Manual

Default Icon
291 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #227 background imageLoading...
Page #227 background image
227
require('user.dali')
res, err = dalicmd('internal', 'queryshortaddr', { addrtype = 'broadcast' })
if res then
log(res:byte())
else
log(err)
end
Example (add 4 DALI short addressed to one group with nr. 7)
require('user.dali')
dalicmd('internal', 'addtogroup', { addrtype = 'short', address = 1, value = 7 })
dalicmd('internal', 'addtogroup', { addrtype = 'short', address = 2, value = 7 })
dalicmd('internal', 'addtogroup', { addrtype = 'short', address = 3, value = 7 })
dalicmd('internal', 'addtogroup', { addrtype = 'short', address = 4, value = 7 })
Setting group 7 to a certain value (event-based script, object type 1 byte 0..100%):
require('user.dali')
value = event.getvalue()
value = math.floor(value * 2.54)
dalicmd('internal', 'arc', { addrtype = 'group', address = 7, value = value })
Example (functions for calling and saving scenes, can be used not only for DALI)
First, you have to define each scene via a Lua table where each item is a table with two items:
group address and value. Each scene has a unique id which can be a number or a string.
callscene(id) sets all objects in given scene to their specified value. First it looks for a saved
scene in storage and uses default values if storage is empty.
savescene(id) gets current values of all objects from given scene and saves the whole scene in
storage.
scenes = {}
scenes[1] = {
{ '15/1/1', 50 },
{ '15/1/2', 75 },

Table of Contents

Other manuals for Embedded Systems LM5p-GSMC

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Embedded Systems LM5p-GSMC and is the answer not in the manual?

Embedded Systems LM5p-GSMC Specifications

General IconGeneral
BrandEmbedded Systems
ModelLM5p-GSMC
CategoryDimmer
LanguageEnglish

Related product manuals