Built in
Gets the phone to its home screen, from the lock screen or from inside an app. Presses Home, then Home again for a phone with a Home button — and a third time, because a phone that fell asleep inside an app wakes on the first press and unlocks back into that app on the second — then swipes up for a phone without one, and presses Home once more, checking for the home screen after each. It cannot get past a passcode.
17 steps
if it fails, stop
if it fails, stop
if it fails, stop
if it fails, stop
if it fails, stop
if it fails, stop