⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 voice.c

📁 蓝牙HANDFREE软件源代码
💻 C
字号:
#include "handsfree_private.h"
#include "handsfree.h"

#include <message.h>


/*
    startVoiceDialAction

    Request to enable the voice dialling functionality on the AG (if supported)
*/
void startVoiceDialAction(uint16 en)
{
    if (isLocalStateConnected())
    {
        /* Send request to enable voice dialling */
        MAKE_MSG(HANDSFREE_VOICE_DIAL_ENABLE_REQ);
        msg->enable = en;
        putMsg(msg);

        /* Reset the pending flag. */
        HFstate.voiceDialPending = 0;
    }
    else if (en)
    {
        /* Only bother connecting to enable voice dialling */
        /* Set pending flag */
        HFstate.voiceDialPending = 1;       

        /* Send the connect request */
        connectReqAction();
    }
}


/*
    hfVoiceDialEnableInd

    Indication containing the current status of the voice dialling
    functionality at the AG (if supported). This tells us whether
    voice dialling is enabled or disabled.
*/
void hfVoiceDialEnableInd(const HANDSFREE_VOICE_DIAL_ENABLE_IND_T *ind)
{
    /* Pass to the interface to deal with it */
    handleVoiceDialStatusInd(ind->status);
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -