onConnectionRequest

Called when a connection request is made to the mock peripheral.

By default, the connection request is accepted.

Return

The result of the connection request, by default ConnectionResult.Accept.

Parameters

peripheral

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

phy

The PHY used for connection.