This adds skeleton for simple tool for testing mcap library. As mcap-lib
uses bt_io, this tool works in daemon-like mode, by utilizing Glib's main
loop.
Due to very unfortunate change Android 4.4.3-r1.1 BT GATT HAL API is
not backward compatible. This adds support for 4.4.3-r1.1 and 4.4.2.
On android PLATFORM_VERSION is used to determine which API should be
used. On Linux we always build with latest API.
This patch adds support for aptX codec. Since this is proprietary codec
it requires to obtain license form vendor (CSR) in order to use it.
Also shared library which provices encoder implementation is required
since this implementation only wraps it into audio HAL.
During configure, if SBC is not installed in the system, we may use
SBC_CFLAGS and SBC_LIBS variables to indicate where SBC headers and
binaries can be found.
However, SBC_CFLAGS variable is not used in android/Makefile.am,
causing the following compile error:
$ ./bootstrap-configure SBC_CFLAGS=-I../sbc SBC_LIBS=-L../sbc/src/
$ make
(...)
android/hal-audio-sbc.c:22:21: fatal error: sbc/sbc.h: No such file or directory
#include <sbc/sbc.h>
^
compilation terminated.
make[1]: *** [android/android_audio_a2dp_default_la-hal-audio-sbc.lo] Error 1
This patch fixes this error by appending SBC_CFLAGS to android_audio_
a2dp_default_la_CFLAGS.
Codec abstraction in hal-audio is now good enough to allow splitting
code into core and codec implementation easily so this patch moves
SBC codec code into separate file and provides interface required for
other codecs to be implemented.
This adds audio HAL for handling SCO. Following needs to be added to
audio_policy.conf:
sco {
outputs {
sco {
...
devices AUDIO_DEVICE_OUT_ALL_SCO
...
}
}
The patch keeps all MCAP specific logic in mcap-lib until it receives
proper unit tests and then eventually will be used by health profile
code as well.
With this patch btdev uses timeout to schedule inquiry results
It also allows btdev to receive hci commands during inquiry.
Previously btdev was blocked since all the inquiry result were sent in
single loop
This patch introduce connect LE device functionality.
There is gatt_device representing remote le device. Each gatt device
has a list own list of clients as it is possible that more apps
would like to use same remote device.
Possible connect scenarios:
1. There is no ACL connection to device:
Then new dev is put on conn_wait_queue and le scan is enabled.
Once device is found we do connect it.
Once device is connected then device is moved form conn_wait_queue to
conn_list and success event is sent to client(s) with conn_id
2. Device is already connected:
Then we update client list, reply with success and do send connect event.
3. For unregisterd clients or uknown conn_id, failed response is sent.