|
MC9S08DZ60_08 Datasheet, PDF (165/416 Pages) Freescale Semiconductor, Inc – 8-Bit HCS08 Central Processor Unit (CPU) | |||
|
◁ |
Initial conditions:
1) Clock supplied from ATE has 500 μs duty period
2) MCG configured for internal reference with 8MHz bus
START TRIM PROCEDURE
TRMVAL = $100
n=1
Chapter 8 Multi-Purpose Clock Generator (S08MCGV1)
MEASURE
INCOMING CLOCK WIDTH
(COUNT = # OF BUS CLOCKS / 8)
COUNT < EXPECTED = 500
(RUNNING TOO SLOW)
CASE ST.ATEMENT COUNT = EXPECTED = 500
TRMVAL =
TRMVAL - 256/ (2**n)
(DECREASING TRMVAL
INCREASES THE FREQUENCY)
COUNT > EXPECTED = 500
(RUNNING TOO FAST)
TRMVAL =
TRMVAL + 256/ (2**n)
(INCREASING TRMVAL
DECREASES THE FREQUENCY)
STORE MCGTRM AND
FTRIM VALUES IN
NON-VOLATILE MEMORY
n = n+1
CONTINUE
YES
IS n > 9?
NO
Figure 8-13. Trim Procedure
In this particular case, the MCU has been attached to a PCB and the entire assembly is undergoing ï¬nal
test with automated test equipment. A separate signal or message is provided to the MCU operating under
user provided software control. The MCU initiates a trim procedure as outlined in Figure 8-13 while the
tester supplies a precision reference signal.
If the intended bus frequency is near the maximum allowed for the device, it is recommended to trim using
a reference divider value (RDIV setting) of twice the ï¬nal value. After the trim procedure is complete, the
reference divider can be restored. This will prevent accidental overshoot of the maximum clock frequency.
MC9S08DZ60 Series Data Sheet, Rev. 4
Freescale Semiconductor
165
|
▷ |