Chapter 19 Simple Sound Generator (SSGV1)
S12ZVHY/S12ZVHL Family Reference Manual Rev. 1.05
Freescale Semiconductor
673
19.4.5
Register Reload
In SSG all registers except SSGCR, SSGIE and SSGIF are double buffered. the value will be reloaded
from config registers to their buffers in three cases: one is when SSG startup (or restart), the other two are
attack/decay mode register reload and non-attack/decay mode register reload. Details as below:
•
When at SSG start/restart time, if the SSGCR’s RDR is set, data in config registers will be loaded
into the internal registers buffers, and the interrupt flag (RNDI of SSGIF) will be set.
•
In attack/decay mode, when amplitude (in SSGAMP) reaches the SSGAT value and the SSGCR’s
RDR is set, all register will reload to their buffer registers, and the interrupt flag (RNDI of SSGIF)
will be set. Refer to
.
•
In non-attack/decay mode, when one tone duration completes and the SSGCR’s RDR is set, all
register will reload to their buffer registers, and the interrupt flag (RNDI of SSGIF) will be set.
Refer to
.
Figure 19-23. Attack/decay Mode Register Reload
reload point
Tone
duration
AMPB
AMPB_1
AMPB_2
AMPB_T
AMPB
AMPB_1
AMPB_T
AMPB
AMPB_1
......
......
......
......
RDR
SSG-
AMPB
reload and restart
stop point
where : Assume one tone duration contains 2 tone cycle
AMPB is the initial value reload from SSGAMP register
AMPB_x is the interim value of SSGAMPB in attack/decay operation
AMPB_T is the value of SSGAT buffer
RDR is the RDR bit of SSGCR register