Author: Arnaud

Hi, Monday again. We just passed the two most exiting weeks in Bitcraze history. As we speak we are passing the 1K Crazyflie sold which is about 5 times over our optimistic estimations. Now the pressure is on, and there is still one week of pre-order left :-).

We are continuing to update the documentation, working on Crazyflie firmware, the PC gui client and as well all emails/administrative work that takes a surprising amount of time :-). Due to popular interest the focus has been on getting the client to work on Mac OSX and getting Crazyflie to work in a standalone mode (ie. no PC) with an E-sky R/C transmitter which is compatible with our radio chip. The transmitter is almost working (still some mapping issues to work out) and the OSX proof-of-concept is on the way to work (it should work out of the box if all the python libs where 64bits).

We should probably clarify that the PS3 controller we use to control the Crazyflie is just one possible input method. Actually any input device could be used which could be translated into roll, pitch, yaw and thrust. The GUI also simplifies it as there is a configuration dialog and soon we might have our first contribution which is for the xbox controller :-)

We are continually updating the wiki and are starting to get some activity on the forum. It is the right place to go if you have questions or want to discuss about the Crazyflie.

Thanks again for supporting us, one more crazy pre-order week to go!

After one week of flying the new copters we have to say that they are preforming very well. We’ve done a lot of crashes but only had one incident with a bent axis on one of the motors which we fixed by replacing the motor.

We have noticed that using some radio channels in combination with some link speeds causes too much packet drops when the motors are powered. It’s almost certainly the PWM that causes ripples on the power supply and that effects the radio transmission. It was by chance we saw this and changing the channel or speed works around the problem.

Currently we are working with Seeedstudio to sort out the details for starting up but we don’t have an estimate for when it will happen yet. But one thing is for sure, we will go with the rapid-prototype mounts for the first DIY kit. We are still working on the details for the molded motor mounts but since there’s a lot of leadtimes for this it would delay the kit with months and we really don’t want that. Since after the summer we have been using the same design for the rapid-prototype motor mounts and we have only had 2 that has broken.

The plan is to package 1 spare motor, 1 spare motor mount and 4 spare propellers with the kit. There will also be extra spare parts available for purchase.

Last week we received one of the new raspberry pi and we wanted to start doing something useful with it. One idea that came directly in mind was to control the copter with it. As it has 2 USB port it should be possible to use one for the gamepad and one for the Crazyradio dongle.

The Raspberry pi running Debian the operation ended up being surprisingly easy: Just apt-get install python, pygame and pyUSB and we where able to run our old script. By adding pyQT we where even able to run the GUI out of the box (it is still a bit heavy though as the GUI is not yet very optimized when receiving fast log informations). So we just made a “headless” version of the control software, launched it automatically with a udev rule when the radio is inserted and it was done!

We can power the Raspberry pi with a USB battery and we now have a small portable ground station for the Crazyflie. We have also proven that our PC software tools are easily portable to other architecture thanks to Python and all its libs. Currently the software is tested on Windows and Linux (x86 and ARM), but it should also work on MAC.

Raspberry PI controlling the Crazyflie

We just finished the top level BOM, test plan, fabrication files, etc… which mean everything required to order the pre-series of the Crazyflie. The pre-series  is meant to be last version before the first real production batch and the idea of it is so that we can test the manufacturing and verify that it is manufactured with good quality.

One of the last minute changes we made for the pre-series has been to power the motors directly from the battery instead of through the power management chip. This should gives us up to 8% more power and efficiency due to power management mosfet on-resistance losses. It should also reducing the voltage drop which causes disturbances to the other circuits. The only drawback is that the Crazyflie consume a bit more power when OFF, because of the leakage current through the motor mosfets, but it is still within acceptable limits (a full battery will still take more than 2 years to be depleted by our electronics). Also the battery can now be swapped/disconnected for storage as we have added a connector.

Our target is to have the Crazyflie DIY kit availible for X-mas. It is very tight and it will be hard but what would life be without challenges :-)

After the LED hack we are back with an inductive charging hack!

The idea of charging Crazyflie inductively is almost as old as the copter itself. Last week we received a Palm Touchstone charging kit that we ordered. Like many phone hacks using this inductive charger we dismounted the receiving coil and electronic and attach it to the Crazyflie:

As the Crazyflie has a power-management circuit, any supplied voltage above ~4.5V will make it charge, and as we have made some soldering pads available for things like this it was a simple task. The coil is very thin and light (about 3g) so the flight performance are not affected a lot by the change. The charger is working very well and provides enough current for charging. We charge with a little less then 500mA and we think the Touchstone can supply up to 1A. One possible problem though is that the copter has to be placed exactly in the middle of the charging station to be able to charge. The phone has magnets to align it to the charge station and on top of that the charge station is not straight but tilted. The magnets are way to strong to let the Crazyflie take off so we are trying to find a landing area design that would permit the copter to land in the right spot and still be able to take off again without the magnets, any ideas?

A couple of weeks ago we discovered that the sensors of our new prototype where not functioning. We have now received new MPU-6050 sensors from Seeedstudio that we are going to solder with hot-air during the week (photos of the soldering will be posted during later this week).

