This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

DALI dimming and scale objects
#1
I am dying trying to wrap my head around this. The touch panel MDT Smart 86 has 4 Objects to control dimming. On/off , Dimming, and I think Visu Scale on one button.

This is how it looks in my LM DR
   

this is how I have configured in ETS4 (PB2 is the button)
   

The button Kitchen does dimm and do on/off, but the scale object does not update to the real dimming value neither in the LM nor on the Button Display.

what am I doing wrong?
Reply
#2
LM does not provide status feedback for DALI light levels. You can create a resident script to poll actual values from ballasts. Do you have many of them?
Reply
#3
(05.01.2019, 13:27)admin Wrote: LM does not provide status feedback for DALI light levels. You can create a resident script to poll actual values from ballasts. Do you have many of them?

Hi! I have 8 devices (4 on each Lunatone).
Reply
#4
Use this resident script, 0 sleep time. It will poll each ballast, then sleep for 1 second internally. You need to create status objects manually, this example uses 32/2/0..32/2/7 range. Data type is 1-byte scale, make sure that status objects are not the same as control objects.

Code:
require('user.dali')

for address = 0, 7 do
  res = dalicmd('internal', 'queryactual', { addrtype = 'short', address = address })

  if res then
    value = res:byte()
    value = math.floor(value / 2.54 + 0.5)
    
    grp.checkupdate('32/2/' .. address, value)
  end

  os.sleep(1)
end
Reply
#5
res = dalicmd('internal', 'queryactual', { addrtype = 'short', address = address })

returns Nill for all addresses ... on/off works flawlessly

ohh my mistake, changed it to "internal2". Works!!! thank you
Reply
#6
(05.01.2019, 18:02)admin Wrote: Use this resident script, 0 sleep time. It will poll each ballast, then sleep for 1 second internally. You need to create status objects manually, this example uses 32/2/0..32/2/7 range. Data type is 1-byte scale, make sure that status objects are not the same as control objects.

Code:
require('user.dali')

for address = 0, 7 do
  res = dalicmd('internal', 'queryactual', { addrtype = 'short', address = address })

  if res then
    value = res:byte()
    value = math.floor(value / 2.54 + 0.5)
   
    grp.checkupdate('32/2/' .. address, value)
  end

  os.sleep(1)
end

Hello Admin 
What method could one use for more devices like 40?
Tag on the control objects could help?
Best Regards,
Reply
#7
Change 7 on line 3 to the number of ballasts you want to poll.
Reply
#8
(25.04.2022, 06:18)admin Wrote: Change 7 on line 3 to the number of ballasts you want to poll.

I did, but its takes 40 seconds to update all feedback.
Is there an optimized solution?
Best Regards,
Reply
#9
You can lower the sleep time between each poll.
Reply
#10
(25.04.2022, 08:52)admin Wrote: You can lower the sleep time between each poll.

Could I set it to 0.1?
Best Regards,
Reply
#11
Try and see if it works for you. DALI bus is very slow so it can be easily overloaded. If you query too often then the control requests will be delayed.
Reply
#12
(25.04.2022, 08:58)admin Wrote: Try and see if it works for you. DALI bus is very slow so it can be easily overloaded. If you query too often then the control requests will be delayed.

Thanks I will try.
Also I should use only one script to read/write from/to DALI Bus in-order to prevent collision?
another thing, How to read the ballast on/off status ?
BR,
Best Regards,
Reply
#13
You can use multiple scripts in parallel. For both on/off and scale status see this: https://forum.logicmachine.net/showthrea...8#pid19988
Reply
#14
(25.04.2022, 09:20)admin Wrote: You can use multiple scripts in parallel. For both on/off and scale status see this: https://forum.logicmachine.net/showthrea...8#pid19988

Big thanks
Best Regards,
Reply


Forum Jump: