crazyflie

This week we have a guest blog post by Giuseppe Silano, Postdoctoral Researcher at the Czech Technical University (CTU) in Prague, Multi-Robot System (MRS) group, who maintains CrazyS, a simulator of the Crazyflie for ROS and Gazebo. Enjoy!

Where CrazyS comes from

Back in 2017, at the University of Sannio in Benevento, we wanted a way to try control algorithms on the Crazyflie 2.0 before risking a real drone. RotorS, the MAV simulator from ETH Zurich, already gave a good model of motors, propellers and sensors for Gazebo. What was missing was the Crazyflie: its physical parameters and, above all, its flight controller.

CrazyS fills that gap. It adds a model of the Crazyflie to RotorS and re-implements the control architecture of the firmware (release 2018.01): the cascade of position, attitude and rate controllers, the complementary filter that estimates the attitude from the IMU, and the mixer that turns the controller outputs into motor commands. You can tune a controller in simulation, look at every signal, and only then move to the real drone. We presented the platform at MED 2018 and later in a chapter of the Springer book Robot Operating System (ROS): The Complete Reference (Volume 4).

A note on how CrazyS differs from CrazySim, which was presented on this blog in 2024. CrazySim compiles and runs the actual Crazyflie firmware against Gazebo. CrazyS instead re-writes the controllers as ROS nodes in C++, so they can be read, changed and logged like any other ROS code. The two approaches answer different questions. If you want to test the firmware you will fly, use CrazySim. If you want to design a new controller and compare it with the stock one, CrazyS is a good fit.

Over the years CrazyS grew one branch per ROS distribution (Kinetic, Melodic, Noetic), picked up an Internal Model Controller and swarm examples, and slowly fell behind ROS 2. This autumn I finally found the time to catch up.

What’s new

ROS 2 Jazzy and Gazebo Sim

The biggest change is the new dev/ros2-jazzy branch, which runs on Ubuntu 24.04 with ROS 2 Jazzy and Gazebo Harmonic. Here the port turned out simpler than I expected. Gazebo Sim already ships the RotorS motor model as the MulticopterMotorModel system, together with odometry, IMU and joint state systems, so CrazyS no longer needs custom Gazebo plugins at all. The drone model is a xacro file that uses these systems, and ros_gz_bridge moves the data to ROS 2. As a check, I fed the same motor speeds to the old and the new simulator: the drone moves the same way in both.

The control code was split into a library that does not depend on ROS, plus thin ROS 2 nodes, and the library now has unit tests. All the Crazyflie examples are ported: hovering with the firmware controller (with or without the state estimator), the Internal Model Controller, swarms, joystick control and a “no controller” mode where you send motor speeds yourself.

ros2 launch rotors_gazebo crazyflie2_hovering_example.launch.pyCode language: CSS (css)

Lee’s geometric controller

The second novelty is a geometric tracking controller on SE(3), from the well-known paper by Lee, Leok and McClamroch. Stefano Grossi developed and tuned it for the Crazyflie in his MSc thesis at the University of Modena and Reggio Emilia, supervised by Lorenzo Sabattini, Beatrice Capelli and Federico Pratissoli. His pull request had been waiting in the repository since 2021, and it is now part of every release, ROS 1 and ROS 2.

Trajectories are written as a list of segments in a YAML file, so a new scenario does not need any code. This is the half circle from the thesis:

segments:
  - {type: line, goal: [0.0, 0.0, 1.0], duration: 2.0, profile: linear}
  - {type: hold, duration: 4.0}
  - {type: line, goal: [1.0, 0.0, 1.0], duration: 2.0, profile: linear}
  - {type: hold, duration: 4.0}
  - {type: arc, center: [0.0, 0.0], angle: 3.14159265359, duration: 5.0, profile: linear}Code language: CSS (css)

A cubic profile instead of linear starts and stops each segment with zero velocity.

The repository includes the scenarios from the thesis (hovering, straight lines, half circles) and a three-drone swarm. In simulation the controller follows them within about 10 cm at the fastest points and settles to a few millimetres at the end.

ros2 launch rotors_gazebo crazyflie2_lee_geometric_controller.launch.py trajectory:=semicircle
ros2 launch rotors_gazebo crazyflie2_swarm_lee_geometric_controller.launch.py

In the video below, you can see the swarm example: three Crazyflies, each with its own geometric controller and its own trajectory, flying in Gazebo Harmonic. All three take off to 1 m. Drone 2 then flies a half circle around the origin, from (1, 0) to (−1, 0). Drone 3 moves into the spot drone 2 has just left. Drone 1 waits a few seconds before heading to (1, 1), so that its path does not cross drone 2’s. The video plays at real speed: each frame was rendered from the simulation clock, 30 frames per simulated second.

