EasyManua.ls Logo

GigaDevice Semiconductor GD32F3x0 - Time-Stamp Function; Tamper Detection

Default Icon
665 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
GD32F3x0 User Manual
231
15.3.11. Time-stamp function
Time-stamp function is performed on RTC_TS pin and is enabled by control bit TSEN.
When a time-stamp event occurs on RTC_TS pin, the calendar value will be saved in
time-stamp registers (RTC_DTS / RTC_TTS / RTC_SSTS) and the time-stamp flag (TSF) is
set to 1 by hardware. Time-stamp event can generate an interrupt if time-stamp interrupt
enable (TSIE) is set.
Time-stamp registers only record the calendar at the first time time-stamp event occurs
which means that time-stamp registers will not change when TSF = 1.
To extend the time-stamp event source, one optional feature is provided: tamper function
can also be considered as time-stamp function if TPTS is set.
Note: When the time-stamp event occurs, TSF is set 2 ck_apre cycles delay because of
synchronization mechanism.
15.3.12. Tamper detection
The RTC_TAMPx pin input can be used for tamper event detection under edge detection
mode or level detection mode with configurable filtering setting.
RTC backup registers (RTC_BKPx)
The RTC backup registers are located in the V
DD
backup domain that remains powered-on
by V
BAT
even if V
DD
power is switched off. The wake up action from Standby Mode or System
Reset does not affect these registers.
These registers are only reset by detected tamper event and backup domain reset.
Tamper detection function initialization
RTC tamper detection function can be independently enabled on tamper input pin by setting
corresponding TPxEN bit. Tamper detection configuration is set before enable TPxEN bit.
When the tamper event is detected, the corresponding flag (TPxF) will assert. Tamper event
can generate an interrupt if tamper interrupt enable (TPIE) is set. Any tamper event will reset
all backup registers (RTC_BKPx).
Timestamp on tamper event
The TPTS bit can control whether the tamper detection function is used as time-stamp
function. If the bit is set to 1, the TSF bit will be set when the tamper event detected as if
“enable” the time-stamp function. Whatever the TPTS bit is, the TPxF will assert when
tamper event detected.

Table of Contents

Related product manuals