Commit a588ee08 authored by Pawel Spychalski (DzikuVx)'s avatar Pawel Spychalski (DzikuVx)
Browse files

docs update fixes#282

parent 72050604
...@@ -6,17 +6,15 @@ Clean-code version of baseflight flight-controller - flight controllers are used ...@@ -6,17 +6,15 @@ Clean-code version of baseflight flight-controller - flight controllers are used
This fork differs from baseflight in that it attempts to use modern software development practices which result in: This fork differs from baseflight in that it attempts to use modern software development practices which result in:
1. greater reliability through code robustness and automated testing. 1. greater reliability through code robustness and automated testing.
2. easier maintenance through code cleanliness. 2. easier maintenance through code cleanliness.
3. easier to develop new features. 3. easier to develop new features.
4. easier to re-use code though code de-coupling and modularisation. 4. easier to re-use code though code de-coupling and modularisation.
The MultiWii software, from which baseflight originated, violates many good software development best-practices. Hopefully this fork will go some way to address them. If you see any bad code in this fork please immediately raise an issue so it can be fixed, or better yet submit a pull request. The MultiWii software, from which baseflight originated, violates many good software development best-practices. Hopefully this fork will go some way to address them. If you see any bad code in this fork please immediately raise an issue so it can be fixed, or better yet submit a pull request.
## Additional Features ## Additional Features
Cleanflight also has additional features not found in baseflight.
* Multi-color RGB LED Strip support (each LED can be a different color using variable length WS2811 Addressable RGB strips - use for Orientation Indicators, Low Battery Warning, Flight Mode Status, etc) * Multi-color RGB LED Strip support (each LED can be a different color using variable length WS2811 Addressable RGB strips - use for Orientation Indicators, Low Battery Warning, Flight Mode Status, etc)
* Oneshot ESC support. * Oneshot ESC support.
* Blackbox flight recorder logging (to onboard flash or external SD card). * Blackbox flight recorder logging (to onboard flash or external SD card).
...@@ -50,11 +48,11 @@ http://www.multiwii.com/forum/viewtopic.php?f=23&t=5149 ...@@ -50,11 +48,11 @@ http://www.multiwii.com/forum/viewtopic.php?f=23&t=5149
## Installation ## Installation
See: https://github.com/cleanflight/cleanflight/blob/master/docs/Installation.md See: https://github.com/cleanflight/cleanflight/blob/master/docs/Installation.md
## Documentation ## Documentation
There is lots of documentation here: https://github.com/cleanflight/cleanflight/tree/master/docs There is lots of documentation here: https://github.com/cleanflight/cleanflight/tree/master/docs
If what you need is not covered then refer to the baseflight documentation. If you still can't find what you need then visit the #cleanflight on the Freenode IRC network If what you need is not covered then refer to the baseflight documentation. If you still can't find what you need then visit the #cleanflight on the Freenode IRC network
...@@ -70,7 +68,7 @@ Etiquette: Don't ask to ask and please wait around long enough for a reply - som ...@@ -70,7 +68,7 @@ Etiquette: Don't ask to ask and please wait around long enough for a reply - som
## Videos ## Videos
There is a dedicated Cleanflight youtube channel which has progress update videos, flight demonstrations, instructions and other related videos. There is a dedicated INAV youtube channel which has progress update videos, flight demonstrations, instructions and other related videos.
https://www.youtube.com/playlist?list=PL6H1fAj_XUNVBEcp8vbMH2DrllZAGWkt8 https://www.youtube.com/playlist?list=PL6H1fAj_XUNVBEcp8vbMH2DrllZAGWkt8
...@@ -78,7 +76,7 @@ Please subscribe and '+1' the videos if you find them useful. ...@@ -78,7 +76,7 @@ Please subscribe and '+1' the videos if you find them useful.
## Configuration Tool ## Configuration Tool
To configure Cleanflight you should use the Cleanflight-configurator GUI tool (Windows/OSX/Linux) that can be found here: To configure INAV you should use the INAV-configurator GUI tool (Windows/OSX/Linux) that can be found here:
https://chrome.google.com/webstore/detail/cleanflight-configurator/enacoimjcgeinfnnnpajinjgmkahmfgb https://chrome.google.com/webstore/detail/cleanflight-configurator/enacoimjcgeinfnnnpajinjgmkahmfgb
...@@ -113,7 +111,5 @@ https://travis-ci.org/cleanflight/cleanflight ...@@ -113,7 +111,5 @@ https://travis-ci.org/cleanflight/cleanflight
[![Build Status](https://travis-ci.org/cleanflight/cleanflight.svg?branch=master)](https://travis-ci.org/cleanflight/cleanflight) [![Build Status](https://travis-ci.org/cleanflight/cleanflight.svg?branch=master)](https://travis-ci.org/cleanflight/cleanflight)
## Cleanflight Releases ## INAV Releases
https://github.com/cleanflight/cleanflight/releases https://github.com/cleanflight/cleanflight/releases
...@@ -26,7 +26,7 @@ Currently supported on the SPRACINGF3, STM32F3DISCOVERY, NAZE32 (including clone ...@@ -26,7 +26,7 @@ Currently supported on the SPRACINGF3, STM32F3DISCOVERY, NAZE32 (including clone
## Usage ## Usage
- Plug in the USB cable and connect to your board with the CleanFlight configurator. - Plug in the USB cable and connect to your board with the INAV configurator.
- For boards without a built in USB/UART adapter, you'll need to plug an external one in. Here is how you wire up the CC3D. Plug your USB/UART adapter into the Flexi port: - For boards without a built in USB/UART adapter, you'll need to plug an external one in. Here is how you wire up the CC3D. Plug your USB/UART adapter into the Flexi port:
...@@ -34,9 +34,9 @@ Currently supported on the SPRACINGF3, STM32F3DISCOVERY, NAZE32 (including clone ...@@ -34,9 +34,9 @@ Currently supported on the SPRACINGF3, STM32F3DISCOVERY, NAZE32 (including clone
- Open the BlHeli Suite. - Open the BlHeli Suite.
- Ensure you have selected the correct Atmel or SILABS "Cleanflight" option under the "Select ATMEL / SILABS Interface" menu option. - Ensure you have selected the correct Atmel or SILABS "INAV" option under the "Select ATMEL / SILABS Interface" menu option.
- Ensure you have port for your external USB/UART adapter selected, if you're using one, otherwise pick the same COM port that you normally use for Cleanflight. - Ensure you have port for your external USB/UART adapter selected, if you're using one, otherwise pick the same COM port that you normally use for INAV.
- Click "Connect" and wait for the connection to complete. If you get a COM error, hit connect again. It will probably work. - Click "Connect" and wait for the connection to complete. If you get a COM error, hit connect again. It will probably work.
......
# MSP Extensions # MSP Extensions
Cleanflight includes a number of extensions to the MultiWii Serial Protocol (MSP). This document describes INAV includes a number of extensions to the MultiWii Serial Protocol (MSP). This document describes
those extensions in order that 3rd party tools may identify cleanflight firmware and react appropriately. those extensions in order that 3rd party tools may identify INAV firmware and react appropriately.
Issue the MSP_API_VERSION command to find out if the firmware supports them. Issue the MSP_API_VERSION command to find out if the firmware supports them.
...@@ -28,7 +28,7 @@ Unassigned slots have rangeStartStep == rangeEndStep. Each element contains the ...@@ -28,7 +28,7 @@ Unassigned slots have rangeStartStep == rangeEndStep. Each element contains the
| rangeStartStep | uint8 | The start value for this element in 'blocks' of 25 where 0 == 900 and 48 == 2100 | | rangeStartStep | uint8 | The start value for this element in 'blocks' of 25 where 0 == 900 and 48 == 2100 |
| rangeEndStep | uint8 | The end value for this element in 'blocks' of 25 where 0 == 900 and 48 == 2100 | | rangeEndStep | uint8 | The end value for this element in 'blocks' of 25 where 0 == 900 and 48 == 2100 |
Thus, for a cleanflight firmware with 40 slots 160 bytes would be returned in response to MSP\_MODE\_RANGES, Thus, for a INAV firmware with 40 slots 160 bytes would be returned in response to MSP\_MODE\_RANGES,
### MSP\_SET\_MODE\_RANGE ### MSP\_SET\_MODE\_RANGE
...@@ -52,7 +52,7 @@ sending this message for all auxiliary slots. ...@@ -52,7 +52,7 @@ sending this message for all auxiliary slots.
### Implementation Notes ### Implementation Notes
* The client should make no assumptions about the number of slots available. Rather, the number should be computed * The client should make no assumptions about the number of slots available. Rather, the number should be computed
from the size of the MSP\_MODE\_RANGES message divided by the size of the returned data element (4 bytes); from the size of the MSP\_MODE\_RANGES message divided by the size of the returned data element (4 bytes);
* The client should ensure that all changed items are returned to the flight controller, including those where a * The client should ensure that all changed items are returned to the flight controller, including those where a
switch or range has been disabled; switch or range has been disabled;
...@@ -86,7 +86,7 @@ Unassigned slots have rangeStartStep == rangeEndStep. Each element contains the ...@@ -86,7 +86,7 @@ Unassigned slots have rangeStartStep == rangeEndStep. Each element contains the
| adjustmentFunction | uint8 | See below | | adjustmentFunction | uint8 | See below |
| auxSwitchChannelIndex | uint8 | The Aux channel number used to perform the function (indexed from 0) | | auxSwitchChannelIndex | uint8 | The Aux channel number used to perform the function (indexed from 0) |
Thus, for a cleanflight firmware with 12 slots 72 bytes would be returned in response to MSP\_ADJUSTMENT\_RANGES, Thus, for a INAV firmware with 12 slots 72 bytes would be returned in response to MSP\_ADJUSTMENT\_RANGES,
### MSP\_SET\_ADJUSTMENT\_RANGE ### MSP\_SET\_ADJUSTMENT\_RANGE
...@@ -128,7 +128,7 @@ note: it would be ideal to disable this when armed ...@@ -128,7 +128,7 @@ note: it would be ideal to disable this when armed
The FC maintains internal state for each adjustmentStateIndex, currently 4 simultaneous adjustment states are maintained. Multiple adjustment ranges The FC maintains internal state for each adjustmentStateIndex, currently 4 simultaneous adjustment states are maintained. Multiple adjustment ranges
can be configured to use the same state but care should be taken not to send multiple adjustment ranges that when active would confict. can be configured to use the same state but care should be taken not to send multiple adjustment ranges that when active would confict.
e.g. Configuring two identical adjustment ranges using the same slot would conflict, but configuring two adjustment ranges that used e.g. Configuring two identical adjustment ranges using the same slot would conflict, but configuring two adjustment ranges that used
only one half of the possible channel range each but used the same adjustmentStateIndex would not conflict. only one half of the possible channel range each but used the same adjustmentStateIndex would not conflict.
The FC does NOT check for conflicts. The FC does NOT check for conflicts.
...@@ -139,7 +139,7 @@ There are many adjustments that can be made, the numbers of them and their use i ...@@ -139,7 +139,7 @@ There are many adjustments that can be made, the numbers of them and their use i
### Implementation Notes ### Implementation Notes
* The client should make no assumptions about the number of slots available. Rather, the number should be computed * The client should make no assumptions about the number of slots available. Rather, the number should be computed
from the size of the MSP\_ADJUSTMENT\_RANGES message divided by the size of the returned data element (6 bytes); from the size of the MSP\_ADJUSTMENT\_RANGES message divided by the size of the returned data element (6 bytes);
* The client should ensure that all changed items are returned to the flight controller, including those where a * The client should ensure that all changed items are returned to the flight controller, including those where a
switch or range has been disabled; switch or range has been disabled;
...@@ -150,12 +150,12 @@ There are many adjustments that can be made, the numbers of them and their use i ...@@ -150,12 +150,12 @@ There are many adjustments that can be made, the numbers of them and their use i
The following MSP commands are replaced by the MSP\_MODE\_RANGES and The following MSP commands are replaced by the MSP\_MODE\_RANGES and
MSP\_SET\_MODE\_RANGE extensions, and are not recognised by MSP\_SET\_MODE\_RANGE extensions, and are not recognised by
cleanflight. INAV.
* MSP\_BOX * MSP\_BOX
* MSP\_SET\_BOX * MSP\_SET\_BOX
See also See also
-------- --------
Modes.md describes the user visible implementation for the cleanflight Modes.md describes the user visible implementation for the INAV
modes extension. modes extension.
# Battery Monitoring # Battery Monitoring
Cleanflight has a battery monitoring feature. The voltage of the main battery can be measured by the system and used to trigger a low-battery warning [buzzer](Buzzer.md), on-board status LED flashing and LED strip patterns. INAV has a battery monitoring feature. The voltage of the main battery can be measured by the system and used to trigger a low-battery warning [buzzer](Buzzer.md), on-board status LED flashing and LED strip patterns.
Low battery warnings can: Low battery warnings can:
...@@ -10,7 +10,7 @@ Low battery warnings can: ...@@ -10,7 +10,7 @@ Low battery warnings can:
Minimum and maximum cell voltages can be set, and these voltages are used to auto-detect the number of cells in the battery when it is first connected. Minimum and maximum cell voltages can be set, and these voltages are used to auto-detect the number of cells in the battery when it is first connected.
Per-cell monitoring is not supported, as we only use one ADC to read the battery voltage. Per-cell monitoring is not supported, as we only use one ADC to read the battery voltage.
## Supported targets ## Supported targets
All targets support battery voltage monitoring unless status. All targets support battery voltage monitoring unless status.
...@@ -31,12 +31,12 @@ The Naze32 has an on-board battery divider circuit; just connect your main batte ...@@ -31,12 +31,12 @@ The Naze32 has an on-board battery divider circuit; just connect your main batte
### CC3D ### CC3D
The CC3D has no battery divider. To use voltage monitoring, you must create a divider that gives a 3.3v The CC3D has no battery divider. To use voltage monitoring, you must create a divider that gives a 3.3v
MAXIMUM output when the main battery is fully charged. Connect the divider output to S5_IN/PA0/RC5. MAXIMUM output when the main battery is fully charged. Connect the divider output to S5_IN/PA0/RC5.
Notes: Notes:
* S5_IN/PA0/RC5 is Pin 7 on the 8 pin connector, second to last pin, on the opposite end from the * S5_IN/PA0/RC5 is Pin 7 on the 8 pin connector, second to last pin, on the opposite end from the
GND/+5/PPM signal input. GND/+5/PPM signal input.
* When battery monitoring is enabled on the CC3D, RC5 can no-longer be used for PWM input. * When battery monitoring is enabled on the CC3D, RC5 can no-longer be used for PWM input.
...@@ -88,7 +88,7 @@ feature CURRENT_METER ...@@ -88,7 +88,7 @@ feature CURRENT_METER
Configure the current meter type using the `current_meter_type` settings here: Configure the current meter type using the `current_meter_type` settings here:
| Value | Sensor Type | | Value | Sensor Type |
| ----- | ---------------------- | | ----- | ---------------------- |
| 0 | None | | 0 | None |
| 1 | ADC/hardware sensor | | 1 | ADC/hardware sensor |
| 2 | Virtual sensor | | 2 | Virtual sensor |
...@@ -111,7 +111,7 @@ Use the following settings to adjust calibration: ...@@ -111,7 +111,7 @@ Use the following settings to adjust calibration:
The virtual sensor uses the throttle position to calculate an estimated current value. This is useful when a real sensor is not available. The following settings adjust the virtual sensor calibration: The virtual sensor uses the throttle position to calculate an estimated current value. This is useful when a real sensor is not available. The following settings adjust the virtual sensor calibration:
| Setting | Description | | Setting | Description |
| ----------------------------- | -------------------------------------------------------- | | ----------------------------- | -------------------------------------------------------- |
| `current_meter_scale` | The throttle scaling factor [centiamps, i.e. 1/100th A] | | `current_meter_scale` | The throttle scaling factor [centiamps, i.e. 1/100th A] |
| `current_meter_offset` | The current at zero throttle (while disarmed) [centiamps, i.e. 1/100th A] | | `current_meter_offset` | The current at zero throttle (while disarmed) [centiamps, i.e. 1/100th A] |
...@@ -134,19 +134,19 @@ current_meter_offset = Imin * 100 = 280 ...@@ -134,19 +134,19 @@ current_meter_offset = Imin * 100 = 280
``` ```
#### Tuning Using Battery Charger Measurement #### Tuning Using Battery Charger Measurement
If you cannot measure current draw directly, you can approximate it indirectly using your battery charger. If you cannot measure current draw directly, you can approximate it indirectly using your battery charger.
However, note it may be difficult to adjust `current_meter_offset` using this method unless you can However, note it may be difficult to adjust `current_meter_offset` using this method unless you can
measure the actual current draw with the craft disarmed. measure the actual current draw with the craft disarmed.
Note: Note:
+ This method depends on the accuracy of your battery charger; results may vary. + This method depends on the accuracy of your battery charger; results may vary.
+ If you add or replace equipment that changes the in-flight current draw (e.g. video transmitter, + If you add or replace equipment that changes the in-flight current draw (e.g. video transmitter,
camera, gimbal, motors, prop pitch/sizes, ESCs, etc.), you should recalibrate. camera, gimbal, motors, prop pitch/sizes, ESCs, etc.), you should recalibrate.
The general method is: The general method is:
1. Fully charge your flight battery 1. Fully charge your flight battery
2. Fly your craft, using >50% of your battery pack capacity (estimated) 2. Fly your craft, using >50% of your battery pack capacity (estimated)
3. Note Cleanflight's reported mAh draw 3. Note INAV's reported mAh draw
4. Re-charge your flight battery, noting the mAh charging data needed to restore the pack to fully charged 4. Re-charge your flight battery, noting the mAh charging data needed to restore the pack to fully charged
5. Adjust `current_meter_scale` to according to the formula given below 5. Adjust `current_meter_scale` to according to the formula given below
6. Repeat and test 6. Repeat and test
...@@ -156,7 +156,7 @@ Given (a) the reported mAh draw and the (b) mAh charging data, calculate a new ` ...@@ -156,7 +156,7 @@ Given (a) the reported mAh draw and the (b) mAh charging data, calculate a new `
current_meter_scale = (charging_data_mAh / reported_draw_mAh) * old_current_meter_scale current_meter_scale = (charging_data_mAh / reported_draw_mAh) * old_current_meter_scale
``` ```
For example, assuming: For example, assuming:
+ A Cleanflight reported current draw of 1260 mAh + A INAV reported current draw of 1260 mAh
+ Charging data to restore full charge of 1158 mAh + Charging data to restore full charge of 1158 mAh
+ A existing `current_meter_scale` value of 400 (the default) + A existing `current_meter_scale` value of 400 (the default)
...@@ -166,8 +166,3 @@ current_meter_scale = (charging_data_mAh / reported_draw_mAh) * old_current_mete ...@@ -166,8 +166,3 @@ current_meter_scale = (charging_data_mAh / reported_draw_mAh) * old_current_mete
= (1158 / 1260) * 400 = (1158 / 1260) * 400
= 368 = 368
``` ```
...@@ -34,18 +34,18 @@ can cause the flight log to drop frames and contain errors. ...@@ -34,18 +34,18 @@ can cause the flight log to drop frames and contain errors.
The Blackbox is typically used on tricopters and quadcopters. Although it will work on hexacopters and octocopters, The Blackbox is typically used on tricopters and quadcopters. Although it will work on hexacopters and octocopters,
because these craft have more motors to record, they must transmit more data to the flight log. This can increase the because these craft have more motors to record, they must transmit more data to the flight log. This can increase the
number of dropped frames. Although the browser-based log viewer supports hexacopters and octocopters, the command-line number of dropped frames. Although the browser-based log viewer supports hexacopters and octocopters, the command-line
`blackbox_render` tool currently only supports tri- and quadcopters. `blackbox_render` tool currently only supports tri- and quadcopters.
Cleanflight's `looptime` setting decides how frequently an update is saved to the flight log. The default looptime on INAV's `looptime` setting decides how frequently an update is saved to the flight log. The default looptime on
Cleanflight is 3500. If you're using a looptime smaller than about 2400, you may experience some dropped frames due to INAV is 2000us. If you're using a looptime smaller than about 2400, you may experience some dropped frames due to
the high required data rate. In that case you will need to reduce the sampling rate in the Blackbox settings, or the high required data rate. In that case you will need to reduce the sampling rate in the Blackbox settings, or
increase your logger's baudrate to 250000. See the later section on configuring the Blackbox feature for details. increase your logger's baudrate to 250000. See the later section on configuring the Blackbox feature for details.
## Setting up logging ## Setting up logging
First, you must enable the Blackbox feature. In the [Cleanflight Configurator][] enter the Configuration tab, First, you must enable the Blackbox feature. In the [INAV Configurator][] enter the Configuration tab,
tick the "BLACKBOX" feature at the bottom of the page, and click "Save and reboot" tick the "BLACKBOX" feature at the bottom of the page, and click "Save and reboot"
Now you must decide which device to store your flight logs on. You can either transmit the log data over a serial port Now you must decide which device to store your flight logs on. You can either transmit the log data over a serial port
to an external logging device like the [OpenLog serial data logger][] to be recorded to a microSDHC card, or if you have to an external logging device like the [OpenLog serial data logger][] to be recorded to a microSDHC card, or if you have
...@@ -59,9 +59,9 @@ flights to a MicroSD card. ...@@ -59,9 +59,9 @@ flights to a MicroSD card.
The OpenLog ships from SparkFun with standard "OpenLog 3" firmware installed. Although this original OpenLog firmware The OpenLog ships from SparkFun with standard "OpenLog 3" firmware installed. Although this original OpenLog firmware
will work with the Blackbox, in order to reduce the number of dropped frames it should be reflashed with the will work with the Blackbox, in order to reduce the number of dropped frames it should be reflashed with the
higher performance [OpenLog Blackbox firmware][]. The special Blackbox variant of the OpenLog firmware also ensures that higher performance [OpenLog Blackbox firmware][]. The special Blackbox variant of the OpenLog firmware also ensures that
the OpenLog is using Cleanflight compatible settings, and defaults to 115200 baud. the OpenLog is using INAV compatible settings, and defaults to 115200 baud.
You can find the Blackbox version of the OpenLog firmware [here](https://github.com/cleanflight/blackbox-firmware), You can find the Blackbox version of the OpenLog firmware [here](https://github.com/cleanflight/blackbox-firmware),
along with instructions for installing it onto your OpenLog. along with instructions for installing it onto your OpenLog.
[OpenLog serial data logger]: https://www.sparkfun.com/products/9530 [OpenLog serial data logger]: https://www.sparkfun.com/products/9530
...@@ -95,11 +95,11 @@ First, tell the Blackbox to log using a serial port (rather than to an onboard d ...@@ -95,11 +95,11 @@ First, tell the Blackbox to log using a serial port (rather than to an onboard d
Configurator's CLI tab, enter `set blackbox_device=SERIAL` to switch logging to serial, and Configurator's CLI tab, enter `set blackbox_device=SERIAL` to switch logging to serial, and
save. save.
You need to let Cleanflight know which of [your serial ports][] you connect your OpenLog to (i.e. the Blackbox port), You need to let INAV know which of [your serial ports][] you connect your OpenLog to (i.e. the Blackbox port),
which you can do on the Configurator's Ports tab. which you can do on the Configurator's Ports tab.
You should use a hardware serial port (such as UART1 on the Naze32, the two-pin Tx/Rx header in the center of the You should use a hardware serial port (such as UART1 on the Naze32, the two-pin Tx/Rx header in the center of the
board). SoftSerial ports can be used for the Blackbox. However, because they are limited to 19200 baud, your logging board). SoftSerial ports can be used for the Blackbox. However, because they are limited to 19200 baud, your logging
rate will need to be severely reduced to compensate. Therefore the use of SoftSerial is not recommended. rate will need to be severely reduced to compensate. Therefore the use of SoftSerial is not recommended.
When using a hardware serial port, Blackbox should be set to at least 115200 baud on that port. When using fast When using a hardware serial port, Blackbox should be set to at least 115200 baud on that port. When using fast
...@@ -124,7 +124,7 @@ telemetry pins. ...@@ -124,7 +124,7 @@ telemetry pins.
Pin RC3 on the side of the board is UART2's Tx pin. If Blackbox is configured on UART2, MSP can still be used on UART1 Pin RC3 on the side of the board is UART2's Tx pin. If Blackbox is configured on UART2, MSP can still be used on UART1
when the board is armed, which means that the Configurator will continue to work simultaneously with Blackbox logging. when the board is armed, which means that the Configurator will continue to work simultaneously with Blackbox logging.
Note that in `PARALLEL_PWM` mode this leaves the board with 6 input channels as RC3 and RC4 pins are used by UART2 as Tx and Rx. Cleanflight automatically shifts logical channel mapping for you when UART2 is enabled in `Ports` tab so you'll have to shift receiver pins that are connected to Naze32 pins 3 to 6 by two. Note that in `PARALLEL_PWM` mode this leaves the board with 6 input channels as RC3 and RC4 pins are used by UART2 as Tx and Rx. INAV automatically shifts logical channel mapping for you when UART2 is enabled in `Ports` tab so you'll have to shift receiver pins that are connected to Naze32 pins 3 to 6 by two.
The OpenLog tolerates a power supply of between 3.3V and 12V. If you are powering your Naze32 with a standard 5V BEC, The OpenLog tolerates a power supply of between 3.3V and 12V. If you are powering your Naze32 with a standard 5V BEC,
then you can use a spare motor header's +5V and GND pins to power the OpenLog with. then you can use a spare motor header's +5V and GND pins to power the OpenLog with.
...@@ -192,19 +192,19 @@ On the Configurator's CLI tab, you must enter `set blackbox_device=SPIFLASH` to ...@@ -192,19 +192,19 @@ On the Configurator's CLI tab, you must enter `set blackbox_device=SPIFLASH` to
then save. then save.
[your serial ports]: https://github.com/cleanflight/cleanflight/blob/master/docs/Serial.md [your serial ports]: https://github.com/cleanflight/cleanflight/blob/master/docs/Serial.md
[Cleanflight Configurator]: https://chrome.google.com/webstore/detail/cleanflight-configurator/enacoimjcgeinfnnnpajinjgmkahmfgb?hl=en [INAV Configurator]: https://chrome.google.com/webstore/detail/cleanflight-configurator/enacoimjcgeinfnnnpajinjgmkahmfgb?hl=en
## Configuring the Blackbox ## Configuring the Blackbox
The Blackbox currently provides two settings (`blackbox_rate_num` and `blackbox_rate_denom`) that allow you to control The Blackbox currently provides two settings (`blackbox_rate_num` and `blackbox_rate_denom`) that allow you to control
the rate at which data is logged. These two together form a fraction (`blackbox_rate_num / blackbox_rate_denom`) which the rate at which data is logged. These two together form a fraction (`blackbox_rate_num / blackbox_rate_denom`) which
decides what portion of the flight controller's control loop iterations should be logged. The default is 1/1 which logs decides what portion of the flight controller's control loop iterations should be logged. The default is 1/1 which logs
every iteration. every iteration.
If you're using a slower MicroSD card, you may need to reduce your logging rate to reduce the number of corrupted If you're using a slower MicroSD card, you may need to reduce your logging rate to reduce the number of corrupted
logged frames that `blackbox_decode` complains about. A rate of 1/2 is likely to work for most craft. logged frames that `blackbox_decode` complains about. A rate of 1/2 is likely to work for most craft.
You can change the logging rate settings by entering the CLI tab in the [Cleanflight Configurator][] and using the `set` You can change the logging rate settings by entering the CLI tab in the [INAV Configurator][] and using the `set`
command, like so: command, like so:
``` ```
...@@ -232,8 +232,8 @@ not diagnose flight problems like vibration or PID setting issues. ...@@ -232,8 +232,8 @@ not diagnose flight problems like vibration or PID setting issues.
The Blackbox starts recording data as soon as you arm your craft, and stops when you disarm. The Blackbox starts recording data as soon as you arm your craft, and stops when you disarm.
If your craft has a buzzer attached, you can use Cleanflight's arming beep to synchronize your Blackbox log with your If your craft has a buzzer attached, you can use INAV's arming beep to synchronize your Blackbox log with your
flight video. Cleanflight's arming beep is a "long, short" pattern. The beginning of the first long beep will be shown flight video. INAV's arming beep is a "long, short" pattern. The beginning of the first long beep will be shown
as a blue line in the flight data log, which you can sync against your recorded audio track. as a blue line in the flight data log, which you can sync against your recorded audio track.
You should wait a few seconds after disarming your craft to allow the Blackbox to finish saving its data. You should wait a few seconds after disarming your craft to allow the Blackbox to finish saving its data.
...@@ -246,7 +246,7 @@ tools will ask you to pick which one of these flights you want to display/decode ...@@ -246,7 +246,7 @@ tools will ask you to pick which one of these flights you want to display/decode
Don't insert or remove the SD card while the OpenLog is powered up. Don't insert or remove the SD card while the OpenLog is powered up.
### Usage - Dataflash chip ### Usage - Dataflash chip
After your flights, you can use the [Cleanflight Configurator][] to download the contents of the dataflash to your After your flights, you can use the [INAV Configurator][] to download the contents of the dataflash to your
computer. Go to the "dataflash" tab and click the "save flash to file..." button. Saving the log can take 2 or 3 computer. Go to the "dataflash" tab and click the "save flash to file..." button. Saving the log can take 2 or 3
minutes. minutes.
...@@ -259,10 +259,10 @@ nothing will be recorded. ...@@ -259,10 +259,10 @@ nothing will be recorded.
### Usage - Logging switch ### Usage - Logging switch
If you're recording to an onboard flash chip, you probably want to disable Blackbox recording when not required in order If you're recording to an onboard flash chip, you probably want to disable Blackbox recording when not required in order
to save storage space. To do this, you can add a Blackbox flight mode to one of your AUX channels on the Configurator's to save storage space. To do this, you can add a Blackbox flight mode to one of your AUX channels on the Configurator's
modes tab. Once you've added a mode, Blackbox will only log flight data when the mode is active. modes tab. Once you've added a mode, Blackbox will only log flight data when the mode is active.
A log header will always be recorded at arming time, even if logging is paused. You can freely pause and resume logging A log header will always be recorded at arming time, even if logging is paused. You can freely pause and resume logging
while in flight. while in flight.
## Viewing recorded logs ## Viewing recorded logs
......
...@@ -20,19 +20,19 @@ Here are the hardware specifications: ...@@ -20,19 +20,19 @@ Here are the hardware specifications:
- 3.3V buck-boost power converter (newer prototypes and production versions) - 3.3V buck-boost power converter (newer prototypes and production versions)
- battery monitoring with an LED for buzzer functionality (actualy for an ALIENWIIF3 variant) - battery monitoring with an LED for buzzer functionality (actualy for an ALIENWIIF3 variant)
(*) Spektrum Compatible DSM2 satellites are supported out of the box. DSMX sat will work with DSM2 protocol with default settings (DSM2, 11bit, 11ms is preset). This is chosen for maximum compatibility. For optimal connection it is recommended to adjust settings to match the capabilities of your transmitter and satellite receiver. If possible it is recommended to use the DSMX protocol since it is known as more reliable. Also to make use of additional channels you should adjust the following two parameters with the Cleanflight Configurator. (*) Spektrum Compatible DSM2 satellites are supported out of the box. DSMX sat will work with DSM2 protocol with default settings (DSM2, 11bit, 11ms is preset). This is chosen for maximum compatibility. For optimal connection it is recommended to adjust settings to match the capabilities of your transmitter and satellite receiver. If possible it is recommended to use the DSMX protocol since it is known as more reliable. Also to make use of additional channels you should adjust the following two parameters with the INAV Configurator.
set serialrx_provider = 1 (0 for 1024bit, 1 for 2048bit) set serialrx_provider = 1 (0 for 1024bit, 1 for 2048bit)
set spektrum_sat_bind = 5 set spektrum_sat_bind = 5
For more detail of the different bind modes please refer the [Spektrum Bind](Spektrum bind.md) document For more detail of the different bind modes please refer the [Spektrum Bind](Spektrum bind.md) document
Deltang receivers in serial mode will work like any other Spektrum satellite receiver (10bit, 22ms) only the bind process will be different. Deltang receivers in serial mode will work like any other Spektrum satellite receiver (10bit, 22ms) only the bind process will be different.
The pin layout for the ALIENWIIF1 is very similar to NAZE32 or the related clones (MW32, Flip32, etc.). The hardware bind pin is connected to pin 41 (PB5). The pin layout for the ALIENWIIF3 is similar to Sparky. The hardware bind pin is connected to pin 25 (PB12). The AlienWii32 firmware will be built as target ALIENWIIF1 or ALIENWIIF3. The firmware image will come with alternative default settings which will give the user a plug and play experience. There is no computer needed to get this into the air with an small Quadcopter. An preconfigured custom mixer for an Octocopter is part of the default settings to allow clean straight wiring with the AlienWii32. The mixer can be activated with "mixer custom" in the CLI. To use the AlienWii32 in an Hexa- or Octocopter or to do some more tuning additional configuration changes can be done as usual in the CLI or the Cleanflight configurator. The pin layout for the ALIENWIIF1 is very similar to NAZE32 or the related clones (MW32, Flip32, etc.). The hardware bind pin is connected to pin 41 (PB5). The pin layout for the ALIENWIIF3 is similar to Sparky. The hardware bind pin is connected to pin 25 (PB12). The AlienWii32 firmware will be built as target ALIENWIIF1 or ALIENWIIF3. The firmware image will come with alternative default settings which will give the user a plug and play experience. There is no computer needed to get this into the air with an small Quadcopter. An preconfigured custom mixer for an Octocopter is part of the default settings to allow clean straight wiring with the AlienWii32. The mixer can be activated with "mixer custom" in the CLI. To use the AlienWii32 in an Hexa- or Octocopter or to do some more tuning additional configuration changes can be done as usual in the CLI or the INAV configurator.
## Flashing the firmware ## Flashing the firmware
The AlienWii32 F1 board can be flashed like the Naze board or the related clones. All the different methods will work in the same way. The AlienWii32 F1 board can be flashed like the Naze board or the related clones. All the different methods will work in the same way.
The AlienWii32 F3 board needs to be flashed via the USB port in DFU mode. Flashing via the Cleanflight GUI is not possible yet. The DFU mode can be activated via setting the BOOT0 jumper during power on of the board. The second method is to connect with an terminal program (i.e. Putty) to the board and enter the character "R" immediately after connecting. Details about the flashing process can be found in the related section of the [Sparky](Board - Sparky.md) documentation. The BOOT0 jumper should be removed and the board needs to be repowerd after firmware flashing. Please be aware, during reboot of the AlienWii F3 board, the GUI will disconnect and an manual reconnect is required. The AlienWii32 F3 board needs to be flashed via the USB port in DFU mode. Flashing via the INAV GUI is not possible yet. The DFU mode can be activated via setting the BOOT0 jumper during power on of the board. The second method is to connect with an terminal program (i.e. Putty) to the board and enter the character "R" immediately after connecting. Details about the flashing process can be found in the related section of the [Sparky](Board - Sparky.md) documentation. The BOOT0 jumper should be removed and the board needs to be repowerd after firmware flashing. Please be aware, during reboot of the AlienWii F3 board, the GUI will disconnect and an manual reconnect is required.
\ No newline at end of file
...@@ -12,7 +12,7 @@ have an on-board USB to uart adapter which connect to the processor's serial por ...@@ -12,7 +12,7 @@ have an on-board USB to uart adapter which connect to the processor's serial por
The board cannot currently be used for hexacopters/octocopters. The board cannot currently be used for hexacopters/octocopters.
Tricopter & Airplane support is untested, please report success or failure if you try it. Tricopter & Airplane support is untested, please report success or failure if you try it.
# Pinouts # Pinouts
...@@ -30,6 +30,7 @@ The 8 pin RC_Input connector has the following pinouts when used in RX_PPM/RX_SE ...@@ -30,6 +30,7 @@ The 8 pin RC_Input connector has the following pinouts when used in RX_PPM/RX_SE
| 8 | PPM Input | Enable `feature RX_PPM` | | 8 | PPM Input | Enable `feature RX_PPM` |
*Connect to the output of a PWM-RSSI conditioner, 0v-3.3v input. *Connect to the output of a PWM-RSSI conditioner, 0v-3.3v input.
NOTE: for the CC3D\_PPM1 build PPM input is on Pin 3 and RSSI\_ADC is on Pin 8 NOTE: for the CC3D\_PPM1 build PPM input is on Pin 3 and RSSI\_ADC is on Pin 8
The 6 pin RC_Output connector has the following pinouts when used in RX_PPM/RX_SERIAL mode The 6 pin RC_Output connector has the following pinouts when used in RX_PPM/RX_SERIAL mode
...@@ -49,7 +50,7 @@ The 8 pin RC_Input connector has the following pinouts when used in RX_PARALLEL_ ...@@ -49,7 +50,7 @@ The 8 pin RC_Input connector has the following pinouts when used in RX_PARALLEL_
| --- | ---------| ------| | --- | ---------| ------|
| 1 | Ground | | | 1 | Ground | |
| 2 | +5V | | | 2 | +5V | |
| 3 | Unused | | | 3 | Unused | |
| 4 | CH1 | | | 4 | CH1 | |
| 5 | CH2 | | | 5 | CH2 | |
| 6 | CH3 | | | 6 | CH3 | |
...@@ -106,10 +107,10 @@ You cannot use USART3 and I2C at the same time. ...@@ -106,10 +107,10 @@ You cannot use USART3 and I2C at the same time.
# Flashing # Flashing
There are two primary ways to get Cleanflight onto a CC3D board. There are two primary ways to get INAV onto a CC3D board.
* Single binary image mode - best mode if you don't want to use OpenPilot. * Single binary image mode - best mode if you don't want to use OpenPilot.
* OpenPilot Bootloader compatible image mode - best mode if you want to switch between OpenPilot and Cleanflight. * OpenPilot Bootloader compatible image mode - best mode if you want to switch between OpenPilot and INAV.
## Single binary image mode. ## Single binary image mode.
...@@ -144,14 +145,14 @@ If you have a JLink debugger, you can use JLinkExe to flash the open pilot bootl ...@@ -144,14 +145,14 @@ If you have a JLink debugger, you can use JLinkExe to flash the open pilot bootl
Here's an example session: Here's an example session:
``` ```
$ /Applications/SEGGER/JLink/JLinkExe $ /Applications/SEGGER/JLink/JLinkExe
SEGGER J-Link Commander V4.90c ('?' for help) SEGGER J-Link Commander V4.90c ('?' for help)
Compiled Aug 29 2014 09:52:38 Compiled Aug 29 2014 09:52:38
DLL version V4.90c, compiled Aug 29 2014 09:52:33 DLL version V4.90c, compiled Aug 29 2014 09:52:33
Firmware: J-Link ARM-OB STM32 compiled Aug 22 2012 19:52:04 Firmware: J-Link ARM-OB STM32 compiled Aug 22 2012 19:52:04
Hardware: V7.00 Hardware: V7.00
S/N: -1 S/N: -1
Feature(s): RDI,FlashDL,FlashBP,JFlash,GDBFull Feature(s): RDI,FlashDL,FlashBP,JFlash,GDBFull
VTarget = 3.300V VTarget = 3.300V
Info: Could not measure total IR len. TDO is constant high. Info: Could not measure total IR len. TDO is constant high.
Info: Could not measure total IR len. TDO is constant high. Info: Could not measure total IR len. TDO is constant high.
...@@ -189,5 +190,5 @@ Info: J-Link: Flash download: Flash download into internal flash skipped. Flash ...@@ -189,5 +190,5 @@ Info: J-Link: Flash download: Flash download into internal flash skipped. Flash
Info: J-Link: Flash download: Total time needed: 0.898s (Prepare: 0.709s, Compare: 0.128s, Erase: 0.000s, Program: 0.000s, Verify: 0.000s, Restore: 0.059s) Info: J-Link: Flash download: Total time needed: 0.898s (Prepare: 0.709s, Compare: 0.128s, Erase: 0.000s, Program: 0.000s, Verify: 0.000s, Restore: 0.059s)
O.K. O.K.
J-Link>q J-Link>q
$