diff --git a/examples/stm32wb/src/bin/eddystone_beacon.rs b/examples/stm32wb/src/bin/eddystone_beacon.rs index cf9a5aa28..d3b3c15ca 100644 --- a/examples/stm32wb/src/bin/eddystone_beacon.rs +++ b/examples/stm32wb/src/bin/eddystone_beacon.rs @@ -11,11 +11,9 @@ use embassy_stm32::rcc::WPAN_DEFAULT; use embassy_stm32_wpan::hci::host::uart::UartHci; use embassy_stm32_wpan::hci::host::{AdvertisingFilterPolicy, EncryptionKey, HostHci, OwnAddressType}; use embassy_stm32_wpan::hci::types::AdvertisingType; -use embassy_stm32_wpan::hci::vendor::stm32wb::command::gap::{ - AdvertisingDataType, DiscoverableParameters, GapCommands, Role, -}; -use embassy_stm32_wpan::hci::vendor::stm32wb::command::gatt::GattCommands; -use embassy_stm32_wpan::hci::vendor::stm32wb::command::hal::{ConfigData, HalCommands, PowerLevel}; +use embassy_stm32_wpan::hci::vendor::command::gap::{AdvertisingDataType, DiscoverableParameters, GapCommands, Role}; +use embassy_stm32_wpan::hci::vendor::command::gatt::GattCommands; +use embassy_stm32_wpan::hci::vendor::command::hal::{ConfigData, HalCommands, PowerLevel}; use embassy_stm32_wpan::hci::BdAddr; use embassy_stm32_wpan::lhci::LhciC1DeviceInformationCcrp; use embassy_stm32_wpan::TlMbox; diff --git a/examples/stm32wb/src/bin/gatt_server.rs b/examples/stm32wb/src/bin/gatt_server.rs index 5ce620350..0dfe0ed09 100644 --- a/examples/stm32wb/src/bin/gatt_server.rs +++ b/examples/stm32wb/src/bin/gatt_server.rs @@ -12,17 +12,17 @@ use embassy_stm32_wpan::hci::event::command::{CommandComplete, ReturnParameters} use embassy_stm32_wpan::hci::host::uart::{Packet, UartHci}; use embassy_stm32_wpan::hci::host::{AdvertisingFilterPolicy, EncryptionKey, HostHci, OwnAddressType}; use embassy_stm32_wpan::hci::types::AdvertisingType; -use embassy_stm32_wpan::hci::vendor::stm32wb::command::gap::{ +use embassy_stm32_wpan::hci::vendor::command::gap::{ AddressType, AuthenticationRequirements, DiscoverableParameters, GapCommands, IoCapability, LocalName, Pin, Role, SecureConnectionSupport, }; -use embassy_stm32_wpan::hci::vendor::stm32wb::command::gatt::{ +use embassy_stm32_wpan::hci::vendor::command::gatt::{ AddCharacteristicParameters, AddServiceParameters, CharacteristicEvent, CharacteristicPermission, CharacteristicProperty, EncryptionKeySize, GattCommands, ServiceType, UpdateCharacteristicValueParameters, Uuid, WriteResponseParameters, }; -use embassy_stm32_wpan::hci::vendor::stm32wb::command::hal::{ConfigData, HalCommands, PowerLevel}; -use embassy_stm32_wpan::hci::vendor::stm32wb::event::{self, AttributeHandle, Stm32Wb5xEvent}; +use embassy_stm32_wpan::hci::vendor::command::hal::{ConfigData, HalCommands, PowerLevel}; +use embassy_stm32_wpan::hci::vendor::event::{self, command::VendorReturnParameters, AttributeHandle, VendorEvent}; use embassy_stm32_wpan::hci::{BdAddr, Event}; use embassy_stm32_wpan::lhci::LhciC1DeviceInformationCcrp; use embassy_stm32_wpan::sub::ble::Ble; @@ -190,11 +190,11 @@ async fn main(_spawner: Spawner) { mbox.ble_subsystem.set_discoverable(&discovery_params).await.unwrap(); } Event::Vendor(vendor_event) => match vendor_event { - Stm32Wb5xEvent::AttReadPermitRequest(read_req) => { + VendorEvent::AttReadPermitRequest(read_req) => { defmt::info!("read request received {}, allowing", read_req); mbox.ble_subsystem.allow_read(read_req.conn_handle).await } - Stm32Wb5xEvent::AttWritePermitRequest(write_req) => { + VendorEvent::AttWritePermitRequest(write_req) => { defmt::info!("write request received {}, allowing", write_req); mbox.ble_subsystem .write_response(&WriteResponseParameters { @@ -206,7 +206,7 @@ async fn main(_spawner: Spawner) { .await .unwrap() } - Stm32Wb5xEvent::GattAttributeModified(attribute) => { + VendorEvent::GattAttributeModified(attribute) => { defmt::info!("{}", ble_context); if attribute.attr_handle.0 == ble_context.chars.notify.0 + 2 { if attribute.data()[0] == 0x01 { @@ -333,7 +333,7 @@ async fn gatt_add_service(ble_subsystem: &mut Ble, uuid: Uuid) -> Result