当前位置: 首页>>代码示例>>C++>>正文


C++ KRIL_DEBUG函数代码示例

本文整理汇总了C++中KRIL_DEBUG函数的典型用法代码示例。如果您正苦于以下问题:C++ KRIL_DEBUG函数的具体用法?C++ KRIL_DEBUG怎么用?C++ KRIL_DEBUG使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了KRIL_DEBUG函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: STK_SendEnvelopeCmd

//******************************************************************************
//
// Function Name: STK_SendEnvelopeCmd
//
// Description:   Handle Send Envelope command
// Notes:
//
//******************************************************************************
int STK_SendEnvelopeCmd(KRIL_Command_t *ril_cmd)
{
    UInt8 *envelopeCmd = (UInt8*)ril_cmd->data;
    
    RawDataPrintfun(envelopeCmd, ril_cmd->datalen, "envelopeCmd");
    // Parse tag
    KRIL_DEBUG(DBG_INFO,"tag:0x%X\n", envelopeCmd[0]);
    switch (envelopeCmd[0])
    {
        case 0xD3:
            if (!STK_MenuSelection(ril_cmd->SimId, envelopeCmd))
                return 0;
            break;
        
        case 0xD6:
            if (!STK_EventDownload(ril_cmd->SimId, envelopeCmd))
                return 0;
            break;
            
        default:
            KRIL_DEBUG(DBG_ERROR,"Not suppported tag:0x%X\n", envelopeCmd[0]);
            return 0;
    }

    return 1;
}
开发者ID:manoranjan2050,项目名称:Compact,代码行数:34,代码来源:bcm_kril_stk_handler.c

示例2: STK_ParseDeviceIdentities

//******************************************************************************
//
// Function Name: STK_ParseDeviceIdentities
//
// Description:   Parse Device Identities(refer to 11.14 section 12.7)
//
// Notes:
//
//******************************************************************************
int STK_ParseDeviceIdentities(UInt8 *byte)
{
    // Check tag
    if (!(byte[0] == 0x82 || byte[0] == 0x02))
    {
        KRIL_DEBUG(DBG_ERROR,"Error Device details tag:0x%X\n", byte[5]);
        return 0;
    }    
    
    // Check source device identity
    if (!(byte[2] == 0x82 || byte[2] == 0x01 || byte[2] == 0x02))
    {
        KRIL_DEBUG(DBG_ERROR,"Error Source Device identity:0x%X\n", byte[7]);
        return 0;
    }
    
    // Check destination device identity
    if (byte[3] != 0x81)
    {
        KRIL_DEBUG(DBG_ERROR,"Error Destination Device identity:0x%X\n", byte[8]);
        return 0;
    }
    
    return 1;    
}
开发者ID:manoranjan2050,项目名称:Compact,代码行数:34,代码来源:bcm_kril_stk_handler.c

示例3: KRIL_GetIMEIHandler

void KRIL_GetIMEIHandler(void *ril_cmd, Kril_CAPI2Info_t *capi2_rsp)
{
    ClientInfo_t clientInfo;
    KRIL_CmdList_t *pdata = (KRIL_CmdList_t*)ril_cmd;

    KRIL_DEBUG(DBG_INFO,"pdata->handler_state:0x%lX\n", pdata->handler_state);
    switch (pdata->handler_state)
    {
        case BCM_SendCAPI2Cmd:
        {
            CAPI2_InitClientInfo(&clientInfo, GetNewTID(), GetClientID());
            CAPI2_MsDbApi_GetElement(&clientInfo, MS_LOCAL_PHCTRL_ELEM_IMEI);
            pdata->handler_state = BCM_RESPCAPI2Cmd;
            break;
        }

        case BCM_RESPCAPI2Cmd:
        {
            ParseIMEIData(pdata, capi2_rsp);
            break;
        }
        
        default:
        {
            KRIL_DEBUG(DBG_ERROR,"Error handler_state:0x%lX\n", pdata->handler_state);
            pdata->handler_state = BCM_ErrorCAPI2Cmd;
            break;
        }
    }        
}
开发者ID:kissingmylove,项目名称:kernel_tassve_2,代码行数:30,代码来源:bcm_kril_misc_handler.c

