Am 05.10.2012 10:51, schrieb Luca Sanna:
the code is output the error of the ubuntu

from bluetooth import *

[...]

nearby_devices = discover_devices()

[...]

the error

luca@luca-XPS-M1330:~/py-temperature/py-temperature$ python bluetooth.py
Traceback (most recent call last):
   File "bluetooth.py", line 14, in <module>
     from bluetooth import *
   File "/home/luca/py-temperature/py-temperature/bluetooth.py", line 19, in 
<module>
     nearby_devices = discover_devices()
NameError: name 'discover_devices' is not defined

The module "bluetooth" doesn't export any function called discover_devices(). You could try "dir(bluetooth)" or "help(bluetooth)" (do that from an interactive prompt) to find out what is in there. I don't know why you expect such a function there, if it is mentioned in the documentation or example code that would be a bug.

Uli

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to