From ba5e2965d7703ec1c80685efb0f81e752d5409c8 Mon Sep 17 00:00:00 2001 From: sienna1022 <81303793+sienna1022@users.noreply.github.com> Date: Mon, 17 May 2021 23:36:25 +0900 Subject: [PATCH] Update doit.py ord(c) --> c ord() doesn't work at Python3....plz change for me I have a trouble...sos --- android/doit.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/android/doit.py b/android/doit.py index 11434fb..5d9767e 100644 --- a/android/doit.py +++ b/android/doit.py @@ -76,7 +76,7 @@ def set_bt_name(payload, src_hci, src, dst): def set_rand_bdaddr(src_hci): - addr = ['%02x' % (ord(c),) for c in os.urandom(6)] + addr = ['%02x' % c for c in os.urandom(6)] # NOTW: works only with CSR bluetooth adapters! os.system('sudo bccmd -d %s psset -r bdaddr 0x%s 0x00 0x%s 0x%s 0x%s 0x00 0x%s 0x%s' % (src_hci, addr[3], addr[5], addr[4], addr[2], addr[1], addr[0]))