In my application I’m using following coding pattern to vibrate my iPhone device
Include: AudioToolbox framework
Header File:
#import "AudioToolbox/AudioServices.h"
Code:
AudioServicesPlaySystemSound(kSystemSoundID_Vibrate);
My problem is that when I run my application it gets vibrate but only for second but I want that it will vibrate continuously until I will stop it.
How could it be possible?
There are numerous examples that show how to do this with a private CoreTelephony call:
_CTServerConnectionSetVibratorState, but it’s really not a sensible course of action since your app will get rejected for abusing the vibrate feature like that. Just don’t do it.