Problems with hardware programs such as camera/microphone crashes after upgrading iOS10

Source: Internet
Author: User

After upgrading to IOS10, the development process will inevitably encounter a lot of pits, the following are some common pits, I did some sorting, I hope that the development of everyone to help:

&1. Call video, webcam, microphone, etc Hardware program crash Flashback problem:

To be aware of the problem iOS10 more strict management of privacy rights, such as access to the camera, microphone and other hardware, you need to request application permissions in advance, allow to use, or now to declare in advance, although the previous requirements are not strict.

In iOS10 such as crashes, logs:

*this app has crashed because it attempted to access privacy-sensitive data without a usage description. The app ' s info.plist must contain an nscamerausagedescription key with a string value explaining to the user how the app u SES this data.

It means: You need to add a "nscamerausagedescription" Key,value to the Info.plist file to add a description.
I'm going to add all the keys I use here to the app's info.plist:

The followingKeyThe values were: Camera Contacts, microphones, albums

<Key>Nscamerausagedescription</key>
<string>cameradesciption</String>
<Key>Nscontactsusagedescription</key>
<string>contactsdesciption</String>
<key>nsmicrophoneusagedescription</key>
<string>microphonedesciption</String>
<key>nsphotolibraryusagedescription</key>
<string>photolibrarydesciption</String>

where this string value can be arbitrarily written
Related fields:

Microphone Permissions: Privacy–microphone usage Description Do you want to allow this app to use your microphone?
Camera permissions: Privacy–camera usage Description Do you want to allow this app to use your camera?
Album Permissions: Privacy–photo library Usage Description Do you want to allow this app to access your media library? Address Book permissions: privacy–contacts Usage Description Do you want to allow this app to access your contacts?
Bluetooth permissions: Privacy–bluetooth Peripheral usage Description Do you Xu Yun this app to use Bluetooth?
Voice to text permissions: Privacy–speech recognition usage Description allow this app to use speech recognition?
Calendar permissions: Privacy–calendars usage Description Do you want to allow this app to use the calendar?
Location permissions: Privacy–location when on use Usage Description we need to get relevant data about you from your location
Location rights: Privacy–location always Usage Description We need to get data about you from your location

Problems with hardware programs such as camera/microphone crashes after upgrading iOS10

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.