Loading system/gd/rust/linux/client/src/command_handler.rs +5 −0 Original line number Diff line number Diff line Loading @@ -886,6 +886,7 @@ impl CommandHandler { addr_type, class, appearance, modalias, bonded, connection_state, uuids, Loading @@ -901,6 +902,8 @@ impl CommandHandler { let alias = adapter.get_remote_alias(device.clone()); let class = adapter.get_remote_class(device.clone()); let appearance = adapter.get_remote_appearance(device.clone()); let modalias = adapter.get_remote_vendor_product_info(device.clone()).to_string(); let bonded = adapter.get_bond_state(device.clone()); let connection_state = match adapter.get_connection_state(device.clone()) { BtConnectionState::NotConnected => "Not Connected", Loading @@ -918,6 +921,7 @@ impl CommandHandler { addr_type, class, appearance, modalias, bonded, connection_state, uuids, Loading @@ -933,6 +937,7 @@ impl CommandHandler { print_info!("Address Type: {:?}", addr_type); print_info!("Class: {}", class); print_info!("Appearance: {}", appearance); print_info!("Modalias: {}", modalias); print_info!("Wake Allowed: {}", wake_allowed); print_info!("Bond State: {:?}", bonded); print_info!("Connection State: {}", connection_state); Loading system/gd/rust/topshim/src/btif.rs +16 −0 Original line number Diff line number Diff line Loading @@ -428,6 +428,22 @@ pub type BtPinCode = bindings::bt_pin_code_t; pub type BtRemoteVersion = bindings::bt_remote_version_t; pub type BtVendorProductInfo = bindings::bt_vendor_product_info_t; impl ToString for BtVendorProductInfo { fn to_string(&self) -> String { format!( "{}:v{:04X}p{:04X}d{:04X}", match self.vendor_id_src { 1 => "bluetooth", 2 => "usb", default => "unknown", }, self.vendor_id, self.product_id, self.version ) } } impl TryFrom<Uuid> for Vec<u8> { type Error = &'static str; Loading Loading
system/gd/rust/linux/client/src/command_handler.rs +5 −0 Original line number Diff line number Diff line Loading @@ -886,6 +886,7 @@ impl CommandHandler { addr_type, class, appearance, modalias, bonded, connection_state, uuids, Loading @@ -901,6 +902,8 @@ impl CommandHandler { let alias = adapter.get_remote_alias(device.clone()); let class = adapter.get_remote_class(device.clone()); let appearance = adapter.get_remote_appearance(device.clone()); let modalias = adapter.get_remote_vendor_product_info(device.clone()).to_string(); let bonded = adapter.get_bond_state(device.clone()); let connection_state = match adapter.get_connection_state(device.clone()) { BtConnectionState::NotConnected => "Not Connected", Loading @@ -918,6 +921,7 @@ impl CommandHandler { addr_type, class, appearance, modalias, bonded, connection_state, uuids, Loading @@ -933,6 +937,7 @@ impl CommandHandler { print_info!("Address Type: {:?}", addr_type); print_info!("Class: {}", class); print_info!("Appearance: {}", appearance); print_info!("Modalias: {}", modalias); print_info!("Wake Allowed: {}", wake_allowed); print_info!("Bond State: {:?}", bonded); print_info!("Connection State: {}", connection_state); Loading
system/gd/rust/topshim/src/btif.rs +16 −0 Original line number Diff line number Diff line Loading @@ -428,6 +428,22 @@ pub type BtPinCode = bindings::bt_pin_code_t; pub type BtRemoteVersion = bindings::bt_remote_version_t; pub type BtVendorProductInfo = bindings::bt_vendor_product_info_t; impl ToString for BtVendorProductInfo { fn to_string(&self) -> String { format!( "{}:v{:04X}p{:04X}d{:04X}", match self.vendor_id_src { 1 => "bluetooth", 2 => "usb", default => "unknown", }, self.vendor_id, self.product_id, self.version ) } } impl TryFrom<Uuid> for Vec<u8> { type Error = &'static str; Loading