Hi all,
I am writing this Web App on Gear S3 and trying to get the device's rotation data. Here is the code I use:
var gyroscopeRVSensor = tizen.sensorservice.getDefaultSensor("GYROSCOPE_ROTATION_VECTOR");
gyroscopeRVSensor.setChangeListener(onChangedGyroscopeSensor);
gyroscopeRVSensor.start(onSuccessGyroscopeSensor);
function onSuccessGyroscopeSensor(sensorData) { }
function onChangedGyroscopeSensor(sensorData)
{
// This method now gets called on a regular basis, but sensorData.x, y, z, w are all 0
}
(Note that when I call GetAvailableSensors on my S3, the 'GYROSCOPE_ROTATION_VECTOR' is in the list)
In the config file, I am using the following Features:
tizen.org/feature/sensor.accelerometer
tizen.org/feature/sensor.gravity
tizen.org/feature/sensor.gyroscope
tizen.org/feature/sensor.gyroscope_rotation_vector
tizen.org/feature/sensor.magnetometer
Any help will be greatly appreciated.
Thanks!