diff --git a/embassy-stm32/Cargo.toml b/embassy-stm32/Cargo.toml index 47a9ece1..88c0f42f 100644 --- a/embassy-stm32/Cargo.toml +++ b/embassy-stm32/Cargo.toml @@ -58,7 +58,7 @@ bare-metal = "1.0.0" atomic-polyfill = "0.1.5" stm32-metapac = { version = "0.1.0", path = "../stm32-metapac", features = ["rt"] } vcell = "0.1.3" -bxcan = "0.6.2" +bxcan = "0.7.0" nb = "1.0.0" stm32-fmc = "0.2.4" seq-macro = "0.3.0" @@ -71,7 +71,7 @@ quote = "1.0.15" stm32-metapac = { version = "0.1.0", path = "../stm32-metapac", default-features = false, features = ["metadata"]} [features] -defmt = ["dep:defmt", "embassy/defmt", "embedded-io?/defmt", "embassy-usb?/defmt"] +defmt = ["dep:defmt", "bxcan/unstable-defmt", "embassy/defmt", "embedded-io?/defmt", "embassy-usb?/defmt"] sdmmc-rs = ["embedded-sdmmc"] net = ["embassy-net" ] memory-x = ["stm32-metapac/memory-x"] diff --git a/examples/stm32f4/src/bin/can.rs b/examples/stm32f4/src/bin/can.rs index 8abce87a..e8377b9a 100644 --- a/examples/stm32f4/src/bin/can.rs +++ b/examples/stm32f4/src/bin/can.rs @@ -5,7 +5,7 @@ use cortex_m_rt::entry; use defmt::*; use embassy_stm32::can::bxcan::filter::Mask32; -use embassy_stm32::can::bxcan::{Frame, StandardId}; +use embassy_stm32::can::bxcan::{Fifo, Frame, StandardId}; use embassy_stm32::can::Can; use embassy_stm32::gpio::{Input, Pull}; use {defmt_rtt as _, panic_probe as _}; @@ -25,7 +25,7 @@ fn main() -> ! { let mut can = Can::new(p.CAN1, p.PA11, p.PA12); - can.modify_filters().enable_bank(0, Mask32::accept_all()); + can.modify_filters().enable_bank(0, Fifo::Fifo0, Mask32::accept_all()); can.modify_config() .set_bit_timing(0x001c0003) // http://www.bittiming.can-wiki.info/