A bug that hid for years

This one is a good story for anyone who writes controllers. Over the years, several issues on GitHub were about the hovering example not behaving as it should, and I had always put the drift down to tuning. While porting the code I finally measured it: on ROS Noetic, after 60 s of plain hovering the drone was 0.9 m off and had turned by 9 degrees, and in Gazebo Harmonic it hit the ground after 67 s.

The cause was much simpler than tuning. Without the state estimator, the controller runs at every odometry message, which arrives at 1 kHz. Its integrators, however, added ki * error * 0.01, as if each step were 10 ms long. Every integral gain was therefore ten times larger than intended. The altitude swung between 0.6 and 1.6 m after take-off, and then the lateral loops slowly built up an oscillation until the drone left. Using the real time between two odometry messages fixed it: the drone now holds its position for as long as you like.

The same lesson came up again in the ROS 2 port. Under load, ROS 2 timers drifted by up to 20% with respect to the simulation time, and the fourth-order derivatives inside the geometric controller turned that jitter into instability in the swarm example. The controller now samples on the odometry time stamps and computes every derivative with the actual time between samples. In short: never trust that dt is what you think it is.

Keeping the old versions alive

Many people still use CrazyS on ROS 1, so the Kinetic, Melodic and Noetic branches received the same fixes and the new controller. Each branch now has its own GitHub Actions workflow that builds it in a Docker container with the matching Ubuntu version. The end-of-life distributions come from the final snapshots on snapshots.ros.org. For the ROS 2 branch, CI also builds the Debian packages the way the ROS buildfarm does, which is the first step towards an apt install.

What CrazyS is not

To be clear about the limits: everything above was tested in simulation, not on a real Crazyflie. The controllers are re-implementations, not the firmware itself. They follow the firmware’s structure, but they are not the code you flash. The firmware position controller in CrazyS also still tracks lateral waypoints poorly: its attitude loop is too slow, and fixing that means re-tuning the whole cascade. For trajectories, the geometric controller and the Internal Model Controller are the better choice today.

Try it

mkdir -p ~/crazys_ws/src && cd ~/crazys_ws/src
git clone -b dev/ros2-jazzy https://github.com/gsilano/CrazyS.git
cd ~/crazys_ws && rosdep install --from-paths src --ignore-src -y
colcon build && source install/setup.bash
ros2 launch rotors_gazebo crazyflie2_lee_geometric_controller.launch.py trajectory:=semicircleCode language: PHP (php)

The ROS 1 instructions are in the README on the master branch.

Links

Final thoughts

If you use CrazyS, whether in a course, a thesis or a paper, I would love to hear about it, and issues and pull requests are always welcome. For questions and bug reports, the best place is the GitHub issues; for anything else, you can find my contacts on my website.

Earlier this year we wrote about how we welcome contributions, and we still do! Every pull request that makes it into our repositories makes the Crazyflie ecosystem better for everyone. Today we want to tell you about our updated contribution guidelines, and why we changed them.

Over the last months more and more of the pull requests we are receiving are written with the help of AI tools. Many of them are great. But we have also noticed a pattern that makes things hard for both you and us.

A lot of the issues we have open on GitHub are not just waiting for someone to write the code. They need decisions first: how should this be solved, how does it fit with the rest of the system, and what will it mean for the future? We usually discuss these things as a team, and that discussion is often most of the work. When a pull request shows up with a ready-made solution, we have to have that discussion anyway, and sometimes the answer is that we want to go in a different direction. That is frustrating for everyone, especially the person who spent time on the code.

On top of that, we work with hardware. Code that compiles and passes CI is a good start, but it doesn’t tell us whether the Crazyflie actually behaves as expected. We always test pull requests on our platforms before merging, and it helps a lot to know what you have already tried.

What’s new?

We have cleaned up our General guidelines for code contributions and split them into sections that follow the life of a pull request. The biggest changes:

  • Talk to us first. Comment on the issue with your proposed approach, and open a pull request once we agree. If there is no issue for your change, open one first. Fixes that don’t involve any design decision, such as typos or documentation corrections, can go straight to a pull request.
  • Tell us how you tested it. Let us know what hardware tests you ran and what you observed.
  • AI tools are welcome, but you are the author. You should understand your change and be able to discuss it in your own words.
  • Clear expectations. Pull requests that don’t follow the guidelines may be converted to a draft or closed. It’s never personal, it lets us spend our review time where it counts.

