examples/bluetooth: Update to use positional-only args to irq().
To match 6a6a5f9e151473bdcc1d14725d680691ff665a82.
This commit is contained in:
parent
9123b67d64
commit
0fd0eb00aa
@ -45,7 +45,7 @@ class BLESimpleCentral:
|
||||
def __init__(self, ble):
|
||||
self._ble = ble
|
||||
self._ble.active(True)
|
||||
self._ble.irq(handler=self._irq)
|
||||
self._ble.irq(self._irq)
|
||||
|
||||
self._reset()
|
||||
|
||||
|
@ -31,7 +31,7 @@ class BLESimplePeripheral:
|
||||
def __init__(self, ble, name="mpy-uart"):
|
||||
self._ble = ble
|
||||
self._ble.active(True)
|
||||
self._ble.irq(handler=self._irq)
|
||||
self._ble.irq(self._irq)
|
||||
((self._handle_tx, self._handle_rx),) = self._ble.gatts_register_services((_UART_SERVICE,))
|
||||
self._connections = set()
|
||||
self._write_callback = None
|
||||
|
@ -35,7 +35,7 @@ class BLETemperature:
|
||||
def __init__(self, ble, name="mpy-temp"):
|
||||
self._ble = ble
|
||||
self._ble.active(True)
|
||||
self._ble.irq(handler=self._irq)
|
||||
self._ble.irq(self._irq)
|
||||
((self._handle,),) = self._ble.gatts_register_services((_ENV_SENSE_SERVICE,))
|
||||
self._connections = set()
|
||||
self._payload = advertising_payload(
|
||||
|
@ -56,7 +56,7 @@ class BLETemperatureCentral:
|
||||
def __init__(self, ble):
|
||||
self._ble = ble
|
||||
self._ble.active(True)
|
||||
self._ble.irq(handler=self._irq)
|
||||
self._ble.irq(self._irq)
|
||||
|
||||
self._reset()
|
||||
|
||||
|
@ -31,7 +31,7 @@ class BLEUART:
|
||||
def __init__(self, ble, name="mpy-uart", rxbuf=100):
|
||||
self._ble = ble
|
||||
self._ble.active(True)
|
||||
self._ble.irq(handler=self._irq)
|
||||
self._ble.irq(self._irq)
|
||||
((self._tx_handle, self._rx_handle),) = self._ble.gatts_register_services((_UART_SERVICE,))
|
||||
# Increase the size of the rx buffer and enable append mode.
|
||||
self._ble.gatts_set_buffer(self._rx_handle, rxbuf, True)
|
||||
|
Loading…
x
Reference in New Issue
Block a user