Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NavEKF3_core::setup_core: is beacon buffer length setted wrong? #26833

Open
luweiagi opened this issue Apr 17, 2024 · 2 comments
Open

NavEKF3_core::setup_core: is beacon buffer length setted wrong? #26833

luweiagi opened this issue Apr 17, 2024 · 2 comments

Comments

@luweiagi
Copy link
Contributor

luweiagi commented Apr 17, 2024

Here we set beacon buffer length as imu_buffer_length+1:

if(dal.beacon() && !rngBcn.storedRange.init(imu_buffer_length+1)) {

image

But, at

// limit to be no longer than the IMU buffer (we can't process data faster than the EKF prediction rate)

image
We said that obs_buffer_length should not longer than the IMU buffer because we can't process data faster than the EKF prediction rate even if obs sensor reading-data speed is faster than the IMU update speed.

So, why we set beacon buffer length as imu_buffer_length+1, which >imu_buffer_length?
Can it be changed as:
image
?

@rmackay9
Copy link
Contributor

Hi @luweiagi,

Thanks for your ongoing bug search, it's very much appreciated.

I think we support multiple beacons that could theoretically each provide an update at a high rate, but I'm also pretty sure that we don't allow the total number of updates from all beacons to be more than 50hz (total, e.g. if 5 beacons then each can only update at 10hz maximum) so I agree that it is probably fine to reduce the size of the rngBcn.storedRange array to be smaller. On the other hand, do we really want to risk making it smaller just to save a few bytes of RAM?

@luweiagi
Copy link
Contributor Author

@rmackay9
Thanks for reply!
No, it's not necessary. I only made a logical judgment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants