Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xcode "Device Locked" When iPhone is unlocked

When I tried to build and run, Xcode said my device was locked. I looked at my iPhone, and it's not locked at all. How do I fix this?

like image 704
Faisal Syed Avatar asked Nov 06 '14 23:11

Faisal Syed


People also ask

Can you see a log of when your iPhone was unlocked?

Answer: A: No. That is if you are talking about locking and unlocking with the device passcode, there is no log for that.

Why won't my Apple Watch unlock when my phone is unlocked?

Make Sure Wrist Detection is Enabled Wrist Detection has to be enabled for Unlock With Apple Watch to work. So head into the Watch app on your ‌iPhone‌, and in the Watch tab, select Passcode and ensure the Wrist Detection switch is in the green ON position.

How do you check phone is locked or unlocked in Swift?

DeviceStatus.swift import Foundation class DeviceStatus : NSObject { func locked(){ print("device locked") // Handle Device Locked events here. } func unlocked(){ print("device unlocked") //Handle Device Unlocked events here. } }


2 Answers

My phone was set to "trust" the Mac, and I still ran into this error with Xcode 6.1.1.

This worked for me:

  • unplug device
  • quit xcode
  • open xcode
  • plug in device
  • build/run
like image 50
Abhi Beckert Avatar answered Sep 24 '22 01:09

Abhi Beckert


Did you by chance not "trust" the device? This will prevent it from communicating with xcode even if the device is unlocked.

Update here's a support doc from Apple: http://support.apple.com/en-us/HT5868

like image 21
tehprofessor Avatar answered Sep 27 '22 01:09

tehprofessor