| 7 | |
| 8 | |
| 9 | BTLibBoard::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 | |
| 43 | BTLibBoard::~BTLibBoard () |
| 44 | { |
nothing calls this directly
no test coverage detected