Showing changes from revision #2 to #3:
Added | Removed | Changed
The Fill entry is used when the current sound is to continue and no new command has been issued.
Entry | |
---|---|
R0 | Pointer to Voice Generator |
R4 | Flag byte |
R6 | Negative if Channel Handler configuration has changed |
R7 | Channel number (0-7) |
R8 | Sample period in µS |
R9 | Pointer to Sound Channel Control Block |
R10 | Buffer end address for this channel (exclusive) |
R11 | Interleave increment (1, 2, 4 or 8) |
R12 | Buffer start address for this channel (inclusive) |
Exit | |
---|---|
R0 | Flag byte |
On exit it is normal to return the same flags as for the Update entry.
The Voice Generator is entered in IRQ mode with IRQs enabled, they must remain enabled to ensure that system devices do not have a lengthy wait to be serviced. The code for a Voice Generator must therefore be re-entrant, and R14 must not be used as a subroutine link register, since an interrupt will corrupt it. Sufficient IRQ stack depth must be maintained for system IRQ handling. You can enter SVC mode if you wish.
To return to the Channel Handler use LDR PC,[R13],#4
The buffer length is a multiple of 4 words (16 bytes) long, and word aligned and the interleave is dependent on the number of channels.