Post not yet marked as solved
Post marked as unsolved with 5 replies, 1,280 views
var peerIdentifier = peripheral!.identifier
do {
configuration = try NINearbyAccessoryConfiguration(accessoryData: accessoryData, bluetoothPeerIdentifier: peerIdentifier)
}catch{
return
}
cacheToken(configuration!.accessoryDiscoveryToken, accessoryName: devicename)
nisession?.run(configuration!)
I configured the source as above, how do I receive Apple Shareable Configuration Data
sessionFailed : Error Domain=com.apple.NearbyInteraction Code=-5887 "NIERROR_SESSION_FAILED_DESCRIPTION" UserInfo={NSLocalizedRecoverySuggestion=NIERROR_SESSION_FAILED_RECOVERY_SUGGESTION, NSLocalizedDescription=NIERROR_SESSION_FAILED_DESCRIPTION, NSLocalizedFailureReason=This session object is invalidated. Dispose of it and create a new one instead.}