示例4: KRIL_GetIMSIHandler

void KRIL_GetIMSIHandler(void *ril_cmd, Kril_CAPI2Info_t *capi2_rsp)
{
    KRIL_CmdList_t *pdata = (KRIL_CmdList_t*)ril_cmd;

    KRIL_DEBUG(DBG_INFO,"pdata->handler_state:0x%lX\n", pdata->handler_state);
    switch (pdata->handler_state)
    {
        case BCM_SendCAPI2Cmd:
        {
            CAPI2_SIM_GetIMSI(GetNewTID(), GetClientID());
            pdata->handler_state = BCM_RESPCAPI2Cmd;
            break;
        }

        case BCM_RESPCAPI2Cmd:
        {
            ParseIMSIData(pdata, capi2_rsp);
            break;
        }
        
        default:
        {
            KRIL_DEBUG(DBG_ERROR,"Error handler_state:0x%lX\n", pdata->handler_state);
            pdata->handler_state = BCM_ErrorCAPI2Cmd;
            break;
        }
    }        
}
开发者ID:kissingmylove,项目名称:kernel_tassve_2,代码行数:28,代码来源:bcm_kril_misc_handler.c

示例5: KRIL_StkService_Running

//******************************************************************************
//
// Function Name: KRIL_StkService_Running
//
// Description:   
// Notes:
//
//******************************************************************************
void KRIL_StkService_Running(void *ril_cmd, Kril_CAPI2Info_t *capi2_rsp)  // gearn fix java sim card 
{
    KRIL_CmdList_t *pdata = (KRIL_CmdList_t*)ril_cmd;

    KRIL_DEBUG(DBG_INFO,"pdata->handler_state:0x%lX\n", pdata->handler_state);
    
    if (capi2_rsp && capi2_rsp->result != RESULT_OK)
    {
        KRIL_DEBUG(DBG_ERROR,"CAPI2 response failed:%d\n", capi2_rsp->result);
        pdata->handler_state = BCM_ErrorCAPI2Cmd;
        return;
    }
    
    switch (pdata->handler_state)
    {
        case BCM_SendCAPI2Cmd:
        {
            CAPI2_SatkApi_SendTerminalProfileReq (InitClientInfo(pdata->ril_cmd->SimId),17,  terminal_profile_data);
            pdata->handler_state = BCM_RESPCAPI2Cmd;
        }    
        
        case BCM_RESPCAPI2Cmd:
            pdata->result = BCM_E_SUCCESS;
            pdata->handler_state = BCM_FinishCAPI2Cmd;
            break;
                    
        default:
            KRIL_DEBUG(DBG_ERROR,"Error handler_state:0x%lX\n", pdata->handler_state);
            pdata->handler_state = BCM_ErrorCAPI2Cmd;
            break;        
        
    }    
}
开发者ID:manoranjan2050,项目名称:Compact,代码行数:41,代码来源:bcm_kril_stk_handler.c

示例6: KRIL_CancelUSSDHandler

