|  |  |  | # AnW_BT_SRV | 
|  |  |  |  | 
|  |  |  | AnW Bluetooth Service API, offered two sorts of releases | 
|  |  |  |  | 
|  |  |  | 1. [APP Release (sta5_btsrv_sdk_*)](#Run-App-on-targets-sta5_btsrv_app.zip) : executable **BTDemo**, launcher **btsrv_client.sh**, essentials libraries (**.so**), and App configures (**.xml**) | 
|  |  |  | 2. [SDK Release (sta5_btsrv_sdk_*)](#Customize-on-SDK-sta5_btsrv_sdk.zip) : open source with **AnWBTServiceDemo.cpp**, imported essentials libraries (**.so**), header (**anwbtservice.h**), and App configures (**.xml**) | 
|  |  |  |  | 
|  |  |  | # USAGE | 
|  |  |  | 1. Support HFP, A2DP, AVRCP, PBAP, .. AnW BT stack | 
|  |  |  | 2. Support Device Search & Pair, Call, Phonebook, Music, ... | 
|  |  |  |  | 
|  |  |  | ## Run App on targets (sta5_btsrv_app.zip) | 
|  |  |  | 1. unzip | 
|  |  |  | 2. Copy results folder "/build/btsrv" to target "/home/btsrv" | 
|  |  |  | 3. go to target, in terminal entering /btsrv folder | 
|  |  |  | 4. run btsrv_client.sh to launch BTDemo demo app and following the menu commands or | 
|  |  |  | ``` | 
|  |  |  | >./btsrv_client.sh | 
|  |  |  | ``` | 
|  |  |  | ## Install | 
|  |  |  | ``` | 
|  |  |  | Please select the function to test: | 
|  |  |  | 1. Install AnWBTService Sdk | 
|  |  |  | 2. Start btsrv | 
|  |  |  | 3. Stop btsrv | 
|  |  |  | 99. Exit btsrv Client. | 
|  |  |  | >1 | 
|  |  |  | ``` | 
|  |  |  | then audio (asound.conf) & App Settings will be copied install to system folder (e.g. /etc/anwbtservice) | 
|  |  |  | ``` | 
|  |  |  | install_btsrv /home/root/btsrv | 
|  |  |  | bt service install successfully. | 
|  |  |  | AnWBTService Sdk install successfully root path:  /home/root/btsrv | 
|  |  |  | ``` | 
|  |  |  | **NOTICE!! The system is required to power off (hard reset) for alsa driver's correct reload.** | 
|  |  |  | ### structure(sta5_btsrv_app.zip) | 
|  |  |  | <pre> | 
|  |  |  | . | 
|  |  |  | └── btsrv | 
|  |  |  | ├── BTDemo (sample program) | 
|  |  |  | ├── btsrv_client.sh (launcher for BTDemo) | 
|  |  |  | └── etc | 
|  |  |  | └──anwbtservice | 
|  |  |  | ├── btmonitor-config.xml (app configures, e.g. log switch) | 
|  |  |  | ├── anw_*_setting.cfg (phone link app settings, e.g. CP/AA) | 
|  |  |  | ├── anw_*_setting.xml (phone link app settings, e.g. CP/AA) | 
|  |  |  | └── lib | 
|  |  |  | └── *.so (essentials libraries) | 
|  |  |  | </pre> | 
|  |  |  | ## Customize on SDK (sta5_btsrv_sdk.zip) | 
|  |  |  | 1. unzip | 
|  |  |  | 2. in terminal entering ./anwbtsrv_sdk/Demo folder | 
|  |  |  | 3. setup tool-chain by command line (source ...) or edit in ./anwbtsrv_sdk/Demo/build_demo.sh | 
|  |  |  | 4. run make or build_demo.sh | 
|  |  |  |  | 
|  |  |  | ``` | 
|  |  |  | > cd ./build/anwbtsrv_sdk/Demo | 
|  |  |  | > source /opt/poky-**/2.5.1/environment-setup-cortexa9hf-neon-poky-linux-gnueabi | 
|  |  |  | > make | 
|  |  |  | or | 
|  |  |  | >./build_demo.sh | 
|  |  |  | ``` | 
|  |  |  | then, result is collected in **./Demo/btsrv** | 
|  |  |  | <div style="page-break-after: always"></div> | 
|  |  |  |  | 
|  |  |  | ### structure(sta5_btsrv_sdk.zip) | 
|  |  |  | <pre> | 
|  |  |  | . | 
|  |  |  | └── Demo | 
|  |  |  | ├── AnWBTServiceDemo.cpp (examples to use anwbtservice) | 
|  |  |  | ├── build_demo.sh (build script, call to make) | 
|  |  |  | ├── makefile (makefile for BTDemo) | 
|  |  |  | ├── btsrv_client.sh (launcher for BTDemo) | 
|  |  |  | ├── etc | 
|  |  |  | │   └──anwbtservice | 
|  |  |  | │        ├── \*.xml, \*.cfg (app settings) | 
|  |  |  | │        └── lib | 
|  |  |  | │             └── *.so (essentials libraries) | 
|  |  |  | ├── import (anwbtservice) | 
|  |  |  | │   ├── anwbtservice.h (service api header) | 
|  |  |  | │   └── \*.so (include libraries) | 
|  |  |  | └── btsrv (ouput for produced, e.g. BTDemo) | 
|  |  |  | </pre> | 
|  |  |  | \ No newline at end of file |