Error codes#
Most functions return a ba_error (error.h); ba_core_init() and
ba_core_close() return a ba_init_error (bacore.h). The reference
page of each function lists the codes it returns.
ba_error#
Code |
Value |
Meaning |
|---|---|---|
|
0 |
Success. |
|
1 |
Not connected, or the connection failed. |
|
2 |
The device does not support the request, such as a sample rate it lacks. |
|
3 |
An invalid argument, a call at the wrong time, or settings the device refused. |
|
4 |
Bluetooth is turned off. |
|
5 |
No Bluetooth adapter. |
|
6 |
Linux: no adapter with |
|
7 |
The firmware file could not be opened. |
|
8 |
The firmware update did not succeed. |
|
9 |
The device disconnected during the firmware update. |
|
11 |
No device with the name passed to |
|
12 |
Managers were not freed before closing the library. |
|
13 |
|
|
15 |
The system’s Bluetooth service did not respond. |
|
16 |
The device refused the firmware image and keeps its current firmware. |
|
17 |
The device could not start the stream; it can be retried. |
|
255 |
Unexpected error; the log has details. |
ba_init_error#
Code |
Value |
Meaning |
|---|---|---|
|
0 |
Success. |
|
7 |
|
|
9 |
|
|
12 |
|
|
255 |
|
The log#
The log file (bacore.log by default) explains failures. When reporting a
problem, set sBACORE_Config_t::log_level to BA_LOG_LEVEL_DEBUG and send
the log.