Author Topic: Discovery events not firing  (Read 16329 times)

TrevorDrawbridge

  • Guest
Discovery events not firing
« on: November 23, 2018, 08:13:00 PM »
I am developing a simple vb.net console project, but am unable to get the DiscoveryStarted, DeviceFound or DiscoveryCompleted events to fire. The AfterOpen event does fire after which I start discovery. The Bluetooth Manager example works correctly. The code is attached together with the output produced on the console when run. What am I doing wrong?

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Discovery events not firing
« Reply #1 on: November 23, 2018, 09:13:46 PM »
Hello,

Bluetooth Framework includes Console demo application that shows how to use it in console. In fact there are 2 ways. The simple one (shown in demo) is to switch to "synchronouse" mode.

So you have to add this line

wclMessageBroadcaster.SetSyncMethod(wclMessageSynchronizationKind.skNone)

as first code line of your Main() function.

More information about Events in Bluetooth Framework.

TrevorDrawbridge

  • Guest
Re: Discovery events not firing
« Reply #2 on: November 24, 2018, 01:46:11 AM »
Thanks Mike.

 

Sitemap 1 2 3 4 5 6 7