| 103 | |
| 104 | |
| 105 | == Bank 63: DMX512 == |
| 106 | The DMX512 bank consists of two parts: the sub-bank part and the data part: |
| 107 | ||= Offset =||= Length =||= Description =|| |
| 108 | ||4 ||1 ||Subbank select || |
| 109 | ||5-end ||till end ||Data || |
| 110 | |
| 111 | The subbank select is the offset of the DMX data as mapped into the bank. |
| 112 | The channel of a given address is: (address-5)+32*subbank. |
| 113 | This allows access to about eight thousand channels, or sixteen universes. |
| 114 | |
| 115 | A typical method to randomly access channels is: |
| 116 | {{{ |
| 117 | variables of unsigned integer type: bank, offset |
| 118 | |
| 119 | bank = int(channel/32) |
| 120 | offset = bank*32 |
| 121 | |
| 122 | write_to_device(OFFSET_SUBBANK, bank) |
| 123 | write_to_device(OFFSET_DATA+channel-offset, value) |
| 124 | }}} |