?? piohshf_private.h
字號:
#ifndef _PIOHSHF_PRIVATE_H
#define _PIOHSHF_PRIVATE_H
#include <csrtypes.h>
#include <hshf_lib.h>
/* Define the buttons used here */
#define BTN_CALL_ACCEPT (1<<2)
#define BTN_CALL_REJECT (1<<3)
#define BTN_VOLUME_DOWN (1<<6)
#define BTN_VOLUME_UP (1<<7)
/* Define additional I/O's here for AutoSira */
/* Buttons that have to be checked for presses */
#define PIOHSHF_BUTTONS_USED (BTN_CALL_ACCEPT | BTN_CALL_REJECT | BTN_VOLUME_UP | BTN_VOLUME_DOWN)
/* Button chords used */
/* Put the device into the different pairing modes */
#define PIOHSHF_PAIR_CHORD (BTN_VOLUME_UP | BTN_VOLUME_DOWN)
/* Toggle between muting and unmuting the microphone. */
#define PIOHSHF_MUTE_CHORD (BTN_VOLUME_UP | BTN_VOLUME_DOWN)
/* Last number redial cmd sent to the AG. */
#define PIOHSHF_REDIAL_CHORD (BTN_CALL_ACCEPT | BTN_CALL_REJECT)
/* Define the flashing LEDs here */
#define LED_CONNECT (1<<4)
#define LED_PAIR (1<<5)
/* Define flashing LED duty cycles */
#define LED_PAIR_ON D_mSEC(200)
#define LED_PAIR_OFF D_mSEC(1800)
#define LED_CONNECT_SLAVE_ON D_mSEC(200)
#define LED_CONNECT_SLAVE_OFF D_mSEC(2800)
#define LED_CONNECT_MASTER_ON D_mSEC(200)
#define LED_CONNECT_MASTER_OFF D_mSEC(4800)
#define LED_CONNECTED_ON D_mSEC(500)
#define LED_CONNECTED_OFF D_mSEC(9500)
/* Define flashing LED duty for AutoSira */
enum {
led_off,
led_on
};
typedef struct
{
uint16 hshfConnectLedState:1;
uint16 hshfPairLedState:1;
uint16 hshfButtonPressPending:1;
} hshfLocalState;
extern hshfLocalState hshfState;
/* Define some timeouts we need to supply to the app */
/* Pairing timeout supplied in seconds and converted to Delay value by core app */
#define PIOHSHF_PAIR_TIMEOUT 120
/* Private functions used by this interface app */
/* piohshf_flash.c - initialise the flashing LEDs (if any) */
void pioHsHfFlashInit(void);
/* piohshf_send.c - request to enter pairing mode */
void pioHsHfPairButton(void);
/* piohshf_send.c - call accept button pressed */
void pioHshfCallAcceptButton(void);
/* piohshf_send.c - call reject button pressed */
void pioHshfCallRejectButton(void);
/* piohshf_send.c - volume down button pressed */
void pioHshfVolumeDownButton(void);
/* piohshf_send.c - volume up button pressed */
void pioHshfVolumeUpButton(void);
/* piohshf_send.c - send a button press if in headset mode */
void pioHshfSendButtonPress(void);
#endif
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -