Added PLL reset to phase setting code

This commit is contained in:
Sebastian 2023-01-14 16:55:21 +01:00
parent b37ae75b74
commit ff02f0e96f
1 changed files with 9 additions and 0 deletions

View File

@ -152,6 +152,15 @@ where
pub fn set_ms_phase(&mut self, i2c: &mut I2C, synth: Multisynth, phase: u8) {
self.write_byte_reg(i2c, synth.phoff_address(), phase);
match self.ms_srcs[synth as usize] {
PLL::A => {
self.write_byte_reg(i2c, PLL_RESET, 1 << 5);
}
PLL::B => {
self.write_byte_reg(i2c, PLL_RESET, 1 << 7);
}
}
}
pub fn pll_reset(&mut self, i2c: &mut I2C) {