We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 6db0b55 + 6d1b48b commit 1a1cfaeCopy full SHA for 1a1cfae
samples/Accelerometer/js/main.js
@@ -31,7 +31,7 @@ Authors:
31
window.addEventListener(
32
"devicemotion",
33
function(evt) {
34
- var coordinate = evt.acceleration;
+ var coordinate = evt.accelerationIncludingGravity;
35
$("#x").text("X: " + Math.round(coordinate.x-0));
36
$("#y").text("Y: " + Math.round(coordinate.y-0));
37
$("#z").text("Z: " + Math.round(coordinate.z-0));
0 commit comments