RE: UDP over Bluetooth
- From: v-terryf@xxxxxxxxxxxxxxxxxxxx ("TerryFei")
- Date: Fri, 10 Mar 2006 02:39:25 GMT
Hi Norman,
Nice to see you!
IPsocket(AF_INET, SOCK_DGRAM, IPPROTO_UDP)
which doesn't say AF_BTH either. So maybe sockets accessing Bluetooth
directly have to be TCP, but sockets accessing Bluetooth indirectly via
Based on TCP/IP protocol, TCP and UDP are all in Transport Layer, incan be either UDP or TCP? Maybe something in Windows is emulating UDP on
top of TCP? Is this dependable?
another word, they are parallel and have not any dependence. Comparing with
TCP, UDP is simpler, faster and cheaper than TCP. UDP is connectionless and
unreliable which means that it does not establish a virtual circuit like
TCP. So in theory, there shouldn't be anything to emulating UDP on top of
TCP.
Best Regards,
Terry Fei [MSFT]
Microsoft Community Support
Get Secure! www.microsoft.com/security
--------------------
From: "Norman Diamond" <ndiamond@xxxxxxxxxxxxxxxx>microsoft.public.win32.programmer.networks:29236
Subject: UDP over Bluetooth
Date: Thu, 9 Mar 2006 16:58:02 +0900
Lines: 28
MIME-Version: 1.0
Content-Type: text/plain;
format=flowed;
charset="iso-2022-jp";
reply-type=original
Content-Transfer-Encoding: 7bit
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2670
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2670
Message-ID: <OyfP280QGHA.5728@xxxxxxxxxxxxxxxxxxxx>
Newsgroups: microsoft.public.win32.programmer.networks
NNTP-Posting-Host: p1185-ipad501marunouchi.tokyo.ocn.ne.jp 222.148.32.185
Path: TK2MSFTNGXA03.phx.gbl!TK2MSFTNGP08.phx.gbl!tk2msftngp13.phx.gbl
Xref: TK2MSFTNGXA03.phx.gbl
X-Tomcat-NG: microsoft.public.win32.programmer.networksNow,
I wrote some code that communicates between Windows XP and a device using
UDP over WiFi and it worked as expected. Next I changed the transport to
UDP over Bluetooth and it worked when I thought it wasn't supposed to.
is this configuration working because of an accident of undocumentedbluetooth/bluetooth_and_socket.asp
behaviour or did it sneak into the category of defined behaviour? If it's
undocumented then of course I have to fix it to use TCP when the transport
is Bluetooth.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/bluetooth/
nsock/socket_2.aspThe af parameter of the socket function is always set to AF_BTH for
Bluetooth sockets.
The type parameter of the socket function is always SOCK_STREAM;
SOCK_DGRAM sockets are not supported by Bluetooth.
For the protocol parameter, BTHPROTO_RFCOMM is the supported protocol.
For more information, see the Windows Sockets documentation in the
Platform SDK.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winsock/wi
doesn't seem to say now, but I thought I had previously read an assertion
there too that Bluetooth doesn't support UDP.
This is still the actual code:
socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP)
which doesn't say AF_BTH either. So maybe sockets accessing Bluetooth
directly have to be TCP, but sockets accessing Bluetooth indirectly via IP
can be either UDP or TCP? Maybe something in Windows is emulating UDP on
top of TCP? Is this dependable?
.
- References:
- UDP over Bluetooth
- From: Norman Diamond
- UDP over Bluetooth
- Prev by Date: Re: ICF SDK
- Next by Date: "Avoid Data Peeking in Winsock"
- Previous by thread: UDP over Bluetooth
- Next by thread: Re: UDP over Bluetooth
- Index(es):
Relevant Pages
|
Loading