Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #75941

Re: attendance system in pybluez

Date 2014-08-09 20:07 -0700
From luofeiyu <elearn2014@gmail.com>
Subject Re: attendance system in pybluez
References <mailman.12789.1407584254.18130.python-list@python.org> <53e60ba8$0$29968$c3e8da3$5496439d@news.astraweb.com>
Newsgroups comp.lang.python
Message-ID <mailman.12790.1407586138.18130.python-list@python.org> (permalink)

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

in the http://homepages.ius.edu/rwisman/C490/html/PythonandBluetooth.htm

*Discovery*

    The address and name of enabled devices within range can be
    discovered by other Bluetooth devices. Discovery can take some time
    to complete, given that radio communications is unreliable. The
    following displays address and name of all enabled devices nearby.

        from bluetooth import *

        print "performing inquiry..."

        *nearby_devices = discover_devices(lookup_names = True)*

        print "found %d devices" % len(nearby_devices)

        for name, addr in nearby_devices:
              print " %s - %s" % (addr, name)

        performing inquiry...
        found 2 devices
        Ray's Nokia - 00:12:D2:5A:BD:E4
        Ray's MacBook - 00:1E:C2:93:DA:6F



On 8/9/2014 4:53 AM, Steven D'Aprano wrote:
> luofeiyu wrote:
>
>> I want to write a program to help my teacher to take attendence.
>>
>> There are 300 students in a big room,everyone has android phone.
> If your students allow strange devices to connect to their android phones,
> then they won't remain their android phones for very long. They will belong
> to whatever hacker takes control of them first.
>
> http://blog.kaspersky.com/bluetooth-security/
>
>
>> I have matched them with my pc in win7 .
>> when all of them seated on the classroom,
>>
>> import bluetooth
>> nearby_devices = bluetooth.discover_devices(lookup_names = True)
>> print("found %d devices" % len(nearby_devices))
>>
>>
>> The function can discover all of them ? 300 bluetooth mac address?
> You will have to ask the author of the bluetooth module. Where did you find
> it? Does it come with documentation? Did you read it?
>
>
>

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

attendance system in pybluez luofeiyu <elearn2014@gmail.com> - 2014-08-09 14:01 -0700
  Re: attendance system in pybluez Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-08-09 21:53 +1000
    Re: attendance system in pybluez luofeiyu <elearn2014@gmail.com> - 2014-08-09 20:07 -0700
    Re: attendance system in pybluez Michael Torrie <torriem@gmail.com> - 2014-08-11 08:02 -0600

csiph-web