Skip to content

Commit 127ab14

Browse files
bors[bot]apeng2012
andauthored
Merge #372
372: Fix, enable PWR clock before accessing the PWR_CR r=burrbull a=apeng2012 dbp can't be written to unless PWRen has been set. Co-authored-by: apeng2012 <peng89769975@163.com>
2 parents f101160 + e0acb5e commit 127ab14

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
3737

3838
### Fixed
3939

40+
- RTC not enable PWR clock
4041
- USART2 remap
4142
- Fix > 2 byte i2c reads
4243
- Send stop after acknowledge errors on i2c

src/rcc.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -327,6 +327,7 @@ impl BKP {
327327
// Enable the backup interface by setting PWREN and BKPEN
328328
let rcc = unsafe { &(*RCC::ptr()) };
329329
crate::pac::BKP::enable(rcc);
330+
crate::pac::PWR::enable(rcc);
330331

331332
// Enable access to the backup registers
332333
pwr.cr.modify(|_r, w| w.dbp().set_bit());

0 commit comments

Comments
 (0)