1

I'm having some trouble trying to play around with bluetooth on my hp laptop (probook 4320s, windows 7 64 bit). I'm guessing that this is a result of icompatible drivers but I just can't figure this out on my own.

I've tried to get this to work on python and c#. On Python, using pybluez:

import bluetooth
print bluetooth.discover_devices()

And on C#, using the 32feet library:

BluetoothClient bc = new BluetoothClient();
BluetoothDeviceInfo[] array = bc.DiscoverDevices();

I will describe the steps Iv'e performed so far by myself in order to solve this so you guys might get a clearer picture:

  1. Made sure that bluetooth works on laptop - indeed it is able to locate devices in the "My Bluetooth" laptop.
  2. Ran the python code, got IOError: No Bluetooth adapter detected.
  3. Ran the C# code, got an PlatformNotSupportedException.
  4. Found out that my current driver Ratlink Motoroal BC4 Bluetooth 3.0+HS Adapter which appears under the bluetooth radios in the device manager might not support these actions so I chose to update the driver on the windows device manager and chose "Generic Bluetooth Adapter". At this point I have both "Generic Bluetooth Adapter" and "Microsoft Bluetooth Enumerator" Under the Bluetooth Radios tab in the device manager.
  5. Run python code, same error.
  6. Run c# code, no exception, however no devices are located. The result of DiscoverDevices is always empty.
  7. Also unable to find bluetooth devices on the "My Bluetooth" folder on the laptop. Getting "Bluetooth radio device unavailable".
  8. After uninstalling and installing randomly, I accidentally got a "Bluetooth Devices" bullet and a Bluetooth Radios bullet in the device Manager. The first holds the Motorolla driver and the other one holds Microsoft Bluetooth Enumerator. The same errors as (5) and (6) persist.

Iv'e been fiddling with different drivers from the hp website without any luck. Also, the code works on two non-hp laptops and fails on a different hp laptop (a pavilion type). Iv'e noticed that other laptops only have the bluetooth radios bullet which contains both the native bluetooth device and a Microsoft enumerator device.

Is there any hope for bluetooth programming on an hp laptop? What am I doing wrong?

Thank you guys in advance

Maor Veitsman
  • 1,544
  • 9
  • 21

1 Answers1

0

First off all, you should know that there are several different Bluetooth stacks. For example sometimes code that is running perfectly on computer with a Toshiba stack wont run properly on computer with Microsoft stack.

Second, I advise you to use 32Feet library.

InTheHand.Net.Sockets.BluetoothClient _BTClient = new InTheHand.Net.Sockets.BluetoothClient();
_BTClient.InquiryLength = new TimeSpan(0, 0, 5);
InTheHand.Net.Sockets.BluetoothDeviceInfo[] _clientDevices = _BTClient.DiscoverDevices(20 ,authenticated, remembered, unknown);
_BTClient.Dispose();
_BTClient = null;

I am using the BTFramework that is not free to use. Good luck

RcMan
  • 893
  • 8
  • 16