mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-04-16 08:42:28 +00:00
example/pbap_client_demo: fix compile without stdin support
This commit is contained in:
parent
cf31ef9b5b
commit
c15d10d569
@ -93,8 +93,6 @@ static uint16_t pbap_cid;
|
|||||||
|
|
||||||
static int sim1_selected;
|
static int sim1_selected;
|
||||||
|
|
||||||
#ifdef HAVE_BTSTACK_STDIN
|
|
||||||
|
|
||||||
static void select_phonebook(const char * phonebook){
|
static void select_phonebook(const char * phonebook){
|
||||||
phonebook_name = phonebook;
|
phonebook_name = phonebook;
|
||||||
sprintf(phonebook_path, "%s%s.vcf", sim1_selected ? "SIM1/telecom/" : "telecom/", phonebook);
|
sprintf(phonebook_path, "%s%s.vcf", sim1_selected ? "SIM1/telecom/" : "telecom/", phonebook);
|
||||||
@ -104,6 +102,8 @@ static void select_phonebook(const char * phonebook){
|
|||||||
printf("[-] Phonebook path '%s'\n", phonebook_path);
|
printf("[-] Phonebook path '%s'\n", phonebook_path);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef HAVE_BTSTACK_STDIN
|
||||||
|
|
||||||
// Testig User Interface
|
// Testig User Interface
|
||||||
static void show_usage(void){
|
static void show_usage(void){
|
||||||
bd_addr_t iut_address;
|
bd_addr_t iut_address;
|
||||||
@ -335,7 +335,7 @@ static void packet_handler(uint8_t packet_type, uint16_t channel, uint8_t *packe
|
|||||||
case PBAP_SUBEVENT_CONNECTION_OPENED:
|
case PBAP_SUBEVENT_CONNECTION_OPENED:
|
||||||
printf("[+] Connected\n");
|
printf("[+] Connected\n");
|
||||||
printf("[+] Pull phonebook\n");
|
printf("[+] Pull phonebook\n");
|
||||||
pbap_pull_phonebook(pbap_cid);
|
pbap_pull_phonebook(pbap_cid, phonebook_path);
|
||||||
break;
|
break;
|
||||||
case PBAP_SUBEVENT_CONNECTION_CLOSED:
|
case PBAP_SUBEVENT_CONNECTION_CLOSED:
|
||||||
printf("[+] Connection closed\n");
|
printf("[+] Connection closed\n");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user