Android Hardware Abstraction Layer
Data Structures | Typedefs | Enumerations
bt_hf.h File Reference

Go to the source code of this file.

Data Structures

struct  bthf_callbacks_t
 
struct  bthf_interface_t
 

Typedefs

typedef void(* bthf_connection_state_callback )(bthf_connection_state_t state, bt_bdaddr_t *bd_addr)
 
typedef void(* bthf_audio_state_callback )(bthf_audio_state_t state, bt_bdaddr_t *bd_addr)
 
typedef void(* bthf_vr_cmd_callback )(bthf_vr_state_t state)
 
typedef void(* bthf_answer_call_cmd_callback )()
 
typedef void(* bthf_hangup_call_cmd_callback )()
 
typedef void(* bthf_volume_cmd_callback )(bthf_volume_type_t type, int volume)
 
typedef void(* bthf_dial_call_cmd_callback )(char *number)
 
typedef void(* bthf_dtmf_cmd_callback )(char tone)
 
typedef void(* bthf_nrec_cmd_callback )(bthf_nrec_t nrec)
 
typedef void(* bthf_chld_cmd_callback )(bthf_chld_type_t chld)
 
typedef void(* bthf_cnum_cmd_callback )()
 
typedef void(* bthf_cind_cmd_callback )()
 
typedef void(* bthf_cops_cmd_callback )()
 
typedef void(* bthf_clcc_cmd_callback )()
 
typedef void(* bthf_unknown_at_cmd_callback )(char *at_string)
 
typedef void(* bthf_key_pressed_cmd_callback )()
 

Enumerations

enum  bthf_at_response_t { BTHF_AT_RESPONSE_ERROR = 0, BTHF_AT_RESPONSE_OK }
 
enum  bthf_connection_state_t {
  BTHF_CONNECTION_STATE_DISCONNECTED = 0, BTHF_CONNECTION_STATE_CONNECTING, BTHF_CONNECTION_STATE_CONNECTED, BTHF_CONNECTION_STATE_SLC_CONNECTED,
  BTHF_CONNECTION_STATE_DISCONNECTING
}
 
enum  bthf_audio_state_t { BTHF_AUDIO_STATE_DISCONNECTED = 0, BTHF_AUDIO_STATE_CONNECTING, BTHF_AUDIO_STATE_CONNECTED, BTHF_AUDIO_STATE_DISCONNECTING }
 
enum  bthf_vr_state_t { BTHF_VR_STATE_STOPPED = 0, BTHF_VR_STATE_STARTED }
 
enum  bthf_volume_type_t { BTHF_VOLUME_TYPE_SPK = 0, BTHF_VOLUME_TYPE_MIC }
 
enum  bthf_nrec_t { BTHF_NREC_STOP, BTHF_NREC_START }
 
enum  bthf_chld_type_t { BTHF_CHLD_TYPE_RELEASEHELD, BTHF_CHLD_TYPE_RELEASEACTIVE_ACCEPTHELD, BTHF_CHLD_TYPE_HOLDACTIVE_ACCEPTHELD, BTHF_CHLD_TYPE_ADDHELDTOCONF }
 
enum  bthf_network_state_t { BTHF_NETWORK_STATE_NOT_AVAILABLE = 0, BTHF_NETWORK_STATE_AVAILABLE }
 
enum  bthf_service_type_t { BTHF_SERVICE_TYPE_HOME = 0, BTHF_SERVICE_TYPE_ROAMING }
 
enum  bthf_call_state_t {
  BTHF_CALL_STATE_ACTIVE = 0, BTHF_CALL_STATE_HELD, BTHF_CALL_STATE_DIALING, BTHF_CALL_STATE_ALERTING,
  BTHF_CALL_STATE_INCOMING, BTHF_CALL_STATE_WAITING, BTHF_CALL_STATE_IDLE
}
 
enum  bthf_call_direction_t { BTHF_CALL_DIRECTION_OUTGOING = 0, BTHF_CALL_DIRECTION_INCOMING }
 
enum  bthf_call_mode_t { BTHF_CALL_TYPE_VOICE = 0, BTHF_CALL_TYPE_DATA, BTHF_CALL_TYPE_FAX }
 
enum  bthf_call_mpty_type_t { BTHF_CALL_MPTY_TYPE_SINGLE = 0, BTHF_CALL_MPTY_TYPE_MULTI }
 
enum  bthf_call_addrtype_t { BTHF_CALL_ADDRTYPE_UNKNOWN = 0x81, BTHF_CALL_ADDRTYPE_INTERNATIONAL = 0x91 }
 

Typedef Documentation

typedef void(* bthf_answer_call_cmd_callback)()

Callback for answer incoming call (ATA)

Definition at line 86 of file bt_hf.h.

typedef void(* bthf_audio_state_callback)(bthf_audio_state_t state, bt_bdaddr_t *bd_addr)

Callback for audio connection state change. state will have one of the values from BtHfAudioState

Definition at line 77 of file bt_hf.h.

typedef void(* bthf_chld_cmd_callback)(bthf_chld_type_t chld)

Callback for call hold handling (AT+CHLD) value will contain the call hold command (0, 1, 2, 3)

Definition at line 115 of file bt_hf.h.

typedef void(* bthf_cind_cmd_callback)()

Callback for indicators (CIND)

Definition at line 123 of file bt_hf.h.

typedef void(* bthf_clcc_cmd_callback)()

Callback for call list (AT+CLCC)