Where to find them

The guidelines live in one place, the General guidelines for code contributions page on our website. To make them easy to find, we are also updating the Contribute section in the README of our repositories so it links straight to them. For other ways to help out, like reporting bugs, improving the documentation or sharing your projects, have a look at our Contribute page.

Building it together

None of this is meant to scare anyone away. It’s the opposite: we want contributing to the Crazyflie ecosystem to be a good experience, where your effort ends up in the codebase instead of in a closed pull request. If something in the guidelines is unclear, or you think we got something wrong, please let us know. And as always, thank you to everyone who has contributed so far. We can’t wait to see what you build next!

49 Crazyflie 2.1 Brushless lifting off their charging docks, flying formations, and landing back to recharge, all driven from a single Crazyradio 2.0. That’s what we have been flying lately, and it’s a great showcase of what the Crazyflie ecosystem can do with a big swarm.

If 49 Crazyflies sounds familiar, you might remember 49 Crazyflies, 1 Crazyradio, and cflib2. This time the formations are a lot more dynamic. They come from a collaboration with the Institute for Data Science in Mechanical Engineering (DSME) at RWTH Aachen University, and we recorded some videos we’re really happy with.

Where the formations come from

The choreographies were generated with SWAN, a pipeline developed at DSME that turns text promt into drone trajectories. In short:

  1. A generative video model turns the prompt into a reference video.
  2. A point tracker converts the motion in that video into trajectories for the swarm.
  3. A planner assigns them to individual drones, and a safety filter makes sure they are collision-free.

What makes these formations fun for us is that they are not static shapes: they move in ways that would be hard to animate by hand. That also makes them a demanding test for the swarm.

Taking it to the real world

The generated SWAN trajectories are turned into splines and deployed on a dense swarm of 49 Crazyflie 2.1 Brushless, flying under the Lighthouse positioning system and lit up by bottom-mounted Color LED decks. We won’t go through the whole setup again (covered by the earlier post), but two parts of the Crazyflie ecosystem made this kind of work practical:

  • Built on cflib2. All communication with the swarm goes through cflib2 over a single Crazyradio 2.0. Before takeoff, we use cflib2 to upload each drone’s trajectory to its memory, and during the show, the High-Level Commander executes it onboard. While they are flying, we log every drone’s position every 50ms, giving us a record of how closely the swarm followed the choreography.
  • No battery swapping. Each Crazyflie takes off and lands on its charging dock. When you want to fly the swarm many times back to back, not having to handle 49 batteries makes a huge difference.

The result is a setup where any idea can go from the computer to a real swarm without having to build the infrastructure yourself.

The videos

Enough talking, here is what it looks like. The video below shows the formations we flew: a ballerina (49 drones), a karate fighter (29 drones), and a hand making an “I love you” (ILY) sign (49 drones).

Wrapping up

Flying 49 Crazyflies through dynamic formations, with one radio, full position logging and drones that recharge themselves between flights shows how far the Crazyflie ecosystem has come for large swarms.

A big thank you to Pascal Reinhold, Alexander Gräfe and Sebastian Trimpe at DSME for their awesome work, and an extra special thanks to Alexander, who coordinated the whole project during his internship with us at Bitcraze. If you want to learn more about SWAN, check out their paper, Generative AI for Safe and Photorealistic Drone Light Shows. And if you want to fly your own swarm, cflib2 is ready to try.

We are happy to have been invited to the IEEE CSS Days 2026 on Wednesday the 21st of October at 19:30 UTC to talk about the Crazyflie in a controls context. The talk is 15 minutes long, including questions. We hope to see you there! Read on for more information about what the talk will contain…

Every now and then we get to interact with the community; our users, customers, ex-colleagues and others. You keep on inspiring us every time, and the discussions help us understand what you are doing in your work and where you are heading next, so that we can prioritise our work and efforts. We also enjoy sharing what is in our pipeline, what we are thinking about and how we imagine our products can be used to do awesome things. This talk will be such a session, with a focus on what improvements have been made lately to the Crazyflie ecosystem that can be interesting from a controls perspective.

IEEE CSS Days – what is it?

IEEE Control Systems Society (CSS) is the IEEE society dedicated to control systems engineering. Their flagship online showcase event, IEEE CSS Days, held 19-23 October, is virtual and free, and will highlight the society’s people, research, industry activities, community activities and more. All information can be found in the link. One of the sessions is “Technical Committee on System Identification and Adaptive Control Session”, and it is during this sessions that we have been invited to talk about the Crazyflie.

