DeviceMotionEvent() constructor creates a new
new DeviceMotionEvent(type) new DeviceMotionEvent(type, options)
A string with the name of the event. It is case-sensitive and browsers always set it to
An object that, in addition of the properties defined in
Event(), can have the following properties:
DeviceMotionEventAccelerationobject giving the acceleration of the device on the three axis X, Y and Z. Acceleration is expressed in m/s².
DeviceMotionEventAccelerationobject giving the acceleration of the device on the three axis X, Y and Z with the effect of gravity. Acceleration is expressed in m/s².
DeviceMotionEventRotationRateobject giving the rate of change of the device's orientation on the three orientation axis alpha, beta and gamma. Rotation rate is express in degrees per seconds.
A number representing the interval of time, in milliseconds, at which data is obtained from the device. It defaults to
|DeviceOrientation Event Specification |
BCD tables only load in the browser