onConnectionLost

open fun onConnectionLost(peripheral: MockPeripheral, reason: DisconnectionReason)

Called when the connection is lost.

Parameters

peripheral

The peripheral the event is for. It can be used to simulate its behavior.

reason

The reason for the disconnection.