0
\$\begingroup\$

I have a DALI setup only with one LED.

I set the high, medium, and low addresses to FF but when I send the compare command, I get no response.

When commands are broadcasted, I get responses for control-query commands are all working.

I tried assigning a short address by broadcasting SET SHORT ADDRESS DTR0 connecting only one ballast and then send the control-query commands, and it worked. I changed the assigned short address to 0xFF before trying to do randomize method for address assigning

I am using MM32 microcontroller.

\$\endgroup\$
0

2 Answers 2

1
\$\begingroup\$

COMPARE command only produces a response in gear which in the initialisationState = ENABLED and the random address <= search address. So you need to first ensure initialisationState is set to ENABLED by sending INITIALISE twice within 100ms. RANDOMISE is optional (for your tests, you will probably want it in a production system). INITIALISE starts a 15 minute timer, after which it will disable itself.

As long as you are within the 15 minutes and you've set the search address to 0xFFFFFF, you should get a response to a COMPARE. But there is also the WITHDRAW command which changes the initialisationState to WITHDRAWN so that would also prevent you from getting responses to COMPARE. Note that you have to send the search address after the INITIALISE or it will be ignored.

\$\endgroup\$
0
\$\begingroup\$

What problem are you trying to solve? Writing DALI commissioning without access to IEC 62386-102 is going to be difficult, and it takes some effort to, ahem, find a copy of the required PDF on one of those websites which take copyright protection with a big grain of salt. In my experience it was easier to rely on the vendor SW to do the provisioning, and once it's been done, focus on writing code for actually using these devices instead of starting with the provisioning process.

That said, the commissioning process requires the INITIALIZE command first (which has to be sent twice in a short time as usual for these "special" commands). Then, you issue RANDOMISE (again twice within 100ms), and only then do the SEARCHADDRH, SEARCHADDRM, SEARCHADDRL followed by COMPARE and detecting a collision or response to that command. Once you've identified the randomAddress of your first device (by repeatedly setting the searchAddress and detecting a response or a collision through COMPARE), you proceed with the PROGRAM SHORT ADDRESS and WITHDRAW. Then you continue until all of your devices have been already addressed. Also as an optimization, you can QUERY CONTROL GEAR PRESENT either as a broadcast, or with an address meaning "devices without short address" to see if there's something on the bus which still needs addressing.

\$\endgroup\$
4
  • \$\begingroup\$ I followed the procedure same as you mentioned above but still no response is coming from the ballast. Is this have to do anything with the timing for sending these commands? INITIALIZE and RANDOMISE commands should be sent twice within 100ms right, then what about other commands? \$\endgroup\$
    – user337983
    Commented Apr 20, 2023 at 12:03
  • \$\begingroup\$ Within the addressing commands, only INITIALISE and RANDOMISE have to be send twice within 100ms, the other commands that need this are setting non volatile configuration information. INITIALISE has 3 options depending on the second byte - all, short adress matching or only those without short address. Are you using the all option, second byte = 0? \$\endgroup\$
    – Martin
    Commented Apr 20, 2023 at 14:59
  • \$\begingroup\$ Yes I am using the all option. \$\endgroup\$
    – user337983
    Commented Apr 21, 2023 at 4:51
  • \$\begingroup\$ Hasn't the maximum repetition interval been shortened to 75ms by a revision to the standard as some older/not-DALI2 certified hardware had problems with the longer interval? \$\endgroup\$
    – SlySven
    Commented Oct 24 at 18:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.