Documentation

Adding devices

A phone has to be trusted, in Developer Mode, and enrolled before it will take instructions.

Plug it in

  1. Connect and trust

    Use a cable that carries data, not a charge-only one. The phone asks whether to trust this computer; tap Trust and enter the passcode. Without this the Mac sees a battery, not a device.

  2. Turn on Developer Mode

    Settings → Privacy & Security → Developer Mode. The phone restarts and asks again after rebooting. The toggle only appears once a Mac with Xcode has connected to the phone at least once.

  3. Enrol it

    The agent reports every attached phone, and they show up under Devices as discovered. Enrolling one is what allows it to be driven. Anything left unenrolled is ignored entirely.

Only enrolled phones are ever touched

A Mac often has other phones plugged into it. The agent is told which devices belong to your workspace and refuses the rest, so a personal phone on the same hub is never woken or driven.

Passcodes stay on your Mac

A task that has to unlock a phone takes the passcode from the agent's own configuration. There is no column for it in our database and it is never sent to us, so a breach here cannot unlock your phones.

Set one from the machine the phone is plugged into:

~/.appfarmmagic/afm devices
~/.appfarmmagic/afm set-passcode <udid>

It prompts rather than taking the code as an argument, so it does not land in your shell history. Restart the agent afterwards for it to take effect.

What gets built onto the phone

Driving an iPhone needs a small test harness installed on it, signed with your Apple ID. The agent builds and installs it the first time you enrol a phone, which takes a few minutes. After that it is cached per device.

The harness is what receives taps and swipes. It runs only while a job is running, and nothing about it is shared between workspaces.

Keeping the phone reachable

  • Turn off auto-lock, or keep a keep-awake schedule on it.
  • Leave the phone on Wi-Fi. USB carries the automation, not the apps’ own traffic.
  • Powered hubs only. Several phones on an unpowered hub will drop off under load.

Device limits

Each plan covers a number of enrolled devices: one on Free, three on Starter, ten on Pro and thirty on Business. Discovered but unenrolled phones do not count.

Ready to plug in a phone?

Connect one iPhone and run a health check in about ten minutes.