saravanan-vdg / openintents

Automatically exported from code.google.com/p/openintents
0 stars 0 forks source link

Pitch and roll in SensorSimulator do not report correct values #249

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.Open sensor simulator.jar
2.move slider full range left to right pitch only ranges from -90 to 90
3.roll goes from -180 to 180

What is the expected output? What do you see instead?
According to this page 
http://developer.android.com/reference/android/hardware/SensorListener.html
values[1]: Pitch, rotation around X axis (-180<=pitch<=180), with positive 
values when the z-axis moves toward the y-axis. 

values[2]: Roll, rotation around Y axis (-90<=roll<=90), with positive 
values when the z-axis moves toward the x-axis. 

The two possible ranges are reversed in Sensor Simulator.

I have verified on my droid how this should work, it appears the google 
documentation is correct, the pitch should transit all the way to 180 and 
not stop at 90.

What version of the product are you using? On what operating system?
1.0

Please provide any additional information below.

Original issue reported on code.google.com by bejmo...@gmail.com on 4 Jan 2010 at 1:02

GoogleCodeExporter commented 9 years ago

Original comment by peli0...@googlemail.com on 4 Jan 2010 at 11:48

GoogleCodeExporter commented 9 years ago
According to the same page from Android API: 

"IMPORTANT NOTE: The axis are swapped when the device's screen orientation 
changes."
Thus, we can imply that these values are correct when the device is in 
landscape mode. However, there is absolutely no mentions of landscape and 
portrait modes in the source code of SensorSimulator. IMHO, the defect has 
transformed into a feature request.

Original comment by eFP...@gmail.com on 3 Apr 2011 at 7:54