MCPcopy Create free account
hub / github.com/brainflow-dev/brainflow / simpleble_adapter_scan_for

Method simpleble_adapter_scan_for

src/board_controller/ble_lib_board.cpp:197–219  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

195}
196
197simpleble_err_t BLELibBoard::simpleble_adapter_scan_for (simpleble_adapter_t handle, int timeout_ms)
198{
199#ifndef STATIC_SIMPLEBLE
200 std::lock_guard<std::mutex> lock (BLELibBoard::mutex);
201 if (BLELibBoard::dll_loader == NULL)
202 {
203 safe_logger (spdlog::level::err, "BLELibBoard::dll_loader is not initialized");
204 return SIMPLEBLE_FAILURE;
205 }
206 simpleble_err_t (*func) (simpleble_adapter_t, int) = (simpleble_err_t (*) (simpleble_adapter_t,
207 int))BLELibBoard::dll_loader->get_address ("simpleble_adapter_scan_for");
208 if (func == NULL)
209 {
210 safe_logger (
211 spdlog::level::err, "failed to get function address for simpleble_adapter_scan_for");
212 return SIMPLEBLE_FAILURE;
213 }
214
215 return func (handle, timeout_ms);
216#else
217 return ::simpleble_adapter_scan_for (handle, timeout_ms);
218#endif
219}
220
221simpleble_err_t BLELibBoard::simpleble_adapter_scan_start (simpleble_adapter_t handle)
222{

Callers

nothing calls this directly

Calls 1

get_addressMethod · 0.45

Tested by

no test coverage detected