Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(17)  |  Call(17)  |  Derive(0)  |  Import(0)

src/p/y/PyBluez-0.20/examples/advanced/write-inquiry-scan.py   PyBluez(Download)
dev_id = 0
try:
    sock = bluez.hci_open_dev(dev_id)
except:
    print("error accessing bluetooth device...")

src/p/y/PyBluez-0.20/examples/advanced/read-local-bdaddr.py   PyBluez(Download)
if __name__ == "__main__":
    dev_id = 0
    hci_sock = _bt.hci_open_dev(dev_id)
    bdaddr = read_local_bdaddr(hci_sock)
    print(bdaddr)

src/p/y/PyBluez-0.20/examples/advanced/inquiry-with-rssi.py   PyBluez(Download)
dev_id = 0
try:
    sock = bluez.hci_open_dev(dev_id)
except:
    print("error accessing bluetooth device...")

src/p/y/PyBluez-0.20/examples/advanced/l2-unreliable-client.py   PyBluez(Download)
def write_flush_timeout( addr, timeout ):
    hci_sock = bt.hci_open_dev()
    # get the ACL connection handle to the remote device
    handle = __get_acl_conn_handle(hci_sock, addr)
    pkt = struct.pack("HH", handle, bt.htobs(timeout))
def read_flush_timeout( addr ):
    hci_sock = bt.hci_open_dev()
    # get the ACL connection handle to the remote device
    handle = __get_acl_conn_handle(hci_sock, addr)
    pkt = struct.pack("H", handle)

src/p/y/PyBluez-0.20/bluetooth/bluez.py   PyBluez(Download)
def _gethcisock (device_id = -1):
    try:
        sock = _bt.hci_open_dev (device_id)
    except:
        raise BluetoothError ("error accessing bluetooth device")
def _write_flush_timeout (addr, timeout):
    hci_sock = _bt.hci_open_dev ()
    # get the ACL connection handle to the remote device
    handle = _get_acl_conn_handle (hci_sock, addr)
    # XXX should this be "<HH"
def _read_flush_timeout (addr):
    hci_sock = _bt.hci_open_dev ()
    # get the ACL connection handle to the remote device
    handle = _get_acl_conn_handle (hci_sock, addr)
    # XXX should this be "<H"?

src/g/r/greenaddress-pos-tools-HEAD/bluetoothreceiver.py   greenaddress-pos-tools(Download)
    def find_local_bdaddr(self):
        dev_id = 0
        hci_sock = _bt.hci_open_dev(dev_id)
 
        old_filter = hci_sock.getsockopt( _bt.SOL_HCI, _bt.HCI_FILTER, 14)

src/p/y/PyMetaWatch-HEAD/inquiry-with-rssi.py   PyMetaWatch(Download)
dev_id = 0
try:
    sock = bluez.hci_open_dev(dev_id)
except:
    print "error accessing bluetooth device..."

src/p/y/PyMetaWatch-HEAD/range.py   PyMetaWatch(Download)
	    dev_id = 0
	    try:
		self.sock_monitor = bluez.hci_open_dev(dev_id)
	    except:
		print "error accessing bluetooth device..."

src/p/y/PyMetaWatch-HEAD/medic.py   PyMetaWatch(Download)
	    dev_id = 0
	    try:
		self.sock_monitor = bluez.hci_open_dev(dev_id)
	    except:
		print "error accessing bluetooth device..."

src/a/i/AIRi-HEAD/python/airi/twisted_bluetooth/bluez.py   AIRi(Download)
def setupSCO():
    # check voice settings. switch to S16 LE mono 8kHz CVSD if needed
    hci_sock=bt.hci_open_dev()
    response = bt.hci_send_req(hci_sock, bt.OGF_HOST_CTL, 
            bt.OCF_READ_VOICE_SETTING, bt.EVT_CMD_COMPLETE, 3)

  1 | 2  Next