h6. [[SoundChannels]] h6(. » [[SoundChannels SWI Calls|SWI Calls]] h6((. » [[Sound_InstallVoice]] h6(((. » [[Sound Voice Generator]] h2. Voice Generator Instantiate The Instantiate entry is called to inform the Voice Generator of a request to attach a channel to it. |_<^{width:4em}. Entry | | |>^. R0 |<^. Channel number | |>^. R5 |<^. Pointer to [[Sound Voice Generator|Voice Generator]] | |_<^{width:4em}. Exit | |>^. R0 |<^. Preserved if the Instantiation was successful, else it is altered. | |>^. R1-R4 |<^. Preserved | |>^. R5 |<^. May be corrupted | |>^. R6-R12 |<^. Preserved | h4. Notes The Voice Generator is entered in SVC mode. To return to the Channel Handler use *LDR PC,[R13],#4* A Voice Generator should ideally be able to support eight channels. The request can either be accepted (R0 preserved on exit), or rejected (R0 altered on exit). The usual reason for rejection is that an algorithm is slow and is already filling as many channels as it can within each buffer period: for example very complex algorithms, or ones that read long samples off disc. h4. See also * [[Sound_Configure]], [[Sound Voice Generator]]