Skip to content

Linear acceleration #51

@BaptisteLucas

Description

@BaptisteLucas

Hi,
I'm trying to use the ICM20948 for both orientation and acceleration sensors.
With your Example7_DMP_Quat6_EulerAngles file it's easy to get the corrected orientation data.

But for the acceleration it seems more difficule.
I tryed to add the sensor linear acceleration mode for the DMP:

	success &= (myICM.enableDMPSensor(INV_ICM20948_SENSOR_GAME_ROTATION_VECTOR) == ICM_20948_Stat_Ok);
	// Enable any additional sensors / features
	success &= (myICM.enableDMPSensor(INV_ICM20948_SENSOR_LINEAR_ACCELERATION) == ICM_20948_Stat_Ok);

The result is that the DMP data contains now raw acceleration : data.Raw_Accel.Data

these accelerations are not corrected by the orientation of the IMU, then I can't use it directly (and I don't know how to use it !)

it seems that this configuration provide the same result as

success &= (myICM.enableDMPSensor(INV_ICM20948_SENSOR_RAW_ACCELEROMETER) == ICM_20948_Stat_Ok);

Is there a way to have the x, y, z acceleration (without the 1g gravity and calibrated ) to be able to know if my sensor is moving left, right, up or down ?

thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions