5
\$\begingroup\$

I'm creating customized DALI Master from scratch. The problem is, that no matter what I do, none of the devices responds to short addressing.

Let's start from the beginning.

  • After connecting single device to DALI bus, it works as expected for all commands if using BROADCAST addressing (first byte equal to 0xFF). Transmission goes both ways reliably, including 'direct arc', 'off' and 'query status' commands. As expected the device responds with dec 64 for 'query status', which means no short address is set.
  • In the next step I tried performing binary search sequence, to assign short address to the device:
    • Initialize command is sent (x2) - 0b10100101 0b00000000
    • Randomise commands is sent (x2) - 0b10100111 0b00000000
    • Binary search is performed, device is detected as expected.
    • Program short address is sent (x1) 0b10110111 0b00000001 (to set short address 0)
    • Verify short address returns 'YES', Query short address returns 0b00000001. Works like charm.
    • Terminate command is sent (x1) - 0b10100001 0b00000000
  • After trying to execute any command with short address (for example querying status) using 0b00000001 0b10010000 device won't respond.
  • What is even more interesting, if broadcast is used again, device responds to 'query status' with status 0, meaning that short address is set...
  • What is more interesting again, sending this command to all short addresses gives no response to any of them.

I already tried 2 different DALI slaves from different manufacturer, both with exactly same result.

\$\endgroup\$
2
  • \$\begingroup\$ Are the slave devices listed in the DALI-2 certification list? It sounds like either incorrect behaviour by the slave devices or marginal physical layer parameters resulting in unreliable operation (power supply current or voltage, cabling, pulse widths or rise/fall times). Also I would advice comparing your results against a known DALI master such as Tridonic DALI USB. \$\endgroup\$
    – Martin
    Commented Oct 11, 2018 at 9:47
  • \$\begingroup\$ I already tested 2 different DALI slaves from 2 different manufacturers (both listed on your website). The signal generated is perfectly fine, pure square. Yes, the next step would be to get certified DALI Master and compare the output. \$\endgroup\$
    – peku33
    Commented Oct 11, 2018 at 17:20

1 Answer 1

3
\$\begingroup\$

In the end I found a solution myself.

There was a bug in start-bit generation procedure.

// 0 ... 0 bits - 0 ... 1 menchester bits - start bits
if(MenchesterBitIndex <= 2)
    return true != MenchesterInverted;

The <= instead of < caused 3 bits to be generated as start bits. For all commands starting with bit 1 this made no difference, so the whole addressing sequence was ok. For normal short addressing the first bit was 0 which generated invalid menchester code.

\$\endgroup\$

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.