UNPKG

1.09 kBTypeScriptView Raw
1import DeviceSensor from './DeviceSensor';
2export interface DeviceMotionMeasurement {
3 acceleration: null | {
4 x: number;
5 y: number;
6 z: number;
7 };
8 accelerationIncludingGravity: {
9 x: number;
10 y: number;
11 z: number;
12 };
13 rotation: {
14 alpha: number;
15 beta: number;
16 gamma: number;
17 };
18 /**
19 * Device's rate of rotation in space expressed in degrees per second (deg/s).
20 */
21 rotationRate: null | {
22 /**
23 * x axis rotation.
24 */
25 alpha: number;
26 /**
27 * y axis rotation.
28 */
29 beta: number;
30 /**
31 * z axis rotation.
32 */
33 gamma: number;
34 };
35 /**
36 * Interval at which data is obtained from the native platform. Expressed in **milliseconds**.
37 */
38 interval: number;
39 orientation: number;
40}
41declare class DeviceMotionSensor extends DeviceSensor<DeviceMotionMeasurement> {
42 Gravity: any;
43}
44export declare const Gravity: any;
45declare const _default: DeviceMotionSensor;
46export default _default;