Adjust gravity, g, in imuSensor object accelerometer

조회 수: 18 (최근 30일)
Gregory Harrison
Gregory Harrison 2021년 4월 8일
편집: Paul 2022년 6월 5일
The imuSensor accelerometer uses a gravity acceleration of 9.81 [m/s^2], but the local gravity in my area is 9.7922 [m/s^2], and I would like to change the value that the imuSensor accelerometer uses for simulation of the accelerometer data to compare with an actual accelerometer. How can this be done?
Thanks
For background information, the gravity at your location can be calculated using the WGS-84 gravity model:
% from https://en.wikipedia.org/wiki/Theoretical_gravity, based on the
% WGS84 ellipsoid, the WGS (World Geodetic System) 1984 Ellipsoidal
% Gravity formula
theta = your latitude in radians
g_theta = 9.7803253359 * ((1 + 0.00193185265241 * sin(theta)^2)/ ...
(sqrt(1 - 0.00669437999013 * sin(theta)^2 )));

채택된 답변

Ryan Salvo
Ryan Salvo 2021년 4월 27일
Hi Gregory,
Unfortunately, it is not currently possible to change the gravity acceleration in imuSensor. I've created an enhancement request for a future release.
Thanks,
Ryan
  댓글 수: 2
John Tamkin
John Tamkin 2022년 6월 5일
Any updates on this? Running into the same issue
Paul
Paul 2022년 6월 5일
편집: Paul 2022년 6월 5일
The better solution, IMO, is to not have imuSensor deal with gravity at all. The input to imuSensor should be specific force, which the user can compute based on whatever gravity model the user is using. Link to further discusson on this issue and others with imuSensor

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Sensor Models에 대해 자세히 알아보기

제품


릴리스

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by