This page has deprecated and moved to the new documentation framework of the main Bitcraze website. Please go to [[https://www.bitcraze.io/]] and go to the menu 'products'.
The BigQuad deck is currently part of our [[https://www.bitcraze.io/early-access/|early access program]]. To better understand what this means also have a look at our [[https://www.bitcraze.io/product-cycle/|Product cycle]].
====== BigQuad expansion deck ======
With the BigQuad deck you can transform your Crazyflie 2.0 to a bigger quad by connecting external ESCs (Electronic Speed Controller) to the breakout connectors on the deck. The autodetection of the deck makes this transformation possible to do in seconds. The deck contains breakout header connectors for additional accessories such as external receiver (CPPM input) and GPS. It also has the possibility to monitor battery voltage and current.
The deck is designed to be installed either on the top or the bottom of the Crazyflie.
Drivers for the BigQuad are integrated in the Crazyflie 2.0 firmware.
===== Specification =====
{{ :projects:crazyflie2:expansionboards:bigquad-revc-top.png?400 |}}
* 4 x ESC connectors
* 0.1” header mounting holes for additional connectivity:
* CPPM input (3 pin)
* GPS input (4 pin)
* I2C expansion (4 pin)
* Battery and current monitoring input (3 pin)
* Buzzer output (2 pin)
* Connect one or two additional decks
* Automatic detection of expansion deck
Electrical specification:
* Power Crazyflie 2.0 with 4.5V - 5.5V from ESC.
* BiqQuad deck inputs are 5V tolerant.
* Battery voltage monitoring divider scaled for input up to 23V.
* Current monitoring input 0V - 3V.
* BiqQuad deck and Crazyflie 2.0 current consumption:
* ~120mA without any additional decks.
* Up to 500mA if Crazyflie 2.0 battery is connected and charging.
* 1-wire memory for automatic expansion deck detection.
Mechanical specification:
* Weight: 3.8g
* Size (WxHxD): 36x40x5mm
* M3 mounting holes placed 30.5mm square.
* Designed for mounting above or under the Crazyflie 2.0
Package contents:
* 1 x BigQuad deck
* 4 x M2x4 nylon screw
* 2 x M2x6 hex spacer
===== Schematic =====
BigQuad expansion deck {{:projects:crazyflie2:expansionboards:bigquad-revc.pdf|schematic}}.
===== Compatibility with Loco deck, microSD and Flow (v2) deck =====
{{ :projects:crazyflie2:expansionboards:bigquaddeck-remove-c1.png?nolink|}}
The Loco deck, microSD and Flow (v2) deck all uses the SPI bus. As the BigQuad deck uses the deck SPI buss pins for possible voltage and current measurement, and they are multiplexed with analog input, the BigQuad deck is not out-of-the-box compatible with these decks. This can fixed:
- By removing capacitor C1 on the BigQuad deck. See image on the right.
- Not having BQ_DECK_ENABLE_PM defined.
- Disabling the extRx functionality by commenting out [[https://github.com/bitcraze/crazyflie-firmware/blob/master/src/deck/drivers/src/bigquad.c#L84|extRxInit()]] in bigquad.c
Capacitor C1 is used to filter the current measurement and removing this has the effect that it will not be filtered any more. Still possible to use it if a deck using the SPI is not wanted any more.
To make it work with the Flow (v2) deck more changes/patching are needed.
- The Flow HW ChipSelect (IO3) interfere with BigQuad PWM and needs to be moved. Cut trace and solder patch on Flow deck from IO3 to IO1.
- Change the CS pin in [[https://github.com/bitcraze/crazyflie-firmware/blob/master/src/deck/drivers/src/flowdeck_v1v2.c#L72|flowdeck_v1v2.c]] (IO3 -> IO1)
Next problem is how to mount the deck in a nice way on the quad, we leave that up to you.
====== Setting up ======
====A big quad is dangerous so make sure to be SAFE!====
Currently there is only a basic setup but as the development advances so will the documentation.
Start by mounting the big quad deck on the frame. After that connect the ESCs according to the diagrams below. **Note** that the 5V is needed for the motor signals and is not optional.
===== Basic connection diagram =====
{{:projects:crazyflie2:expansionboards:esc-basic-setup.png?direct&600|}}
===== Basic connection picture =====
{{:projects:crazyflie2:expansionboards:bigquad-basic-connection.png?direct&600|}}
===== Attaching the Crazyflie 2.0 =====
The front of the Crazyflie 2.0 should be pointing in the direction of the arrows (front) on the BigQuad deck.
If the frame allows it, the Crazyflie 2.0 motors can be kept mounted but it is fine to remove them as well. Attach and connect the Crazyflie 2.0 using either the long or short deck pins. Use the included nylon spacer and screws to secure the Crazyflie 2.0 in place and to keep it level.
{{ :projects:crazyflie2:expansionboards:bigquaddeck-2.jpg?direct&400|}}
====== Building Firmware ======
The BigQuad deck contains a 1-wire memory so it can be automatically detected and functions initialized. However as this currently is an ongoing development and a bigger quads ads a new level of caution we have decided to not enable the functionality by default. Therefore the firmware needs to be compiled with the ENABLE_BQ_DECK flag enabled.
==== Enable BigQuad features ====
Make sure to have the crazyflie-firmware code updated to a later version then [[https://github.com/bitcraze/crazyflie-firmware/commit/dbaaa914a54bf31a6bf155b26b09c472dc684086|this commit]].
Then define the flag [[https://github.com/bitcraze/crazyflie-firmware/blob/master/deck/drivers/src/bigquad.c#L84|ENABLE_BQ_DECK]], preferably in the [[https://github.com/bitcraze/crazyflie-firmware/blob/master/tools/make/config.mk.example|config.mk]] file add
CFLAGS += -DENABLE_BQ_DECK
Clean and build the firmware and flash it using you preferred method.
Now when the Crazyflie 2.0 is started and it is connected to the BigQuad deck it will start outputting PWM signals to the ESC connectors. The motors [[https://forum.bitcraze.io/viewtopic.php?f=6&t=2069#p10502|will not spin during the Crazyflie 2.0 power on self-test]] (POST).
===== Current firmware status notes (2019-10)=====
* CPPM input is working but calibration and dynamic channel setup is not implemented yet. Doing the first tests with cfclient and gamepad is wise but might not be as reliable as a RC transmitter and receiver, yet.
* When the BQ-Deck is detected it will automatically switch to brushless motor drivers. It will be noted in the cfclient console if it is detected or not.
* 1mbit or 2mbit datarate seem to be more stable when communicating with the BigQuad deck attached. It is wise to do a range test before flying far away.
* Different PID tuning parameters might be needed for it to fly well. Currently this has to be [[https://github.com/bitcraze/crazyflie-firmware/blob/269730f369b4df34535708d13274abebacb71b5a/src/modules/interface/pid.h|hard coded]]. Later this will be saved in the EEPROM or in the 1-wire memory.
* External battery voltage/current reading is implemented but no logic behind it, so don't run out of battery. You can connect the cable (MON port) and watch the log variable.
* The PWM output is set to 400Hz. Use ESCs which can handle this or compile with [[https://github.com/bitcraze/crazyflie-firmware/blob/269730f369b4df34535708d13274abebacb71b5a/src/drivers/interface/motors.h#L92|new value]]. There is also the possibility to [[https://github.com/bitcraze/crazyflie-firmware/blob/269730f369b4df34535708d13274abebacb71b5a/src/drivers/interface/motors.h#L65|enable]] OneShot125 output.
* **Be safe**, it is experimental software. Run all testing **without** props!
====== Reference setup ======