void KRIL_CancelUSSDHandler(void *ril_cmd, Kril_CAPI2Info_t *capi2_rsp)
{
    KRIL_CmdList_t *pdata = (KRIL_CmdList_t *)ril_cmd;

    if (capi2_rsp != NULL)    	
    {
        KRIL_DEBUG(DBG_INFO, "handler_state:0x%lX::result:%d\n", pdata->handler_state, capi2_rsp->result);
        if(capi2_rsp->result != RESULT_OK)
        {
            pdata->result = RILErrorResult(capi2_rsp->result);
            pdata->handler_state = BCM_ErrorCAPI2Cmd;
            return;
        }
    }

    switch(pdata->handler_state)
    {
        case BCM_SendCAPI2Cmd:
        {
            KRIL_DEBUG(DBG_INFO, "gUssdID:%d\n", gUssdID);
            if(gUssdID != CALLINDEX_INVALID)
            {
                CAPI2_SS_EndUSSDConnectReq(GetNewTID(), GetClientID(), gUssdID);
                pdata->handler_state = BCM_RESPCAPI2Cmd;
            }
            else
            {
                pdata->handler_state = BCM_ErrorCAPI2Cmd;
            }
        }
        break;

        case BCM_RESPCAPI2Cmd:
        {
            if (capi2_rsp->result != RESULT_OK)
            {
                pdata->handler_state = BCM_ErrorCAPI2Cmd;
                return;
            }
            gUssdID = CALLINDEX_INVALID;

            if(gPreviousUssdID != CALLINDEX_INVALID)
            {
                gUssdID = gPreviousUssdID;
                gPreviousUssdID = CALLINDEX_INVALID;
            } 
            pdata->handler_state = BCM_FinishCAPI2Cmd;
        }
        break;

        default:
        {
            KRIL_DEBUG(DBG_ERROR, "handler_state:%lu error...!\n", pdata->handler_state);
            pdata->handler_state = BCM_ErrorCAPI2Cmd;
            break;
        }
    }
}
开发者ID:Ashutos97,项目名称:GT-S5360-opensource-Update-2,代码行数:58,代码来源:bcm_kril_suppsvc_handler.c

示例7: STK_ParseTextString

//******************************************************************************
//
// Function Name: STK_ParseTextString
//
// Description:   Parse Text String(refer to 11.14 section 12.15)
//
// Notes:
//
//******************************************************************************
int STK_ParseTextString(UInt8 *byte, SATKString_t *intext)
{
    // Check Text string tag
    UInt8 add_len;
    UInt8 DCS;

    if (!(byte[0] == 0x8D || byte[0] == 0x0D))
    {
        KRIL_DEBUG(DBG_ERROR,"Error Text string tag:0x%X\n", byte[0]);
        return 0;
    }    
    
    // Check Length
    //intext->len = byte[1] - 1;
    add_len = byte[1];
    if (add_len == 0x81)  // gearn large  get input
    {
        intext->len= byte[2]- 1;
        DCS = byte[3];
        // Parse Text string
        memcpy(intext->string, &byte[4], intext->len);
        KRIL_DEBUG(DBG_ERROR,"STK_ParseTextString DCS:0x%X add_len:%d intext->len:%d\n", DCS, add_len, intext->len);
    }
    else
    {
        intext->len = byte[1] - 1;
        DCS = byte[2];  
        memcpy(intext->string, &byte[3], intext->len);
        KRIL_DEBUG(DBG_ERROR,"STK_ParseTextString DCS:0x%X add_len:%d intext->len:%d\n", DCS, add_len, intext->len);
    }   
	
    // Check Data coding scheme
    switch (DCS)
    {
        case 0x00:
            intext->unicode_type = UNICODE_GSM;
            break;
            
        case 0x04:
            intext->unicode_type = UNICODE_UCS1;
            break;
        
        case 0x08:
            intext->unicode_type = UNICODE_80;
            break;
        
        default:
            KRIL_DEBUG(DBG_ERROR,"Not supported coding scheme:0x%02X Error!\n", byte[2]);
            return 0;
    }
    
    return 1;
}
开发者ID:manoranjan2050,项目名称:Compact,代码行数:62,代码来源:bcm_kril_stk_handler.c

示例8: KRIL_GetDeviceIdentityHandler

