![Geehy SEMICONDUCTOR APM32F405 Series User Manual Download Page 279](http://html1.mh-extra.com/html/geehy-semiconductor/apm32f405-series/apm32f405-series_user-manual_573630279.webp)
www.geehy.com Page 278
Tamper signal filter
TPSFSEL bit of the register RTC_TACFG is used to configure the sampling
frequency of tamper detection, and TPFCSEL bit of RTC_TACFG is used to
configure after how many valid tamper signals are detected continuously, an
tamper event can be generated.
In particular, if an tamper signal has been generated on the tamper detection pin
before the tamper detection pin is enabled, an tamper event will be immediately
generated on the enabled tamper detection pin.
Tamper timestamp
At some times, in order to record the tamper detection events, RTC can latch
the current tamper timestamp and this function can be enabled quickly through
TPTSEN bit of the register RTC_TACFG, not needing to enable the timestamp
function additionally.
Automatic wake-up
Compared with RTC alarm, the hardware structure of the automatic wake-up is
simpler, and it has no complicated configuration process of RTC alarm, so it is a
good scheme to wake up the low power consumption.
There is a 16-bit self-decrement reload counter in RTC, and it is used to wake
up the device automatically.
The clock of this counter is selected by WUCLKSEL bit of the register
RTC_CTRL, and by selecting different clocks, the automatic wake-up cycle can
be configured from 122μs to 36h. First turn off the automatic wake-up, namely,
clear WUTEN; when WUTWFLG flag bit is set to 1, configure WUCLKSEL bit of
the RTC_CTRL register and the reload register RTC_AUTORLD.
When the counter decreases to 0, a wake-up event will be generated, WUTFLG
flag bit will be set to 1, and before entering the next round of automatic wake-
up, this flag bit must be cleared.
RTC output
RTC output transmits the internal RTC calibration clock, alarm signal, and
automatic wake-up signal to the outside.
RTC calibration clock
Calibration clock output is generally used to observe the accuracy of RTC clock
source, and the observed value is used to calibrate the clock source. 512Hz and
1Hz signal output sources can be selected through CALOSEL bit of RTC_CTRL
register, and CALOEN bit of RTC_CTRL register can enable the calibration
output.