An overview of the talk

The title is “Advancements in the Crazyflie as a Testbed for Drone Control Research” – let’s break that down a little bit. We envision the Crazyflie to be a platform for trying new things; a canvas with just enough things premade for you to test your concepts with as little effort as possible. This is also true for the controls field. All the ideas floating around in the research community, and everything that has already been done, combined, intend to solve control problems at different levels and in different ways. We want to support as many ways of working as possible, and we believe we have lately done some advancements that can help you in your work. We want to share them with you, and are excited to see what cool things you can come up with using them.

Some examples of improvements

We are aware of that all of you will not be able to catch the CSS session. For that reason, here are some of the things that will be mentioned. If you have been reading the blog, you will probably recognise them:

Onboard, decentralised positioning – not really new, but something we keep coming back to when talking to the community. Lighthouse, which is laser-based, is still our highest performing positioning system. However, as we move into larger swarms, UWB has the advantage of not requiring line-of-sight between satellites and robot – this keeps Loco Positioning System interesting.

Bidirectional DSHOT and RPM telemetry – The Crazyflie Brushless now carries the possibility to get measurements of the rotor speeds. motorsGetRPM()in motors.c gives you what you need to get started.

cflib2 – The new, rust-powered cflib. It is already released (still on version 0, so expect API changes), and gives you performance and reliability boosts compared to the old cflib, and with more to come. Together with radio improvements, the radio performance has increased immensely: we have flown 49 drones on one Crazyradio in our flight lab. If you use Python for scripting, we highly recommend you try the new lib out.

As we move into bigger swarms, swarm management becomes a topic: Communication, monitoring, flashing and configuration. This is something that we are working on.

Let us know what you think of these improvements, when you start using them!

Event details

Here are the details for the talk:

Event: IEEE CSS Days
Time: 21st of October, 19:30 UTC
Speaker: Stefan Thorstenson
Title: “Advancements in the Crazyflie as a Testbed for Drone Control Research”

We hope to see you there!

And, if not, we will hopefully catch you some other time. In the meantime, keep on letting us know what you are working on – we are always interested to hear about it and discuss.

And so, two of our products have reached the end of the road. This time it is the Z-ranger deck v2 and the Crazyradio PA. Both have now been discontinued, and our remaining stock has run out.

This is not a particularly dramatic change. Both products already have well-established successors, and much of what they enabled has simply become part of the next generation of the ecosystem. Still, they have been around for quite a while, so here’s a proper goodbye.

Z-ranger deck v2: knowing where the floor is

The idea behind the Z-ranger was simple: point a distance sensor downwards and give the Crazyflie a good measurement of its height above the ground. It enabled accurate height hold without an external positioning system and became a building block for early autonomous flight experiments.

The original Z-ranger used the VL53L0x Time-of-Flight sensor. In 2018 we introduced the Z-ranger deck v2, together with the Flow deck v2, using the newer VL53L1x sensor and extending the useful ranging distance. The Z-ranger v2 could measure the distance to the ground up to 4 metres.

There was always a close relationship between the Z-ranger and the Flow deck. The two decks share the same basic downward-facing ranging functionality, but the difference is that the Flow deck v2 also contains a PMW3901 optical flow sensor, allowing the Crazyflie to measure horizontal movement relative to the ground.

Over time, that has made the Flow deck the more useful general-purpose solution. You get the ground-distance measurement of the Z-ranger, but also the motion information needed for position hold and autonomous movement in X and Y.

Rather than maintaining two products with overlapping functionality, we are consolidating around the Flow deck v2. For existing Z-ranger users, nothing suddenly stops working. The firmware support remains, and there is no reason to replace a Z-ranger that is already doing its job in an experiment. For new setups, however, the the Flow deck v2 is now the natural choice.

Crazyradio PA: a small USB dongle that did a lot of work

The second product leaving the store is the Crazyradio PA. It has been our main USB radio dongle for communicating with Crazyflies for many years. Based on the nRF24LU1+, with a power amplifier providing up to 20 dBm output power, it provided the communication link behind everything from someone flying their first Crazyflie to fairly substantial research swarms.

By 2023, though, the nRF24LU1+ platform was becoming increasingly limiting for what we wanted to do next. That led to Crazyradio 2.0, based on the much more capable nRF52840. From the beginning, Crazyradio 2.0 was designed both as a replacement for Crazyradio PA and as a platform on which we could continue developing the communication side of the Crazyflie ecosystem. The nRF52840 gives us substantially more processing power, memory and radio flexibility, as well as a more convenient bootloader and room to experiment with new communication protocols and scheduling strategies.

