Struct esp32_nimble::BLEHIDDevice
source · pub struct BLEHIDDevice { /* private fields */ }
Implementations§
source§impl BLEHIDDevice
impl BLEHIDDevice
pub fn new(server: &mut BLEServer) -> Self
sourcepub fn report_map(&mut self, map: &[u8])
pub fn report_map(&mut self, map: &[u8])
Sets the Plug n Play characteristic value.
pub fn manufacturer(&mut self, name: &str)
pub fn pnp(&mut self, sig: u8, vid: u16, pid: u16, version: u16)
sourcepub fn hid_info(&mut self, country: u8, flags: u8)
pub fn hid_info(&mut self, country: u8, flags: u8)
Sets the HID Information characteristic value.1
sourcepub fn input_report(&mut self, report_id: u8) -> Arc<Mutex<BLECharacteristic>>
pub fn input_report(&mut self, report_id: u8) -> Arc<Mutex<BLECharacteristic>>
Create input report characteristic
pub fn output_report(&mut self, report_id: u8) -> Arc<Mutex<BLECharacteristic>>
pub fn feature_report(&mut self, report_id: u8) -> Arc<Mutex<BLECharacteristic>>
sourcepub fn boot_input(&self) -> Arc<Mutex<BLECharacteristic>>
pub fn boot_input(&self) -> Arc<Mutex<BLECharacteristic>>
Creates a keyboard boot input report characteristic
sourcepub fn boot_output(&self) -> Arc<Mutex<BLECharacteristic>>
pub fn boot_output(&self) -> Arc<Mutex<BLECharacteristic>>
Creates a keyboard boot input report characteristic
sourcepub fn hid_control(&self) -> &Arc<Mutex<BLECharacteristic>>
pub fn hid_control(&self) -> &Arc<Mutex<BLECharacteristic>>
Returns the HID control point characteristic.
sourcepub fn protocol_mode(&self) -> &Arc<Mutex<BLECharacteristic>>
pub fn protocol_mode(&self) -> &Arc<Mutex<BLECharacteristic>>
Returns the protocol mode characteristic.
sourcepub fn set_battery_level(&mut self, level: u8)
pub fn set_battery_level(&mut self, level: u8)
Set the battery level characteristic value.
sourcepub fn hid_service(&self) -> &Arc<Mutex<BLEService>>
pub fn hid_service(&self) -> &Arc<Mutex<BLEService>>
Returns a pointer to the HID service.