On the manufacturing side we received the motors we will use which brings us one step closer to making the Crazyflie available (as long as everything else is working :-))

On the software side we are working hard to clean up the copter firmware and PC client architecture. The goal is to make it as easy as possible to setup and fly but also to modify or tweak.

 

We are still working hard on the Crazyflie code while we are waiting for the new prototypes. We are also working on finalizing the Crazyradio, the radio dongle we are making to communicate with Crazyflie.

In order for us to test the radio hardware performance we brought a RFExplorer:

The radio chip (nRF24U1) is put in continuous carrier mode, which makes it emit constantly at a single frequency. Below is a screenshot of the measured frequency and power from the radio dongle:

This measurement is not that useful as an absolute value (for one we do not have a RF test chamber) but it will give us the opportunity to compare the next prototype with this one. Our next radio prototype uses smaller SMD component for the RF parts which is supposed to give better performance. We already compared it with another dev board and our radio seems to have similar performance :).

While waiting for our next round of prototypes we are continuing the work on the software. As we feel that the copter is now stable enough for release we are concentrating on making the software easier to use and better organized.

We have also run a little profiling test on the Crazyflie firmware to see how much CPU was used by the current stabilisation algorithm. We use FreeRTOS and added some functionality to log all the task transitions.  The first result was quite worrying as it seems that we where using about 90% of the avaliable CPU. After further investigation is appeared that the problem came from the fact that we where testing Debug buils. When optimizing for size (-Os of GCC) it brings us back to 70% cpu usage and optimisation for speed (-O3) to 65%:

We are currently running two sensor fusion algorithms in parallel and have a lot of room for improvement for the code efficiency but we believe that would be good enough.

There has also been some work done on the PC GUI, there are now more flight settings and it is easier to use. We are currently adding a Joystick configuration window to be able to add support for new joysticks/gamepads more easily:

Crazyflie GUI: Flight data tab

To begin with, we have just created a Bitcraze Announcement google-group that we will use as a very-low-volume mailing list to make big announcements like the release of Crazyflie. So if you are interested by buying Crazyflie just subscribe to the list and you will receive a mail as soon as it becomes available.

 

As for the project, we are now waiting for the next (and hopefully last) prototype run. In the mean time we are trying to fix everything from the todo-list. One item was to verify that the radio dongle can receive PPM signal from a RC remote, as it was designed for. This is what I  have been working on last week and the result hardware-wise is this kind of hacked programming/RC-training cable attached to our radio dongle:

The idea is to be able to control Crazyflie using a RC transmitter only (without a computer) so that the radio dongle would be powered and controlled by the RC transmitter. This kind of transmitter generates a PPM (Pulse Position Modulated) signal which is acquired from the training jack of our ‘Turnigy 9X’ transmitter. We do not plan to manufacture such cables right now as there are too much kind of RC transmitter around there  and we believe that you will be able to hook the Crazyradio dongle to your transmitter without problem :-).

As the cotper firmware can not fly easily without the PC yet (most of the settings are still sent from the PC software before flight) we decided, as a first step, to use the PC anyway but by using the radio dongle for the PPM acquisition:

A HID USB joystick mode has been added to the radio dongle so that it is now recognized as a joystick by the PC (in addition to the radio endpoints) and transmits the axis position of the RC transmitter to the PC. By mapping the axis the same way a Plastation3 gamepad is mapped we could fly Crazyflie with the RC remote and with an unmodified version of our PC software. This permitted to verify that the radio dongle can acquire PPM signals (with a little hardware change that has been sent just-in-time to our manufacturer for the next prototype) and so Crazyflie will also be able to fly without PC :-). In the case of our radio transmitter however we will have to connect the radio dongle to the TX module port instead of the training jack as the training jack does not provide power.

This is still work in progress and it is unlikely the ‘pc-free’ functionality will be finished before the copter release but at least now we know that the hardware can do it.

To communicate with the Crazyflie we are using a custom radio protocol with almost-baseband 2.4GHz radio chips: the nRF24 family from Nordic semiconductor. This kind of radio chip is easy to cable, easy to use and require a very minimal software stack. Wifi or bluetooth would have required a lot more electronic and software so we chose to not use them for the Crazyflie. We however made sure to keep the possibility to add other radio on an expansion board (ie. both UART and SPI are available on the expansion connector).

One things with using a custom radio is that we have to make a computer interface in order to be able to communicate with the copter. We called it the Crazyradio dongle:

 

This radio dongle is built around a nRF24LU1p chip which contains, among other things, the radio transceiver, a 8051 microcontroller and an USB device peripheral. We wrote the firmware running in the nRF24LU1 from scratch and it is compiled with the SDCC compiler. This firmware source code is going to be open like the rest of the copter code.

The radio is bidirectional which permits to send command and receive telemetry from the copter. The bandwidth is not great but has been enough to debug the regulation. On the computer side we are using python and pyUsb to interface the radio dongle.

We have added a 10 pins connector that can be used to program the dongle for development purposes (the dongle can also be updated via USB) or to power the electronic and provide signals input/output. We designed the dongle in such a way that it is going to be possible to power it with up to 15V and to input a PPM signal. This will permit to use this radio dongle with a RC remote control (ie. to control the copter without the need of a PC).