Earlier this year, for example, we flew 49 Crazyflie 2.1 Brushless drones using a single Crazyradio 2.0 while testing cflib2 and improvements to the radio firmware. That is a useful illustration of why moving the radio platform forward matters: communication is part of the research infrastructure too, especially when experiments start scaling from one robot to many.

What changes for existing users?

Not very much is changing for existing users. If you already have a Z-ranger deck v2 or Crazyradio PA, you can continue using them. Discontinuation does not mean that they suddenly become incompatible with the Crazyflie ecosystem.

For new setups, however, use the Flow deck v2 for downward ranging capability and optical flow measurement. 

And as far as a radio goes, the Crazyradio 2.0 is the only alternative on which ongoing communication development is focused.

Most of us who work on Crazyflie firmware live in one corner of it at a time — a driver here, a control loop there — and rarely step back to see the whole tree at once. We built a treemap of the firmware to do exactly that: one picture, every source file, sized by how much code it actually is and grouped by the directory it lives in. It makes you realize how much is going on in the firmware to make your part work.

How the map was built

The map straight out of a real build: for the cf2 target, we let Kbuild run to completion and then read its own .cmd files, the bookkeeping Kbuild already writes for every compiled object, recording exactly which source file produced it. Group those files by their top-level directory under src/ — deck, drivers, hal, init, lib, modules, platform, utils — plus vendor and scripts alongside, size each tile by lines of code, and the tree draws itself.

The treemap

Below is the top-level view of the crazyflie-firmware. Quite beautiful, right? We think so, at least. It contains years of work from the Bitcraze team and all of you out there who have directly contributed or indirectly by finding bugs and asking for new features.

Click into modules/src and it’s 91 files, 27,680 lines — the flight logic. hal/src is leaner: 21 files, 7,036 lines, sitting right above the raw drivers.

Walking the tree

Ordered the way the map itself reads, biggest tile first:

  • vendor — a second, separate pile of third-party code (FreeRTOS itself, libdw1000, test frameworks), distinct from lib.
  • lib — vendored third-party libraries the firmware builds on (the STM32 standard peripheral library, CMSIS, FatFS, Segger RTT).
  • drivers — low-level code talking directly to individual chips: sensors, radio, motors.
  • modules — the flight logic: commander, controller, state estimator, Kalman filter, CRTP handling.
  • deck — drivers for the decks (flow deck, lighthouse, LED ring, and the rest), detected and brought up at runtime.
  • hal — the hardware abstraction layer sitting above the raw drivers (sensor fusion input, power management, storage) that the rest of the firmware calls into.
  • utils — small shared helpers used across the rest of the tree: CRC, PID, filters, assertions.
  • scripts — build tooling (Kconfig, Makefiles, dependency-checking scripts). Sized like everything else, but none of it is actually compiled into the firmware.

platform and init are in there too, but at this scale they barely register as pixels — more on why that’s fitting below.

Some observations

Diff two builds instead of looking at just one, and a couple of things pop out that are easy to state but satisfying to actually go and check.

CF2 vs. CF2.1 Brushless. These are two different physical boards, but walk the diff and the only directories where a single file differs are hal/src and platform/src. Everything else in the tree — all of modules, all of drivers, all of lib — is the same source code, regardless of whether it ends up on a brushed or a brushless frame. The resulting code differs mainly due to the configuration found in e.g. platform_defaults_cf2.h.

sensors_mpy9250_lps25h.c in the bottom left corner is not compiled into the Brushless – it does not have those sensors. The same is true for Crazyflie 2.1. However, the Crazyflie 2.0 has these sensors. The sensor setting is selected at runtime, which is why you can flash your CF2.0 and CF2.1 with the same firmware.

Every controller ships in every build. modules/src has a whole cluster of controllers sitting side by side — PID, Mellinger, INDI, Brescianini, Lee — and all of them get compiled in. Which controller actually flies the drone is a parameter you can flip at runtime.

Closing thoughts

Line them all up and the codebase is huge, but the part of it that’s actually specific to one physical board is tiny. platform and init — the directories that differ per board and handle bringing the system up — barely show up next to vendor and modules. That’s easy to feel intuitively after enough time in the codebase, and much easier to actually see laid out flat like this.

It would take a long time to work your way through every corner of this tree, if you ever fully do. The tool that generates this map can be found here, and it works on one or two (compare) Kbuild targets. It already has compiled examples.

