• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ MAKE_CL_MESSAGE函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: connectionHandleReadRemoteSupportedFeaturesRequest

/****************************************************************************
NAME	
    connectionHandleReadRemoteSupportedFeaturesRequest

DESCRIPTION
    Request to read the supported features of a remote device.

RETURNS
    void
*/
void connectionHandleReadRemoteSupportedFeaturesRequest(connectionReadInfoState *state, const CL_INTERNAL_DM_READ_REMOTE_SUPP_FEAT_REQ_T *req)
{
	/* Check the resource lock */
	if (!state->stateInfoLock)
	{
		bdaddr addr;

		/* Check we got a valid addr */
		if (!SinkGetBdAddr(req->sink, &addr))
		{
			/* Send an error to the app as it didn't pass in a valid sink */
			sendRemoteSupportedFeaturesCfm(req->theAppTask, hci_error_no_connection, 0, req->sink);		
		}
		else
		{
			/* Response not outstanding so issue request */
			MAKE_PRIM_C(DM_HCI_READ_REMOTE_FEATURES);
			connectionConvertBdaddr_t(&prim->bd_addr, &addr);
			VmSendDmPrim(prim);

			/* Set the lock */
			state->stateInfoLock = req->theAppTask;
			state->sink = req->sink;
		}		
	}
	else
	{
		/* Lock set so queue up the request */
		MAKE_CL_MESSAGE(CL_INTERNAL_DM_READ_REMOTE_SUPP_FEAT_REQ);
		COPY_CL_MESSAGE(req, message);
		MessageSendConditionallyOnTask(connectionGetCmTask(), CL_INTERNAL_DM_READ_REMOTE_SUPP_FEAT_REQ, message, &state->stateInfoLock);
	}
}
开发者ID:Duiesel,项目名称:thebirdfree-personal,代码行数:43,代码来源:dm_info_handler.c


示例2: connectionHandleDmHciModeChangeEvent

/****************************************************************************
NAME	
    connectionHandleDmHciModeChangeEvent

DESCRIPTION
    An indication from BlueStack that an ACL has been opened. Some clients
	may need this information so pass the indication up to the task 
	registered as the "app task" (we don't know who else to pass this to!).

RETURNS
    void
*/
void connectionHandleDmHciModeChangeEvent(Task task, const DM_HCI_MODE_CHANGE_EVENT_T *ev)
{
    const msg_filter *msgFilter = connectionGetMsgFilter();
	if (task && (msgFilter[0] & msg_group_mode_change)) 
    {
		/* Check mode change was successful */
		if ((ev->status == HCI_SUCCESS) && ((ev->mode == HCI_BT_MODE_ACTIVE) || (ev->mode == HCI_BT_MODE_SNIFF)))
		{
			MAKE_CL_MESSAGE(CL_DM_MODE_CHANGE_EVENT);
			connectionConvertBdaddr(&message->bd_addr, &ev->bd_addr);

			/* Convert HCI mode into connection library power mode */
			switch (ev->mode)
			{
				case HCI_BT_MODE_ACTIVE:
					message->mode = lp_active;
					break;
				case HCI_BT_MODE_SNIFF:
					message->mode = lp_sniff;
					break;
				default:
					Panic();
					break;
			}
			message->interval = ev->length;
			MessageSend(task, CL_DM_MODE_CHANGE_EVENT, message);
		}
    }
}
开发者ID:Duiesel,项目名称:thebirdfree-personal,代码行数:41,代码来源:dm_info_handler.c


示例3: ConnectionReadClassOfDevice

void ConnectionReadClassOfDevice(Task theAppTask)
{
    /* Create internal message and sent to the CL */
    MAKE_CL_MESSAGE(CL_INTERNAL_DM_READ_CLASS_OF_DEVICE_REQ);
    message->theAppTask = theAppTask;
    MessageSend(connectionGetCmTask(), CL_INTERNAL_DM_READ_CLASS_OF_DEVICE_REQ, message);
}
开发者ID:stephen-kun,项目名称:koovox_adk4.0,代码行数:7,代码来源:ConnectionReadClassOfDevice.c


示例4: ConnectionSmSendKeypressNotificationRequest

