Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>I posted a response to this earlier but it seems never to have appeared! :-(</p> <p>Anyway, I'm the maintainer of the 32feet.NET library and the author of the Widcomm support. Firstly, as far as I know the license should not be a problem for commercial distribution. See Peter Foot's comment at <a href="http://32feet.net/forums/t/2289.aspx" rel="nofollow noreferrer">http://32feet.net/forums/t/2289.aspx</a>:</p> <blockquote> <p>"32feet.NET is free for commercial or non-commercial use. If you use the binaries you can just use the library as-is, if you make modifications to the source you need to include the 32feet.NET License.txt document and ensure the file headers are not modified/removed."</p> </blockquote> <p>I'll see if Peter can post a comment here to give certainty.</p> <p>Anyway, we haven't implemented support for the Widcomm virtual COM port functionality, (its certainly possible though no one has asked for it -- apart from yourself). I'm not a big fan of virtual COM ports. It always seems much easier to use a direct 'sockets' connection, rather than attempt to setup a COM port, and try to find what name it was created as[1], and then have to open a SerialPort to use it, and then if the connection is lost one doesn't know and have simply to keep retrying... Its so much easier just to do the following:</p> <pre><code>Dim addr As BluetoothAddress _ = BluetoothAddress.Parse("001122334455") ' Dim ep As New BluetoothEndPoint(addr, BluetoothService.SerialPort) Dim cli As New BluetoothClient cli.Connect(ep) Dim peerStream As Stream = cli.GetStream() peerStream.Write/Read ... </code></pre> <p>See more at <a href="http://www.alanjmcf.me.uk/comms/bluetooth/32feet.NET%20--%20User%20Guide.html" rel="nofollow noreferrer">http://www.alanjmcf.me.uk/comms/bluetooth/32feet.NET%20--%20User%20Guide.html</a></p> <p>To answer your specific Widcomm questions. Multiple instances of a Bluetooth service can be created, i.e. multiple SPP services (each using the SPP Service Class Id), each can supply a Service Name attribute to allow clients to select between them. In most cases it won't be necessary, so just pass null or zero-length string -- the Widcomm SDK docs don't say what's allowed. As to the Window handles, Widcomm uses C++ virtual methods (yuk -- this makes <em>direct</em> P/Invoking mostly impossible) to implement events/callbacks, presumably Mr Figueira's code converts those callbacks into Window messages.</p> <p>[1] Creating Bluetooth virtual COM ports is not straightforward. On MSFT+Win32, one isn't told what name was selected for the COM port! On MSFT+WM the official API doesn't work well on many device types. And our unofficial method of doing it requires a reboot IIRC. :-(</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload