Skip to content

Commit

Permalink
Update Inav V2 Beta
Browse files Browse the repository at this point in the history
  • Loading branch information
ted-rcnet committed Apr 29, 2018
1 parent 313377f commit 7d29e90
Show file tree
Hide file tree
Showing 3,363 changed files with 181,690 additions and 2,483,545 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
780 changes: 52 additions & 728 deletions Makefile

Large diffs are not rendered by default.

9 changes: 5 additions & 4 deletions Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,15 @@ Vagrant.configure(2) do |config|
# Every Vagrant development environment requires a box. You can search for
# boxes at https://atlas.hashicorp.com/search.
config.vm.box = "ubuntu/trusty64"
config.vm.synced_folder ".", "/home/vagrant/inav"

# Enable provisioning with a shell script. Additional provisioners such as
# Puppet, Chef, Ansible, Salt, and Docker are also available. Please see the
# documentation for more information about their specific syntax and use.
config.vm.provision "shell", inline: <<-SHELL
apt-get remove -y binutils-arm-none-eabi gcc-arm-none-eabi
add-apt-repository ppa:terry.guo/gcc-arm-embedded
apt-get update
apt-get install -y git gcc-arm-none-eabi=4.9.3.2015q3-1trusty1 ruby
sudo add-apt-repository ppa:terry.guo/gcc-arm-embedded
sudo apt-add-repository ppa:brightbox/ruby-ng
sudo apt-get update
sudo apt-get install -y --force-yes git gcc-arm-none-eabi=4.9.3.2015q3-1trusty1 libnewlib-arm-none-eabi ruby2.4 ruby2.4-dev
SHELL
end
4 changes: 0 additions & 4 deletions build_docs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,9 @@ doc_files=(
'Migrating from baseflight.md'
'Boards.md'
'Board - AlienFlight.md'
'Board - CC3D.md'
'Board - ChebuzzF3.md'
'Board - CJMCU.md'
'Board - ColibriRace.md'
'Board - Motolab.md'
'Board - Naze32.md'
'Board - Olimexino.md'
'Board - Paris Air Hero 32.md'
'Board - Sparky.md'
'Board - RMDO.md'
Expand Down
20 changes: 1 addition & 19 deletions docs/1wire.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,30 +8,12 @@ This is the option you need to select for the bootloader:

![Flashing BlHeli Bootloader](assets/images/blheli-bootloader.png)

Currently supported on the SPRACINGF3, STM32F3DISCOVERY, NAZE32 (including clones such as the FLIP32) and CC3D.

## Wiring

- For the NAZE, no external wiring is necessary. Simply plug in the board via USB cable.

- For the CC3D, connect [a USB to UART adapter](http://bit.ly/cf-cp2102) to the flex port.

- Ensure MSP is enabled on the flex port. Unfortunatly the main port cannot be used in the current configuration due to the inverter on this port.

- You'll only need this connection to the CC3D, do not plug in the normal USB connection.

- If you need one, I prefer the [CP2102](http://bit.ly/cf-cp2102) as it is cheap and [the driver](https://www.silabs.com/products/mcu/Pages/USBtoUARTBridgeVCPDrivers.aspx) is readily available.

- In the case that your board does not power on fully without a battery attached, it is OK to attach the battery before following the steps below. However, it may not be necessary in all cases.
Currently supported on all boards with at least 128kB of flash memory (all F3, F4 and F7).

## Usage

- 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:

![Flashing BlHeli Bootloader](assets/images/serial1wire-cc3d-wiring.jpg)

- Open the BlHeli Suite.

- Ensure you have selected the correct Atmel or SILABS "Cleanflight" option under the "Select ATMEL / SILABS Interface" menu option.
Expand Down
35 changes: 10 additions & 25 deletions docs/Battery.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,24 +22,7 @@ When dealing with batteries **ALWAYS CHECK POLARITY!**
Measure expected voltages **first** and then connect to the flight controller. Powering the flight controller with
incorrect voltage or reversed polarity will likely fry your flight controller. Ensure your flight controller
has a voltage divider capable of measuring your particular battery voltage.

### Naze32

The Naze32 has an on-board battery divider circuit; just connect your main battery to the VBAT connector.

**CAUTION:** When installing the connection from main battery to the VBAT connector, be sure to first disconnect the main battery from the frame/power distribution board. Check the wiring very carefully before connecting battery again. Incorrect connections can immediately and completely destroy the flight controller and connected peripherals (ESC, GPS, Receiver etc.).

### CC3D

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.

Notes:

* 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.

* When battery monitoring is enabled on the CC3D, RC5 can no-longer be used for PWM input.
On the first battery connection is always advisable to use a current limiter device to limit damages if something is wrong in the setup.

### Sparky

Expand All @@ -53,19 +36,19 @@ Configure min/max cell voltages using the following CLI setting:

`vbat_scale` - Adjust this to match actual measured battery voltage to reported value.

`vbat_max_cell_voltage` - Maximum voltage per cell, used for auto-detecting battery voltage in 0.1V units, i.e. 43 = 4.3V
`vbat_max_cell_voltage` - Maximum voltage per cell, used for auto-detecting battery voltage in 0.01V units, i.e. 430 = 4.30V

`set vbat_warning_cell_voltage` - Warning voltage per cell; this triggers battery-out alarms, in 0.1V units, i.e. 34 = 3.4V
`set vbat_warning_cell_voltage` - Warning voltage per cell; this triggers battery-out alarms, in 0.01V units, i.e. 340 = 3.40V

`vbat_min_cell_voltage` - Minimum voltage per cell; this triggers battery-out alarms, in 0.1V units, i.e. 33 = 3.3V
`vbat_min_cell_voltage` - Minimum voltage per cell; this triggers battery-out alarms, in 0.01V units, i.e. 330 = 3.30V

e.g.

```
set vbat_scale = 110
set vbat_max_cell_voltage = 43
set vbat_warning_cell_voltage = 34
set vbat_min_cell_voltage = 33
set vbat_scale = 1100
set vbat_max_cell_voltage = 430
set vbat_warning_cell_voltage = 340
set vbat_min_cell_voltage = 330
```

# Current Monitoring
Expand Down Expand Up @@ -187,3 +170,5 @@ set battery_capacity = 2200 // battery capacity is 2200mAh
set battery_capacity_warning = 660 // the battery warning alarm will sound and the capacity related OSD items will blink when left capacity is less than 660 mAh (30% of battery capacity)
set battery_capacity_critical = 440 // the battery critical alarm will sound and the OSD battery gauge and remaining capacity item will be empty when left capacity is less than 440 mAh (20% of battery capacity)
```

Note that in this example even though your warning capacity (`battery_capacity_warning`) is set to 30% (660mAh), since 440mAh (`battery_capacity_critical`) is considered empty (0% left), the OSD capacity related items will only start to blink when the remaining battery percentage shown on the OSD is below 12%: (`battery_capacity_warning`-`battery_capacity_critical`)*100/(`battery_capacity`-`battery_capacity_critical`)=(660-440)*100/(2200-440)=12.5
28 changes: 3 additions & 25 deletions docs/Blackbox.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,7 @@ save.
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.

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
You should use a hardware serial port. 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.

When using a hardware serial port, Blackbox should be set to at least 115200 baud on that port. When using fast
Expand All @@ -114,24 +113,7 @@ Connect the "TX" pin of the serial port you've chosen to the OpenLog's "RXI" pin
pin to the OpenLog, as this will cause the OpenLog to interfere with any shared functions on the serial port while
disarmed.

#### Naze32 serial port choices

On the Naze32, the TX/RX pins on top of the board are connected to UART1, and are shared with the USB connector.
Therefore, MSP must be enabled on UART1 in order to use the Configurator over USB. If Blackbox is connected to the pins
on top of the Naze32, the Configurator will stop working once the board is armed. This configuration is usually a good
choice if you don't already have an OSD installed which is using those pins while armed, and aren't using the FrSky
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
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. 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,
then you can use a spare motor header's +5V and GND pins to power the OpenLog with.

#### Other flight controller hardware
Boards other than the Naze32 may have more accessible hardware serial devices, in which case refer to their
documentation to decide how to wire up the logger. The key criteria are:
The key criteria to choose a serial port are:

* Should be a hardware serial port rather than SoftSerial.
* Cannot be shared with any other function (GPS, telemetry) except MSP.
Expand Down Expand Up @@ -173,11 +155,7 @@ tubing instead.
Some flight controllers have an onboard SPI NOR dataflash chip which can be used to store flight logs instead of using
an OpenLog.

The full version of the Naze32 and the CC3D have an onboard "m25p16" 2 megabyte dataflash storage chip. This is a small
chip with 8 fat legs, which can be found at the base of the Naze32's direction arrow. This chip is not present on the
"Acro" version of the Naze32.

The SPRacingF3 has a larger 8 megabyte dataflash chip onboard which allows for longer recording times.
The SPRacingF3 has a 8 megabyte dataflash chip onboard which allows for longer recording times.

These chips are also supported:

Expand Down
15 changes: 1 addition & 14 deletions docs/Board - Airbot F4 and Flip32 F4.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,17 +83,4 @@ This board allows for single **SoftwareSerial** port on small soldering pads loc
| Pad | SoftwareSerial Role |
| ---- | ---- |
| CH5 | RX |
| CH6 | TX |

## FrSky SmartPort using SoftwareSerial

SmartPort telemetry is possible using SoftwareSerial. RX and TX lines have to be bridged using
1kOhm resistor (confirmed working with 100Ohm, 1kOhm and 10kOhm)

```
SmartPort ---> RX (CH5 pad) ---> 1kOhm resistor ---> TX (CH6 pad)
```

* Telemetry has to be inverted with `set telemetry_inversion = ON`
* Port should be configured for _57600bps_
* Tested with FrSky X4R
| CH6 | TX |
3 changes: 0 additions & 3 deletions docs/Board - AlienFlight.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ https://micro-motor-warehouse.com

Here are the general hardware specifications for this boards:

- STM32F103CBT6 MCU (ALIENFLIGHTF1)
- STM32F303CCT6 MCU (ALIENFLIGHTF3)
- STM32F405RGT6 MCU (ALIENFLIGHTF4)
- STM32F711RET6 MCU (ALIENFLIGHTNGF7)
Expand Down Expand Up @@ -59,8 +58,6 @@ For more detail of the different bind modes please refer the CleanFlight Spektru

Deltang receivers in serial mode will work like any other Spektrum satellite compatible receiver (10bit, 22ms) only the bind process will be different.

The pin layout for the AlienFlight F1 is very similar to NAZE32 or the related clones (MW32, Flip32, etc.). The pin layout for the AlienFlight F3 is similar to Sparky. The new AlienFlightF3 V2 design have the sensor connected via SPI and some slightly different pin layout. All AlienFlight F3 flight controllers running the same firmware which takes care on the differences with a hardware detection. The AlienFlight F4 and F7 have their individual pin layouts and are independent designs.

(**) OpenSky receiver with telemetry is enabled by default if present on the board.

The AlienFlight firmware will be built as target ALIENFLIGHTF1, ALIENFLIGHTF3, ALIENFLIGHTF4 or ALIENFLIGHTNGF7. 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 a small Quadcopter. A preconfigured custom mixer for an Octocopter is part of the default settings to allow clean straight wiring with the AlienFlight. The mixer can be activated with "mixer custom" in the CLI. To use the AlienFlight controller in a Hexa- or Octocopter or to do some more tuning additional configuration changes can be done as usual in the CLI or the BetaFlight configurator.
Expand Down
Loading

0 comments on commit 7d29e90

Please sign in to comment.