title: Can't discover service created with PyBluez
body: <p>I'm trying to make a simple bluetooth service on Python using PyBluez and looks like it works, but I can't find that service with neither my phone, nor with PyBluez itself. I'm able to discovery my phone bluetooth when I do search with PyBluez, but not the server created with PyBluez. What's wrong with the code bellow?</p>
  
  <pre><code>import bluetooth
  
  server_sock=bluetooth.BluetoothSocket( bluetooth.RFCOMM )
  
  port = 0 # automatically choose port
  server_sock.bind(("",port))
  server_sock.listen(1)
  
  uuid = "1e0ca4ea-299d-4335-93eb-27fcfe7fa848"
  bluetooth.advertise_service( server_sock, "FooBar Service", uuid )
  
  client_sock,address = server_sock.accept()
  print "Accepted connection from ",address
  
  data = client_sock.recv(1024)
  print "received [%s]" % data
  
  client_sock.close()
  server_sock.close()
  </code></pre>
  
  <p>I'm enabling service visibility with <code>hciconfig hci0 piscan</code>, so my phone is able to find a bluetooth device with name of my PC, but not the service I've created (I mean <code>FooBar Service</code>).
  Also I can't find my service using <code>sdptool browse</code> command.</p>
  
  <p>Do I misunderstand something? How to connect to the service I've created?</p>
  
  <p><strong>update</strong></p>
  
  <p>Here is the below mentioned code result executed on my Windows 7 PC with D-Link Bluetooth adapter.</p>
  
  <p><img src="https://i.stack.imgur.com/uTdyq.png" alt="enter image description here"></p>
  
  <p><strong>update</strong></p>
  
  <p>Finally it worked when I run client from another computer. It doesn't work locally, but why I can't discover this service from any device? Is there anything special I should do to make it behave like a normal Bluetooth service?</p>