English
Language : 

PXD20RM Datasheet, PDF (1391/1628 Pages) Freescale Semiconductor, Inc – PXD20 Microcontroller
Table 39-43. Work flow of generating a sequence of notes by one channel (continued)
3. Configure the SGM
• Clocking/ DDS mode
• ASR envelope
• Enable the interrupt when reaching the
configurable volume level at Release/no-output
Phase
• Configure the DDSF (frequency) of 1st note for
this channel
• Check the SGMST. Wait until the operation
status is IDLE(STATCHx=3'b000).
• check the FIFO status. If the fifo is Full, enable
the SGMCTL.SOGCHx
• Configure the DDSF (frequency) and/or other
configurations (envelope...) of 2nd note for this
channel
all DDS-configuration are buffered
Start the Sound generation by DDS.
Generate the 1st NOTE
......
SGM ISR:
Configure the DDSF
(frequency) and/or other
configurations ( envelope...) of
the 3nd note for this channel
When reaching the target volume at end
of Release/no-output Phase of the 1st
pulse (note), raise the interrupt and
synchronously reload the buffered
configurations of the 2nd note.
Generate the 2nd note
......
SGM ISR:
Configure the DDSF
(frequency) and/or other
configurations ( envelope...) of
the 4nd note for this channel
When reaching the target volume at
Release/no-output Phase of the 2nd
pulse (note), raise the interrupt and
synchronously reload the buffered
configurations of the 3rd note.
......
......
...
To Stop the current DDS Generation:
4. Clear the SGMCTL.SOGCHx.
5. Check the SGMST. Wait until the operation
status is IDLE(STATCHx=3'b000)
* 6. Disable the DMA request. (optional)
*7. Write 0/1 to FIFO read/write pointer of this
channel. Clear the FIFO and Flush the DataPath.
*8. Check the SGMST. Wait until the FIFO of
current channel is ready(FLSCHx=0).
*9. Configure the DMA descriptor of move another
wavetable from memory to FIFO
*10. Set the watermark. Enable the DMA request.
* DMA controller will move the PCM data
from memory to SGM FIFO (optional)
...
Freescale Semiconductor
PXD20 Microcontroller Reference Manual, Rev. 1
Preliminary—Subject to Change Without Notice
39-67