void ConnectionSmSendKeypressNotificationRequest(const bdaddr* bd_addr, cl_sm_keypress_type type)
{
	MAKE_CL_MESSAGE(CL_INTERNAL_SM_SEND_KEYPRESS_NOTIFICATION_REQ);
	message->bd_addr = *bd_addr;
	message->type = type;
	MessageSend(connectionGetCmTask(), CL_INTERNAL_SM_SEND_KEYPRESS_NOTIFICATION_REQ, message);
}
开发者ID:Duiesel,项目名称:thebirdfree-personal,代码行数:7,代码来源:ConnectionSmSendKeypressNotificationRequest.c


示例5: ConnectionWriteClassOfDevice

void ConnectionWriteClassOfDevice(uint32 cod)
{
    /* All requests are sent through the internal state handler */
    MAKE_CL_MESSAGE(CL_INTERNAL_DM_WRITE_CLASS_OF_DEVICE_REQ);
    message->class_of_device = cod;
    MessageSend(connectionGetCmTask(), CL_INTERNAL_DM_WRITE_CLASS_OF_DEVICE_REQ, message);
}
开发者ID:stephen-kun,项目名称:koovox_adk4.0,代码行数:7,代码来源:dm_baseband_cod.c


示例6: ConnectionSmUnRegisterOutgoingService

void ConnectionSmUnRegisterOutgoingService(const bdaddr* bd_addr, dm_protocol_id protocol_id, uint32 channel)
{
#ifdef CONNECTION_DEBUG_LIB
    if ((protocol_id != protocol_l2cap) && (protocol_id != protocol_rfcomm))
    {
        CL_DEBUG(("Out of range protocol id 0x%x\n", protocol_id));
    }

    /* TODO: Check if we should check channel range for outgoing service channel */
    if((protocol_id == protocol_rfcomm) &&
            ((channel < RFCOMM_SERVER_CHANNEL_MIN) ||
                    (channel > RFCOMM_SERVER_CHANNEL_MAX))
        )
    {
        CL_DEBUG(("Out of range RFCOMM server channel 0x%lx\n", channel));
    }

    if(bd_addr == NULL)
    {
       CL_DEBUG(("Out of range Bluetooth Address 0x%p\n", (void*)bd_addr)); 
    }
#endif

    {
        MAKE_CL_MESSAGE(CL_INTERNAL_SM_UNREGISTER_OUTGOING_REQ);
        message->bd_addr = *bd_addr;
        message->protocol_id = protocol_id;
        message->channel = channel;
        MessageSend(connectionGetCmTask(), CL_INTERNAL_SM_UNREGISTER_OUTGOING_REQ, message);
    }
}
开发者ID:stephen-kun,项目名称:csr8670,代码行数:31,代码来源:ConnectionSmUnRegisterOutgoingService.c


示例7: ConnectionRfcommDeallocateChannel

void ConnectionRfcommDeallocateChannel(Task theAppTask, uint8 local_server_channel)
{
    MAKE_CL_MESSAGE(CL_INTERNAL_RFCOMM_UNREGISTER_REQ);
    message->theAppTask = theAppTask;
    message->local_server_channel = local_server_channel;
    MessageSend(connectionGetCmTask(), CL_INTERNAL_RFCOMM_UNREGISTER_REQ, message);
}
开发者ID:stephen-kun,项目名称:koovox_adk4.0,代码行数:7,代码来源:rfc.c


示例8: ConnectionRfcommDisconnectResponse

void ConnectionRfcommDisconnectResponse(Sink sink)
{
	/* Send an internal message */
	MAKE_CL_MESSAGE(CL_INTERNAL_RFCOMM_DISCONNECT_RSP);
    message->sink = sink;
	MessageSend(connectionGetCmTask(), CL_INTERNAL_RFCOMM_DISCONNECT_RSP, message);
}
开发者ID:stephen-kun,项目名称:koovox_adk4.0,代码行数:7,代码来源:rfc.c


示例9: ConnectionClearParameterCache

