aioble/examples/temp_sensor.py: Wait forever for client to disconnect.

This sets the disconnected timeout to None, so that the peripheral waits
forever for the client to disconnect.  Previously the peripheral would
abort the connection after 60 seconds (because that's the default timeout).

Signed-off-by: Stephen More <stephen.more@gmail.com>
pull/835/head
Stephen More 2024-03-25 16:10:09 -04:00 zatwierdzone przez Damien George
rodzic 191494ede7
commit d4362d5cc3
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -56,7 +56,7 @@ async def peripheral_task():
appearance=_ADV_APPEARANCE_GENERIC_THERMOMETER,
) as connection:
print("Connection from", connection.device)
await connection.disconnected()
await connection.disconnected(timeout_ms=None)
# Run both tasks.