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

Method BTLibBoard

src/board_controller/bt_lib_board.cpp:9–41  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7
8
9BTLibBoard::BTLibBoard (int board_id, struct BrainFlowInputParams params) : Board (board_id, params)
10{
11 char bluetoothlib_dir[1024];
12 bool res = get_dll_path (bluetoothlib_dir);
13 std::string bluetoothlib_path = "";
14#ifdef _WIN32
15 std::string lib_name;
16 if (sizeof (void *) == 4)
17 {
18 lib_name = "BrainFlowBluetooth32.dll";
19 }
20 else
21 {
22 lib_name = "BrainFlowBluetooth.dll";
23 }
24#elif defined(__APPLE__)
25 std::string lib_name = "libBrainFlowBluetooth.dylib";
26#else
27 std::string lib_name = "libBrainFlowBluetooth.so";
28#endif
29 if (res)
30 {
31 bluetoothlib_path = std::string (bluetoothlib_dir) + lib_name;
32 }
33 else
34 {
35 bluetoothlib_path = lib_name;
36 }
37
38 safe_logger (spdlog::level::debug, "use dyn lib: {}", bluetoothlib_path.c_str ());
39 dll_loader = new DLLLoader (bluetoothlib_path.c_str ());
40 initialized = false;
41}
42
43BTLibBoard::~BTLibBoard ()
44{

Callers

nothing calls this directly

Calls 1

get_dll_pathFunction · 0.85

Tested by

no test coverage detected