MCPcopy Create free account
hub / github.com/deviceplug/btleplug / reset_peripheral

Function reset_peripheral

tests/common/peripheral_finder.rs:170–174  ·  view source on GitHub ↗

Reset the test peripheral to its default state.

(peripheral: &Peripheral)

Source from the content-addressed store, hash-verified

168
169/// Reset the test peripheral to its default state.
170pub async fn reset_peripheral(peripheral: &Peripheral) {
171 send_control_command(peripheral, gatt_uuids::CMD_RESET_STATE).await;
172 // Brief pause to let the peripheral process the reset
173 time::sleep(Duration::from_millis(100)).await;
174}
175
176/// Find a characteristic by UUID from the peripheral's discovered characteristics.
177pub fn find_characteristic(

Calls 1

send_control_commandFunction · 0.85