Type Property

EAAccessoryDidConnect

A notification that is posted when an accessory becomes connected and available for your application to use.

Declaration

static let EAAccessoryDidConnect: NSNotification.Name

Discussion

The notification object is the shared accessory manager. The userInfo dictionary contains an EAAccessoryKey, whose value is an EAAccessory object representing the accessory that is now connected. If a Bluetooth accessory was selected by the user in the Bluetooth picker, this dictionary contains the EAAccessorySelectedKey key. Before delivery of this notification can occur, you must call the registerForLocalNotifications() method to let the system know you are interested in receiving this notification.

In some cases, the connection notification may be sent before authentication has completed, resulting in an empty protocolStrings array and a subsequent disconnection message. If this happens, another connection message is sent later, when authentication succeeds.

See Also

Monitoring Connection Status Changes

static let EAAccessoryDidDisconnect: NSNotification.Name

A notification that is posted when an accessory is disconnected and no longer available for your application to use.

let EAAccessoryKey: String

A key that indicates the accessory object whose status changed.

let EAAccessorySelectedKey: String

A key that indicates the accessory object that the user selected.