Is this an interesting way to look at a codebase you already partly know? And now that it’s laid out flat in front of you — is there anything in here that looks like it could use some tidying up? We’d like to hear about it.

What does it take to bring a new coordination stack to the Crazyflie? In this guest post, Jim Steele, founder of Tapestry OS, shares his experience building a Zephyr-based firmware port for the Crazyflie 2.1 Brushless and using it to explore decentralized coordination with three drones. We’re happy to welcome Jim to the blog to share the work and what he learned along the way.

The Crazyflie platform has an excellent answer to the question of how to fly a drone autonomously. The firmware is well-documented and actively maintained with hardware abstraction, sensor drivers, and state estimators providing solid infrastructure that a research team can build on confidently.

The question I kept running into is one layer above that: once you have drones that can fly reliably, how do you coordinate what a collective of them does together? Not at the trajectory level (Crazyswarm2 handles that well) but at the level of distributed state: what does each drone know about where the others are, how fresh is that information, and how does the collective continue functioning correctly when a drone fails or communication is interrupted?

3 Brushless flying seen on a beige workplace background

Most research teams answer this question by writing custom coordination firmware specific to their experiment. The result works, but it does not transfer to the next experiment or the next platform. I wanted an answer that would.

Tapestry OS provides this layer as an open-source coordination stack built on Zephyr RTOS. It includes a distributed world model, gossip-based state propagation, fault-tolerant consensus, and a declarative application API that lets domain experts express collective behavior without touching the underlying firmware. This post is about porting Tapestry to the Crazyflie 2.1 Brushless and validating its core coordination claim on three drones flying in collective formation.

The port

Tapestry’s stack has seven layers, L1 through L7. For the Crazyflie port, the work lives in L1: the Physical Substrate Interface, Tapestry’s equivalent of a board support package. We began by developing a native Zephyr port for the Crazyflie 2.1 Brushless. This had to include the flight control itself: attitude (rate + angle), altitude-hold, position-hold loops, sensor drivers, and a Lighthouse V2 deck driver. Bitcraze stock firmware was an invaluable reference (the control cascade architecture and the Lighthouse calibration math especially) though Tapestry’s implementation is written from scratch and shares no code with it. 

Bring-up including L2 had some surprises, including two real bugs in Zephyr’s STM32 I2C driver that the Tapestry repository carries as patches until they are upstreamed. Streaming console output over the Crazyradio early in the port made debugging much less painful.

Lighthouse positioning took the longest. The interesting problems were pairing the base station’s sweep planes correctly from raw deck timestamps, and rejecting phantom rays from specular room reflections. The eventual implemented solution gates rays against the base station’s optical field of view (a hardware constant that survives recalibration) plus triangulation-consistency and rate-of-motion checks. Once resolved, position accuracy is solid.

Tapestry’s higher layers, including the L3 gossip transport and the L4 Collective State Manager, required no changes. That is the point: once the foundation is in place, the coordination logic does not care whether it is running on a ground robot or a drone.

The formation demo

Three Crazyflie 2.1 Brushless drones, each running Zephyr with the Tapestry substrate and collective world model, were flown in a simple formation. Each drone reads its own absolute position from the Lighthouse deck and gossips it to its peers every 500 ms over the nRF51’s peer-to-peer radio channel. The resulting world model holds fresh entries for its two peers, with staleness tracking, and continually compares its distance to each fresh peer against a target spacing: too close pushes away, too far pulls closer. 

The example formation in the following video shows two drones hover and align in equilibrium. When a third powers on and flies among them, the three maintain separation until the third drone ends its mission, lands itself, and the remaining two close back into their line before landing.

There is no leader, no ground station, and no phase script: each drone runs Tapestry’s decentralized world model and shares only its own position over gossip. The recovery behavior is the part to watch closely. When one drone ends its mission, it lands and goes silent. The remaining two re-form their line about ten seconds after the departure, without any instruction from an external system. This is deliberately the same code path that would handle a real mid-flight interruption. 

This is Tapestry’s first demonstration on real Crazyflie drones: a coherent shared understanding of collective state, maintained entirely through peer-to-peer gossip, driving behavior through local rules. The demo logic can be expressed as a declarative L7 Choreo with the Tapestry SDK without touching firmware.

What is available

The Crazyflie 2.1 Brushless support is in the Tapestry OS repository under Apache 2.0. It includes the steps to recreate this demo: per-drone configuration, Lighthouse calibration, and ESC provisioning.

