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

📄 btrfcommserver.h

📁 1、手持设备的机器人--服务器端; 2、通过蓝牙通讯;
💻 H
字号:
#ifndef BTRFCOMMSERVER_
#define BTRFCOMMSERVER_

/*
 * Copyright (c) 2004-2005 Mobile Robotics
 * http://mobilerobotics.sf.net
 *
 * File: BtRFCOMMServer.h
 * Author: Johan Johanson
 * Date: January 26, 2005
 * Updated: February 10, 2005
 *
 * Description: Builds upon BtServerBase
 * 				Defines an RFCOMM based abstract class
 *
*/

#include "BtServerBase.h"
#include "sections.h"

class BtRFCOMMServer : public BtServerBase
{
public:
	BtRFCOMMServer() EXT_SEG;
	virtual ~BtRFCOMMServer() EXT_SEG;

	virtual Boolean init(Char *serviceName, UInt16 maxNumClients, Boolean advanceCredit) EXT_SEG;
	virtual Boolean listen() EXT_SEG;
	
	// packet must be persistent, non-local
	virtual Boolean sendPacket(BtDataPacket *packet, UInt16 receiver) EXT_SEG;
	
	void advanceCredit(UInt8 credit, UInt16 link) EXT_SEG;

protected:
	virtual Boolean onConnectedInbound(BtLibSocketEventType *event) EXT_SEG;
	virtual Boolean onConnectRequest(BtLibSocketEventType *event) EXT_SEG;
	virtual Boolean onDisconnected(BtLibSocketEventType *event) EXT_SEG;
	
protected:
	Boolean advCredit;
};

#endif

⌨️ 快捷键说明

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