Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
uPython-mirror
Commits
fa391eed
Commit
fa391eed
authored
Oct 06, 2015
by
Damien George
Browse files
stmhal: In RTC.wakeup, fix setting of wucksel to get correct period.
Thanks to Peter Hinch. See issue #1490.
parent
37ab061f
Changes
1
Hide whitespace changes
Inline
Side-by-side
stmhal/rtc.c
View file @
fa391eed
...
...
@@ -464,7 +464,7 @@ mp_obj_t pyb_rtc_wakeup(mp_uint_t n_args, const mp_obj_t *args) {
// set WUTIE to enable wakeup interrupts
// set WUTE to enable wakeup
// program WUCKSEL
RTC
->
CR
|
=
(
1
<<
14
)
|
(
1
<<
10
)
|
(
wucksel
&
7
);
RTC
->
CR
=
(
RTC
->
CR
&
~
7
)
|
(
1
<<
14
)
|
(
1
<<
10
)
|
(
wucksel
&
7
);
// enable register write protection
RTC
->
WPR
=
0xff
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment