×

Discussion Board

Results 1 to 3 of 3
  1. #1
    Registered User
    Join Date
    Nov 2007
    Posts
    10

    Detecting the nearest Bluetooth

    I have tried search but haven't found anything.

    Is there any way to detect the nearest Bluetooth device?

    I have made code like this:
    Code:
     x = time()
        try:
            b = socket.socket(socket.AF_BT, socket.SOCK_STREAM)
            b.connect((address,5))
            b.close()
        except:
            q = 1
        y = time()
        return y-x
    It return time how long it takes to connect to Bluetooth device with that address. Point is that it errors because of number 5.

    However this takes very long time.. especially if Bluetooth device isn't in area.
    I have tried make it stop connecting after X seconds but without success.

    Thanks in advance.

  2. #2
    Super Contributor
    Join Date
    Mar 2003
    Location
    Espoo, Finland
    Posts
    976

    Re: Detecting the nearest Bluetooth

    Quote Originally Posted by JereKuusela View Post
    I have tried search but haven't found anything.
    Is there any way to detect the nearest Bluetooth device?
    Let's start first by eliminating the basics:
    • Is there any near-by devices with "Bluetooth" set as "On"
    • Is that device's "My phone's visibility" set as "Shown to all"
    • Are you able to find that device with built-in S60 software


    Just making sure,

    --jouni

  3. #3
    Registered User
    Join Date
    Nov 2007
    Posts
    10

    Re: Detecting the nearest Bluetooth

    I mean I have tried search for solution. :P

    And yes, I can detect Bluetooth devices even with my code, it's just very slow because I don't know how to interrupt it.

    Cheers,
    Jere
    Last edited by JereKuusela; 2008-06-03 at 07:47.

Similar Threads

  1. Find Nearest Mobile Bluetooth Device
    By sevenhills in forum Symbian
    Replies: 4
    Last Post: 2008-04-17, 09:20
  2. How To Make The S60 Emulator See My USB Bluetooth Dongle ?
    By Mo7ammed_01 in forum Symbian Tools & SDKs
    Replies: 1
    Last Post: 2006-07-25, 00:14
  3. How To Make The S60 Emulator See My USB Bluetooth Dongle ?
    By Mo7ammed_01 in forum Symbian Networking & Messaging (Closed)
    Replies: 1
    Last Post: 2006-07-25, 00:12
  4. Detecting and initiating bluetooth pairing
    By GrahamDouglas in forum Symbian Networking & Messaging (Closed)
    Replies: 0
    Last Post: 2005-02-02, 10:53
  5. Nokia 7650 support Bluetooth audo?
    By ovjo12 in forum Bluetooth Technology
    Replies: 5
    Last Post: 2003-07-17, 18:50

Posting Permissions

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