Handling a software update is done through READ_DFU and WRITE_DFU function.
The following Interrupt lines must be used to derive the state:
- DFU_START_IRQ
- DFU_PACKET_IRQ
- DFU_STOP_IRQ
Whenever a software update is triggered, the DFU_START_IRQ goes high.
Then the fixture must get ready for receiving firmware. One of the following responses of the Fixture is required:
- 0x0: DFU_ACCEPT
- 0x1 – 0xFF: DFU_ABORT
A fixture responds by using WRITE_DFU function. The Timeout for the response is set to 20 seconds. Writing a response will disable the DFU_START_IRQ flag.
After accepting the DFU, the iQ.Controller starts to send firmware packets. Each packet has a unique id which is counted upwards. Length is variable up to 200Byte. Default length is 128 Byte. packetNr is stored in Big Endian not Little Endian!
| data[0] | data[1] | data[2] | data[2] | … | data[202] |
|---|---|---|---|---|---|
| packetNr | packetNr | data[0] | dmx[1] | … | dmx[200] |
After reading the packet, the next packet will be transfered automatically. No extra response necessary.
If there occurs an error it is possible to abort the DFU early by writing a response greater than 0 (0x1 – 0xFF).
DFU is aborted if no packet is read for 30 seconds. It can take up to 30 seconds before the first packet arrives. Please make sure not to abort before this timeout.
After receiving the last packet, DFU_STOP_IRQ flag will go high in order to signal that all packets are transfered and DFU transmission is finished.
Now a last response from the fixture is required. The response should be one of the following:
- 0x0: DFU_SUCCESS
- 0x1: DFU_ERROR_FLASH_ERASE
- 0x2: DFU_ERROR_NOT_IN_PROGRESS
- 0x3: DFU_ERROR_CORRUPTED_HEADER
- 0x4: DFU_ERROR_CORRUPTED_IMAGE
- 0x5: DFU_ERROR_INVALID_IMAGE_VERSION
- 0x6: DFU_ERROR_NO_PREAMBLE
- 0x7: DFU_ERROR_INVALID_FIXTURE_ID
- 0x8: DFU_ERROR_UNKNOWN
- 0x9: DFU_ERROR_SIGNATURE_NECESSARY_NOT_FOUND
- 0x0A: DFU_ERROR_PACKET_TIMEOUT
- 0x0B – 0xFF: Reserved
