Adapters
SimpleBLE.is_bluetooth_enabled — Function
Check if system bluetooth is enabled
SimpleBLE.adapters_get_count — Function
Get number of adapters in system
SimpleBLE.get_adapter — Function
get_adapter(i)Acquire a handle to an adapter. i is an index starting at 0. You can check the number of adapters with adapters_get_count.
SimpleBLE.get_adapters — Function
Get a Vector of adapters
SimpleBLE.identifier — Method
SimpleBLE.address — Method
SimpleBLE.power_on — Function
SimpleBLE.power_off — Function
SimpleBLE.is_powered — Function
SimpleBLE.set_callback_on_power_on — Function
set_callback_on_power_on(callback, adapter)
set_callback_on_power_on(adapter) do
# Stuff
endSet a callback that is called when an adapter is powered on.
SimpleBLE.set_callback_on_power_off — Function
set_callback_on_power_off(callback, adapter)
set_callback_on_power_off(adapter) do
# Stuff
endSet a callback that is called when an adapter is powered off.
SimpleBLE.scan_start — Function
scan_start(adapter)Start scanning for peripherals. Results can be acquired with scan_get_results. Or check each peripheral found or updated inside a callback set by set_callback_on_scan_found
SimpleBLE.scan_stop — Function
scan_stop(adapter)Stop a scan
SimpleBLE.scan_is_active — Function
scan_is_active(adapter)Check if adapter is scanning
SimpleBLE.scan_for — Function
scan_for(adapter, timeout_ms)Scan for a specified number of ms. Results can be acquired with scan_get_results. Or check each peripheral found or updated inside a callback set by set_callback_on_scan_found
See also scan_start, scan_stop
SimpleBLE.scan_get_results — Function
SimpleBLE.get_paired_peripherals — Function
get_paired_peripherals(adapter)Get list of peripherals paired with adapter
SimpleBLE.get_connected_peripherals — Function
get_connected_peripherals(adapter)Get a vector of connected peripherals.
SimpleBLE.set_callback_on_scan_start — Function
set_callback_on_scan_start(callback, adapter)
set_callback_on_scan_start(adapter) do
# Stuff
endSet a callback that is called when an adapter starts scanning.
See also scan_start, scan_stop, scan_for
SimpleBLE.set_callback_on_scan_stop — Function
set_callback_on_scan_stop(callback, adapter)
set_callback_on_scan_stop(adapter) do
# Stuff
endSet a callback that is called when an adapter stops scanning.
See also scan_start, scan_stop, scan_for
SimpleBLE.set_callback_on_scan_found — Function
set_callback_on_scan_found(callback, adapter)
set_callback_on_scan_found(adapter) do peripheral
# Stuff
endSet a callback that is called when an adapter finds a peripheral.
See also scan_start, scan_stop, scan_for
SimpleBLE.set_callback_on_scan_updated — Function
set_callback_on_scan_updated(callback, adapter)
set_callback_on_scan_updated(adapter) do peripheral
# Stuff
endSet a callback that is called when an adapter updates a peripheral.
See also scan_start, scan_stop, scan_for