Skip to main content

Aila_NotifyVibrate

Trigger device vibration for specified time.

Signature

void Aila_NotifyVibrate(float duration);

Parameters

  • duration - Vibration duration in seconds

Description

For the Mobile Imager (legacy), this activates the sled vibration motor for the specified duration in seconds.

This function can be used to emulate notification vibrations on Apple devices that do not have a built-in vibration motor, such as the iPod Touch 6.

Usage

@implementation AppDelegate

- (void)application:(UIApplication *)application
didReceiveRemoteNotification:(NSDictionary *)userInfo
fetchCompletionHandler:(void (^)(UIBackgroundFetchResult))handler {

// Vibrate for 1 second on notification
Aila_NotifyVibrate(1.0f);

handler(UIBackgroundFetchResultNewData);
}

@end

See Also