void KRIL_GetDeviceIdentityHandler(void *ril_cmd, Kril_CAPI2Info_t *capi2_rsp)
{
    ClientInfo_t clientInfo;
    KRIL_CmdList_t *pdata = (KRIL_CmdList_t*)ril_cmd;

    if (capi2_rsp != NULL)
    {
        KRIL_DEBUG(DBG_INFO, "handler_state:0x%lX::result:%d\n", pdata->handler_state, capi2_rsp->result);
        if(capi2_rsp->result != RESULT_OK)
        {
            pdata->result = RILErrorResult(capi2_rsp->result);
            pdata->handler_state = BCM_ErrorCAPI2Cmd;
            return;
        }
    }

    switch (pdata->handler_state)
    {
        case BCM_SendCAPI2Cmd:
        {
            CAPI2_InitClientInfo(&clientInfo, GetNewTID(), GetClientID());
            CAPI2_MsDbApi_GetElement(&clientInfo, MS_LOCAL_PHCTRL_ELEM_IMEI);
            pdata->handler_state = BCM_GetIMEIInfo;
            break;
        }

        case BCM_GetIMEIInfo:
        {
            ParseIMEIData(pdata, capi2_rsp);
            CAPI2_InitClientInfo(&clientInfo, GetNewTID(), GetClientID());
            CAPI2_MsDbApi_GetElement(&clientInfo, MS_LOCAL_PHCTRL_ELEM_SW_VERSION);
            pdata->handler_state = BCM_RESPCAPI2Cmd;
            break;
        }

        case BCM_RESPCAPI2Cmd:
        {
            CAPI2_MS_Element_t *rsp = (CAPI2_MS_Element_t *) capi2_rsp->dataBuf;
            KrilImeiData_t *imeisv_result = (KrilImeiData_t *)pdata->bcm_ril_rsp;
            strcpy(imeisv_result->imeisv, rsp->data_u.u3Bytes);
            KRIL_DEBUG(DBG_INFO, "u3Bytes:[%s] imeisv:[%s]\n", rsp->data_u.u3Bytes, imeisv_result->imeisv);
            pdata->handler_state = BCM_FinishCAPI2Cmd;
            break;
        }

        default:
        {
            KRIL_DEBUG(DBG_ERROR,"Error handler_state:0x%lX\n", pdata->handler_state);
            pdata->handler_state = BCM_ErrorCAPI2Cmd;
            break;
        }
    }
}
开发者ID:kissingmylove,项目名称:kernel_tassve_2,代码行数:53,代码来源:bcm_kril_misc_handler.c

示例9: STK_ParseEventList

//******************************************************************************
//
// Function Name: STK_ParseEventList
//
// Description:   Parse Event List(refer to 11.14 section 12.25)
//
// Notes:
//
//******************************************************************************
int STK_ParseEventList(SimNumber_t SimId, UInt8 *byte)
{    
    // Check Event List tag
    if (!(byte[0] == 0x19 || byte[0] == 0x99))
    {
        KRIL_DEBUG(DBG_ERROR,"Error Event List tag:0x%X\n", byte[0]);
        return 0;
    }        
    
    if (0 == byte[1])
    {
        KRIL_DEBUG(DBG_ERROR,"Event list length is 0 Error!!!\n");
        return 0;
    }
    
    KRIL_DEBUG(DBG_INFO,"Event Id:%d\n",byte[2]);

    switch (byte[2])
    {
        case 4:
        {
           // User activity
	         CAPI2_SatkApi_SendUserActivityEvent (InitClientInfo(SimId));
	         break;       
        }
    
        case 5:
        {
            // Idle screen available
	          CAPI2_SatkApi_SendIdleScreenAvaiEvent (InitClientInfo(SimId));            
            break;
        }
        
        case 7:
        {
            // Language selection
            if (!STK_ParseLanguageSelection(SimId, &byte[7]))
                return 0;
                
            break;
        }
        
        
        default:
            KRIL_DEBUG(DBG_ERROR,"Unknow Enevt ID:%d\n", byte[2]);
            return 0;
    }

    
    return 1;
}
开发者ID:manoranjan2050,项目名称:Compact,代码行数:60,代码来源:bcm_kril_stk_handler.c

示例10: KRIL_AgpsClosePkcs15Handler

