generate rccperipheral for rtc
This commit is contained in:
parent
546aead070
commit
604ea4029c
@ -26,6 +26,8 @@ impl PeripheralToClock {
|
|||||||
};
|
};
|
||||||
for field in &body.fields {
|
for field in &body.fields {
|
||||||
if let Some(peri) = field.name.strip_suffix("EN") {
|
if let Some(peri) = field.name.strip_suffix("EN") {
|
||||||
|
let peri = if peri == "RTCAPB" { "RTC" } else { peri };
|
||||||
|
|
||||||
// Timers are a bit special, they may have a x2 freq
|
// Timers are a bit special, they may have a x2 freq
|
||||||
let peri_clock = {
|
let peri_clock = {
|
||||||
if regex!(r"^TIM\d+$").is_match(peri) {
|
if regex!(r"^TIM\d+$").is_match(peri) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user