CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2008

    How to identify which COM ports are connected to BlueTooth devices?

    Hi All

    I'm wondering if there is a way to know, using a C# program, among my COM ports which are connected to BlueTooth devices?

    For example, let us assume that of my ports 1 through 9, the COM ports 7 and 8 are connected to some type of BlueTooth device. So I want my C# program to scan all my COM ports, and indicate to me that ports 7 and 8 are connected to BlueTooth devices.

    How can I achieve this goal? Specially code samples would be highly appreciated.

    Thank you in advance!

  2. #2
    Join Date
    Aug 2008

    Re: How to identify which COM ports are connected to BlueTooth devices?


    If you are able to program the bluetooth device, then you need to write a function which recieves a ping query from your PC and send the answer to it.

    For e.g.:
    You get the ports on your computer and then sends query to each port (preferrably keyed one) and the port which sends you the correct answer is conencted with a BT device.

    If you are not in condition to program the device, then just read the specification of the BT-stack. There must be some function in the API for handshake.


Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Windows Mobile Development Center

Click Here to Expand Forum to Full Width

On-Demand Webinars (sponsored)

We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.