From: pr.jung Date: Tue, 17 Jan 2017 10:07:21 +0000 (+0900) Subject: [ITC][device][Non-ACR][Vibrate before close haptic handle] X-Git-Tag: 4.0_Bringup~104^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3ebe0b7874fb051b3d90b0e1ce1bda4bfb36983e;p=test%2Ftct%2Fnative%2Fapi.git [ITC][device][Non-ACR][Vibrate before close haptic handle] Change-Id: If1b17568a217873f879307bb8681a063ff1111df Signed-off-by: pr.jung --- diff --git a/src/itc/device/ITs-device_haptic.c b/src/itc/device/ITs-device_haptic.c index 466ecbf36..1d7f51a65 100755 --- a/src/itc/device/ITs-device_haptic.c +++ b/src/itc/device/ITs-device_haptic.c @@ -180,11 +180,17 @@ int ITc_device_haptic_open_close_p(void) int nDeviceIndex = nDeviceCount - 1; + int nDuration = 20; + int nFeedback = 50; // 0~100 + haptic_effect_h pHapticEffect; + // Target API nRet = device_haptic_open(nDeviceIndex, &hHapticDevice); PRINT_RESULT(DEVICE_ERROR_NONE, nRet, "device_haptic_open", DeviceGetError(nRet)); CHECK_HANDLE(hHapticDevice, "device_haptic_open"); + nRet = device_haptic_vibrate(hHapticDevice, nDuration, nFeedback, &pHapticEffect); + // Target API nRet = device_haptic_close(hHapticDevice); PRINT_RESULT(DEVICE_ERROR_NONE, nRet, "device_haptic_close", DeviceGetError(nRet)); @@ -193,4 +199,4 @@ int ITc_device_haptic_open_close_p(void) } #endif //COMMON_IOT /** @} */ -/** @} */ \ No newline at end of file +/** @} */