How to control more than 50 crazyflies?

Discussions and questions about the Crazyradio
NicksonYap
Beginner
Posts: 11
Joined: Mon May 07, 2018 5:04 pm

Re: How to control more than 50 crazyflies?

Post by NicksonYap » Mon May 06, 2019 11:18 pm

I think i'll try trajectories first, since the go_to commands is assuming a linear trajectory

Using this, I suppose?
https://github.com/bitcraze/crazyflie-l ... h_level.py

Is the trajectory uploads persistent? Or do we have to re-upload everytime CF restarts? (I'm really hoping it is presistent)

Now I recall why I had the impression that a Crazyradio can support more than 3/4 CF, it's because the example here uses 1 radio to attempt controlling 10. Last I recall I did try this example and end up being able to fly only up to 3/4 CFs
https://github.com/bitcraze/crazyflie-l ... equence.py



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

Re: How to control more than 50 crazyflies?

Post by arnaud » Wed May 29, 2019 8:19 am

Hi,

The trajectory is not percistent when uploaded via the radio, though there is way to have the trajectory in the flash which make it persistant, this is what we did in our Demo at ICRA. With this method you need to compile a flash a new firmware for each trajectory/set of trajectories. Saving trajectories sent via radio would be technically possible but needs new firmware.

As for the number of Crazyflie per radio, we found a bug at ICRA that limits the number of Crazyflie per radio to ~4, we had to use 2 radios for our demo. It seems that there is a bug in the python implementation, the bug is tracked on github: https://github.com/bitcraze/crazyflie-l ... issues/118

estrategico
Beginner
Posts: 20
Joined: Mon Aug 13, 2018 3:20 am

Re: How to control more than 50 crazyflies?

Post by estrategico » Mon Jun 03, 2019 12:55 am

We are experimenting a similar situation:
We flew a swarm of 16 CF2.0 with the trajectory in flash and suddenly some of them just fall with no reason, seems like they lose power, but we check all batteries and all were charged.(4CFs Fall down).

All CFs are numerated from 1 to 16
When we flew from 1 to 8 CFs alone they play all trajectory ok
We flew the 9 to 16 CF they play the trajectory ok also
we flew odd numbers and ok
we flew even and ok
we flew 12 then two fall down.

We use a phyton script just to indicate CFs which trajectory to play and go in sync, we don't send trajectories on air they are already uploaded on flash.

We are using 5 radios in similar setup from channels 70 to 120
"radio://0/70/2M/E7E7E7E701"
"radio://0/70/2M/E7E7E7E702"
"radio://0/70/2M/E7E7E7E703"
"radio://0/70/2M/E7E7E7E704"
"radio://1/80/2M/E7E7E7E705"
"radio://1/80/2M/E7E7E7E706"
"radio://1/80/2M/E7E7E7E707"
"radio://1/80/2M/E7E7E7E708"
...

Disable the Bluetooth via firmware can help?

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

Re: How to control more than 50 crazyflies?

Post by arnaud » Wed Jun 05, 2019 8:27 am

This is odd, if you are playing pre-loaded trajectories I see no reason why the Crazyflie would just fall: they should be flying autonomously independent of each-other.

Are they restarting when falling and have you confirmed that the cause of the Crazyflie falling is when you are adding more and not some other factor?

Disabling bluetooth is always good: bluetooth is taking the radio to send beacons and so it is using part of the available bandwidth for each Crazyflie. Though, I do not expect that disabling bluethooth solves this problem.

estrategico
Beginner
Posts: 20
Joined: Mon Aug 13, 2018 3:20 am

Re: How to control more than 50 crazyflies?

Post by estrategico » Fri Jun 07, 2019 3:19 am

Hello Arnaud than you for your answer.
Some of them restart and others lose connection.
Another possibility may be a lack of feertos heap memory, because I decrease the assignment to 36000kb, (making room for the trajectory in flash memory)
But I don't see how the quantity of CFs can be related and be the cause of that behavior.

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

Re: How to control more than 50 crazyflies?

Post by arnaud » Thu Jun 13, 2019 8:04 am

You should not need to touch the heap to make room for the trajectory in flash: the Crazyflie CPU can access flash directly and you should be able to run trajectories directly from the flash. Though I am not sure the API is currently setup to read from flash but it should be quite easy to adapt. There is about 700KBytes of flash free in the Crazyflie.

Changing the stack sizes in the Crazyflie can indeed cause problem. Normally we do not use the heap during runtime though: all the memory is allocated at startup and then only the log blocks can allocate and de-allocate a bit of memory. So if you have random crash after startup it is most likely a problem of stack size rather than heap size.

estrategico
Beginner
Posts: 20
Joined: Mon Aug 13, 2018 3:20 am

Re: How to control more than 50 crazyflies?

Post by estrategico » Wed Jul 10, 2019 4:15 pm

We finally could flight a swarm with 15 drones but changing addresses avoiding that they were consecutive in the same radio and using 5 radios as you can see in this video:

https://drive.google.com/file/d/1-Cp3o- ... sp=sharing

Some of them simply refuse to connect in particular addresses.

But checking the sequence in the bitcraze newsletter "LongsynchronizedSequence.py"
https://bitcraze.us13.list-manage.com/t ... 168a317638
I´m curious with the fact that he´s controlling 9 drones with only one radio same channel and consecutive addresses,
Was this made with an experimental firmware or crazyflie-lib-python or Did you find how to close the issue #118 reported?

Delays with many connections on one radio #118

kimberly
Expert
Posts: 111
Joined: Fri Jul 06, 2018 11:13 am

Re: How to control more than 50 crazyflies?

Post by kimberly » Mon Jul 22, 2019 11:31 am

Let's continue on this thread: viewtopic.php?f=8&t=3574&p=17068#p17068

Post Reply