IFlyISVRecognizer Class Reference
| Inherits from | NSObject |
|---|---|
| Declared in | IFlyISVRecognizer.h |
delegate
The delegate of FlyISVRecognizer responsing to IFlyISVDelegate.
@property (assign) id<IFlyISVDelegate> delegateDeclared In
IFlyISVRecognizer.h
+ sharedInstance
FlyISVRecognizer is a kind of Singleton calss.The function can be used as below:
IFLyISVRecognizer *recognizer=[IFlyISVRecognizer creteRecognizer: self];
+ (instancetype)sharedInstanceDeclared In
IFlyISVRecognizer.h
– generatePassword:
Genrerate a serial number password
Princeple:
1.Number serial has no 1 in itself;
2.The nuber serial has no same number(“98765432"is right while "99876543” is wrong)
- (NSString *)generatePassword:(int)lengthParameters
length |
the serial number’s length,length of “98765432” is 8,generally length is 8 and other value is forbidden |
|---|
Declared In
IFlyISVRecognizer.h
– getPasswordList:
Used to get password from server
- (NSArray *)getPasswordList:(int)pwdtParameters
pwdt |
when pwdt is 1,the function will return chinese text;while pwdt is 2, the funciton will return number serial |
|---|
Declared In
IFlyISVRecognizer.h
– isListening
Used to judge if the engine is running in listenning
- (BOOL)isListeningReturn Value
YES: the engine is listenning;
No : the engine is not listenning
Declared In
IFlyISVRecognizer.h
– sendRequest:authid:pwdt:ptxt:vid:err:
Used to query or delete the voiceprint model in server
- (BOOL)sendRequest:(NSString *)cmd authid:(NSString *)auth_id pwdt:(int)pwdt ptxt:(NSString *)ptxt vid:(NSString *)vid err:(int *)errParameters
cmd |
“del”: delete model; |
|---|---|
pwdt |
voiceprint type |
ptxt |
voiceprint txt,only fixed voiceprint and number serial have this,in free voiceprint model this param shall be set nil. |
vid |
another voiceprint type model,user can use this to query or delete model in server can be @“jakillasdfasdjjjlajlsdfhdfdsadff”,totally 32 bits; |
authid: |
user id ,can be @“tianxia” or other; |
Declared In
IFlyISVRecognizer.h
– setParameter:forKey:
Set the voiceprint params
- (BOOL)setParameter:(NSString *)value forKey:(NSString *)keyParameters
value |
参数值 |
|---|---|
key |
参数类型 |
Return Value
设置成功返回YES,失败返回NO
Discussion
| key | value |
|---|---|
| sst | @“train” or @“verify” |
| auth_id | @“tianxia” or other |
| sub | @“ivp” |
| ptxt | |
| rgn | @“5” |
| pwdt | @“1”,or @“2”, or @“3” |
| auf | @“audio/L16;rate=16000” or @“audio/L16;rate=8000” |
| vad_enable | @“1” or @“0” |
| vad_timeout | @“3000” |
| vad_speech_tail | @“100” |
Declared In
IFlyISVRecognizer.h
– getParameter:
Get the voiceprint params used the same as function of setParameter
- (NSString *)getParameter:(NSString *)keyDeclared In
IFlyISVRecognizer.h