void ConnectionClearParameterCache(const bdaddr *addr)
{
    /* Send an internal message requesting this action */
    MAKE_CL_MESSAGE(CL_INTERNAL_DM_CLEAR_PARAM_CACHE_REQ);
    message->bd_addr = *addr;
    MessageSend(connectionGetCmTask(), CL_INTERNAL_DM_CLEAR_PARAM_CACHE_REQ, message);
}
开发者ID:stephen-kun,项目名称:koovox_adk4.0,代码行数:7,代码来源:dm_baseband_cache.c


示例10: ConnectionSmRegisterIncomingService

void ConnectionSmRegisterIncomingService(dm_protocol_id protocol_id, uint32 channel, dm_security_in security)
{
    /* Check params are within allowed values - debug build only */
#ifdef CONNECTION_DEBUG_LIB
    if ((protocol_id != protocol_l2cap) && (protocol_id != protocol_rfcomm))
    {
        CL_DEBUG(("Out of range protocol id 0x%x\n", protocol_id));
    }

    if((protocol_id == protocol_rfcomm) && ((channel < RFCOMM_SERVER_CHANNEL_MIN) || (channel > RFCOMM_SERVER_CHANNEL_MAX)))
    {
        CL_DEBUG(("Out of range RFCOMM server channel 0x%lx\n", channel));
    }

    /* Are any bits other then valid dm_security_in bits are set. */
    if (security & ~sec_in_bitmask)
    {
        CL_DEBUG(("Invalid dm_security_in bits set 0x%x\n", (security & ~sec_in_bitmask)));
    }
    
#endif

    {
    MAKE_CL_MESSAGE(CL_INTERNAL_SM_REGISTER_REQ);
    message->protocol_id = protocol_id;
    message->channel = channel;
    message->outgoing_ok = FALSE;   
    message->security_level = security;
    message->psm = 0;
    MessageSend(connectionGetCmTask(), CL_INTERNAL_SM_REGISTER_REQ, message);
    }
}
开发者ID:stephen-kun,项目名称:csr8670,代码行数:32,代码来源:dm_security_service.c


示例11: ConnectionSyncRegister

void ConnectionSyncRegister(Task theAppTask)
{
	/* Send an internal register request message */
	MAKE_CL_MESSAGE(CL_INTERNAL_SYNC_REGISTER_REQ);
	message->theAppTask = theAppTask;
	MessageSend(connectionGetCmTask(), CL_INTERNAL_SYNC_REGISTER_REQ, message);
}
开发者ID:Duiesel,项目名称:thebirdfree-personal,代码行数:7,代码来源:dm_sync.c


示例12: ConnectionReadRemoteSuppFeatures

void ConnectionReadRemoteSuppFeatures(Task theAppTask, Sink sink)
{
	/* All requests are sent through the internal state handler */    
	MAKE_CL_MESSAGE(CL_INTERNAL_DM_READ_REMOTE_SUPP_FEAT_REQ);
	message->theAppTask = theAppTask;
	message->sink = sink;
	MessageSend(connectionGetCmTask(), CL_INTERNAL_DM_READ_REMOTE_SUPP_FEAT_REQ, message);
}
开发者ID:Duiesel,项目名称:thebirdfree-personal,代码行数:8,代码来源:dm_info_supp_features.c


示例13: ConnectionReadRemoteVersion

void ConnectionReadRemoteVersion(Task theAppTask, Sink sink)
{
    /* All requests are sent through the internal state handler */
    MAKE_CL_MESSAGE(CL_INTERNAL_DM_READ_REMOTE_VERSION_REQ);
    message->theAppTask = theAppTask;
    message->sink = sink;
    MessageSendConditionallyOnTask(connectionGetCmTask(), CL_INTERNAL_DM_READ_REMOTE_VERSION_REQ, message, &theCm.infoState.stateInfoLock);
}
开发者ID:Duiesel,项目名称:thebirdfree-personal,代码行数:8,代码来源:dm_info_remote_version.c


示例14: ConnectionL2capDisconnectResponse

void ConnectionL2capDisconnectResponse(uint8 identifier, Sink sink)
{
	/* Send an internal message */
	MAKE_CL_MESSAGE(CL_INTERNAL_L2CAP_DISCONNECT_RSP);
    message->identifier = identifier;
	message->sink = sink;
	MessageSend(connectionGetCmTask(), CL_INTERNAL_L2CAP_DISCONNECT_RSP, message);
}
开发者ID:stephen-kun,项目名称:csr8670,代码行数:8,代码来源:l2cap.c