This is an initial port. We chose Zephyr to unlock a standardized, scalable ecosystem that allows the Crazyflie to integrate with industrial-grade RTOS tooling. We chose standard PWM for this port to simplify the initial Zephyr hardware abstraction with a stable and reliable baseline for our formation coordination logic. A number of Crazyflie capabilities are not yet available on the Zephyr-based stack (Kalman estimation, flow deck, and DSHOT among them), and contributions are welcome.

If you are doing swarm research on the Crazyflie and want coordination infrastructure you do not have to build yourself, the Tapestry repository is a good starting point. Try the port, open an issue if you hit hardware-specific bugs, and share your formation experiments on GitHub or in the Bitcraze forum.

We’re happy to announce that release 2026.08 is now available. This update ships a reworked lighthouse geometry estimator with a redesigned interactive Lighthouse tab, bidirectional DSHOT RPM telemetry, and a new deck supervisor for runtime deck health monitoring, along with a number of smaller bug fixes and quality-of-life improvements. Alongside the release, we’ve also shipped a fix for a long-standing lighthouse FPGA decode issue affecting simultaneous sensor hits. Thanks to our community contributors for their valuable additions to this release.

Major updates

Lighthouse geometry estimator rework
A large rework of the lighthouse base station geometry estimation (cflib + cfclient), replacing the old batch estimation script with a continuous, interactive workflow built into the client. Base stations and samples can now be added, removed, and verified live during a session, while the updated UI provides a live status feedback. Thanks to @krichardsson and @cafeciaojoe for their work in this project.

Bidirectional DSHOT and RPM telemetry
Motors driven over bidirectional DSHOT can now report their measured RPM back to the firmware. This feeds both telemetry and a new arming check: each motor is spun up and confirmed to actually be turning at the requested RPM before arming is allowed, catching a disconnected or seized motor before takeoff instead of after. Thanks to @EliaCareda for this contribution.

Deck supervisor
A new deck supervisor subsystem continuously monitors deck health at runtime, mirroring the role the platform supervisor plays for the flight controller itself. A deck that stops responding or reports a fault now surfaces an explicit error code instead of a simple alive/not-alive flag, so problems can be diagnosed rather than just detected.

Radio platform-packet handling moved into the nRF51 interrupt
All null CRTP platform packets — P2P, battery-voltage polling, bootloader, radio commands, safelink init — are now handled entirely inside the nRF51’s radio interrupt handler instead of being passed through safelink to the STM32. Battery-voltage queries in particular are answered directly from a packet rebuilt every ADC cycle, keeping this traffic off the application processor and giving these commands a fast, consistent response path.

Lighthouse FPGA: simultaneous sensor hit decode fix
Fixes a bug where a sweep crossing two sensors at (nearly) the same instant broke LFSR channel decoding and caused the firmware to discard the entire sweep block. This update belongs to the lighthouse-fpga repository. You can update your Lighthouse deck by flashing the 2026.08 release firmware via cfclient.

Persistent parameters settable from apps
Parameters marked PARAM_PERSISTENT can now be set from firmware apps, not just from a connected client, and their stored value is enforced/restored at boot.

Release overview

crazyflie-firmware release 2026.08 GitHub

crazyflie2-nrf-firmware release 2026.08 GitHub

cfclient (crazyflie-clients-python) release 2026.8 GitHub, PyPi

cflib (crazyflie-lib-python) release 0.1.33 GitHub, PyPi

Inheriting an experiment is often harder than building one. A PhD student graduates. A postdoc moves on. A sensor gets discontinued, and six months later, reproducing the earlier work means reconstructing a software environment, rebuilding a hardware setup, and re-deriving assumptions that were never written down anywhere. The paper is still there, but the experiment usually isn’t.

Reproducibility is normally discussed in terms of published results: can someone else get the same numbers from the same method, but in practice, most labs run into a different problem first, and it’s a more mundane one. Continuity. A new student needs to take over a project without starting from scratch, or a collaborating lab needs to replicate a setup without rebuilding the surrounding infrastructure. Then the experiment itself needs room to evolve without dragging everything underneath it into a rewrite.

Preserving context, not just code

Code and datasets are easier to share now than they’ve ever been, and that’s real progress. But a repository is not the same thing as an experiment. What a new student actually inherits is a pile of things that rarely make it into a GitHub repo: hardware configurations, positioning system calibration, flight scripts tuned by trial and error, a specific combination of dependency versions that happens to work, and a layer of tacit lab knowledge. That last part is usually the stuff someone would tell you in five minutes at the whiteboard. It never gets written down.

