3

Multipeer Connectivity in iOS

 3 years ago
source link: https://www.raywenderlich.com/19987381-multipeer-connectivity-in-ios
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
Multipeer Connectivity in iOSGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupShapeGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroupGroup

This course is available as part of the raywenderlich.com Professional subscription. To learn more click here

Multipeer Connectivity in iOS

Jan 12 2021 · Video Course (22 mins) · Advanced

In this course, you'll learn how to use Multipeer Connectivity: Apple's framework for transferring data between devices with no external network.

Version

  • Swift 5, iOS 14, Xcode 12

Set up Info.plist

2:08 Free

The first step to adding Multipeer Connectivity to any app is to ask for permission and tell users why it will use a local network. You'll use Info.plist for this.

In order to advertise your device to others, you'll need to use a reference to a Multipeer Connectivity Session object.

Once your device is advertising that it’s available, you'll need to employ MCNearbyServiceAdvertiserDelegate to handle requests to connect to other devices.

Discovery

3:19

When you have devices advertised through Multipeer Connectivity, the next step is to discover them. For that, you can use an MCNearbyServiceBrowser object.

Send Data

4:11

With an MCSession on one device, you can send data. And on another, an MCSessionDelegate will receive it.

Multipeer Connectivity provides a standard UI that abstracts what can be achieved with MCNearbyServiceBrowser: MCBrowserViewController.

Who is this for?

If you need a way to communicate wirelessly with Apple devices in close proximity to each other, in a blazing fast way, and you're quite comfortable with Swift, this course is likely a good match for you. SwiftUI and Combine knowledge will be helpful: they're both used in this course, but are not essential for employing Multipeer Connectivity.

Covered concepts

  • Local Networking
  • MCSession
  • MCNearbyServiceAdvertiser
  • MCBrowserViewController
  • Combine

Contributors

Jessy Catterwaul

Fascinated by technology consistently making learning easier, Jessy enjoys exploring new techniques involving creative software...

Instructor
Adriana Kutenko

Graphic Illustrator with a Bachelor’s Degree in Fine Arts. I am a perpetual perfection seeker with a big passion for History...

Illustrator

Comments

Add a rating for this content

Sign in to add a rating

All videos. All books.
One low price.

A raywenderlich.com subscription is the best way to learn and master mobile development — plans start at just $19.99/month!

Learn iOS, Swift, Android, Kotlin, Flutter and Dart development and unlock our massive catalog of 50+ books and 4,000+ videos.

The largest and most up-to-date collection of courses and books on iOS, Swift, Android, Kotlin, Flutter, Dart, Server-Side Swift, Unity and more!

All videos. All books. One low price.

A raywenderlich.com subscription is the best way to learn and master mobile development — plans start at just $19.99/month!

Learn iOS, Swift, Android, Kotlin, Flutter and Dart development and unlock our massive catalogue of 50+ books and 4,000+ videos.

  • © 2021 Razeware LLC
  • Made with ♥ from around the world
  • 6000+ Tutorials and counting

raywenderlich.com and our partners use cookies to understand how you use our site and to serve you personalized content and ads. By continuing to use this site, you accept these cookies, our privacy policy and terms of service .


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK