I have two sensor which is connected over TTL to ESP board. I have a formula to calculate the sensor value and there is time interval variable. I am confused about variable value. sensor sends data at 20Hz and I read the value with serial read. Do I need to decleare interval value as 1000/20 = 50ms or read interval because two sensor is not synchronous and read time changes.
I am trying to implement gyro/gnss kalman filtering for angular speed. I am using gyro with 20 hz and gps data is 10hz. but they are not synchronous. There is time interval value on transition matrix. I am confused about the declering time interval as sensor speed or read time.
Thanks
If your system model does not take the different measurement times properly into account, that introduces a lag or mismatch and an additional source of error.
That complicates an already difficult problem. If you have not worked your way through Kalman filter theory and/or do not have an appropriate system model, you are better off just averaging the state variable estimates.
Your application description is not much clearer than your first post. But why the need to sync? I will guess, you could use independent filters for each sensor and then sample the Kalman output from each one at the same time. That should overcome any problem with interpolation.
Performance depends a lot on input data quality and matching filter coefficients to that input, as mentioned in the previous post.
System model get input of gyro yaw rate and heading change. time interval only needs at gyro output. Measurement is gyrorate*dt - headingchange. Trying to find error rate of gyro.