Protocol

NFCMiFareTag

An interface for interacting with a MIFARE tag.

Declaration

protocol NFCMiFareTag

Overview

The NFCTagReaderSessionDelegate receives an object that conforms to the NFCMiFareTag protocol when the NFCTagReaderSession detects a MIFARE-compatible tag. To interact with an ISO 7816-compliant MIFARE DESFire tag, such as an NFC Forum T4T tag platform NDEF tag, add the identifier D2760000850101 to the com.apple.developer.nfc.readersession.iso7816.select-identifiers array in your Info.plist file. When the reader session finds a tag matching this identifier, the session sends the delegate a tag object that conforms to the NFCISO7816Tag protocol.

For the delegate to receive the tag object, your app must include the Near Field Communication Tag Reader Session Formats Entitlement.

Topics

Getting Tag Information

var mifareFamily: NFCMiFareFamily

The MIFARE product family identifier for the tag.

Required.

enum NFCMiFareFamily

Identifiers for the MIFARE product families.

var identifier: Data

The unique hardware identifier of the tag.

Required.

var historicalBytes: Data?

The historical bytes extracted from an Answer To Select response.

Required.

Sending Commands

func sendMiFareISO7816Command(NFCISO7816APDU, completionHandler: (Data, UInt8, UInt8, Error?) -> Void)

Sends an ISO 7816 command APDU to the tag and receives a response APDU.

Required.

Relationships

Inherits From

See Also

Tag Types

Creating NFC Tags from Your iPhone

Save data to tags, and interact with them using native tag protocols.

protocol NFCISO7816Tag

An interface for interacting with an ISO 7816 tag.

Beta
protocol NFCISO15693Tag

An interface for interacting with an ISO 15693 tag.

protocol NFCFeliCaTag

An interface for interacting with a FeliCa tag.

Beta
protocol NFCNDEFTag

An interface for interacting with an NDEF tag.

Beta
class NFCTagCommandConfiguration

A set of parameters you use to define the configuration of an NFC tag command.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software