EasyManuals Logo

Embedded Systems LogicMachine5 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 #229 background imageLoading...
Page #229 background image
229
local main, rev, step, val, new, delay
step = 10 -- in %
delay = 0.5 -- in seconds
-- ignore "stop" command
val = tonumber(event.datahex, 16)
if val == 0 then
return
end
-- up, normal mode
if event.dst == up then
main, rev = up, down
-- down, reverse step
elseif event.dst == down then
main, rev = down, up
step = -step
-- invalid object
else
return
end
-- current output object value
val = grp.getvalue(out) or 0
while true do
-- main object in "stop" state
if not grp.getvalue(main) then
return
end
-- reverse object in "start" state
if grp.getvalue(rev) then
return
end
-- get new value
new = math.min(100, val + step)

Table of Contents

Other manuals for Embedded Systems LogicMachine5

Questions and Answers:

Question and Answer IconNeed help?

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

Embedded Systems LogicMachine5 Specifications

General IconGeneral
BrandEmbedded Systems
ModelLogicMachine5
CategoryDimmer
LanguageEnglish

Related product manuals