Unable to locate Crazyflie properly with LPS

All discussions related to the Loco Positioning system
Post Reply
Urinprobe
Beginner
Posts: 3
Joined: Fri Feb 10, 2017 2:24 pm

Unable to locate Crazyflie properly with LPS

Post by Urinprobe »

Hi there,

I'm currently working on setting up a lab for my thesis. While not having much experience with this kind of stuff, the topic is just fascinating.

I have set up all 6 nodes and can can see them in rviz, yet the displayed location of the drone is just utterly wrong.

What steps can I take to debug the problem?

Regards,

Simon
tariqse
Beginner
Posts: 5
Joined: Sat Dec 24, 2016 10:37 am

Re: Unable to locate Crazyflie properly with LPS

Post by tariqse »

I'm having the same problem as well
arnaud
Bitcraze
Posts: 2538
Joined: Tue Feb 06, 2007 12:36 pm

Re: Unable to locate Crazyflie properly with LPS

Post by arnaud »

Hi,

First I would look at the ranges from the Crazyflie to the anchor. You can do that using rqtplot: Start the hover launchfile, launch rqt_plot, display /crazyflie/ranging/ranges[0] to [5]. This will show you the distance measurement to all the anchor and will allow you to verify that the ranges are correct and the anchor mapping is right: getting closer to anchor address 1 should make /crazyflie/ranging/ranges[0] smaller.

/Arnaud
Urinprobe
Beginner
Posts: 3
Joined: Fri Feb 10, 2017 2:24 pm

Re: Unable to locate Crazyflie properly with LPS

Post by Urinprobe »

Running rqt_plot returns the following messages in the terminal:

TopicCompleter.update_topics(): could not get message class for topic type "crazyflie_driver/GenericLogData" on topic "/crazyflie/log_ranges"
TopicCompleter.update_topics(): could not get message class for topic type "bitcraze_lps_estimator/RangeArray" on topic "/crazyflie/ranging"
TopicCompleter.update_topics(): could not get message class for topic type "crazyflie_driver/GenericLogData" on topic "/crazyflie/log_kfpos"
TopicCompleter.update_topics(): could not get message class for topic type "crazyflie_driver/GenericLogData" on topic "/crazyflie/log_kfqt"

How do I see the ranges in the window that opens?

Simon
arnaud
Bitcraze
Posts: 2538
Joined: Tue Feb 06, 2007 12:36 pm

Re: Unable to locate Crazyflie properly with LPS

Post by arnaud »

This looks like you did not source the "devel/setup.bash" workspace file in the console you are launching rqt_plot (https://wiki.bitcraze.io/doc:lps:index#ros)
Urinprobe
Beginner
Posts: 3
Joined: Fri Feb 10, 2017 2:24 pm

Re: Unable to locate Crazyflie properly with LPS

Post by Urinprobe »

That did the trick!

Turns out only 2 of the anchors were actually returning non-zero values. Reflashing the firmware and reconfiguring the nodes solved that and I can now properly locate my crazyflie. Thank you!
arnaud
Bitcraze
Posts: 2538
Joined: Tue Feb 06, 2007 12:36 pm

Re: Unable to locate Crazyflie properly with LPS

Post by arnaud »

Glad that it helped! Have fun with autonomous flying :-).
Post Reply