//RIL_REQUEST_AGPS_CLOSE_PKCS15
void KRIL_AgpsClosePkcs15Handler(void *ril_cmd, Kril_CAPI2Info_t *capi2_rsp)
{
	KRIL_CmdList_t *pdata = (KRIL_CmdList_t *)ril_cmd;
	unsigned char *pSockId = (unsigned char *)pdata->ril_cmd->data;

    if (capi2_rsp != NULL)
        KRIL_DEBUG(DBG_ERROR, "handler_state:0x%lX::result:%d\n", pdata->handler_state, capi2_rsp->result);

    switch(pdata->handler_state)
    {
        case BCM_SendCAPI2Cmd:
        {
			ClientInfo_t* pLcsClientInfo = InitClientInfo(pdata->ril_cmd->SimId);

			KRIL_DEBUG(DBG_ERROR, "KRIL_AgpsClosePkcs15Handler, sockID=%d \n", (unsigned char)(*pSockId));
			CAPI2_SimApi_SendDeactivateAppiReq(pLcsClientInfo, (UInt8) (*pSockId));
			pdata->handler_state = BCM_AGPS_DESELECT_PKCS15;
			break;
		}
		case BCM_AGPS_DESELECT_PKCS15:
		{
			//MsgType_t: ::MSG_SIM_DEACTIVATE_APPLI_RSP
			//ResultData: ::SIM_DEACTIVATE_APPLI_RES_t
			SIM_DEACTIVATE_APPLI_RES_t * rsp = (SIM_DEACTIVATE_APPLI_RES_t *) capi2_rsp->dataBuf;
			ClientInfo_t* pLcsClientInfo = InitClientInfo(pdata->ril_cmd->SimId);

			KRIL_DEBUG(DBG_ERROR, "KRIL_Agps SendDeactivateAppiReq, result=%d \n", rsp->result);
			CAPI2_SimApi_SendCloseSocketReq(pLcsClientInfo, (UInt8) (*pSockId));
			pdata->handler_state = BCM_RESPCAPI2Cmd;
			break;
		}

		case BCM_RESPCAPI2Cmd:
		{
			//MsgType_t: ::MSG_SIM_CLOSE_SOCKET_RSP
			//ResultData: ::SIM_CLOSE_SOCKET_RES_t

			SIM_CLOSE_SOCKET_RES_t * rsp = (SIM_CLOSE_SOCKET_RES_t *) capi2_rsp->dataBuf;

			KRIL_DEBUG(DBG_ERROR, "KRIL_Agps SendCloseSocketReq, result=%d \n", rsp->result);
			pdata->handler_state = BCM_FinishCAPI2Cmd;
			break;
		}
		default:
        {
            KRIL_DEBUG(DBG_ERROR,"Error handler_state:0x%lX\n", pdata->handler_state);
            pdata->handler_state = BCM_ErrorCAPI2Cmd;
            break;
        }
	}
}
开发者ID:badcompany1982,项目名称:android_kernel_zte_V768,代码行数:52,代码来源:bcm_kril_agps_handler.c

示例11: STK_ParseItemIdentifier

//******************************************************************************
//
// Function Name: STK_ParseItemIdentifier
//
// Description:   Parse Item Identifier(refer to 11.14 section 12.10)
//
// Notes:
//
//******************************************************************************
int STK_ParseItemIdentifier(UInt8 *byte, UInt8 *itemId)
{
    // Check item identifier tag
    if (!(byte[0] == 0x90 || byte[0] == 0x10))
    {
        KRIL_DEBUG(DBG_ERROR,"Error Item identifier tag:0x%X\n", byte[0]);
        return 0;
    }
    
    // Check identifier of item chosen
    *itemId = byte[2];
    KRIL_DEBUG(DBG_INFO,"itemId:%d\n",*itemId);
    return 1;
}
开发者ID:manoranjan2050,项目名称:Compact,代码行数:23,代码来源:bcm_kril_stk_handler.c

示例12: KRIL_ChangeBarringPasswordHandler

