Author Topic: Problem with OnDiscoveryComplete event in service.  (Read 14871 times)

AntonM

  • Guest
Problem with OnDiscoveryComplete event in service.
« on: February 16, 2012, 06:25:11 AM »
Hi all,

I am writing windows service that must discover bluetooth devices but OnDiscoveryComplete event are not called correctly.
Some times it called with very long delay and pointer to device list is null, some times it not called.
I am using code from DiscoveryDemo to realize searching process.
Can somebody help me?

Offline Mike Petrichenko

  • Bluetooth Framework Developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 3675
  • Karma: 1000
    • Wireless Communication Libraries
Re: Problem with OnDiscoveryComplete event in service.
« Reply #1 on: February 16, 2012, 07:55:08 AM »
Hi,

Unfortunately WCL C++ Demos don't include service demo but you can take a look on BluetoothConsole demo code to find out how to use WCL in service/console. In few words: you have to have windows message loop in your application to be able to process WCL events.

If you are OK with C#/VB.NET you can take a look on ServiceDemo from WCL .NET Edition.

 

Sitemap 1 2 3 4 5 6 7