示例15: ConnectionL2capUnregisterRequest

void ConnectionL2capUnregisterRequest(Task appTask, uint16 psm)
{
    /* Send an internal message */
    MAKE_CL_MESSAGE(CL_INTERNAL_L2CAP_UNREGISTER_REQ);
    message->theAppTask = appTask;
    message->app_psm = psm;
    MessageSend(connectionGetCmTask(), CL_INTERNAL_L2CAP_UNREGISTER_REQ, message);
}
开发者ID:Duiesel,项目名称:thebirdfree-personal,代码行数:8,代码来源:ConnectionL2capUnregisterRequest.c


示例16: ConnectionL2capDisconnectRequest

void ConnectionL2capDisconnectRequest(Task appTask, Sink sink)
{
	/* Send an internal message */
	MAKE_CL_MESSAGE(CL_INTERNAL_L2CAP_DISCONNECT_REQ);
	message->theAppTask = appTask;	
	message->sink = sink;
	MessageSend(connectionGetCmTask(), CL_INTERNAL_L2CAP_DISCONNECT_REQ, message);
}
开发者ID:stephen-kun,项目名称:csr8670,代码行数:8,代码来源:l2cap.c


示例17: ConnectionSetLinkPolicy

void ConnectionSetLinkPolicy(Sink sink, uint16 size_power_table, lp_power_table const *power_table)
{
    MAKE_CL_MESSAGE(CL_INTERNAL_DM_SET_LINK_POLICY_REQ);
    message->sink = sink;
    message->size_power_table = size_power_table;
    message->power_table = power_table;
    MessageSend(connectionGetCmTask(), CL_INTERNAL_DM_SET_LINK_POLICY_REQ, message);
}
开发者ID:stephen-kun,项目名称:csr8670,代码行数:8,代码来源:dm_link_policy.c


示例18: ConnectionSmSetTrustLevel

void ConnectionSmSetTrustLevel(const bdaddr* bd_addr, uint16 trusted)
{
    /* Update the Trusted Device List */
    MAKE_CL_MESSAGE(CL_INTERNAL_SM_SET_TRUST_LEVEL_REQ)
	message->bd_addr = *bd_addr;
	message->trusted = trusted;
	MessageSend(connectionGetCmTask(), CL_INTERNAL_SM_SET_TRUST_LEVEL_REQ, message);
}
开发者ID:Duiesel,项目名称:thebirdfree-personal,代码行数:8,代码来源:ConnectionSmSetTrustLevel.c


示例19: ConnectionUnregisterServiceRecord

void ConnectionUnregisterServiceRecord(Task appTask, uint32 service_record_hdl)
{
	/* Create an internal message and send it to the state machine */
	MAKE_CL_MESSAGE(CL_INTERNAL_SDP_UNREGISTER_RECORD_REQ);
	message->theAppTask = appTask;
	message->service_handle = service_record_hdl;
	MessageSend(connectionGetCmTask(), CL_INTERNAL_SDP_UNREGISTER_RECORD_REQ, message);
}
开发者ID:stephen-kun,项目名称:koovox_adk4.0,代码行数:8,代码来源:sdp_register.c


示例20: ConnectionWriteCachedClockOffset

void ConnectionWriteCachedClockOffset(const bdaddr *addr, uint16 clk_offset)
{
    /* Send an internal message requesting this action */
    MAKE_CL_MESSAGE(CL_INTERNAL_DM_WRITE_CACHED_CLK_OFFSET_REQ);
    message->bd_addr = *addr;
    message->clock_offset = clk_offset;
    MessageSend(connectionGetCmTask(), CL_INTERNAL_DM_WRITE_CACHED_CLK_OFFSET_REQ, message);
}
开发者ID:stephen-kun,项目名称:csr8670,代码行数:8,代码来源:dm_baseband_cache.c



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ MAKE_HRESULT函数代码示例发布时间:2022-05-30
下一篇:
C++ MAKE_CLASS函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap