g-sensor calibration problem
John Lee
john_lee at openmoko.com
Fri Jun 20 11:56:37 CEST 2008
On Fri, Jun 20, 2008 at 10:45:26AM +0100, Andy Green wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Somebody in the thread at some point said:
>
> | x = -72, y = -990, t = 1.976891 pi
> |
> | It's quite reasonable. However,
> |
> | * sometimes after booting
> | * always after resume (apm -s)
> |
> | the result will look like this:
> |
> | x = 1620, y = -36, t = 0.492928 pi
>
> Do you notice any explosion at this time and you fly through the air
> horizontally :?)
>
> I don't know what it is, there is a setting on the thing to reduce
> sensitivity to increase dynamic range that would change output, but it
> would change it down, not to 1620.
>
> 1620 is raw count of 90... can you check to see if the output is still
> responsive to movement correctly, ie, perhaps the issue is one about the
> baseline offset is wrong after powerup and we need to explicitly reset
> the thing (it fetches them from internal EEPROM when reset).
abnormal result:
held vertically:
x = 1512, y = -972, t = 0.318138 pi
x = 1512, y = -972, t = 0.318138 pi
x = 1512, y = -990, t = 0.315471 pi
x = 1548, y = -972, t = 0.321528 pi
x = 1530, y = -1008, t = 0.314568 pi
x = 1512, y = -990, t = 0.315471 pi
x = 1494, y = -990, t = 0.313720 pi
x = 1494, y = -972, t = 0.316399 pi
x = 1494, y = -972, t = 0.316399 pi
x = 1512, y = -990, t = 0.315471 pi
rotate 90 degrees clockwise around z-axis (right side down)
x = 2286, y = -162, t = 0.477480 pi
x = 2286, y = -180, t = 0.474988 pi
x = 2286, y = -180, t = 0.474988 pi
x = 2286, y = -162, t = 0.477480 pi
x = 2286, y = -162, t = 0.477480 pi
x = 2286, y = -162, t = 0.477480 pi
x = 2286, y = -162, t = 0.477480 pi
x = 2286, y = -162, t = 0.477480 pi
x = 2286, y = -162, t = 0.477480 pi
x = 2286, y = -162, t = 0.477480 pi
x = 2286, y = -180, t = 0.474988 pi
rotate 180 (upside down):
x = 1602, y = 972, t = 0.673594 pi
x = 1584, y = 972, t = 0.675193 pi
x = 1602, y = 972, t = 0.673594 pi
x = 1584, y = 972, t = 0.675193 pi
x = 1602, y = 972, t = 0.673594 pi
x = 1584, y = 972, t = 0.675193 pi
x = 1602, y = 972, t = 0.673594 pi
x = 1584, y = 972, t = 0.675193 pi
x = 1584, y = 972, t = 0.675193 pi
x = 1584, y = 972, t = 0.675193 pi
rotate 270 (left side down):
x = 612, y = 36, t = 0.518703 pi
x = 612, y = 54, t = 0.528014 pi
x = 612, y = 36, t = 0.518703 pi
x = 630, y = 36, t = 0.518169 pi
x = 612, y = 54, t = 0.528014 pi
x = 630, y = 54, t = 0.527217 pi
x = 630, y = 36, t = 0.518169 pi
x = 612, y = 36, t = 0.518703 pi
x = 630, y = 36, t = 0.518169 pi
x = 612, y = 54, t = 0.528014 pi
x = 612, y = 36, t = 0.518703 pi
x = 630, y = 36, t = 0.518169 pi
you see the y value is always about right
but the x value has +1620 offset.
>
> I would suspect the raw data is shifted somehow but it doesn't seem
> likely the way we bitbang it address-first.
>
> - -Andy
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.9 (GNU/Linux)
> Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org
>
> iEYEARECAAYFAkhbfDUACgkQOjLpvpq7dMqeugCeJDd8DitJgRStcXV/BMn4jZt+
> lFUAn19pBINYegKOCSefPTX8sb/85jBO
> =APu5
> -----END PGP SIGNATURE-----
More information about the openmoko-kernel
mailing list