DeviceMotionEvent.interval

  • Revision slug: Web/API/DeviceMotionEvent.interval
  • Revision title: DeviceMotionEvent.interval
  • Revision id: 400133
  • Created:
  • Creator: Sheppy
  • Is current revision? No
  • Comment 16 words addedMoved From DOM/DeviceMotionEvent.interval to Web/API/DeviceMotionEvent.interval

Revision Content

{{ DomRef() }}

Summary

Returns the interval, in milliseconds, at which device motion events fire. You can use this to determine the granularity of motion events. Read only.

Syntax

var interval = motionEvent.interval;

On return, interval is the time, in milliseconds, between device motion events.

Example

Specification

See also

Revision Source

<p>{{ DomRef() }}</p>
<h3 id="Summary" name="Summary">Summary</h3>
<p>Returns the interval, in milliseconds, at which device motion events fire. You can use this to determine the granularity of motion events. <strong>Read only.</strong></p>
<h3 id="Syntax" name="Syntax">Syntax</h3>
<pre class="eval"><em>var interval</em> = <em>motionEvent</em>.interval;
</pre>
<p>On return, <code>interval</code> is the time, in milliseconds, between device motion events.</p>
<h3 id="Example" name="Example">Example</h3>
<h3 id="Specification" name="Specification">Specification</h3>
<ul> <li><a class="external" href="http://www.w3.org/TR/orientation-event/" title="http://www.w3.org/TR/orientation-event/">DeviceOrientation Event Specification</a></li>
</ul>
<h3 id="See_also">See also</h3>
<ul> <li>{{ domxref("DeviceMotionEvent") }}</li> <li><a href="/en/Detecting_device_orientation" title="Detecting device orientation">Detecting device orientation</a></li> <li>{{ domxref("window.ondevicemotion") }}</li>
</ul>
Revert to this revision