blatann.examples.peripheral_rssi module

This is a simple example which demonstrates enabling RSSI updates for active connections.

blatann.examples.peripheral_rssi.on_rssi_changed(peer, rssi)

Event callback for when the RSSI with the central device changes by the configured dBm threshold

Parameters
  • peer – The peer object

  • rssi (int) – The new RSSI for the connection

blatann.examples.peripheral_rssi.on_connect(peer, event_args)

Event callback for when a central device connects to us

Parameters
blatann.examples.peripheral_rssi.on_disconnect(peer, event_args)

Event callback for when the client disconnects from us (or when we disconnect from the client)

Parameters
blatann.examples.peripheral_rssi.main(serial_port)