Remove gravity factor from accelerometer
10 ビュー (過去 30 日間)
古いコメントを表示
Vasileios Skaramagkas
2019 年 6 月 23 日
回答済み: Sulaymon Eshkabilov
2019 年 6 月 23 日
Hello,
I am using a 3axis acceleromter ADXL345 and I want to frequencies between 0.5-25 Hz. I want to do some filtering first in order to get rid of the gravity factor and the dv offset as well as some noise. I have read multiple articles on the internet but none seems to be very clear. Can someone give me some quick tips to guide me with my task?
Thank you in advance
2 件のコメント
Jim Riggs
2019 年 6 月 23 日
This question is quite fuzzy for the following reasons:
Accelerometers do not measure gravity - they measure specific force which is the applied force (without the effects of gravity). Most people who use accelerometers that want to know the acceleration of the body being measured have to ADD the effect of gravity to get the true acceleration.
If you want to know how to select a filter for noise rejection, we need to know a bit more about the application.
If you want to estimate sensor bias, that is a different problem.
You need to restate your question and provide more information.
採用された回答
Sulaymon Eshkabilov
2019 年 6 月 23 日
Hi,
In your case, to reduce noise influence from your acceleration measurements with accelerometers you would need to employ band-pass filter (e.g. Butterworth) within [0.5, 30] Hz. E.g.:
SN = ... % Measured signal
% Band pass frequency range is between 0.5 and 30 Hz.
f1 = 0.5; f2=30;
% Normalized pass frequency ranges (Wn1, Wn2):
Wn1=f1/(0.5*fs);
Wn2=f2/(0.5*fs);
% Second order (N=2) filter passes all signal components within
% a frequency range of: [Wn1 Wn2]
N=2;
% Compute second order filter coefficients:
[b, a] = butter(N, [Wn1, Wn2], 'bandpass');
filter_F = filter(b, a, SN);
% Take FFT... of the filtered signal: filter_F
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Analog Filters についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!