The problem compounds as the work moves forward. A sensor gets replaced. ROS moves to a new version. New questions branch off from the original project, and each one drags a little more infrastructure along with it.

A stable platform doesn’t solve reproducibility. Poorly documented assumptions are still poorly documented assumptions. But it can remove one source of uncertainty: the platform underneath the experiment hasn’t become something completely different. That matters when the next researcher needs to understand what was built before they can build on it.

Compatibility over time has research value

Infrastructure that survives across multiple projects tends to become more useful with time. A platform a lab can keep using across student cohorts and research directions accumulates knowledge around it: working configurations, scripts, extensions, troubleshooting experience and, eventually, people who know how the pieces fit together.

That’s one of the less obvious benefits of the Crazyflie® ecosystem. The platform has changed considerably over the years, as it should. Hardware has evolved, APIs have developed and tools have come and gone. But much of the underlying architecture and the way the pieces relate to each other remains recognizable.

That technical lineage matters. Someone returning to Crazyflie research from five or even ten years ago won’t find exactly the same system, but neither will they find an unrelated one. The communication model, firmware architecture, development tools and approach to hardware extensions have evolved incrementally rather than being repeatedly replaced.

It means older work can remain useful as a starting point rather than simply becoming a historical reference.

Reproducibility between people, not just between runs

Reproducing an experimental result and continuing someone else’s research aren’t quite the same problem. But they share much of the same infrastructure.

Robotics has irreducible uncertainty in it, and no platform removes that. What a well-designed, long-lived platform can do is lower the cost of understanding, reconstructing and extending previous work.

It’s a less visible kind of value than a benchmark result. But in labs where a project outlives the people who started it, that continuity is often what makes cumulative research possible at all

Did you know?

  • Today’s firmware still supports Crazyflie 2.0 (apart from certin recent features)
  • You can take over someone else’s sysid work. If you would build your own platform you would need to redo that. (When the Crazyflie 2.1 Brushless came out immediately people rushed to get out their sys id papers. There’s multiple out there now already.)
  • CRTP (the radio protocol) has been stable for over a decade.
  • Param/log TOC lets the Crazyflie tell a client at runtime what parameters/logs are available. This (among other things) allows years-old scripts to maintain compatibility with newer firmwares and even across different platforms in the ecosystem.
  • The firmware reports its own firmware revision so user logs can include this.
  • The deck port (the pins) are unchanged. The deck working on your Crazyflie 2.0 works on your Crazyflie 2.1 Brushless.
  • Out-of-tree extension points; allows writing apps controllers and estimators for the community to separate their work from our firmware version.

Flying formations with a swarm is always fun to develop and watch, but it is also a great way to stress-test the software behind it. As part of the development of cflib2, we put it through one of its toughest tests yet: flying 49 Crazyflies in coordinated formations.

The entire swarm was controlled using a single Crazyradio 2.0, highlighting the combined improvements in cflib2 and Crazyradio firmware over the past few months.

The setup

The hardware configuration was relatively straightforward. We used 49 Crazyflie 2.1 Brushless drones, each one equipped with a bottom-mounted Color LED deck for vivid lighting effects. For positioning, we used the Lighthouse positioning system, covering the entire flight area, which was roughly 5x5x2m. Its accuracy allowed the Crazyflies to fly grid formations with just 0.4m spacing between them.

One of the big practical challenges when managing a large swarm is swapping the depleted batteries for charged ones. Thanks to the Crazyflie 2.1 Brushless PCB design, each drone can now charge while sitting on its charging dock, making it much easier to prepare the swarm for the next flight.

Flying the formations

The swarm performed a sequence of synchronized formations under the control of a central PC. Rather than streaming the full trajectories to every drone, the formations are built using the Crazyflie’s High-Level Commander. Each Crazyflie receives simple motion commands such as go to or spiral, and executes the corresponding trajectory onboard. At the same time, it receives commands for changing the color of the Color LED deck.

Using cflib2, these commands can be sent to all 49 Crazyflies through a singe Crazyradio 2.0, which was not possible with cflib.

Looking ahead

This demonstration is an exciting milestone for cflib2 and showcases what the new library makes possible. While controlling 49 Crazyflies is an impressive demonstration, cflib2 is designed to benefit projects of every size. Whether you are flying a single Crazyflie or coordinating a large swarm, the goal is to provide a faster, more scalable, and more robust communication library.

Most of the functionalities from cflib have already been migrated to cflib2, and development is continuing. For many applications, cflib2 is already ready to use, so if you would like to try it out, you can find the repository here.