Home BSS User Forum BSS Archive Threads Discussion London Architect with Soundweb London
Options

How are signed 32-bit integers represented in DI messages?

The BumpSVPercent DI command takes a scaled percentage. How are negative numbers represented? Is the high-order bit set? Does the AMX programming environment use the same representation as the Blu DI protocol, allowing straight math on an AMX 32-bit integer to produce the needed representation?

Thanks --
--Daniel

Comments

  • Options
    nitrogennitrogen Posts: 7
    Two's complement, big endian. If your unsigned 32-bit ints work from the AMX, then your signed ones should as well. Just be sure to send it big endian (i.e. high order byte first).
  • Options
    Dan LynchDan Lynch Posts: 472
    -1 = 0xFF FF FF FF
    -2 = 0xFF FF FF FE
    -3 = 0xFF FF FF FD
    etc.

    Dan
  • Options
    kirchhkirchh Posts: 18
    Thanks for the info -- exactly what I needed.

    --Daniel
  • Options
    Dan LynchDan Lynch Posts: 472
    It's on page 21 of \"London DI Kit.pdf\". Not every question needs to go to the user group.

    Dan
  • Options
    kirchhkirchh Posts: 18
    It's on page 21 of \"London DI Kit.pdf\".

    There's no explicit statement of the representation of negative numbers on that page of the manual, though I suppose it could be derived by performing a calculation on an example. I hope 'nitrogen' doesn't feel s/he was answering an unnecessary inquiry with his/her clear, direct answer.
    Not every question needs to go to the user group.

    Quite true. That's why of the hundreds of questions I've had over the last two weeks while developing an LA design and coding a complete AMX control system, I've only posted a handful to the forum.

    --Daniel
This discussion has been closed.