Skip to content

Commit

Permalink
fix(deps): update xmc pac crates (minor) (#273)
Browse files Browse the repository at this point in the history
* fix(deps): update xmc pac crates

* fix: correcting errors

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Lucas Brendel <[email protected]>
  • Loading branch information
renovate[bot] and lucasbrendel authored Dec 1, 2024
1 parent 2bb7142 commit f472607
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 21 deletions.
14 changes: 7 additions & 7 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@ keywords = ["arm", "cortex-m", "hal", "xmc"]
features = ["xmc4100"]

[dependencies]
xmc4100 = { version = "0.13.0", optional = true }
xmc4200 = { version = "0.13.0", optional = true }
xmc4300 = { version = "0.12.0", optional = true }
xmc4400 = { version = "0.13.0", optional = true }
xmc4500 = { version = "0.13.0", optional = true }
xmc4700 = { version = "0.12.0", optional = true }
xmc4800 = { version = "0.12.0", optional = true }
xmc4100 = { version = "0.14.0", optional = true }
xmc4200 = { version = "0.14.0", optional = true }
xmc4300 = { version = "0.13.0", optional = true }
xmc4400 = { version = "0.14.0", optional = true }
xmc4500 = { version = "0.14.0", optional = true }
xmc4700 = { version = "0.13.0", optional = true }
xmc4800 = { version = "0.13.0", optional = true }
cortex-m = { version = "0.7.7", features = ['critical-section-single-core'] }
nb = "1.1.0"
cortex-m-rt = "0.7.3"
Expand Down
6 changes: 3 additions & 3 deletions src/flash.rs
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ impl Flash {
Margin::Default => self.regs.marp().write(|w| w.margin().value1()),
Margin::Tight0 => self.regs.marp().write(|w| w.margin().value2()),
Margin::Tight1 => self.regs.marp().write(|w| w.margin().value3()),
}
};
}

pub fn enable_double_bit_error_trap(&self) {
Expand Down Expand Up @@ -425,7 +425,7 @@ impl Flash {
Event::SingleBitError => self.regs.fcon().write(|w| w.pfsberm().set_bit()),
Event::DoubleBitError => self.regs.fcon().write(|w| w.pfdberm().set_bit()),
Event::EndOfBusy => self.regs.fcon().write(|w| w.eobm().set_bit()),
}
};
}

pub fn disable_event(&self, event: Event) {
Expand All @@ -436,7 +436,7 @@ impl Flash {
Event::SingleBitError => self.regs.fcon().write(|w| w.pfsberm().clear_bit()),
Event::DoubleBitError => self.regs.fcon().write(|w| w.pfdberm().clear_bit()),
Event::EndOfBusy => self.regs.fcon().write(|w| w.eobm().clear_bit()),
}
};
}

pub fn program_page(&self, address: *mut u32, data: PageData) {
Expand Down
22 changes: 11 additions & 11 deletions src/scu.rs
Original file line number Diff line number Diff line change
Expand Up @@ -531,15 +531,15 @@ impl Scu {
0 => match channel {
6 => scu.g0orcen().write(|w| w.enorc6().set_bit()),
7 => scu.g0orcen().write(|w| w.enorc7().set_bit()),
_ => (),
_ => unreachable!(),
},
1 => match channel {
6 => scu.g1orcen().write(|w| w.enorc6().set_bit()),
7 => scu.g1orcen().write(|w| w.enorc7().set_bit()),
_ => (),
_ => unreachable!(),
},
_ => (),
}
_ => unreachable!(),
};
}

pub fn disable_out_of_range_comparator(&self, group: u32, channel: u32) {
Expand All @@ -549,15 +549,15 @@ impl Scu {
0 => match channel {
6 => scu.g0orcen().write(|w| w.enorc6().clear_bit()),
7 => scu.g0orcen().write(|w| w.enorc7().clear_bit()),
_ => (),
_ => unreachable!(),
},
1 => match channel {
6 => scu.g1orcen().write(|w| w.enorc6().clear_bit()),
7 => scu.g1orcen().write(|w| w.enorc7().clear_bit()),
_ => (),
_ => unreachable!(),
},
_ => (),
}
_ => unreachable!(),
};
}

pub fn read_gpr(&self, index: u32) -> u32 {
Expand All @@ -575,7 +575,7 @@ impl Scu {
0 => scu.gpr0().write(|w| unsafe { w.bits(data) }),
1 => scu.gpr1().write(|w| unsafe { w.bits(data) }),
_ => unimplemented!(),
}
};
}

pub fn enable_hibernate_domain(&self) {
Expand Down Expand Up @@ -670,7 +670,7 @@ impl Scu {
PeripheralClock::Ecat0 => scu.cgatset2().write(|w| w.ecat0().set_bit()),
#[cfg(any(feature = "xmc4700", feature = "xmc4800"))]
PeripheralClock::Ebu => scu.cgatset3().write(|w| w.ebu().set_bit()),
}
};
}

#[cfg(not(feature = "xmc4500"))]
Expand Down Expand Up @@ -717,7 +717,7 @@ impl Scu {
PeripheralClock::Ecat0 => scu.cgatclr2().write(|w| w.ecat0().set_bit()),
#[cfg(any(feature = "xmc4700", feature = "xmc4800"))]
PeripheralClock::Ebu => scu.cgatclr3().write(|w| w.ebu().set_bit()),
}
};
}

#[cfg(not(feature = "xmc4500"))]
Expand Down

0 comments on commit f472607

Please sign in to comment.