Removing unused code
This commit is contained in:
parent
585613f48f
commit
c518797d08
|
@ -823,7 +823,6 @@ const APP: () = {
|
||||||
|
|
||||||
let dds_output = &mut c.resources.dds_output;
|
let dds_output = &mut c.resources.dds_output;
|
||||||
if let Some(pounder) = c.resources.pounder {
|
if let Some(pounder) = c.resources.pounder {
|
||||||
dds_output.lock(|dds_output| {
|
|
||||||
let profile = pounder
|
let profile = pounder
|
||||||
.ad9959
|
.ad9959
|
||||||
.serialize_profile(
|
.serialize_profile(
|
||||||
|
@ -833,6 +832,7 @@ const APP: () = {
|
||||||
*adc0 as f32 / 0xFFFF as f32,
|
*adc0 as f32 / 0xFFFF as f32,
|
||||||
)
|
)
|
||||||
.unwrap();
|
.unwrap();
|
||||||
|
dds_output.lock(|dds_output| {
|
||||||
dds_output.push(profile);
|
dds_output.push(profile);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -115,7 +115,7 @@ impl QspiInterface {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn start_stream(&mut self) -> Result<(), Error> {
|
fn start_stream(&mut self) -> Result<(), Error> {
|
||||||
if self.qspi.is_busy() {
|
if self.qspi.is_busy() {
|
||||||
return Err(Error::Qspi);
|
return Err(Error::Qspi);
|
||||||
}
|
}
|
||||||
|
@ -136,34 +136,6 @@ impl QspiInterface {
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn write_profile(&mut self, data: [u32; 4]) -> Result<(), Error> {
|
|
||||||
if self.streaming == false {
|
|
||||||
return Err(Error::Qspi);
|
|
||||||
}
|
|
||||||
|
|
||||||
let qspi_regs = unsafe { &*hal::stm32::QUADSPI::ptr() };
|
|
||||||
unsafe {
|
|
||||||
core::ptr::write_volatile(
|
|
||||||
&qspi_regs.dr as *const _ as *mut u32,
|
|
||||||
data[0],
|
|
||||||
);
|
|
||||||
core::ptr::write_volatile(
|
|
||||||
&qspi_regs.dr as *const _ as *mut u32,
|
|
||||||
data[1],
|
|
||||||
);
|
|
||||||
core::ptr::write_volatile(
|
|
||||||
&qspi_regs.dr as *const _ as *mut u32,
|
|
||||||
data[2],
|
|
||||||
);
|
|
||||||
core::ptr::write_volatile(
|
|
||||||
&qspi_regs.dr as *const _ as *mut u32,
|
|
||||||
data[3],
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
Ok(())
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
impl ad9959::Interface for QspiInterface {
|
impl ad9959::Interface for QspiInterface {
|
||||||
|
|
Loading…
Reference in New Issue