Introduction

In iOS 12 and earlier, there was only limited support for reading NDEF NFC tags. Unfortunately, this isn’t enough to read the majority of transit cards.

iOS 13 has significantly expanded the CoreNFC API, such that it is possible to read some NFC transit cards on iPhone 7 and later.

It is fairly early days for both Metrodroid on iOS and NFC support on iOS in general, so we expect to see many issues. There are still significant limitations imposed by iOS, but we aim to get as close to feature parity with the Android version as we can.

Requirements

Note: other iOS devices, including those supported by Apple Pay, do not support the new CoreNFC APIs available in iOS 13.

Getting Metrodroid for iOS

We’re currently working on getting Metrodroid available to interested testers via TestFlight. Watch this page for further updates.

If you are a member of the Apple Developer Program, you can build Metrodroid for iOS from source and deploy it to your device today!

Known differences and issues

Card support

Metrodroid for iOS does not support:

UX differences

UI differences

Accessibility

Some accessibility features are not available from iOS version:

Other missing features

Build Metrodroid for iOS from source

Note: We’re working on making this available via TestFlight.

Requirements:

Note: If you want to deploy your build to a physical device and use NFC support, you must also enroll in the Apple Developer Program. This has an annual membership fee.

Open ./native/metrodroid in Xcode, and you should be able to compile and deploy as normal. This will invoke Gradle to generate any needed resources.

Using in the simulator

Note: This works even if you are not enrolled in the Apple Developer Program.

Once you’ve deployed to the simulator, you can load card dumps by dragging Metrodroid card JSON files from Finder to the simulator window.

Deploying to a physical device

Note: you must be enrolled in the Apple Developer Program to deploy to a physical device with NFC support.

You will need to modify the signing configuration in Xcode before you can deploy:

  1. Open the Project Navigator (⌘1)

  2. Select metrodroid (the project) at the root of the tree.

  3. In the projects and targets list, pick the metrodroid target. This has a green Metrodroid logo.

  4. Click Signing & Capabilities.

    You should see a Team of Unknown Name appear in red, and the errors No account for team and No profiles for 'org.metrodroid.ios' were found. We’ll resolve these issues in the next steps.

  5. Change the Team to your Apple Developer Program Team’s name. This is either your full name, or your organisation’s name.

    If you don’t see a team name in the list, you need to set up your Apple ID in Xcode first.

    You should now see the error Failed to register bundle identifier. We’ll resolve that next.

  6. Set a unique bundle identifier. For example, com.example.metrodroid.ios.dev.

    If you don’t have your own domain name, but have a GitHub account, use something like io.github.your_name_here.metrodroid.ios.

You should now see Waiting to repair, Creating provisioning profile, and then the errors should disappear.

At this point, you can deploy to your device!

Note: when submitting pull requests, please ensure that your developer ID and bundle name changes have been removed from native/metrodroid/metrodroid.xcodeproj/project.pbxproj.