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

pkg/uwb-dw1000: fix default group delay, use OTP values when possible #18000

Merged
merged 5 commits into from Apr 26, 2022

Conversation

fjmolinas
Copy link
Contributor

Contribution description

This PR fixed the default values for the transmitter calibration block group delay. It seems that when I ported this I set the default group delay to the wrong value of 5 or (DW1000_CHANNEL_DEFAULT), when the actual correct value for the default channel 5 is 0xC0. This fixes it.

Furthermore, by playing with the default firmware decawave provides its boards with there is also calibrated TX_POWER and PG_DELAY values stored in the OTP memory (at least for channel 5). These values are calibrated to account for fabrication process variation in antenna gains among others and therefore be sure that the output TX power is according to regulations, so use them when they are available.

A couple of cleanups are piggy-packed int his PR, mainly to reduce CI builds.

Testing procedure

Bench results of twr_aloha against master, a notable improvement should be visible, running on IoT-LAB and evaluating the mean error over 14nodes I get:

          count      mean       std       min       25%       50%       75%       max
method                                                                               
deca    18185.0  0.084623  0.091720  0.000000  0.027582  0.060342  0.112198  0.967802
master  18192.0  0.194518  0.146984  0.000015  0.111583  0.173077  0.246428  6.866262
pr      18161.0  0.113226  0.120171  0.000004  0.040586  0.082905  0.150210  1.110259

Issues/PRs references

Split from #17988

@fjmolinas fjmolinas added the CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR label Apr 25, 2022
@github-actions github-actions bot added the Area: pkg Area: External package ports label Apr 25, 2022
@kaspar030
Copy link
Contributor

Happy 18k everyone!!

Copy link
Contributor

@kaspar030 kaspar030 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK.

Code changes look fine. Provided testing indicates big improvements.

@fjmolinas fjmolinas merged commit 1850f97 into RIOT-OS:master Apr 26, 2022
@fjmolinas
Copy link
Contributor Author

Thanks!

@fjmolinas fjmolinas deleted the pr_uwb_dw1000_fix_group_delay branch April 26, 2022 06:18
@chrysn chrysn added this to the Release 2022.07 milestone Aug 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: pkg Area: External package ports CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants