本文整理汇总了C++中BTC_PRINT函数的典型用法代码示例。如果您正苦于以下问题:C++ BTC_PRINT函数的具体用法?C++ BTC_PRINT怎么用?C++ BTC_PRINT使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了BTC_PRINT函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: EXhalbtc8723a1ant_ConnectNotify
VOID
EXhalbtc8723a1ant_ConnectNotify(
IN PBTC_COEXIST pBtCoexist,
IN u1Byte type
)
{
BOOLEAN bWifiConnected=FALSE;
if(pBtCoexist->btInfo.bBtDisabled) {
halbtc8723a1ant_PsTdma(pBtCoexist, NORMAL_EXEC, FALSE, 9);
} else {
if(BTC_ASSOCIATE_START == type) {
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], CONNECT START notify\n"));
//set 0x550[3]=1 before PsTdma
halbtc8723a1ant_Reg0x550Bit3(pBtCoexist, TRUE);
halbtc8723a1ant_PsTdma(pBtCoexist, NORMAL_EXEC, TRUE, 8); // extend wifi slot
} else if(BTC_ASSOCIATE_FINISH == type) {
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], CONNECT FINISH notify\n"));
pBtCoexist->fBtcGet(pBtCoexist, BTC_GET_BL_WIFI_CONNECTED, &bWifiConnected);
if(!bWifiConnected) { // non-connected scan
halbtc8723a1ant_PsTdma(pBtCoexist, NORMAL_EXEC, FALSE, 0);
} else {
halbtc8723a1ant_CoexForWifiConnect(pBtCoexist);
}
}
}
}
示例2: halbtc8723a1ant_CoexTable
VOID
halbtc8723a1ant_CoexTable(
IN PBTC_COEXIST pBtCoexist,
IN BOOLEAN bForceExec,
IN u4Byte val0x6c0,
IN u4Byte val0x6c8,
IN u1Byte val0x6cc
)
{
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_TRACE_SW, ("[BTCoex], %s write Coex Table 0x6c0=0x%x, 0x6c8=0x%x, 0x6cc=0x%x\n",
(bForceExec? "force to":""), val0x6c0, val0x6c8, val0x6cc));
pCoexDm->curVal0x6c0 = val0x6c0;
pCoexDm->curVal0x6c8 = val0x6c8;
pCoexDm->curVal0x6cc = val0x6cc;
if(!bForceExec) {
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_TRACE_SW_DETAIL, ("[BTCoex], preVal0x6c0=0x%x, preVal0x6c8=0x%x, preVal0x6cc=0x%x !!\n",
pCoexDm->preVal0x6c0, pCoexDm->preVal0x6c8, pCoexDm->preVal0x6cc));
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_TRACE_SW_DETAIL, ("[BTCoex], curVal0x6c0=0x%x, curVal0x6c8=0x%x, curVal0x6cc=0x%x !!\n",
pCoexDm->curVal0x6c0, pCoexDm->curVal0x6c8, pCoexDm->curVal0x6cc));
if( (pCoexDm->preVal0x6c0 == pCoexDm->curVal0x6c0) &&
(pCoexDm->preVal0x6c8 == pCoexDm->curVal0x6c8) &&
(pCoexDm->preVal0x6cc == pCoexDm->curVal0x6cc) )
return;
}
halbtc8723a1ant_SetCoexTable(pBtCoexist, val0x6c0, val0x6c8, val0x6cc);
pCoexDm->preVal0x6c0 = pCoexDm->curVal0x6c0;
pCoexDm->preVal0x6c8 = pCoexDm->curVal0x6c8;
pCoexDm->preVal0x6cc = pCoexDm->curVal0x6cc;
}
示例3: halbtc8723a1ant_MonitorBtCtr
VOID
halbtc8723a1ant_MonitorBtCtr(
IN PBTC_COEXIST pBtCoexist
)
{
u4Byte regHPTxRx, regLPTxRx, u4Tmp;
u4Byte regHPTx=0, regHPRx=0, regLPTx=0, regLPRx=0;
//u1Byte u1Tmp;
regHPTxRx = 0x770;
regLPTxRx = 0x774;
u4Tmp = pBtCoexist->fBtcRead4Byte(pBtCoexist, regHPTxRx);
regHPTx = u4Tmp & bMaskLWord;
regHPRx = (u4Tmp & bMaskHWord)>>16;
u4Tmp = pBtCoexist->fBtcRead4Byte(pBtCoexist, regLPTxRx);
regLPTx = u4Tmp & bMaskLWord;
regLPRx = (u4Tmp & bMaskHWord)>>16;
pCoexSta->highPriorityTx = regHPTx;
pCoexSta->highPriorityRx = regHPRx;
pCoexSta->lowPriorityTx = regLPTx;
pCoexSta->lowPriorityRx = regLPRx;
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_BT_MONITOR, ("[BTCoex], High Priority Tx/Rx (reg 0x%x)=0x%x(%d)/0x%x(%d)\n",
regHPTxRx, regHPTx, regHPTx, regHPRx, regHPRx));
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_BT_MONITOR, ("[BTCoex], Low Priority Tx/Rx (reg 0x%x)=0x%x(%d)/0x%x(%d)\n",
regLPTxRx, regLPTx, regLPTx, regLPRx, regLPRx));
// reset counter
pBtCoexist->fBtcWrite1Byte(pBtCoexist, 0x76e, 0xc);
}
示例4: btinfo_evt_dump
void btinfo_evt_dump(struct btinfo_8761au *info)
{
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,"cid:0x%02x, len:%u\n", info->cid, info->len);
if (info->len > 2)
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,
"byte2:%s%s%s%s%s%s%s%s\n"
, info->connection?"connection ":""
, info->scoe_sco?"scoe_sco ":""
, info->inq_page?"inq_page ":""
, info->acl_busy?"acl_busy ":""
, info->sco_busy?"sco_busy ":""
, info->hid?"hid ":""
, info->a2dp?"a2dp ":""
, info->ftp?"ftp":""
);
if (info->len > 3)
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,"retry_cnt:%u\n", info->retry_cnt);
if (info->len > 4)
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,"rssi:%u\n", info->rssi);
if (info->len > 5)
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,"byte5:%s%s\n"
, info->esco_sco?"eSCO_SCO ":""
, info->master_slave?"Master_Slave ":"");
}
示例5: EXhalbtc8723a1ant_ScanNotify
VOID
EXhalbtc8723a1ant_ScanNotify(
IN PBTC_COEXIST pBtCoexist,
IN u1Byte type
)
{
BOOLEAN bWifiConnected=FALSE;
halbtc8723a1ant_NotifyFwScan(pBtCoexist, type);
if(pBtCoexist->btInfo.bBtDisabled) {
halbtc8723a1ant_PsTdma(pBtCoexist, NORMAL_EXEC, FALSE, 9);
} else {
pBtCoexist->fBtcGet(pBtCoexist, BTC_GET_BL_WIFI_CONNECTED, &bWifiConnected);
if(BTC_SCAN_START == type) {
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], SCAN START notify\n"));
if(!bWifiConnected) { // non-connected scan
//set 0x550[3]=1 before PsTdma
halbtc8723a1ant_Reg0x550Bit3(pBtCoexist, TRUE);
}
halbtc8723a1ant_PsTdma(pBtCoexist, NORMAL_EXEC, TRUE, 4);
} else if(BTC_SCAN_FINISH == type) {
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], SCAN FINISH notify\n"));
if(!bWifiConnected) { // non-connected scan
halbtc8723a1ant_PsTdma(pBtCoexist, NORMAL_EXEC, FALSE, 0);
} else {
halbtc8723a1ant_CoexForWifiConnect(pBtCoexist);
}
}
}
}
示例6: rtl_btcoex_sendmsgbysocket
u8 rtl_btcoex_sendmsgbysocket(struct rtl_priv *rtlpriv, u8 *msg, u8 msg_size, bool force) {
//u8 i;
u8 error;
struct msghdr udpmsg;
mm_segment_t oldfs;
struct iovec iov;
struct bt_coex_info *pcoex_info = &rtlpriv->coex_info;
if(false == force) {
if(false == pcoex_info->BT_attend) {
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_CRITICAL,"TX Blocked: WiFi-BT disconnected\n");
return _FAIL;
}
}
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,"<<<<<<<<<<<<<<<<<<<<<<<<WIFI_TO_BT,msg:%s\n",msg);
/********test code***********
for(i =0;i<msg_size;i++)
printk("%02x",msg[i]);
printk("\n");
*******************/
iov.iov_base = (void *)msg;
iov.iov_len = msg_size;
udpmsg.msg_name = &pcoex_info->bt_addr;
udpmsg.msg_namelen = sizeof(struct sockaddr_in);
#if (LINUX_VERSION_CODE <= KERNEL_VERSION(3, 18, 0))
udpmsg.msg_iov = &iov;
udpmsg.msg_iovlen = 1;
#endif
udpmsg.msg_control = NULL;
udpmsg.msg_controllen = 0;
udpmsg.msg_flags = MSG_DONTWAIT | MSG_NOSIGNAL;
udpmsg.msg_flags = 0;
oldfs = get_fs();
set_fs(KERNEL_DS);
#if (LINUX_VERSION_CODE < KERNEL_VERSION(4, 1, 0))
error = sock_sendmsg(pcoex_info->udpsock, &udpmsg, msg_size);
#else
error = sock_sendmsg(pcoex_info->udpsock, &udpmsg);
#endif
set_fs(oldfs);
if(error < 0) {
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_CRITICAL,"Error when sendimg msg, error:%d\n",error);
return _FAIL;
}
return _SUCCESS;
}
示例7: EXhalbtc8723a1ant_MediaStatusNotify
VOID
EXhalbtc8723a1ant_MediaStatusNotify(
IN PBTC_COEXIST pBtCoexist,
IN u1Byte type
)
{
if(BTC_MEDIA_CONNECT == type) {
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], MEDIA connect notify\n"));
} else {
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], MEDIA disconnect notify\n"));
}
}
示例8: EXhalbtc8723a1ant_LpsNotify
VOID
EXhalbtc8723a1ant_LpsNotify(
IN PBTC_COEXIST pBtCoexist,
IN u1Byte type
)
{
if(BTC_LPS_ENABLE == type) {
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], LPS ENABLE notify\n"));
} else if(BTC_LPS_DISABLE == type) {
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], LPS DISABLE notify\n"));
halbtc8723a1ant_PsTdma(pBtCoexist, NORMAL_EXEC, FALSE, 8);
}
}
示例9: EXhalbtc8723a1ant_IpsNotify
VOID
EXhalbtc8723a1ant_IpsNotify(
IN PBTC_COEXIST pBtCoexist,
IN u1Byte type
)
{
if(BTC_IPS_ENTER == type) {
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], IPS ENTER notify\n"));
halbtc8723a1ant_CoexAllOff(pBtCoexist);
} else if(BTC_IPS_LEAVE == type) {
BTC_PRINT(BTC_MSG_INTERFACE, INTF_NOTIFY, ("[BTCoex], IPS LEAVE notify\n"));
//halbtc8723a1ant_InitCoexDm(pBtCoexist);
}
}
示例10: rtl_btcoex_dump_tx_msg
void rtl_btcoex_dump_tx_msg(u8 *tx_msg, u8 len, u8 *msg_name)
{
u8 i = 0;
return;
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,"_%s\n",msg_name);
for(i=0;i<len;i++)
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,"%02x ",tx_msg[i]);
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,"\n");
}
示例11: EXhalbtc8723a1ant_InitHwConfig
//============================================================
// extern function start with EXhalbtc8723a1ant_
//============================================================
VOID
EXhalbtc8723a1ant_InitHwConfig(
IN PBTC_COEXIST pBtCoexist
)
{
BTC_PRINT(BTC_MSG_INTERFACE, INTF_INIT, ("[BTCoex], 1Ant Init HW Config!!\n"));
// backup rf 0x1e value
pCoexDm->btRf0x1eBackup =
pBtCoexist->fBtcGetRfReg(pBtCoexist, BTC_RF_A, 0x1e, 0xfffff);
pBtCoexist->fBtcWrite1Byte(pBtCoexist, 0x40, 0x20);
// enable counter statistics
pBtCoexist->fBtcWrite1Byte(pBtCoexist, 0x76e, 0x4);
// coex table
pBtCoexist->fBtcWrite1Byte(pBtCoexist, 0x6cc, 0x0); // 1-Ant coex
pBtCoexist->fBtcWrite4Byte(pBtCoexist, 0x6c8, 0xffff); // wifi break table
pBtCoexist->fBtcWrite4Byte(pBtCoexist, 0x6c4, 0x55555555); //coex table
// antenna switch control parameter
pBtCoexist->fBtcWrite4Byte(pBtCoexist, 0x858, 0xaaaaaaaa);
pBtCoexist->fBtcWrite2Byte(pBtCoexist, 0x860, 0x210); //set antenna at wifi side if ANTSW is software control
pBtCoexist->fBtcWrite4Byte(pBtCoexist, 0x870, 0x300); //SPDT(connected with TRSW) control by hardware PTA
pBtCoexist->fBtcWrite4Byte(pBtCoexist, 0x874, 0x22804000); //ANTSW keep by GNT_BT
// coexistence parameters
pBtCoexist->fBtcWrite1Byte(pBtCoexist, 0x778, 0x1); // enable RTK mode PTA
}
示例12: rtl_btcoex_close_kernel_socket
void rtl_btcoex_close_kernel_socket(struct rtl_priv *rtlpriv) {
struct bt_coex_info *pcoex_info = &rtlpriv->coex_info;
if(pcoex_info->sock_open & KERNEL_SOCKET_OK)
{
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_CRITICAL,"release kernel socket\n");
cancel_delayed_work(&rtlpriv->works.socket_wq);
sock_release(pcoex_info->udpsock);
pcoex_info->sock_open &= ~(KERNEL_SOCKET_OK);
if(true == pcoex_info->BT_attend)
pcoex_info->BT_attend = false;
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_CRITICAL,"sock_open:%d, BT_attend:%d\n",pcoex_info ->sock_open,pcoex_info ->BT_attend);
}
}
示例13: rtl_send_complete_event_to_BT
u8 rtl_send_complete_event_to_BT(struct rtl_priv *rtlpriv,RTW_HCI_EXT_CMD BT_RELATED_CMD,RTL_HCI_STATUS status)
{
rtl_hci_event *hci_event;
u8 local_buf[6] = "";
u8 len=0,tx_event_length = 0;
u8 *ret_par;
u8 *event_data = NULL;
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,"#LEVEL_END,rtl_send_complete_event_to_BT\n");
hci_event = (rtl_hci_event*)(&local_buf[0]);
event_data = hci_event->data;
hci_event->event_code = HCI_EVENT_COMMAND_COMPLETE;
*event_data = 0x1;
*(event_data + 1) = HCIOPCODELOW(BT_RELATED_CMD, OGF_EXTENSION);
*(event_data + 2) = HCIOPCODEHIGHT(BT_RELATED_CMD, OGF_EXTENSION);
len = len + 3;
ret_par = &hci_event->data[len];
ret_par[0] = status;
len++;
hci_event->length = len;
//total tx event length + event_code length + sizeof(length)
tx_event_length = hci_event->length + 2;
rtl_btcoex_dump_tx_msg((u8 *)hci_event, tx_event_length,"rtl_send_complete_event_to_BT");
status = rtl_btcoex_sendmsgbysocket(rtlpriv,(u8 *)hci_event, tx_event_length,false);
return status;
}
示例14: rtl_btcoex_SendEventExtBtCoexControl
void rtl_btcoex_SendEventExtBtCoexControl(struct rtl_priv *rtlpriv, u8 bNeedDbgRsp, u8 dataLen, void *pData)
{
u8 len=0, tx_event_length = 0;
u8 local_buf[32] = "";
u8 *ret_par;
u8 opCode=0;
u8 *pInBuf=(u8 *)pData;
rtl_hci_event *hci_event;
BTC_PRINT(BTC_MSG_SOCKET, SOCKET_NORMAL,"#LEVEL_WIFI_ACTIVE,SendEventExtBtCoexControl\n");
opCode = pInBuf[0];
hci_event = (rtl_hci_event*)(&local_buf[0]);
hci_event->event_code = HCI_EVENT_EXTENSION_RTK;
hci_event->data[0] = HCI_EVENT_EXT_BT_COEX_CONTROL; //extension event code
len ++;
ret_par = hci_event->data + len;
memcpy(&ret_par[0], pData, dataLen); /*maybe not safe here*/
len += dataLen;
hci_event->length = len;
//total tx event length + event_code length + sizeof(length)
tx_event_length = hci_event->length + 2;
rtl_btcoex_dump_tx_msg((u8 *)hci_event, tx_event_length, "BT COEX CONTROL");
rtl_btcoex_sendmsgbysocket(rtlpriv,(u8 *)hci_event, tx_event_length,false);
}
示例15: halbtc8723a1ant_SetCoexTable
VOID
halbtc8723a1ant_SetCoexTable(
IN PBTC_COEXIST pBtCoexist,
IN u4Byte val0x6c0,
IN u4Byte val0x6c8,
IN u1Byte val0x6cc
)
{
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_TRACE_SW_EXEC, ("[BTCoex], set coex table, set 0x6c0=0x%x\n", val0x6c0));
pBtCoexist->fBtcWrite4Byte(pBtCoexist, 0x6c0, val0x6c0);
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_TRACE_SW_EXEC, ("[BTCoex], set coex table, set 0x6c8=0x%x\n", val0x6c8));
pBtCoexist->fBtcWrite4Byte(pBtCoexist, 0x6c8, val0x6c8);
BTC_PRINT(BTC_MSG_ALGORITHM, ALGO_TRACE_SW_EXEC, ("[BTCoex], set coex table, set 0x6cc=0x%x\n", val0x6cc));
pBtCoexist->fBtcWrite1Byte(pBtCoexist, 0x6cc, val0x6cc);
}