void KRIL_ChangeBarringPasswordHandler(void *ril_cmd, Kril_CAPI2Info_t *capi2_rsp)
{
    KRIL_CmdList_t *pdata = (KRIL_CmdList_t *)ril_cmd;

    if (capi2_rsp != NULL)    	
    {
        KRIL_DEBUG(DBG_INFO, "handler_state:0x%lX::result:%d\n", pdata->handler_state, capi2_rsp->result);
        if(capi2_rsp->result != RESULT_OK)
        {
            pdata->result = RILErrorResult(capi2_rsp->result);
            pdata->handler_state = BCM_ErrorCAPI2Cmd;
            return;
        }
    }

    switch(pdata->handler_state)
    {
        case BCM_SendCAPI2Cmd:
        {
            KrilCallBarringPasswd_t *tdata = (KrilCallBarringPasswd_t *)pdata->ril_cmd->data;
            KRIL_DEBUG(DBG_INFO, "fac_id:%d OldPasswd:%s NewPasswd:%s NewPassConfirm:%s\n", 
                                  tdata->fac_id, tdata->OldPasswd, tdata->NewPasswd, tdata->NewPassConfirm);
            CAPI2_SS_SendCallBarringPWDChangeReq(GetNewTID(), GetClientID(), ssBarringTypes[tdata->fac_id], (UInt8*) tdata->OldPasswd, (UInt8*) tdata->NewPasswd, (UInt8*) tdata->NewPassConfirm);
            pdata->handler_state = BCM_RESPCAPI2Cmd;
        }
        break;

        case BCM_RESPCAPI2Cmd:
        {
                NetworkCause_t *presult = (NetworkCause_t *) capi2_rsp->dataBuf;
                KRIL_DEBUG(DBG_INFO, "NetworkCause:%d\n", *presult);
            pdata->handler_state = BCM_FinishCAPI2Cmd;

                if(GSMCAUSE_SUCCESS != *presult)
                {
                    pdata->handler_state = BCM_ErrorCAPI2Cmd;
            }
        }
        break;

        default:
        {
            KRIL_DEBUG(DBG_ERROR, "handler_state:%lu error...!\n", pdata->handler_state);
            pdata->handler_state = BCM_ErrorCAPI2Cmd;
            break;
        }
    }
}
开发者ID:Ashutos97,项目名称:GT-S5360-opensource-Update-2,代码行数:48,代码来源:bcm_kril_suppsvc_handler.c

示例13: CAPI2_PMU_IsSIMReady

/* CAPI2 callback functions */
void CAPI2_PMU_IsSIMReady(UInt32 tid, UInt8 clientID)
{
    if (tid || clientID) { } //fixes warnings
    /* NOT implemented yet */
    KRIL_DEBUG(DBG_TRACE, " --->Capi2 Callback\n");
   CAPI2_PMU_IsSIMReady_RSP(tid, clientID, pmu_is_sim_ready());
}
开发者ID:manoranjan2050,项目名称:Compact,代码行数:8,代码来源:bcm_cp_cmd_handler.c

示例14: _DEF

void _DEF(CAPI2_SOCKET_ParseIPAddr)(UInt32 tid, UInt8 clientID, char_ptr_t ipString)
{
    if (tid || clientID) { } //fixes warnings
      
    /* NOT implemented yet */
    KRIL_DEBUG(DBG_TRACE, " --->Capi2 Callback!\n");
}
开发者ID:manoranjan2050,项目名称:Compact,代码行数:7,代码来源:bcm_cp_cmd_handler.c

示例15: CAPI2_GPIO_ConfigOutput_64Pin

//CAPI2_LINUX_INTEGRATION_CHANGE 1.2.10.2 TEMPORARY
void CAPI2_GPIO_ConfigOutput_64Pin(UInt32 tid, UInt8 clientID, UInt32 mask)
{
    if (tid || clientID || mask) { } //fixes warnings

    KRIL_DEBUG(DBG_TRACE," --->Capi2 Callback\n");
    CAPI2_GPIO_ConfigOutput_64Pin_RSP(tid, clientID, FALSE);
}
开发者ID:manoranjan2050,项目名称:Compact,代码行数:8,代码来源:bcm_cp_cmd_handler.c


注:本文中的KRIL_DEBUG函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。