I'm currently working on a project, where I'd like to use the vibrating motor situated inside the Android phone.
I'd figured out, that setting the right permission in the manifest and getting an instance of the vibrator:
Vibrator v = (Vibrator) game.getSystemService(Context.VIBRATOR_SERVICE);
would give me access to it. As far as I can see the only methods to make it vibrate are:
public abstract void vibrate (long milliseconds)
and
public abstract void vibrate (long[] pattern, int repeat)
Yet I'd like to have control the power of the vibration:
How can I control the power of the vibration?
Update:
Shouldn't the speed be controlled by varying voltage (or PWMing DC)?
To access it, open the “Settings” app and go to Sounds And Vibration > Vibration Intensity. Tune the available sliders to adjust the vibration intensity of incoming calls, notifications, and touch interaction response to your liking.
There are several ways to increase a motor's vibration strength, such as increasing the motor speed, the eccentric mass, or the mass' distance from the motor shaft.
As per the below, I don't believe it's possible to control the intensity. What you could do is use short bursts so the device doesn't vibrate as fast? But I've not tested this personally.
http://developer.android.com/reference/android/os/Vibrator.html and controlling vibration intensity in android phones? is it possible?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With