Definition at line 131 of file bt_hf.h.

typedef void(* bthf_cnum_cmd_callback)()

Callback for CNUM (subscriber number)

Definition at line 119 of file bt_hf.h.

typedef void(* bthf_connection_state_callback)(bthf_connection_state_t state, bt_bdaddr_t *bd_addr)

Callback for connection state change. state will have one of the values from BtHfConnectionState

Definition at line 72 of file bt_hf.h.

typedef void(* bthf_cops_cmd_callback)()

Callback for operator selection (COPS)

Definition at line 127 of file bt_hf.h.

typedef void(* bthf_dial_call_cmd_callback)(char *number)

Callback for dialing an outgoing call If number is NULL, redial

Definition at line 100 of file bt_hf.h.

typedef void(* bthf_dtmf_cmd_callback)(char tone)

Callback for sending DTMF tones tone contains the dtmf character to be sent

Definition at line 105 of file bt_hf.h.

typedef void(* bthf_hangup_call_cmd_callback)()

Callback for disconnect call (AT+CHUP)

Definition at line 90 of file bt_hf.h.

typedef void(* bthf_key_pressed_cmd_callback)()

Callback for keypressed (HSP) event.

Definition at line 140 of file bt_hf.h.

typedef void(* bthf_nrec_cmd_callback)(bthf_nrec_t nrec)

Callback for enabling/disabling noise reduction/echo cancellation value will be 1 to enable, 0 to disable

Definition at line 110 of file bt_hf.h.

typedef void(* bthf_unknown_at_cmd_callback)(char *at_string)

Callback for unknown AT command recd from HF at_string will contain the unparsed AT string

Definition at line 136 of file bt_hf.h.

typedef void(* bthf_volume_cmd_callback)(bthf_volume_type_t type, int volume)

Callback for disconnect call (AT+CHUP) type will denote Speaker/Mic gain (BtHfVolumeControl).

Definition at line 95 of file bt_hf.h.

typedef void(* bthf_vr_cmd_callback)(bthf_vr_state_t state)

Callback for VR connection state change. state will have one of the values from BtHfVRState

Definition at line 82 of file bt_hf.h.

Enumeration Type Documentation

Enumerator
BTHF_AT_RESPONSE_ERROR 
BTHF_AT_RESPONSE_OK 

Definition at line 23 of file bt_hf.h.

Enumerator
BTHF_AUDIO_STATE_DISCONNECTED 
BTHF_AUDIO_STATE_CONNECTING 
BTHF_AUDIO_STATE_CONNECTED 
BTHF_AUDIO_STATE_DISCONNECTING 

Definition at line 36 of file bt_hf.h.

Enumerator
BTHF_CALL_ADDRTYPE_UNKNOWN 
BTHF_CALL_ADDRTYPE_INTERNATIONAL 

Definition at line 204 of file bt_hf.h.

Enumerator
BTHF_CALL_DIRECTION_OUTGOING 
BTHF_CALL_DIRECTION_INCOMING 

Definition at line 188 of file bt_hf.h.

Enumerator
BTHF_CALL_TYPE_VOICE 
BTHF_CALL_TYPE_DATA 
BTHF_CALL_TYPE_FAX 

Definition at line 193 of file bt_hf.h.

Enumerator
BTHF_CALL_MPTY_TYPE_SINGLE 
BTHF_CALL_MPTY_TYPE_MULTI 

Definition at line 199 of file bt_hf.h.

Enumerator
BTHF_CALL_STATE_ACTIVE 
BTHF_CALL_STATE_HELD 
BTHF_CALL_STATE_DIALING 
BTHF_CALL_STATE_ALERTING 
BTHF_CALL_STATE_INCOMING 
BTHF_CALL_STATE_WAITING 
BTHF_CALL_STATE_IDLE 

Definition at line 178 of file bt_hf.h.

Enumerator
BTHF_CHLD_TYPE_RELEASEHELD 
BTHF_CHLD_TYPE_RELEASEACTIVE_ACCEPTHELD 
BTHF_CHLD_TYPE_HOLDACTIVE_ACCEPTHELD 
BTHF_CHLD_TYPE_ADDHELDTOCONF 

Definition at line 61 of file bt_hf.h.

Enumerator
BTHF_CONNECTION_STATE_DISCONNECTED 
BTHF_CONNECTION_STATE_CONNECTING 
BTHF_CONNECTION_STATE_CONNECTED 
BTHF_CONNECTION_STATE_SLC_CONNECTED 
BTHF_CONNECTION_STATE_DISCONNECTING 

Definition at line 28 of file bt_hf.h.

Network Status

Enumerator
BTHF_NETWORK_STATE_NOT_AVAILABLE 
BTHF_NETWORK_STATE_AVAILABLE 

Definition at line 165 of file bt_hf.h.

Enumerator
BTHF_NREC_STOP 
BTHF_NREC_START 

Definition at line 54 of file bt_hf.h.

Service type

Enumerator
BTHF_SERVICE_TYPE_HOME 
BTHF_SERVICE_TYPE_ROAMING 

Definition at line 172 of file bt_hf.h.

Enumerator
BTHF_VOLUME_TYPE_SPK 
BTHF_VOLUME_TYPE_MIC 

Definition at line 48 of file bt_hf.h.

Enumerator
BTHF_VR_STATE_STOPPED 
BTHF_VR_STATE_STARTED 

Definition at line 43 of file bt_hf.h.