tests/multi_bluetooth: Update to new config('mac') behaviour.

pull/6405/head
Jim Mussared 2020-08-14 15:16:29 +10:00 zatwierdzone przez Damien George
rodzic c4af714d58
commit 26b66804e9
6 zmienionych plików z 7 dodań i 7 usunięć

Wyświetl plik

@ -146,7 +146,7 @@ def instance1():
try:
# Connect to peripheral and then disconnect.
print("gap_connect")
ble.gap_connect(0, BDADDR)
ble.gap_connect(*BDADDR)
if not wait_for_event(_IRQ_PERIPHERAL_CONNECT, TIMEOUT_MS):
return
conn_handle, _, _ = waiting_data

Wyświetl plik

@ -36,7 +36,7 @@ def instance1():
def irq(ev, data):
nonlocal finished, adv_types, adv_data
if ev == _IRQ_SCAN_RESULT:
if data[1] == BDADDR:
if data[0] == BDADDR[0] and data[1] == BDADDR[1]:
adv_types.add(data[2])
if adv_data is None:
adv_data = bytes(data[4])

Wyświetl plik

@ -76,7 +76,7 @@ def instance1():
try:
# Connect to peripheral and then disconnect.
print("gap_connect")
ble.gap_connect(0, BDADDR)
ble.gap_connect(*BDADDR)
if not wait_for_event(_IRQ_PERIPHERAL_CONNECT, TIMEOUT_MS):
return
print("gap_disconnect:", ble.gap_disconnect(waiting_data[0]))
@ -88,7 +88,7 @@ def instance1():
# Connect to peripheral and then let the peripheral disconnect us.
print("gap_connect")
ble.gap_connect(0, BDADDR)
ble.gap_connect(*BDADDR)
if not wait_for_event(_IRQ_PERIPHERAL_CONNECT, TIMEOUT_MS):
return
wait_for_event(_IRQ_PERIPHERAL_DISCONNECT, TIMEOUT_MS)

Wyświetl plik

@ -97,7 +97,7 @@ def instance1():
# Connect to peripheral.
print("gap_connect")
ble.gap_connect(0, BDADDR)
ble.gap_connect(*BDADDR)
if not wait_for_event(_IRQ_PERIPHERAL_CONNECT, TIMEOUT_MS):
return
conn_handle, _, _ = waiting_data

Wyświetl plik

@ -137,7 +137,7 @@ def instance1():
try:
# Connect to peripheral and then disconnect.
print("gap_connect")
ble.gap_connect(0, BDADDR)
ble.gap_connect(*BDADDR)
if not wait_for_event(_IRQ_PERIPHERAL_CONNECT, TIMEOUT_MS):
return
conn_handle, _, _ = waiting_data

Wyświetl plik

@ -85,7 +85,7 @@ def instance1():
try:
# Connect to peripheral and then disconnect.
print("gap_connect")
ble.gap_connect(0, BDADDR)
ble.gap_connect(*BDADDR)
if not wait_for_event(_IRQ_PERIPHERAL_CONNECT, TIMEOUT_MS):
return
conn_handle, _, _ = waiting_data