LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Bluetooth Discover

I have an application (LV 8.20) that communicates with an industrial device using Bluetooth. The software filters out unwated devices (phones, PDAs etc) and only returns devices that have a certain device name (eg 'product_xyz_111').

Whenever the software is run for the first time (after a PC reboot), the Bloothooth Discover function only returns the Device Addresses and not the Device Names. Every other time the software is run, it returns both the Device Names and Device Addresses.

Has anybody else observed this behaviour, (or have any suggestions)?

Thanks

Si
0 Kudos
Message 1 of 13
(4,732 Views)

Hi there,

I'm seeing exactly the same thing.  When a device is discovereed for the first time using this vi, the devices name isn't found.  After this the name is found every time.

However if you then turn the device off and on again, the name dissapears from the discover.  Not quite sure of a way around this yet.  I believe it might be a Windows driver "feature" as I have seen this behaviour before.

Workarounds/ideas:

I can only suggest running the discover twice at this stage.  I'll look into it more.

AdamB

Applications Engineering Team Leader | National Instruments | UK & Ireland
0 Kudos
Message 2 of 13
(4,716 Views)
This is still an outstanding issue within my project and now that it is being distributed, I have customers complaining about it.

Has anyone found a workaround for this yet?
0 Kudos
Message 3 of 13
(4,385 Views)

Hello,

 

I tried using the workaround above of calling the discovery twice if all names were not returned:

 

simpleBluetoothWorkaround.PNG

But I found it wasn't totally reliable, it helped it return about 75% of names where before it was 0%. But its fairly quick.

 

I have another workaround that gives an even higher return (100% on my test system) but at the expense of time. This took 90 seconds to get the names of 3 devices:

 

simpleBluetoothWorkaround2.PNG

All other cases are just wired through. That new function is Bluetooth RFCOMM Service Discovery, and it usually always forces a valid name to be returned (as well as services so potentially you could store this data for use in the program later to make it slightly more efficient if the device you wanted to use was one of the ones that didn't return a name).

 

I hope this helps!

0 Kudos
Message 4 of 13
(4,369 Views)
Hi Mark,

That does solve the problem (sort of). I now get units on the first discover. Like you say, speed of discovery is compromised.

I use this method for the first discover and then do a standard discover for subsequent searches.

Has this problem been reported to R&D? I first discovered it in LV8.5 and it is still in LV2009.

Thanks

Simon
0 Kudos
Message 5 of 13
(4,332 Views)

Hello,

 

I will report this, however I don't think there is much to be done about it for the reason below:

 

I believe its an issue with the bluetooth drivers rather than LabVIEW, my evidence for this is that if I load the Bluesoleil panel and do the same thing after a reboot (discover devices) it too reports the addresses and not the names. I have to query the services on the device to get its name (which is what gave me the idea for the workaround.

 

 

0 Kudos
Message 6 of 13
(4,328 Views)
Does the Bluesoleil driver work with LabVIEW? If it does it would appear to overcome the limited Bluetooth compatibility within LabVIEW.

Thanks

Simon
Message Edited by ssk on 09-23-2009 05:58 AM
0 Kudos
Message 7 of 13
(4,324 Views)
This was reported to R&D (#186017) for further investigation.
0 Kudos
Message 8 of 13
(4,322 Views)

ssk wrote:
Does the Bluesoleil driver work with LabVIEW? If it does it would appear to overcome the limited Bluetooth compatibility within LabVIEW.

Thanks

Simon
 
For me, it doesn't have any different results to LabVIEW bluetooth (you still have to query services), however results may vary. I haven't tried running LabVIEW with the bluesoleil driver, this was just an observation on my personal laptop.
0 Kudos
Message 9 of 13
(4,320 Views)

No, bluesoleil driver doesnt work with LabVIEW!!! The reason is , LabVIEW works with windows drivers only

 i tried discovering bluetooth by installing te bluesoleil software but wasnt able to make the bluetooth work.

but as soon as i uninstalled the bluesoleil drivers  and allowed windows to install the bluetooth on its own, my Bluetooth was getting discovered with adddress and name 

Somil Gautam
Think Weird
0 Kudos
Message 10 of 13
(4,315 Views)