# PBCSDKDemo
**Repository Path**: pbcsf_bigdata_duanhw/PBCSDKDemo
## Basic Information
- **Project Name**: PBCSDKDemo
- **Description**: iOS 语音PCM文件上传, 并识别相关内容等功能
- **Primary Language**: Objective-C
- **License**: Not specified
- **Default Branch**: master
- **Homepage**: None
- **GVP Project**: No
## Statistics
- **Stars**: 1
- **Forks**: 0
- **Created**: 2020-03-30
- **Last Updated**: 2022-11-22
## Categories & Tags
**Categories**: Uncategorized
**Tags**: None
## README
# PBCSDKKit
iOS上语音录制库,并自动识别结果
#### 效果图
#### 介绍
iOS 语音录制库, 并自动识别结果
原则:接入简单、使用便捷
* PBCSDKKit.framework (200K)
#### 使用说明
1. 引入库文件
```
#import
```
2. 开启录音
```
- (BOOL)start;
```
录音之前,请初始化:
* 语音识别地址
```
NSString *recognitionURL;
```
* 用户唯一标识符
```
NSString *uid;
```
3. 停止录音
```
- (void)stop;
```
4. 暂停录音
```
- (void)pause;
```
5. 录音完成(stop)之后回调函数,返回语音识别结果
```
- (void)speechRecognitionResults:(id)resultObject;
```
#### 常见问题
1. 开启录音权限,以source code的方式打开Info.plist文件,在dict标签中加入以下属性:
```
NSMicrophoneUsageDescription
请开启语音功能
```
2. 新特性要求App内访问网络请求,要采用 HTTPS 协议:
```
"App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file."
* ① 在Info.plist中添加 NSAppTransportSecurity 类型 Dictionary ;
* ② 在 NSAppTransportSecurity 下添加 NSAllowsArbitraryLoads 类型Boolean ,值设为 YES;
```