Method: BLE::Adapter#stop_discovery
- Defined in:
- lib/ble/adapter.rb
#stop_discovery ⇒ Boolean
Note:
The discovery procedure is shared
This method will cancel any previous #start_discovery transaction. between all discovery sessions thus calling #stop_discovery will only release a single session.
140 141 142 143 144 145 146 147 148 149 150 151 |
# File 'lib/ble/adapter.rb', line 140 def stop_discovery @o_adapter[I_ADAPTER].StopDiscovery true rescue DBus::Error => e case e.name when E_FAILED then false when E_NOT_READY then false when E_NOT_AUTHORIZED then raise NotAuthorized else raise ScriptError end end |