From d68701223f550672d70b4b9248ec1653b8187283 Mon Sep 17 00:00:00 2001 From: Mikhail Grushinskiy Date: Sat, 7 Sep 2024 21:24:36 -0400 Subject: [PATCH] Update bbn_wave_freq_m5atomS3.ino --- bbn_wave_freq_m5atomS3/bbn_wave_freq_m5atomS3.ino | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bbn_wave_freq_m5atomS3/bbn_wave_freq_m5atomS3.ino b/bbn_wave_freq_m5atomS3/bbn_wave_freq_m5atomS3.ino index ae3fdb3..7549fca 100644 --- a/bbn_wave_freq_m5atomS3/bbn_wave_freq_m5atomS3.ino +++ b/bbn_wave_freq_m5atomS3/bbn_wave_freq_m5atomS3.ino @@ -295,8 +295,8 @@ void setup(void) { float twoKi = (2.0f * 0.0001f); mahony_AHRS_init(&mahony, twoKp, twoKi); - float omega_init = 0.02 * (2 * PI); // init frequency Hz * 2 * PI (start converging from omega_init/2) - float k_gain = 1000.0; // Aranovskiy gain + float omega_init = 0.03 * (2 * PI); // init frequency Hz * 2 * PI (start converging from omega_init/2) + float k_gain = 200.0; // Aranovskiy gain float t_0 = 0.0; float x1_0 = 0.0; float theta_0 = - (omega_init * omega_init / 4.0); @@ -305,9 +305,9 @@ void setup(void) { aranovskiy_init_state(&state, t_0, x1_0, theta_0, sigma_0); { - float process_noise_covariance = 0.6; + float process_noise_covariance = 0.1; float measurement_uncertainty = 2.0; - float estimation_uncertainty = 10.0; + float estimation_uncertainty = 100.0; kalman_smoother_init(&kalman_freq, process_noise_covariance, measurement_uncertainty, estimation_uncertainty); }