nn::hid::CTR::GyroscopeReader::EnableAxisRotation Member Function

Syntax

void EnableAxisRotation();

Arguments

None.

Return Values

None.

Description

Enables Axial rotation of the gyro sensor.

When axial rotation is enabled, the rotation matrix specified by the nnhid::CTR::GyroscopeReader::SetRotationAxis function is used to perform a rotational transform on the sampling data, and the result is output.

This process can be used to treat the sensor in the CTR like it is positioned at a tilt.

If axial rotation is performed and acceleration correction is also performed, you need to pay special attention to the settings of the accelerometer.
In this case, the AccelerometerReader and the gyro sensor must share the same settings for axial rotation.
If you are using the default AccelerometerReader, when you call the functions nn::hid::CTR::GyroscopeReader::EnableAxisRotation, nn::hid::CTR::GyroscopeReader::DisableAxisRotation, nn::hid::CTR::GyroscopeReader::SetAxisRotationMatrix or nn::hid::CTR::GyroscopeReader::ResetAxisRotationMatrix the SDK calls the corresponding nn::hid::CTR::AccelerometerReader function and the settings are shared. But when you have specified an independent nn::hid::CTR::AccelerometerReader instance with the constructor, these settings must be made by the application.
Note that if the settings for axial rotation are not shared in common, the process of acceleration correction may behave in inappropriate ways.

This is disabled as the default.


CONFIDENTIAL