diff --git a/Cargo.lock b/Cargo.lock index 7dc698b..77cf37a 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1028,6 +1028,16 @@ dependencies = [ "managed", ] +[[package]] +name = "smoltcp-nal" +version = "0.1.0" +source = "git+https://github.com/vertigo-designs/smoltcp-nal.git?branch=main#6a656dd78c5f7543475e95c0eaf81def95fc5a10" +dependencies = [ + "embedded-nal", + "heapless", + "smoltcp", +] + [[package]] name = "stabilizer" version = "0.4.1" @@ -1050,7 +1060,7 @@ dependencies = [ "panic-semihosting", "paste", "serde", - "smoltcp", + "smoltcp-nal", "stm32h7xx-hal", ] @@ -1075,7 +1085,7 @@ dependencies = [ [[package]] name = "stm32h7xx-hal" version = "0.8.0" -source = "git+https://github.com/quartiq/stm32h7xx-hal?branch=rs/smoltcp-update#87a650664beab422b33f1e3d842f8d585ab5fdab" +source = "git+https://github.com/stm32-rs/stm32h7xx-hal?branch=dma#2b8a04caac566a8560f400ddd6503508f78bea77" dependencies = [ "bare-metal 1.0.0", "cast", diff --git a/Cargo.toml b/Cargo.toml index 26016e1..23aab3a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -52,15 +52,14 @@ branch = "feature/mqtt-interface" [dependencies.mcp23017] git = "https://github.com/mrd0ll4r/mcp23017.git" -[dependencies.smoltcp] -version = "0.7" -features = ["ethernet", "proto-ipv4", "socket-tcp", "proto-ipv6"] -default-features = false +[dependencies.smoltcp-nal] +git = "https://github.com/vertigo-designs/smoltcp-nal.git" +branch = "main" [dependencies.stm32h7xx-hal] features = ["stm32h743v", "rt", "unproven", "ethernet", "quadspi"] -git = "https://github.com/quartiq/stm32h7xx-hal" -branch = "rs/smoltcp-update" +git = "https://github.com/stm32-rs/stm32h7xx-hal" +branch = "dma" [features] semihosting = ["panic-semihosting", "cortex-m-log/semihosting"] diff --git a/src/bin/dual-iir.rs b/src/bin/dual-iir.rs index e76020a..88dca46 100644 --- a/src/bin/dual-iir.rs +++ b/src/bin/dual-iir.rs @@ -27,13 +27,11 @@ const IIR_CASCADE_LENGTH: usize = 1; #[derive(Debug, Deserialize, StringSet)] pub struct Settings { - iir: [[iir::IIR; IIR_CASCADE_LENGTH]; 2], } impl Settings { pub fn new() -> Self { Self { - iir: [[iir::IIR::default(); IIR_CASCADE_LENGTH]; 2], } } } @@ -168,9 +166,9 @@ const APP: () = { } #[task(priority = 1, resources=[mqtt_interface, afes, iir_ch])] - fn settings_update(mut c: settings_update::Context) { - let settings = &c.resources.mqtt_interface.settings; - c.resources.iir_ch.lock(|iir| *iir = settings.iir); + fn settings_update(c: settings_update::Context) { + let _settings = &c.resources.mqtt_interface.settings; + //c.resources.iir_ch.lock(|iir| *iir = settings.iir); // TODO: Update AFEs } diff --git a/src/bin/lockin-external.rs b/src/bin/lockin-external.rs index bbe09a3..ffeb849 100644 --- a/src/bin/lockin-external.rs +++ b/src/bin/lockin-external.rs @@ -25,15 +25,13 @@ const SCALE: f32 = i16::MAX as _; // The number of cascaded IIR biquads per channel. Select 1 or 2! const IIR_CASCADE_LENGTH: usize = 1; -#[derive(Debug, Deserialize, StringSet)] +#[derive(Deserialize, StringSet)] pub struct Settings { - iir: [[iir::IIR; IIR_CASCADE_LENGTH]; 2], } impl Settings { pub fn new() -> Self { Self { - iir: [[iir::IIR::default(); IIR_CASCADE_LENGTH]; 2], } } } @@ -228,9 +226,9 @@ const APP: () = { } #[task(priority = 1, resources=[mqtt_interface, afes, iir_ch])] - fn settings_update(mut c: settings_update::Context) { - let settings = &c.resources.mqtt_interface.settings; - c.resources.iir_ch.lock(|iir| *iir = settings.iir); + fn settings_update(c: settings_update::Context) { + let _settings = &c.resources.mqtt_interface.settings; + //c.resources.iir_ch.lock(|iir| *iir = settings.iir); // TODO: Update AFEs }