![ARTERY AT32F435 Series Скачать руководство пользователя страница 498](http://html1.mh-extra.com/html/artery/at32f435-series/at32f435-series_reference-manual_2977592498.webp)
AT32F435/437
Series Reference Manual
2022.11.11
Page 498
Rev 2.03
Return:
After cross operation is completed, the actual value closest to C2 can be obtained by comparing the
difference (calculated as absolute value) between the actual sampling value and C2 before and after
crossing C2 so as to get the best calibration value HICKCAL or HICKTRIM.
If the difference after crossing is less than the one before crossing C2, the calibration value after crossing
prevails, and stops the calibration process until the next condition for auto calibration appears.
If the difference after crossing is greater than the one before crossing C2, the calibration value before
crossing prevails, and it will return by one step to the one before crossing, and stops the calibration
process until the next condition for auto calibration appears.
According to the cross-return strategy, in theory, it is possible to get the frequency accuracy that is 0.5
steps away from the center frequency.
Four conditions for enabling auto calibration function are as follows:
1.
The rising edge of the CANLON (from 0 to 1)
2.
When CALON=1, reference signal is lost and restored
3.
When the sample counter is less than C1
4.
When the sample counter is greater than C3
Even though the sampling counter is between C1 and C3, at the rising edge the CANLON, the auto
calibration module can also be activated so that the HICK frequency can be adjusted to be within a range
of 0.5 steps of the center frequency as soon as the CANLON is enabled.
U
nder one of the above-mentioned circumstances, the HICK frequency can be calibrated to be within
0.5 steps of the center frequency. To achieve the best calibration accuracy, it is recommended to remain
step as 1 (default value). If the step is set to 0, either HICKCAL or HICKTRIM will not be able to be
calibrated.
22.6 Register description
Refer to the list of abbreviations used in register descriptions.
These peripheral registers must be accessed by words (32 bits).
22.6.1 ACC register map
Table 22-2 ACC register map and reset values
Register name
Offset
Reset value
ACC_STS
0x00
0x0000 000
ACC_CTRL1
0x04
0x0000 0100
ACC_CTRL2
0x08
0x0000 2080
ACC_C1
0x0C
0x0000 1F2C
ACC_C2
0x10
0x0000 1F40
ACC_C3
0x14
0x00000 1F54
22.6.2 Status register (ACC_STS)
Bit
Register
Reset value
Type
Description
Bit 31: 2
Reserved
0x0000000
resd
Kept at its default value.
Bit 1
RSLOST
0x0
ro
Reference Signal Lost
0: Reference Signal is not lost
1: Reference Signal is lost
Note: During the calibration, when the sample counter of
the calibration module is twice that of C2, if a SOF
reference signal is not detected, it means that the
reference signal is lost. The internal statue machine will
move to the idle state unless another SOF signal is
detected, otherwise, the internal clock sample counter