Add a logg script for a swarm to cflib
Posted: Thu Oct 21, 2021 10:41 am
Hi everyone,
I have been working for a while with a swarm of quadcopters. The task was to test the trajectory flight of multiple Crazyflies conducting formation change while avoiding each other.
In order to evaluate the trajectories, I had to record (log) the position of each Crazyflie during the flight. Therefore, I created a script that logs the position of each Crazyflie, and saves it into a .csv or .npy (or both). On top of that, the user inserts a path to save the files in, if the path does not exist, the program creates the path. The script is not restricted only to logging position, but the user has to insert the log variables.
I could log the position of up to 16 Crazyflies (flying at the same time). I did not test it with more Crazyflies due to room constraints, but I think it is possible to work with more Crazyflies.
My question is: is this something that exists already (I couldn't find anything similar, but maybe I have missed something)? If not, maybe we can add it with a git pull request? I thought maybe other users are looking for a feature for logging variables from multiple Crazyflies too.
The following solutions are used in my script: first question and second question
I have been working for a while with a swarm of quadcopters. The task was to test the trajectory flight of multiple Crazyflies conducting formation change while avoiding each other.
In order to evaluate the trajectories, I had to record (log) the position of each Crazyflie during the flight. Therefore, I created a script that logs the position of each Crazyflie, and saves it into a .csv or .npy (or both). On top of that, the user inserts a path to save the files in, if the path does not exist, the program creates the path. The script is not restricted only to logging position, but the user has to insert the log variables.
I could log the position of up to 16 Crazyflies (flying at the same time). I did not test it with more Crazyflies due to room constraints, but I think it is possible to work with more Crazyflies.
My question is: is this something that exists already (I couldn't find anything similar, but maybe I have missed something)? If not, maybe we can add it with a git pull request? I thought maybe other users are looking for a feature for logging variables from multiple Crazyflies too.
The following solutions are used in my script: first question and second question