CHAPTER 18:Sound Generator
S6J3200 Series Hardware Manual Document Number: 002-04852 Rev. *G
427
(1) Software makes initial settings to those registers which are needed in DMA transfer. The DMA transfer
is based on a block data of "4-byte size x 2", and this block can be repeated N times. DMAC sets
following registers to prepare for a DMA transfer, through the "DMA Transfer Intermediate Register
(SGDMAR)".
-
Amplitude Data Register (SGAR)
-
Frequency Data Register (SGFR)
-
Tone Output Number Register (SGNR)
-
Time Cycle Register (SGTCR)
-
Increase and Decrease Data Register (SGIDR)
-
PWM Cycle Data Register (SGPCR)
The destination address of the DMA transfer is a fixed one on the "DMA Transfer Intermediate Register
(SGDMAR)".
(2) Software configures the "DMA Transfer Update Enable Register (SGDER)" to enable the automatic
update of the following registers during DMA transfer.
-
Amplitude Data Register (SGAR)
-
Frequency Data Register (SGFR)
-
Tone Output Number Register (SGNR)
-
Time Cycle Register (SGTCR)
-
Increase and Decrease Data Register (SGIDR)
-
PWM Cycle Data Register (SGPCR)
(3) Software initialize Interrupt status bit (SGCR.INT) by writing "1" to Interrupt status clear bit
(SGCCR.INTC). Then, the software configures the Sound Control Register (SGCR) in the needed mode,
and this must include the following bit operations.
-
DMA transfer start interrupt setting enable bit (SGCR.DMA) to "1"(enabled)
-
Interrupt enable bit (SGCR.INTE) to "1"(enabled)
(4) Write "1" to the Start bit (SGCR.ST).
(5) The interrupt occurs immediately after setting Start bit (SGCR.ST), since the Sound Generator is
enabled on DMA transfer (SGCR.DMA="1"). An Interrupt request (PIRQ) is asserted, and this interrupt is
used as a DMA transfer request.
(6) DMAC clears the interrupt, and write registers in the Sound Generator through the "DMA Transfer
Intermediate Register (SGDMAR)". This operation configures the following registers by 2 steps.
[1st step]
-
Amplitude Data Register (SGAR)
-
Frequency Data Register (SGFR)
-
Tone Output Number Register (SGNR)
[2nd step]
-
Time Cycle Register (SGTCR)
-
Increase and Decrease Data Register (SGIDR)
-
PWM Cycle Data Register (SGPCR)
(*1: DMA block size must to be "4-byte size x 2" for the access to "DMA Transfer Intermediate Register
(SGDMAR)")
(7) The outputs of SGO and SGA start, according to the register settings above.
(8) The Tone pulse counter counts the number of tone pulses. When the following conditions are satisfied,
the interrupt is generated.
-
Tone pulse counter is 0x00
Содержание S6J3200 Series
Страница 1041: ...CHAPTER 28 LCD Controller 1040 S6J3200 Series Hardware Manual Document Number 002 04852 Rev G...
Страница 1044: ...CHAPTER 28 LCD Controller S6J3200 Series Hardware Manual Document Number 002 04852 Rev G 1043...
Страница 1047: ...CHAPTER 28 LCD Controller 1046 S6J3200 Series Hardware Manual Document Number 002 04852 Rev G...
Страница 1050: ...CHAPTER 28 LCD Controller S6J3200 Series Hardware Manual Document Number 002 04852 Rev G 1049...
Страница 1084: ...CHAPTER 28 LCD Controller S6J3200 Series Hardware Manual Document Number 002 04852 Rev G 1083...
Страница 1086: ...CHAPTER 28 LCD Controller S6J3200 Series Hardware Manual Document Number 002 04852 Rev G 1085...
Страница 1088: ...CHAPTER 28 LCD Controller S6J3200 Series Hardware Manual Document Number 002 04852 Rev G 1087...