📄 ag_types.h
字号:
#ifndef _AG_TYPES_H
#define _AG_TYPES_H
/*lint -e756 -e830 */
/*
this file is needed by off chip apps e.g. EAGdriver but csrtypes.h
cannot be used in that context so we need to pull in common/types_t.h
in that case
*/
#ifdef __XAP__
#include <csrtypes.h>
#else
#include "common/types.h"
#endif
/* IMPORTANT - update if new PS keys are added to the list of AG PS Keys */
#define AG_INTERFACE_PS_BASE 1
/* Service class of device the EAG will try to connect to */
#define UNSPECIFIED_TARGET 0x0000
#define HEADSET_TARGET 0x1108
#define HANDSFREE_TARGET 0x111E
#define UNDEFINED_HANDLE 0x00
#define ONLY_ONE_HANDLE 0x01
#define AG_SIZE_LINK_KEY 0x10
#define MAX_PIN_LENGTH 0x10
typedef enum
{
agProfileNotSet = 0,
agHeadsetProfile,
agHandsFreeProfile
} ag_profile_role_t;
typedef enum
{
last_numer_redial,
dial_number,
dial_memory_location
} dial_mode_t;
typedef enum
{
AgErrorConnectRequestWhenNotIdle,
AgErrorPairRequestWhenNotIdle,
AgErrorCancelWhenIdle,
AgErrorDataRequestWhenNotConnected,
AgErrorInquiryRequestWhenNotIdle,
AgErrorScoRequestWhenNotConnected,
AgErrorScoRequestWhenScoConnected,
AgErrorUnexpectedPrimitive,
AgErrorScoNotConnected,
AgErrorRfcommNotConnected,
AgErrorCannotCancelThisMode,
AgErrorDisconnectRequestWhenNotConnected,
AgErrorSmDeviceDatabaseError,
AgErrorUnknownConnectTarget,
AgWarnLocalSniffNotEnabled,
AgWarnLocalParkNotEnabled,
AgWarnLocalLowPwrModeNotEnabled,
AgWarnRemoteDevDoesNotSupportSniffMode,
AgWarnRemoteDevDoesNotSupportParkMode,
AgWarnRemoteLowPwrModeNotEnabled
} ag_error_code_t;
typedef enum
{
AgPairingError,
AgPairingComplete,
AgPairingCancelled,
AgPairingTimedOut,
AgPairingFailed
} ag_pair_status_t;
typedef enum
{
AgInquiryError,
AgInquiryComplete,
AgInquiryCancelled,
AgMaxResponsesReached
} ag_inquiry_status_t;
typedef enum
{
AgConnectComplete,
AgConnectTimeout,
AgConnectCancelled,
AgConnectDisconnect,
AgConnectFailed,
AgConnectDisconnectAbnormal,
AgConnectRemoteRefusal,
AgConnectServiceNotSupported
} ag_connection_status_t;
typedef uint16 ag_handle_t;
typedef uint16 pkt_type_t;
typedef uint16 timeout_t;
#ifndef PIO_EAG_ENABLED
typedef uint16 clk_offset_t;
typedef uint16 ag_sco_connection_handle_t;
typedef uint8 page_scn_rep_mode_t;
typedef uint8 page_scn_mode_t;
typedef uint8 page_scn_per_mode_t;
#endif
typedef struct
{
uint32 lap; /* Lower Address Part 00..23 */
uint8 uap; /* upper Address Part 24..31 */
uint16 nap; /* Non-significant 32..47 */
} bd_addr_t;
typedef struct
{
uint16 authentication;
uint16 encryption;
} ag_auth_config_t;
typedef struct
{
uint16 max_intval;
uint16 min_intval;
} ag_park_config_t;
typedef struct
{
uint16 max_intval;
uint16 min_intval;
uint16 attempt;
uint16 timeout;
} ag_sniff_config_t;
typedef enum
{
call_setup_no_call,
call_setup_incoming_call,
call_setup_outgoing_call,
call_setup_remote_party_alert
} ag_call_setup_vals_t;
/*lint +e756 +e830 */
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -