Instance Method

centralManager:didFailToConnectPeripheral:error:

Invoked when the central manager fails to create a connection with a peripheral.

Declaration

- (void)centralManager:(CBCentralManager *)central didFailToConnectPeripheral:(CBPeripheral *)peripheral error:(NSError *)error;

Parameters

central

The central manager providing this information.

peripheral

The peripheral that failed to connect.

error

The cause of the failure.

Discussion

This method is invoked when a connection initiated via the connectPeripheral:options: method fails to complete. Because connection attempts do not time out, a failed connection usually indicates a transient issue, in which case you may attempt to connect to the peripheral again.

See Also

Monitoring Connections with Peripherals

- centralManager:didConnectPeripheral:

Invoked when a connection is successfully created with a peripheral.

- centralManager:didDisconnectPeripheral:error:

Invoked when an existing connection with a peripheral is torn down.