DCEFeedback
With DCEFeedback APIs, user can trigger feedback on the device to respond for some specific events.
@interface DCEFeedback : NSObject
Method | Description |
---|---|
vibrate |
Trigger a vibration when the method is called. |
beep |
Trigger a beep when the method is called. |
vibrate
Trigger a vibrate when the method is called.
+ (void)vibrate;
Code Snippet
- Objective-C
- Swift
[DCEFeedback vibrate]; // For example, if `vibrate` is called in the TextResultCallback of DBR, the device will trigger a vibration each time when barcode result is detected. - (void)textResultCallback:(NSInteger)frameId imageData:(iImageData *)imageData results:(NSArray<iTextResult *> *)results{ [DCEFeedback vibrate]; }
DCEFeedback.vibrate // For example, if `vibrate` is called in the TextResultCallback of DBR, the device will trigger a vibration each time when barcode result is detected. func textResultCallback(_ frameId: Int, imageData: iImageData, results: [iTextResult]?) { DCEFeedback.beep() }
beep
Trigger a beep when the method is called.
+ (void)beep;
Code Snippet
- Objective-C
- Swift
[DCEFeedback beep]; // For example, if `beep` is called in the TextResultCallback of DBR, the device will trigger a beep each time when barcode result is detected. - (void)textResultCallback:(NSInteger)frameId imageData:(iImageData *)imageData results:(NSArray<iTextResult *> *)results{ [DCEFeedback beep]; }
DCEFeedback.beep() // For example, if `beep` is called in the TextResultCallback of DBR, the device will trigger a beep each time when barcode result is detected. func textResultCallback(_ frameId: Int, imageData: iImageData, results: [iTextResult]?) { DCEFeedback.beep() }