11#ifndef ZEPHYR_INCLUDE_BLUETOOTH_HFP_AG_H_
12#define ZEPHYR_INCLUDE_BLUETOOTH_HFP_AG_H_
40#define BT_HFP_AG_CODEC_CVSD 0x01
41#define BT_HFP_AG_CODEC_MSBC 0x02
42#define BT_HFP_AG_CODEC_LC3_SWB 0x03
105 char number[CONFIG_BT_HFP_AG_PHONE_NUMBER_MAX_LEN + 1];
121 void (*
connected)(
struct bt_conn *conn,
struct bt_hfp_ag *ag);
182 int (*
memory_dial)(
struct bt_hfp_ag *ag,
const char *location,
char **number);
209 void (*
outgoing)(
struct bt_hfp_ag *ag,
struct bt_hfp_ag_call *call,
const char *number);
220 void (*
incoming)(
struct bt_hfp_ag *ag,
struct bt_hfp_ag_call *call,
const char *number);
239 void (*
ringing)(
struct bt_hfp_ag_call *call,
bool in_band);
248 void (*
accept)(
struct bt_hfp_ag_call *call);
257 void (*
held)(
struct bt_hfp_ag_call *call);
275 void (*
reject)(
struct bt_hfp_ag_call *call);
Bluetooth subsystem core APIs.
int bt_hfp_ag_remote_accept(struct bt_hfp_ag_call *call)
Notify HFP Unit that the remote accepts the call.
bt_hfp_ag_call_dir
Definition hfp_ag.h:92
hfp_ag_hf_indicators
Definition hfp_ag.h:75
int bt_hfp_ag_remote_ringing(struct bt_hfp_ag_call *call)
Notify HFP Unit that the remote starts ringing.
int bt_hfp_ag_roaming_status(struct bt_hfp_ag *ag, uint8_t status)
Set roaming status.
int bt_hfp_ag_reject(struct bt_hfp_ag_call *call)
Reject the incoming call.
int bt_hfp_ag_signal_strength(struct bt_hfp_ag *ag, uint8_t strength)
Set signal strength.
int bt_hfp_ag_voice_recognition(struct bt_hfp_ag *ag, bool activate)
Enable/disable the voice recognition function.
int bt_hfp_ag_terminate(struct bt_hfp_ag_call *call)
Terminate the active/hold call.
int bt_hfp_ag_accept(struct bt_hfp_ag_call *call)
Accept the incoming call.
int bt_hfp_ag_vre_state(struct bt_hfp_ag *ag, uint8_t state)
set voice recognition engine state
bt_hfp_ag_indicator
Definition hfp_ag.h:28
int bt_hfp_ag_register(struct bt_hfp_ag_cb *cb)
Register HFP AG profile.
int bt_hfp_ag_retrieve(struct bt_hfp_ag_call *call)
Retrieve the held call.
int bt_hfp_ag_remote_incoming(struct bt_hfp_ag *ag, const char *number)
Notify HFP Unit of an incoming call.
int bt_hfp_ag_hold(struct bt_hfp_ag_call *call)
Hold the active call.
int bt_hfp_ag_battery_level(struct bt_hfp_ag *ag, uint8_t level)
Set battery level.
int bt_hfp_ag_vre_textual_representation(struct bt_hfp_ag *ag, uint8_t state, const char *id, uint8_t type, uint8_t operation, const char *text)
set voice recognition engine state and textual representation
int bt_hfp_ag_remote_terminate(struct bt_hfp_ag_call *call)
Notify HFP Unit that the remote terminates the active/hold call.
int bt_hfp_ag_vgm(struct bt_hfp_ag *ag, uint8_t vgm)
Set the HF microphone gain.
int bt_hfp_ag_audio_connect(struct bt_hfp_ag *ag, uint8_t id)
Create audio connection.
int bt_hfp_ag_ongoing_calls(struct bt_hfp_ag *ag, struct bt_hfp_ag_ongoing_call *calls, size_t count)
Set the ongoing calls.
int bt_hfp_ag_outgoing(struct bt_hfp_ag *ag, const char *number)
Dial a call.
int bt_hfp_ag_connect(struct bt_conn *conn, struct bt_hfp_ag **ag, uint8_t channel)
Create the hfp ag session.
int bt_hfp_ag_explicit_call_transfer(struct bt_hfp_ag *ag)
explicit call transfer
int bt_hfp_ag_inband_ringtone(struct bt_hfp_ag *ag, bool inband)
Set In-Band Ring Tone.
int bt_hfp_ag_hf_indicator(struct bt_hfp_ag *ag, enum hfp_ag_hf_indicators indicator, bool enable)
Activate/deactivate HF indicator.
int bt_hfp_ag_set_operator(struct bt_hfp_ag *ag, uint8_t mode, char *name)
Set currently network operator.
int bt_hfp_ag_hold_incoming(struct bt_hfp_ag_call *call)
Put the incoming call on hold.
int bt_hfp_ag_vgs(struct bt_hfp_ag *ag, uint8_t vgs)
Set the HF speaker gain.
int bt_hfp_ag_remote_reject(struct bt_hfp_ag_call *call)
Notify HFP Unit that the remote rejects the call.
bt_hfp_ag_call_status
Definition hfp_ag.h:81
int(* bt_hfp_ag_query_subscriber_func_t)(struct bt_hfp_ag *ag, char *number, uint8_t type, uint8_t service)
Query subscriber number callback function.
Definition hfp_ag.h:71
int bt_hfp_ag_disconnect(struct bt_hfp_ag *ag)
Disconnect the hfp ag session.
int bt_hfp_ag_service_availability(struct bt_hfp_ag *ag, bool available)
Set service availability.
@ BT_HFP_AG_CALL_DIR_INCOMING
Definition hfp_ag.h:94
@ BT_HFP_AG_CALL_DIR_OUTGOING
Definition hfp_ag.h:93
@ HFP_AG_BATTERY_LEVEL_IND
Definition hfp_ag.h:77
@ HFP_AG_ENHANCED_SAFETY_IND
Definition hfp_ag.h:76
@ BT_HFP_AG_SERVICE_IND
Definition hfp_ag.h:29
@ BT_HFP_AG_CALL_SETUP_IND
Definition hfp_ag.h:31
@ BT_HFP_AG_CALL_HELD_IND
Definition hfp_ag.h:32
@ BT_HFP_AG_SIGNAL_IND
Definition hfp_ag.h:33
@ BT_HFP_AG_BATTERY_IND
Definition hfp_ag.h:35
@ BT_HFP_AG_CALL_IND
Definition hfp_ag.h:30
@ BT_HFP_AG_ROAM_IND
Definition hfp_ag.h:34
@ BT_HFP_AG_IND_MAX
Definition hfp_ag.h:36
@ BT_HFP_AG_CALL_STATUS_DIALING
Definition hfp_ag.h:84
@ BT_HFP_AG_CALL_STATUS_INCOMING_HELD
Definition hfp_ag.h:88
@ BT_HFP_AG_CALL_STATUS_ALERTING
Definition hfp_ag.h:85
@ BT_HFP_AG_CALL_STATUS_ACTIVE
Definition hfp_ag.h:82
@ BT_HFP_AG_CALL_STATUS_INCOMING
Definition hfp_ag.h:86
@ BT_HFP_AG_CALL_STATUS_WAITING
Definition hfp_ag.h:87
@ BT_HFP_AG_CALL_STATUS_HELD
Definition hfp_ag.h:83
state
Definition parser_state.h:29
__UINT32_TYPE__ uint32_t
Definition stdint.h:90
__UINT8_TYPE__ uint8_t
Definition stdint.h:88
HFP profile AG application callback.
Definition hfp_ag.h:112
void(* ringing)(struct bt_hfp_ag_call *call, bool in_band)
HF ringing Callback.
Definition hfp_ag.h:239
void(* voice_recognition)(struct bt_hfp_ag *ag, bool activate)
Voice recognition activation/deactivation callback.
Definition hfp_ag.h:387
void(* codec)(struct bt_hfp_ag *ag, uint32_t ids)
Supported codec Ids callback.
Definition hfp_ag.h:293
void(* vgs)(struct bt_hfp_ag *ag, uint8_t gain)
HF VGS setting callback.
Definition hfp_ag.h:340
void(* audio_connect_req)(struct bt_hfp_ag *ag)
Audio connection request callback.
Definition hfp_ag.h:320
void(* incoming_held)(struct bt_hfp_ag_call *call)
HF incoming call is held Callback.
Definition hfp_ag.h:229
void(* accept)(struct bt_hfp_ag_call *call)
HF call accept Callback.
Definition hfp_ag.h:248
void(* codec_negotiate)(struct bt_hfp_ag *ag, int err)
Codec negotiate callback.
Definition hfp_ag.h:303
void(* outgoing)(struct bt_hfp_ag *ag, struct bt_hfp_ag_call *call, const char *number)
HF outgoing Callback.
Definition hfp_ag.h:209
void(* sco_disconnected)(struct bt_conn *sco_conn, uint8_t reason)
HF SCO/eSCO disconnected Callback.
Definition hfp_ag.h:148
void(* hf_indicator_value)(struct bt_hfp_ag *ag, enum hfp_ag_hf_indicators indicator, uint32_t value)
HF indicator value callback.
Definition hfp_ag.h:461
int(* subscriber_number)(struct bt_hfp_ag *ag, bt_hfp_ag_query_subscriber_func_t func)
Get subscriber number callback.
Definition hfp_ag.h:448
int(* number_call)(struct bt_hfp_ag *ag, const char *number)
HF phone number calling request Callback.
Definition hfp_ag.h:198
void(* retrieve)(struct bt_hfp_ag_call *call)
HF call retrieve Callback.
Definition hfp_ag.h:266
void(* incoming)(struct bt_hfp_ag *ag, struct bt_hfp_ag_call *call, const char *number)
HF incoming Callback.
Definition hfp_ag.h:220
void(* vgm)(struct bt_hfp_ag *ag, uint8_t gain)
HF VGM setting callback.
Definition hfp_ag.h:330
void(* sco_connected)(struct bt_hfp_ag *ag, struct bt_conn *sco_conn)
HF SCO/eSCO connected Callback.
Definition hfp_ag.h:139
void(* connected)(struct bt_conn *conn, struct bt_hfp_ag *ag)
HF AG connected callback to application.
Definition hfp_ag.h:121
void(* reject)(struct bt_hfp_ag_call *call)
HF call reject Callback.
Definition hfp_ag.h:275
void(* held)(struct bt_hfp_ag_call *call)
HF call held Callback.
Definition hfp_ag.h:257
void(* explicit_call_transfer)(struct bt_hfp_ag *ag)
HF explicit call transfer callback.
Definition hfp_ag.h:369
int(* get_ongoing_call)(struct bt_hfp_ag *ag)
Get ongoing call information Callback.
Definition hfp_ag.h:168
void(* ecnr_turn_off)(struct bt_hfp_ag *ag)
HF ECNR turns off callback.
Definition hfp_ag.h:352
void(* transmit_dtmf_code)(struct bt_hfp_ag *ag, char code)
Transmit a DTMF Code callback.
Definition hfp_ag.h:436
void(* ready_to_accept_audio)(struct bt_hfp_ag *ag)
Ready to accept audio callback.
Definition hfp_ag.h:405
void(* terminate)(struct bt_hfp_ag_call *call)
HF call terminate Callback.
Definition hfp_ag.h:284
int(* request_phone_number)(struct bt_hfp_ag *ag, char **number)
Request phone number callback.
Definition hfp_ag.h:423
int(* memory_dial)(struct bt_hfp_ag *ag, const char *location, char **number)
HF memory dialing request Callback.
Definition hfp_ag.h:182
void(* disconnected)(struct bt_hfp_ag *ag)
HF disconnected callback to application.
Definition hfp_ag.h:130
The ongoing call.
Definition hfp_ag.h:104
char number[CONFIG_BT_HFP_AG_PHONE_NUMBER_MAX_LEN+1]
Definition hfp_ag.h:105
uint8_t type
Definition hfp_ag.h:106
enum bt_hfp_ag_call_dir dir
Definition hfp_ag.h:107
enum bt_hfp_ag_call_status status
Definition hfp_ag.h:108