0.1.33 • Published 8 months ago

compass-heading-js v0.1.33

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

compass-heading-js

npm version License

Overview

Converts device orientation to compass heading.

Installation

You can install this library using npm:

npm install compass-heading-js

Props

keydescriptiion
alphaThe device's compass heading
betathe device's tilt front-to-back
gammathe device's tilt left-to-right

Usage

import { calculateCompassHeading } from "compass-heading-js";

const alpha = 45;
const beta = 30;
const gamma = 60;

const heading = calculateCompassHeading(alpha, beta, gamma);
console.log(heading);
// Output: 260.76847951640775

License

This project is licensed under the MIT License - see the LICENSE file for details.

0.1.32

8 months ago

0.1.33

8 months ago

0.1.30

9 months ago

0.1.31

9 months ago

0.1.27

10 months ago

0.1.28

10 months ago

0.1.29

10 months ago

0.1.21

11 months ago

0.1.22

11 months ago

0.1.23

11 months ago

0.1.24

11 months ago

0.1.25

11 months ago

0.1.26

10 months ago

0.1.20

12 months ago

0.1.17

12 months ago

0.1.18

12 months ago

0.1.19

12 months ago

0.1.14

1 year ago

0.1.15

1 year ago

0.1.16

1 year ago

0.1.11

1 year ago

0.1.12

1 year ago

0.1.13

1 year ago

0.1.10

1 year ago

0.1.9

1 year ago

0.1.8

1 year ago

0.1.7

1 year ago

0.1.4

1 year ago

0.1.6

1 year ago

0.1.5

1 year ago

0.1.2

1 year ago

0.1.1

1 year ago

0.1.3

1 year ago

0.1.0

2 years ago