add better interface handling
This commit is contained in:
parent
e6114d2c52
commit
714715b4aa
2 changed files with 5 additions and 0 deletions
|
|
@ -131,4 +131,8 @@ impl<'a, T: DacInterface> DpcmDac<'a, T> {
|
||||||
false
|
false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn disable_output(&mut self) {
|
||||||
|
self.output.disable();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
pub trait DacInterface {
|
pub trait DacInterface {
|
||||||
// write the amplitude (0->100%)
|
// write the amplitude (0->100%)
|
||||||
|
fn disable(&mut self);
|
||||||
fn write_amplitude(&mut self, amplitude: u8);
|
fn write_amplitude(&mut self, amplitude: u8);
|
||||||
}
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue