当前位置:网站首页>Stm32cubemx (8): RTC and RTC wake-up interrupt
Stm32cubemx (8): RTC and RTC wake-up interrupt
2022-07-05 04:58:00 【Shrimp paste】
Real time clock (RTC):
it It's an independent BCD Timer / Counter .RTC Provide A calendar clock 、 Two programmable The alarm clock is broken , And one A periodic programmable wake-up flag with interrupt function .RTC Also included for managing low power mode Automatic wake-up unit .
Two 32 Bit registers contain binary decimal format (BCD) Seconds of 、 minute 、 Hours (12 or 24 hourly )、 star
Period 、 date 、 Month and year . Besides , Sub second values in binary format are also available .
The system can automatically compensate the days of the month to 28、29( Leap year )、30 and 31 God . And you can have daylight saving time
compensate .
Other 32 The bit register also contains programmable alarm sub seconds 、 second 、 minute 、 Hours 、 What day and date of the week .
block diagram :
According to the picture above : Work out RTC clock frequency :32.768kHZ/128/256=1HZ
interrupt :
choice LSE As RTC Clock source :
Code :
RTC Wake up interrupt :
There is more configuration in the following step :
Code :
Callback function :
边栏推荐
猜你喜欢
AutoCAD - scaling
Create a pyGame window with a blue background
Recherche de mots pour leetcode (solution rétrospective)
AutoCAD - Document Management
[groovy] closure (closure call | closure default parameter it | code example)
Redis has four methods for checking big keys, which are necessary for optimization
An article takes you to thoroughly understand descriptors
PostgreSQL surpasses mysql, and the salary of "the best programming language in the world" is low
Detailed introduction of OSPF header message
【acwing】837. Number of connected block points
随机推荐
3dsmax scanning function point connection drawing connection line
mysql审计日志归档
Looking at Chinese science and technology from the Winter Olympics: what is the mystery of the high-speed camera that the whole people thank?
AutoCAD - Zoom previous
Database under unity
Judge the position of the monster in the role under unity3d
[groovy] closure (closure call is associated with call method | call () method is defined in interface | call () method is defined in class | code example)
SQLServer 存储过程传递数组参数
54. 螺旋矩阵 & 59. 螺旋矩阵 II ●●
MySQL audit log archiving
xss注入
AutoCAD - set layer
Unity check whether the two objects have obstacles by ray
Unity intelligent NPC production -- pre judgment walking (method 1)
Unity writes timetables (without UI)
Emlog blog theme template source code simple good-looking responsive
C # perspective following
On-off and on-off of quality system construction
Unity synergy
Lua determines whether the current time is the time of the day