GD32W51x User Manual
410
Level detection mode with configurable filtering on tamper input detection
When FLT bit is not reset to 0x0, the tamper detection is set to level detection mode and FLT
bit determines the consecutive number of samples (2, 4 or 8) needed for valid level. When
DISPU is set to 0x0(this is default), the internal pull-up resistance will pre-charge the tamper
input pin before each sampling and thus larger capacitance is allowed to connect to the
tamper input pin. The pre-charge duration is configured through PRCH bit. Higher
capacitance needs long pre-charge time.
The time interval between each sampling is also configurable. Through adjusting the sampling
frequency (FREQ), software can balance between the power consuming and tamper
detection latency.
16.3.15.
Calibration clock output
Calibration clock can be output on the PC15/PA3/PA8 if COEN bit is set to 1.
When the COS bit is set to 0(this is default) and asynchronous prescaler is set to
0x7F(FACTOR_A), the frequency of RTC_CALIB is f
rtcclk
/64.When the RTCCLK is 32.768KHz,
RTC_CALIB output is corresponding to 512Hz.It’s recommend to using rising edge of
RTC_CALIB output for there may be a light jitter on falling edge.
When the COS bit is set to 1, the RTC_CALIB frequency is:
𝑓
𝑟𝑡𝑐_𝑐𝑎𝑙𝑖𝑏
=
𝑓
𝑟𝑡𝑐𝑐𝑙𝑘
(𝐹𝐴𝐶𝑇𝑂𝑅_𝐴+1)×(𝐹𝐴𝐶𝑇𝑂𝑅_𝑆+1)
(17-5)
When the RTCCLK is 32.768 KHz, RTC_CALIB output is corresponding to 1Hz if prescaler
are default values.
16.3.16.
Alarm output
When OS control bits are not reset, RTC_ALARM alternate function output is enabled. This
function will directly output the content of alarm flag or auto wakeup flag bit in RTC_STAT.
The OPOL bit in RTC_CTL can configure the polarity of the alarm or auto wakeup flag output
which means that the RTC_ALARM output is the opposite of the corresponding flag bit or not.
16.3.17.
RTC security protection
The rules for accessing RTC registers in secure and nonsecure protection modes are shown