7

I'm trying to get started with this library: 32feet

I have a Broadcomm Bluetooth Stack and haven't been able to figure out how to get this library set up. When I run my code, I get:

Unhandled Exception: System.PlatformNotSupportedException: No supported Bluetooth protocol stack found.

After digging around on their site, I found this: Installation instructions

It says to copy the appropriate DLL's into the project and then run the Test32FeetWidcommWin32.exe. I've tried putting the files in every single folder in my Visual Studio project and then running that EXE, but I still get the same error. Initially I tried just adding the InTheHand.Net.Personal.dll file as a reference to my project, but that didn't work either.

What could I be doing wrong?

Mike Atlas
  • 8,193
  • 4
  • 46
  • 62
telkins
  • 10,440
  • 8
  • 52
  • 79
  • It sounds to me like the library you're trying to use isn't able to locate any compatible Bluetooth drivers on your development machine, despite your efforts. – Mike Atlas Jul 10 '12 at 15:10
  • Why not ask the library author for help? https://32feet.codeplex.com/discussions – Mike Atlas Jul 10 '12 at 15:10
  • @MikeAtlas I have gotten my Bluetooth drivers to work with C, C++, Java, and Python so I don't know why this library isn't working. I didn't notice the discussion area on that website so I will also post there. – telkins Jul 10 '12 at 15:18
  • You could try monitoring your application with [ProcMon](http://technet.microsoft.com/en-us/sysinternals/bb896645.aspx) to see where it's looking to find the DLL(s) and failing. Filter on your app name and result-failures. – Mike Atlas Jul 10 '12 at 15:54
  • What operating system are you using? – Security Hound Jul 10 '12 at 18:52
  • @Ramhound My target framework is ".NET Framework 4 Client Profile" if that is what you mean. And Win7 32-bit. – telkins Jul 10 '12 at 18:56

2 Answers2

8

It may also simply be that BlueTooth is not turned on in Windows.

I was using the .NET InTheHand library, and received this message only because BlueTooth was turned off in Windows, and resolved it by activating BlueTooth.

david.barkhuizen
  • 5,239
  • 4
  • 36
  • 38
3

I just solved this. I think the problem was an old reference in my project to the NETCF version of the DLL from when I was trying to brute-force a solution, so I wiped my project clean and then started adding everything again and it worked!

A helpful tool to those trying to figure out their problem with this is to copy and paste the app.config file into your release directory with the app you are creating, and change the name to <YOUREXENAME>.exe.config. When you then run your EXE file, it should create a more detailed trace file. For mine, I found that coredll.dll was the culprit by not loading and was masked by the Stack not supported exception. After an easy Google search I found the problem to be with NETCF.

edit: To be clear, after I cleaned out my project a bit I re-added the reference to the correct InTheHand.Net.Personal.dll file and also added the 32feetWidcomm.dll file to my Release folder.

telkins
  • 10,440
  • 8
  • 52
  • 79
  • How did you know that your reference is old. I'm just getting the same problem as you. Same exception. The reference is InTheHand.Net.Personal version 3.5.605.0. Is the last version from the 32 feet page. – Diego Unanue May 21 '14 at 13:08