UPGRADE YOUR SKILLS: Learn advanced Swift and SwiftUI on Hacking with Swift+! >>

A problem with setting up my iPhone for development

Forums > iOS

Hello, I am following the Swift Ui in 100 days ocurses and I am on day 16 now. However since I am blind I want to use a physical device to preview my app rather than XCode, as then I can physically touch the screen and feel the arreagement of controls onscreen. However, when I open Devices & simulators (CMD+SHIFT+2) and choose my iPhone I get an error stating that "Failed to set up device for development". I run MacOS 12.4 and iOS 15.6.

3      

hi,

the version of Xcode also matters. for example, Xcode 13.2 would not be able to handle an install on MacOS 12.4 and iOS 15.6.

check out the Minimum requirements and supported SDKs for compatibility with your version of Xcode.

hope that helps,

DMG

3      

  Hi, I have checked that list, but I have the latest xCode possible (Version 13.4 (13F17a)

3      

Reading the Apple Developer's Forum, some suggest restarting the iPhone. Yet, others suggest deleting the app and rebuilding it (and possibly even restarting the iPhone as well).

Stackoverflow, has a longer sequence to reestablish trust of your device with the Mac / Xcode. I provided a link here as there are lot of suggestions there about how go about it.

If any of these work, it would be useful to know.

3      

No joy. I have taken the following steps

  1. I have restarted both my iPhone and the Mac.
    1. I have unplugged the iPhone from the Mac, deleted it from known devices list and reauthenticated.
  2. I have unpaired the iPhone from within xCode and reauthenticated it there as well.
    1. I tried to view the logs from the device manager, but as assumed, they were empty.

3      

try to un-install Xcode then download then pair to your iPhone

3      

I'd prefer to wait with this step as my network is very slow. But if I have no way I will do that as I want to understand how various views look visually on the screen.

3      

I have restarted X-Code with Clean My Mac Pro, but it still does not work. Now I am out of ideas.

3      

Sometimes you forget that you have a paid Developer's subscription with Apple, and that not everyone will have that, or will want that.

It is possible that you have not set up your signing and capabilites in Xcode. You can download your app without a paid Apple Developer's account, but will have some restrictions and missing items, such in-app purchases, GameCenter, etc. (Those require a paid Developer's subscription).

  1. In the Xcode preferences, open the Accounts tab
  2. Add your account, login with your Apple ID

Then

  1. In main app area, choose the Target, and select the Signing and Capabilites tab
  2. For the team choose Personal Team
  3. Check Automatic signing is enabled (if your were in an organisation this might be different, but as it is just for an individual you don't need the hassle.)
  4. Connect your device, and select it from the pull down list in Xcode.
  5. Run the project.

I'm not sure, but you may get some query about trusting the device or Xcode.

3      

Hacking with Swift is sponsored by Essential Developer

SPONSORED Join a FREE crash course for mid/senior iOS devs who want to achieve an expert level of technical and practical skills – it’s the fast track to being a complete senior developer! Hurry up because it'll be available only until April 28th.

Click to save your free spot now

Sponsor Hacking with Swift and reach the world's largest Swift community!

Archived topic

This topic has been closed due to inactivity, so you can't reply. Please create a new topic if you need to.

All interactions here are governed by our code of conduct.

 
Unknown user

You are not logged in

Log in or create account
 

Link copied to your pasteboard.