Bluetooth 有程式可以測試嗎 |
答題得分者是:axsoft
|
kraen
一般會員 發表:5 回覆:1 積分:1 註冊:2003-12-01 發送簡訊給我 |
||
axsoft
版主 發表:681 回覆:1056 積分:969 註冊:2002-03-13 發送簡訊給我 |
http://windowssdk.msdn.microsoft.com/en-us/library/ms678239.aspx Bluetooth
Bluetooth Functions
<!--Content type: PSDK_1. Transform: psdk2mtps.xslt.--> <!---->
The functions in this section are used for managing Bluetooth devices and services.
Bluetooth is also supported by using the Windows Sockets programming interface. For more information about programming Bluetooth by using the Windows Sockets interface, see BluetoothAuthenticateDevice |
Sends an authentication request to a remote Bluetooth device. |
BluetoothDisplayDeviceProperties | Invokes the Control Panel device information property sheet. | |
BluetoothEnableIncomingConnections | Modifies whether a local Bluetooth radio accepts incoming connections. | |
BluetoothFindDeviceClose | Closes an enumeration handle that is associated with a device query. | |
BluetoothFindFirstRadio | Begins the enumeration of local Bluetooth radios. | |
BluetoothFindNextRadio | Finds the next Bluetooth radio. | |
BluetoothGetDeviceInfo | Retrieves information about a remote Bluetooth device. The Bluetooth device must have been previously identified through a successful device inquiry function call. | |
BluetoothIsConnectable | Determines whether a Bluetooth radio or radios is connectable. | |
BluetoothRegisterForAuthentication | Registers a callback function that is called when a particular Bluetooth device requests authentication. | |
BluetoothSdpEnumAttributes | Enumerates through the SDP record stream and calls the callback function for each attribute in the record. | |
BluetoothSdpGetContainerElementData | Iterates over a container stream and returns each element that is contained within the container element. | |
BluetoothSdpGetString | Converts a raw string that is embedded in the SDP record into a Unicode string. | |
BluetoothSelectDevicesFree | Frees resources associated with a previous call to the BluetoothSelectDevices function. | |
BluetoothSetServiceState | Enables or disables services for a Bluetooth device. | |
BluetoothUpdateDeviceRecord | Updates the local computer cache about a Bluetooth device. |
int WSAStartup( WORD wVersionRequested, LPWSADATA lpWSAData );
Error code | Meaning |
---|---|
WSASYSNOTREADY | Indicates that the underlying network subsystem is not ready for network communication. |
WSAVERNOTSUPPORTED | The version of Windows Sockets support requested is not provided by this particular Windows Sockets implementation. |
WSAEINPROGRESS | A blocking Windows Sockets 1.1 operation is in progress. |
WSAEPROCLIM | Limit on the number of tasks supported by the Windows Sockets implementation has been reached. |
WSAEFAULT | The lpWSAData is not a valid pointer. |
App versions | DLL versions | wVersion requested |
wVersion | wHigh version |
End result |
---|---|---|---|---|---|
1.1 | 1.1 | 1.1 | 1.1 | 1.1 | use 1.1 |
1.0 1.1 | 1.0 | 1.1 | 1.0 | 1.0 | use 1.0 |
1.0 | 1.0 1.1 | 1.0 | 1.0 | 1.1 | use 1.0 |
1.1 | 1.0 1.1 | 1.1 | 1.1 | 1.1 | use 1.1 |
1.1 | 1.0 | 1.1 | 1.0 | 1.0 | Application fails |
1.0 | 1.1 | 1.0 | --- | --- | WSAVERNOTSUPPORTED |
1.0 1.1 | 1.0 1.1 | 1.1 | 1.1 | 1.1 | use 1.1 |
1.1 2.0 | 1.1 | 2.0 | 1.1 | 1.1 | use 1.1 |
2.0 | 2.0 | 2.0 | 2.0 | 2.0 | use 2.0 |
WORD wVersionRequested; WSADATA wsaData; int err; wVersionRequested = MAKEWORD( 2, 2 ); err = WSAStartup( wVersionRequested, &wsaData ); if ( err != 0 ) { /* Tell the user that we could not find a usable */ /* WinSock DLL. */ return; } /* Confirm that the WinSock DLL supports 2.2.*/ /* Note that if the DLL supports versions greater */ /* than 2.2 in addition to 2.2, it will still return */ /* 2.2 in wVersion since that is the version we */ /* requested. */ if ( LOBYTE( wsaData.wVersion ) != 2 || HIBYTE( wsaData.wVersion ) != 2 ) { /* Tell the user that we could not find a usable */ /* WinSock DLL. */ WSACleanup( ); return; } /* The WinSock DLL is acceptable. Proceed. */
Client | Requires Windows Vista, Windows XP, Windows 2000 Professional, Windows NT Workstation, Windows Me, Windows 98, or Windows 95. |
---|---|
Server | Requires Windows Server "Longhorn", Windows Server 2003, Windows 2000 Server, or Windows NT Server. |
Header |
Declared in Winsock2.h.
|
Library |
Use Ws2_32.lib.
|
DLL | Requires Ws2_32.dll. |
本站聲明 |
1. 本論壇為無營利行為之開放平台,所有文章都是由網友自行張貼,如牽涉到法律糾紛一切與本站無關。 2. 假如網友發表之內容涉及侵權,而損及您的利益,請立即通知版主刪除。 3. 請勿批評中華民國元首及政府或批評各政黨,是藍是綠本站無權干涉,但這裡不是政治性論壇! |