-
Notifications
You must be signed in to change notification settings - Fork 80
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
Remove outliers in distances #52
Comments
Hi, I'm happy you are interested in contributing to the project! At this point in the code the anchor has received a packet from another anchor and we have calculated the distance to the other anchor. The idea would be to check if the distance is resonable or not, and to discard samples that seems to be "wrong". As you can see in the code there is currently only a very basic check that verifies that the distance is larger than First some information: The distance is really not a distance, it is actually the Time Of Flight for the radio waves between the two anchors and it is measured in ticks of the UWB radio clock (see definition of As the distance value is passed on to the Crazyflie in the UWB packets, the easiest way to examine it is probably to log it from the crazyflie. It is available in the tdoaEngine.tof log variable. To use it you first have to set the anchor pair you are interested in through the parameters tdoaEngine.logId and tdoaEngine.logOthrId. Note that the logging system samples the value at regular intervals and you will not get all distance values that the anchor sees. Now to the actual outlier problem. I'm not sure what the best strategy would be, but know some things
One simple approach would be to low pass filter the distance. Since it is a bit cumbersome to work on the anchor firmware (flashing all anchors take some time) you can probably make some experiments in the Crazyflie instead. A good spot would be here https://github.com/bitcraze/crazyflie-firmware/blob/master/src/deck/drivers/src/lpsTdoa3Tag.c#L180-L194 or here https://github.com/bitcraze/crazyflie-firmware/blob/master/src/utils/src/tdoa/tdoaEngine.c#L224-L235. Good luck! |
Thanks for all the details, I was thinking exactly about a low pass filter. |
Yes, the positions are stored in the anchors, but they currently only know about their own position. The remote anchor position is included in all packets but it is currently not decoded. From a protocol point of view the position is also not guaranteed to be included, so it would be nice to have a solution that does not rely on that. |
lps-node-firmware/src/uwb_tdoa_anchor3.c
Lines 475 to 479 in 6f5eb46
Hi @krichardsson, I've seen this
TODO
, how can I contribute to remove those outliers?The text was updated successfully, but these errors were encountered: