Search This Blog

Showing posts with label INAV. Show all posts
Showing posts with label INAV. Show all posts

Sunday, 17 August 2025

INAV Troubleshooting - Quick Tips


1. FIRMWARE  
Are you using the correct firmware target for your board? 
Note that the SpeedyBee F405 Wing Mini board uses the WING target, NOT the MINI target.

2. BOARD ORIENTATION 
Does the animation move the same way as your plane?
Set FC orientation using the Alignment Tool if the board is not facing forward

3. INAV MIX in the RADIO
Do Not set up V-Tail or Elevon mixing in the radio, that is done in the INAV Mixer

Must use this basic mix in the radio. I call it the INAV Mix.
Ch1 100 AIL
Ch2 100 ELE
Ch3 100 THR
Ch4 100 RUD
Ch5 ARM Switch (must be Ch5 for ELRS)
Ch6 7 8 etc. for your desired flight modes, but always include a switch position where no modes are selected. This will allow for ACRO.

In the radio, adjust the endpoints of Ch 1 to 4 to give PWM range of 1000 to 2000 in the INAV Receiver graphs.

4. OUPUTS Page - Enable Motor and Servo Output
Choose the correct ESC Protocol and Servo Refresh Rate for your gear. 
Use STANDARD and 50 Hz if they are unknown.
Use the slider controls on this page to calibrate Standard ESCs, and check if the motor runs. 

5. PORTS - Enable separate UARTs for Serial RX, GPS and Digital FPV if required. 
SBUS Rx with F405 boards require Serial RX to be on UART2.

6. CONFIGURATION - Turn On "GPS for Navigation and Telemetry" (if GPS will be used)

7. FAILSAFE - Only set as RTH if you have a GPS setup.
Arming will be prevented if failsafe is RTH on a non-GPS setup.

8. RECEIVER - Connect the receiver to the Serial RX UART 
Choose the Channel Order for your type of radio. AETR is most common
Choose the Serial Receiver Provider for your receiver - CRSF for ELRS, SBUS for SBUS etc.
Check that the Rx is bound to your radio.

Check that the INAV Channel bars for Roll, Pitch, Yaw and Throttle move to the RIGHT when moving the radio sticks UP and RIGHT?
If one moves to the left then you may have reversed a channel in the radio.

9. ARMING PROBLEMS - Read the Arming Flags message along the bottom of the INAV window and in your FPV goggles. Type STATUS in to the CLI for more clues.

Arming is only possible in ACRO, HORIZON, ANGLE or MANUAL modes, and GPS must have acquired at least 6 satellites and a 3D lock.

To bypass the Arming Flags, hold the throttle stick down and yaw right while arming. 
BEWARE this is for troubleshooting only and is not a safe flying condition. 
Disconnect the battery to clear Arming Flag bypass.

Saturday, 8 March 2025

My INAV OSD for HD FPV

 Here is how I arrange my HD FPV OSD for DJI and Walksnail Avatar gear and ELRS RC link


DJI Vista / Runcam Link / Caddx Air Unit.  OSD overlayed using the WTFOS Chrome web tool



Walksnail Avatar.  OSD overlayed using the WalkSnail OSD App





Link to the Diff file for this layout - https://drive.google.com/file/d/1mwzIve5VPeCUxOykSMxM8u7kcGjdz56K/view?usp=sharing

Tuesday, 11 June 2024

INAV VTOL Tailsitter


INAV 7.1 now has VTOL capability, thanks to INAV dev Shota Hyashi 

With Mixer Profile switching and a Transition mode we can now change between horizontal and vertical board alignments on the fly.

It is not yet perfect, lots of experimentation with PIDs and rates is required to make each different model work smoothly.

INAV VTOL doc - https://github.com/iNavFlight/inav/blob/master/docs/VTOL.md

Tailsitter initial setup tips

At this stage (INAV 7.1.2 June 2024) Tailsitter is not available as a platform choice so you need to enter this CLI command - Set tailsitter_orientation_offset = ON

This allows the board orientation to be horizontal for Mixer Profile 1 and vertical for Mixer Profile 2 with a 45º pitch forward transition mode.

Start with a normal fixed wing INAV setup. This will be Mixer Profile 1 / PID Profile 1.

Turn on "PID Profile will use same index...." so that the mixer and PIDs will match when switching Profiles.



Change to Mixer Profile 2 and PID Profile 2 and choose Quad X as the Mixer Preset.

Again turn on "PID Profile will use same index...." 

Later we will need to alter the Quad X mixer settings depending on the fixed wing model we are using. 

I am testing the AtomRC Theer wing and AtomRC Penguin.


In the Modes page - Configure Mixer Profile 2 and Profile Transition Modes using a channel which is operated by a 3 position switch.

Low channel value enables Profile 2 (VTOL), middle value adds the Transition Mode, high value switches to Profile 1 (level flight).


OK that covers the basics for all INAV tail sitters.

Now we need to make changes depending on the particular model, and play with the PIDs 


AtomRC Theer Tailsitter settings 

13th June 2024 - My Theer Tailsitter is now working OK for takeoff, hover, transition and level flight. I am having problems switching back to vertical and remaining stable. 

Profile 1 - use a normal twin motor flying wing mix


Profile 2 - Use Quad X mix like this screenshot, but make the changes below

In VTOL flight Motors give thrust and roll control.
Elevons give pitch and yaw control










Delete motors 3 and 4

Change Motor Roll values to 1, -1. Adjust directions as required to give the correct stabilisation direction..

Change Motor Pitch and Yaw values to 0, 0

Add elevon servo mixes and adjust directions and weights as required


This is the resulting Tailsitter mix


Initially the Theer did not have enough pitch stability action to keep it vertical so I added more elevon area. 

The preset Quad PIDs are incorrect for servo control so it's best to use values closer to Airplane PIDs for pitch and yaw, then adjust from there. 

For more elevon action in Angle mode I increased the pitch P value until the servos started shuddering, then backed off a bit. 

Then I increased the Level Pitch P value for more aggressive Angle mode pitch stability. 


set mc_p_level = 40 (0 to 255) Default value is 20

Here is my latest Theer VTOL Diff_All file Use with caution.




AtomRC Penguin Tailsitter settings (Not yet tested)

Profile 1 - normal mix for a twin motor plane without rudder


Profile 2 - Quad X but needs the changes below

In VTOL flight Motors give thrust and roll control,
elevator gives pitch control and ailerons give yaw control.

Delete motors 3 and 4

Change Motor Roll values 1, -1. Adjust directions as required to give the correct stabilisation direction.

Change Motor Pitch and Yaw values to 0, 0

Add elevator and aileron servo mixes and adjust directions and weights as required

Try increasing the Level Pitch P value for more Angle mode pitch stability

set mc_p_level = 40 (0 to 255) Default value is 20

In VTOL mode Elevator controls Pitch as usual but Ailerons change to Yaw


My YouTube VTOL Playlist 

WARNING - The INAV VTOL code is still being developed and is not yet complete. 

My tailsitters are still fairly unreliable and I haven't added GPS yet.  More tweaking is required. 








Thursday, 14 March 2024

Best Radios for INAV 2024


This advice applies to non INAV models as well. The only difference is you would use receivers with PWM outputs for servos rather than a Serial output for a flight control board

INAV only requires a very simple model setup in the radio, just the 4 control channels plus a few mode switches. 

You can get by with just about any radio system including RadioMaster, FrSKY, FlySKY, Futaba and Spektrum as long as the receiver can output a serial signal using a protocol like iBUS, SRXL2, SBUS or CRSF.

My preference is for radios that use the EdgeTX operating system and ExpressLRS RF protocol. EdgeTX is the most flexible and programmable operating system and ExpressLRS gives the most secure and long range RF link.

Spektrum and FlySKY operating systems are less flexible and more locked down than EdgeTX.

Below are my top suggestions for a good INAV radio in 2024

Note: EdgeTX, INAV and ExpressLRS are all RC Community developed OpenSource projects so they are often updated and  will require a little more research and experimentation to master than traditional locked down systems like Spektrum.


ExpressLRS Radios

1. RadioMaster Boxer ELRS  (or Boxer 4in1 with ELRS RF Module) 

The Boxer is a very reasonably priced radio with plenty of switches. One momentary, one locking, two 2 position, two 3 position and one 6 position switch as well as two pots. It has a full sized JR RF module bay. The only things missing are sliders on the sides. There is a large battery bay for 2S LiPos.



2. Zorro and TX16S are good options too, although I am not a fan of the colour touch screen version of EdgeTX on the TX16S. 

My daily radio is actually the Zorro 4in1 with Ranger ELRS RF module. The game controller form factor is not to everyone's taste but I like it. It uses 18350 Li Ion batteries which are hard to find and have less capacity. But I like the side sliders for panning cameras and also crow braking on gliders. 







The TX16S would suit someone who wants all the bells and whistles including a large colour touch screen. But I find it unnecessarily big and heavy.












3. FrSKY TaranisQ X7 with external BetaFPV or RadioMaster ELRS RF Module

This is FrSKYs cheapest radio and it was my favourite for many years. I love the rotary selector dial and overall feel.
It only binds with FrSKY ACCESS and D16 receivers unless you add an external ELRS RF module.




ELRS Receivers

Any ELRS receiver can be used with any ELRS radio or module

RadioMaster RP1, RP2, RP3, RP4TD ELRS or any of the PWM receivers with Serial output enabled

BetaFPV - ELRS Nano, Lite, SuperD and Micro PWM or SuperP PWM with Serial output enabled

ELRS gear has amazing range, at least 5km even with the nano receiver versions. Or you can think of it as very secure RF link for short range even with obstacles. The diversity receivers like SuperD and RP4TD extend the link security even further for extended long range or close range penetration.


SBUS Radios

1. RadioMaster Boxer 4in1 

All RadioMasters radios come in different versions. CR2500 for one chip multi-protocol (Mainly used for RadioMaster and FrSKY receivers), 4in1 with 4 chip multi-protocol, or ELRS.

2. Zorro and TX16S are also good options. ELRS external module can be added


3. FrSKY TaranisQ X7 (only compatible with FrSKY ACCESS and D16 receivers)

4. FrSKY Tandem and Twin radios (Higher quality hardware but more expensive and limited to FrSKY receivers)


SBUS Receivers

FrSKY X6R, RX6R

RadioMaster R81, R86C

FlySKY iA6B using iBUS or SBUS


My YouTube Playlists to help with the learning curve. It's worth the little extra effort of watching a few videos on the relevant subjects

RADIOMASTER Playlist

INAV Playlist

ExpressLRS Playlist

OpenTX / EdgeTX Playlist

Wednesday, 11 October 2023

Unusual RC and INAV problems and solutions

This post will be an ongoing log of troubleshooting solutions that I come across in video comments and questions. 

Some solutions are obvious and just require reading the manual, or checking connections. But some solutions are unexpected and weird.

This will document some of the more unusual problems that can mess up an RC setup


List of odd problems and their solutions


INAV

"Pitch / Roll not centered" error message

Cause 1 - Switch mistakenly assigned to Aileron channel in the radio

Cause 2 - Aileron or Elevator trim not centred

Cause 3 - Wrong Stick Mode selected eg. Mode 1 instead of Mode 2


Disarming with any aileron input

Cause - Used an existing model setup in the radio which had aileron mixing on the same channel as Arming in INAV.

GOLDEN RULE - Create a new fresh model for your INAV setup to avoid any leftover mixes


Outputs working in the INAV configurator but actual servos don't move

5V servos used with 6V servo BEC setting. One servo burned out and prevented others from working.. 



AtomRC Penguin on INAV

Turning right and crashing during launch.

Cause -  ESCs were out of sync after lots of INAV VTOL configuration testing.

Recalibrating the ESCs in INAV Outputs Page corrected the problem.


SpeedyBee F405-Wing MINI 

USER modes not available for analog camera switching in INAV 7.0

Cause - This feature missed the deadline to be included in INAV 7.0. Updated firmware available on the Product page and INAV 7.1


Board stopped working after prolonged setup session

Cause - Bent pin on the "between-board" connector after repeated disassemblies.


Board not working at all

Cause - Wrong firmware flashed. The F405 Wing MINI uses the SPEEDYBEEF405WING firmware not the SPEEDYBEEF405MINI firmware


SpeedyBee F405-Wing 

Graphs not moving in Configurator Receiver page, even with properly bound receiver.

Serial Rx was enabled for UART 1 and UART2 in the Ports page. Only one UART can be used for receiver connection.


No voltage on DJI 9V port 

Cause - Bent ground pin needed straightening


No output on S8, no Soft Serial for S-Port function 

Cause - Factory firmware bugs, upgrade to INAV 6.1.1


SIYI F24 INAV - Can't ARM

PWM end points and mid points are 1020 - 1540 - 2040 but INAV expects 1000 - 1500 - 2000

Solution - Adjust PWM values in the SIYI End Point page


FrSKY GRX8 

Receiver unable to enter bind mode 

Cause - Worn bind button contact. Needed to push harder on the bind button


Kootai A505 J3 Cub 

Will not initiate 

Cause - Futaba FASST protocol uses REVERSED throttle channel


Skywalker X8 

Wings out of alignment. 

Manufacturer glued the spar at the top of the channel in one wing and bottom of the channel in the other wing - Cut out spar and foam packing and re glue correctly.


FIMI Manta - Matek F405 VTOL - Ardupilot ELRS 

RC connection won't work 

Cause - SERIAL5 was set to CRSF (Parameter = 23) as well as SERIAL6 which prevented Rx connection.

Only SERIAL6 should be set to CRSF


Sunday, 25 June 2023

Simplified INAV

How to simplify INAV model setup and start flying sooner.

The key to simplicity is having a plane that is trimmed and balanced well mechanically, and just starting with the basic INAV modes. The default tuning PIFFs (stabilisation parameters) will be OK for most normal performance planes using INAV 6 and beyond.

The advanced modes like Auto Launch, Auto Tune, Auto Trim and Missions will just complicate your first INAV experience. It is much simpler and safer to get the model flying well first, then add advanced modes later.

This article is intended for fixed wing pilots who know how to mechanically set up a model for correct throws, trims and CG. 

Start with a model that is easy to fly and has adjustable push rods.

INAV manual mode uses 100% weight and 30% expo by default. So before you install the flight control board, adjust the pushrod lengths and connection holes to give reasonable throws using 100% servo travel. 

Aim for about 15mm or 20º max throw up and down. This also maximises the torque and resolution  of the servo.

This usually means moving the pushrod to an inner hole on the servo arm and an outer hole on the control surface horn. 

If possible, fly the model first to check aileron and elevator trims and CG placement. Adjust the trims by changing the pushrod lengths mechanically and don't use the radio trims.  If you can't fly first just make sure the control surfaces are level or have the recommended amount of reflex.

Radio trims should never be used in INAV because they are only fully applied in manual mode. Switching to other modes will give different trims.

The initial setup doesn't have to be perfect and it's OK if the plane is a little too agile with these full throws, as long as it is flyable.

Once the plane is close to good trim you can enable "Continuously trim servos" in the Configuration page. This will continuously save fine adjustments to the servo midpoints for level flight in Manual.


Essential INAV Modes

The only modes you need to set up initially are ACRO, ANGLE, MANUAL and RTH

ACRO is the default INAV mode and is active if no other mode is selected. In ACRO the plane is stabilised against any un-commanded rotations, like a side gust of wind. The model will tend to hold its orientation but respond normally to your stick inputs. ACRO is arguably the best general flying mode.

MANUAL is a mode that has to be selected, it is not the default mode. There is no stabilisation at all in this mode. Stick inputs are passed straight through to the servos, with whatever expo and rates are set up in INAV. It is used to check trim and CG balance, and for safety if something is wrong with other modes. Experienced pilots may prefer to fly in MANUAL mode.

ANGLE is the fully self levelling stabilised mode. It is a mode by itself, but it is also active when any of the nav or GPS modes are used. In this simplified INAV setup it is also used to check board pitch trim. Most airfoils need a few degrees of "nose-up" or "angle of attack" to maintain level flight. This trim setting can be found in the PIDS page - Mechanics Tab - LEVEL TRIM (deg). I usually start with +4 degrees then check if the plane is rising or descending in ANGLE mode and adjust as required.

Flying in ANGLE mode may feel odd to experienced pilots because you have to hold the sticks at the angle you want to fly at and it will self level when you centre the sticks. 

RTH mode uses GPS data to automatically fly the model back to the home location. It can also be set as the Failsafe action, to bring the model back home if RC signal is lost. In the INAV Failsafe screen choose RTH.

The above modes are all you need for a basic setup.

If you have more than one mode selected at the same time then INAV follows the following hierarchy:

RTH is top of the tree and overrides all other modes, then Manual, then all other modes. Angle is always active when any of the GPS guided NAV modes are selected. 

Non-essential INAV modes to add once you have a working model

NAV LAUNCH is fun to play with but I prefer to launch normally with full control. It is easy to muck up the switch sequence and cause a failed launch. 

CRUISE and LOITER modes are useful for FPV flights but not essential.

AUTO TUNE is used to fine tune rotation rates and throws

AUTO TRIM is not needed if  Continuously trim servos is enabled

Mode switches

It is best to have your starting switch positions with no modes selected, which means the board will always start in ACRO

Here are my modes for the simple setup

CH 5 (2 position) Nothing - ARM 

Arming on CH 5 is essential for ELRS receivers

CH 6 (3 position) Nothing - ANGLE - MANUAL

CH 7 (2 position) Nothing - RTH


Extra modes to add once your INAV setup is flying well

CH 8 (3 position) Nothing - NAV CRUISE - NAV LOITER


Note that when all switches are in the "Nothing" range the board will be in ACRO 


BEFORE THE FIRST FLIGHT

Check the control surfaces are responding correctly to stick movements. 

Do the High 5 check.

Check the control surfaces are responding correctly for stabilisation. 

Switch to Angle Mode and roll the plane to the right. Check that the left aileron moves up and right aileron moves down to counter the roll. Lift the tail up and check that the elevator moves up to counter the pitch change.

ACRO Throws

Check the control surface throws in ACRO Mode. They may be too small for sufficient control. Ideally they should be about 80% of the Manual Mode throws. If the throws are too small go to the PID Tuning page and increase the FF parameter for Roll and Pitch, then check throws again. If there is no difference between ACRO and MANUAL Mode throws then FF is too high. 

This will ensure you have enough control to launch in ACRO Mode and some headroom for stabilisation.

First Flight adjustments

On the first flight I will launch in MANUAL then switch to ACRO and fly a few circuits to make sure the plane is flying OK. 


Switch to ANGLE mode. Take note of whether the model holds altitude or climbs or descends. If you haven't entered anything in the Fixed Wing Level Trim window then the plane will most likely descend.

I usually start with +4º and adjust more or less from there.


Launch again, climb to about 50m, fly out a bit then try RTH. Your model should turn and fly back to the arming site and circle above you at about 50m altitude and radius of 75m.

If that all works then you are ready to continue your INAV adventure.

Friday, 26 May 2023

SpeedyBee F405 Wing soft serial fix

The SpeedyBee F405 Wing is an inexpensive but fully featured flight control board for INAV or Ardupilot.

The first release INAV 6 firmware for this board did not have soft serial support enabled, so it was not possible to use Smart Port telemetry from FrSKY receivers.

Smart Port connection from an FrSKY receiver allows all telemetry to be sent back to the radio.

Here are the updated firmware hex files to enable soft serial on the T2  pin of UART2:

SpeedyBee F405 Wing INAV 6.1.0 fix soft serial firmware 



UPDATE JUNE 2023

S8 bug fix - With the factory loaded firmware S8 pins did nothing, S9 acted as S8, S10 acted as S9 etc.

This has been remedied with the release of SB F405 Wing INAV 6.1 firmware. 


INAV UPDATE 

Latest firmware INAV 6.1.1 also fixes the "Dolphining" problem which was introduced by INAV 6.1 to all FCBs

Saturday, 20 May 2023

Smart Port Telemetry, INAV and F4

FrSKY receivers with S-Port capability can send telemetry data back to the transmitter. The data can come from FrSKY S-Port telemetry sensors but also from flight control boards (FCBs).

SBUS and Smart Port are inverted signals, compared to normal convention for flight control boards and receivers. Flight control boards need to un-invert these inputs to be usable.

F7 boards have inverters on all UARTs which can be enabled in the configurator, so SBUS and SmartPort inputs can be connected to any UART.

F4 boards only have one UART inverter (for SBUS), usually on the Rx2 pin. But we need an inverted Tx pin for the Smart Port input.

So this is where Soft Serial comes in. Soft Serial creates a software defined UART which can be inverted.

By enabling Soft Serial or "CPU based serial ports" Tx2 becomes available as an inverted pin for Smart Port connection.

The steps below show how:

1. Enable "Enable CPU based serial ports" and "Telemetry output" in the INAV configuration page



2. Choose "SmartPort" in the Telemetry column for SOFTSERIAL1 in the Ports page


3. Choose SBUS, OFF, AUTO or OFF in the Receiver page


4. On the F4 board connect SBUS to the SBUS pin and SmartPort into the TX2 pin




5. "Discover new" sensors on your transmitter, and you should see all the extra FC telemetry appearing.










Sunday, 25 October 2020

RC, FPV and FCB terms


FPV - First Person View. Flying a model while wearing video goggles or watching a screen showing video transmitted from the aircraft.

VTx VRx - Video transmitter and video receiver used for FPV.

FCB - Flight Control Board (eg. Matek F405-Wing)

MCU - Microcontroller Unit (Main processor chip of FCB eg. STM32F405)


IMU - Inertial Measurement Unit (Gyro and Accelerometer chip eg. MPU6000)


Baro - Barometer Altitude sensor (eg. BMP280)


Magnetometer - Electronic Compass (eg QMC5883)


DFU - Direct Firmware Upload (Processor Mode which allows firmware upload)


MSP - Multiwii Serial Protocol. Communication protocol used by INAV and FCBs. MSP came from Multiwii software, which was derived from the Nintendo Wii Game Controller. 


Serial Port - Pins or pads on FCBs for connecting external devices. Serial means all channel signals use the same wire. 


UART - Universal Asynchronous Receiver Transmitter Serial port. Pins or pads where UART devices (GPS, RC receivers, camera controls) connect to the FCB. Pins labelled - Ground Voltage RX TX. RX from the device connects to TX on the FCB


I2C or I squared C - Inter Integrated Circuit Serial port. Pins or pads where I2C devices (compass, OLED screen) connect to the FCB. Pins labelled - Ground Voltage SDA SCL


SPI - Serial Peripheral Interface. Connection interface for onboard devices like SD card reader and barometer


ADC - Analog to Digital converter. FCB component that converts a varying voltage input to a digital output. Used for displaying battery voltage, current, analog airspeed sensor and analog RSSI values.


Soft Serial - Extra Serial port enabled in software, by repurposing spare UARTs pins. Eg Smart Port telemetry connection to an unused TX pin.


Vbat - Flight battery Voltage. May be filtered on some FCBs to reduce video interference


OSD - On Screen Display


GNSS - Global Navigation Satellite System (Commonly called GPS, but GPS only refers to the US satellite system. Other GNSS systems include Galileo, GLONASS)


OLED - Organic Light Emitting Diode used in OLED data display screens and some FPV goggles


RSSI - Received Signal Strength Indicator. A number representing the strength of an RC signal at the receiver.


LQ - Link Quality. A number representing the strength and quality of an RC signal.


LFR - Lost Frame Rate % - Percentage of lost frames in an RC Signal


PWM - Pulse Width Modulation. Basic RC signal protocol which uses an individual wire for each channel signal. Used for connecting servos to a receiver or receiver to FCB.


PPM or CPPM - Pulse Position Modulation. Serial RC protocol. Used for connecting a receiver to FCB, or RF module to a transmitter. All channel signals on one wire


SBUS - FrSKY and Futaba Serial RC protocol. Used for connecting a receiver to FCB, or RF module to a transmitter. All channel signals on one wire. 


S-Port - FrSKY Smart Port Telemetry system. Extra socket found on FrSky receivers to connect telemetry sensors.


F-Port - FrSKY SBUS and SPort combined. RC and telemetry signals on one wire.


F-Bus - F-Port version 2


Tandem (TD) - FrSKY RC system which uses 2.4GHz and 900MHz RF simultaneously


iBUS - FlySKY Serial RC protocol. All channel signals on one wire.


CRSF - Crossfire. Team Black Sheep long range RC protocol. Similar to FPort.


R9 - FrSKY Long range RC 900MHz protocol 


ExpressLRS (ELRS) - Open Source, Long range, low latency RC system. 2.4GHz or 900MHz versions. Uses the CRSF protocol.


ESC - Electronic Speed Controller


BEC - Battery eliminator circuit. Confusing term for a voltage regulator found on ESCs and FCBs. BECs reduce and smooth out the battery voltage for use by lower voltage devices. Eg. 9V or 5V for FPV gear, 5, 6 or 7.2V for servos. 

Wednesday, 24 June 2020

INAV Waypoint Mission Notes


Using Mission Control in the iNav configurator

First waypoint needs to be closer than 100m to the arming or home position. 

This default distance of 100m (10000cm) can be changed in the CLI.

set nav_wp_safe_distance = 10000 (0 - 65000)

Can't arm if it's too far away. May be a safety feature so you dont load the wrong mission.





Default Alt and Speed for all waypoints can be preset using the little gear icon. 

Note that Waypoint Speed is not used for fixed wing and rover missions (only used for multi rotors)

Fixed Wing and Rover both use Cruise Throttle to set the speed for missions. Cruise Throttle must be set high enough for safe RTH and Pos Hold flying.

Waypoint height is in cm (above the home altitude)
5000cm = 50m


If you dont tick "RTH at end of the mission" the plane will loiter at the last waypoint using Pos Hold and Alt Hold.

Rovers need RTH and Landing ticked to stop when home position is reached.

Saving the mission

Save file (Saves the mission on to your computer or phone for later use)

Save Mission to FC (Temporarily saves mission to the FC. Mission is deleted when the FC is powered down)

Save Eeprom Mission (Saved to the FC until it is overwritten by the next Save Eeprom mission command)

Activating the mission

Before arming:
Stick command - Pitch UP and Roll RIGHT to make the mission available for this flight.

In the air:
Turn WP switch on while flying to activate the mission.
Turn WP switch off to end the mission and return to normal iNav control

Satellite view instead of drawn maps

Click on the little gear icon in iNav Configurator, top right, to change map providers.

Choose Bing Maps and enter your personal API key, then restart iNav Configurator and that's all.

OK, how do you get an API key? Quite easy really.

Just enter iNav as the application, nothing else required.






Saturday, 2 May 2020

INAV Basics (pre version 3) - FAQs, Firmware and Configuration

This information is correct up to INAV V2.6
FAQs and common problems 

Which firmware target to flash?
Printed on the bottom of most Matek boards or on the product page

Servo throws are too small in stabilised modes?
Increase FF values in PID Tuning page

Not holding altitude in Angle Mode?
Increase Pitch Degrees in Configuration Page (or Mechanics tab of the PID page for INAV 3, 4 and 5)

Flying too slow in Altitude Hold and RTH modes?
Increase Cruise Throttle value in Advanced Tuning page

Will failsafe work if signal is lost?
Turn off the transmitter and check that the little parachute turns red in the INAV configurator

GPS not working?
Switch Rx and Tx connections

Servo reversed?
Select reverse for that servo in the INAV configurator Outputs page

Stabilisation reversed?
Invert the Channel in your transmitter.
Check that the board is facing the right way. Arrow pointing forward.

How to use Autotrim?
Fly in Manual Mode, activate Autotrim and fly level for 2 seconds, keep autotrim on, land and disarm. Repeat whenever you need to retrim.

How to use Autotune?
Fly in Acro Mode, activate Autotune and fly around for a few minutes making full deflection roll and pitch changes. Turn Autotune off in the air. Land and disarm. Save the new PIFFs by pulling both sticks down and out.

Stick Commands don't work?
May be prevented by a Throttle Cut switch or lack of Yaw channel on a flying wing.
Elevator, Aileron, Throttle and Rudder channels must be active but the board disarmed.

Introduction to INAVFlight for fixed wing

INAVFlight is Open Source firmware for flight control boards, which enables GPS navigation for planes and flying wings, as well as multi rotors.

It is an independent project developed by hobbyists and hosted on Github. The developers are not paid, they do this purely as a hobby. So that means any changes happen because a developer feels like it, or enough users have asked and a developer agrees or has the time to write the code.


INAV is quite amazing, powerful, confusing, messy and hard to understand initially, but really worth making the effort to learn.


Before connecting a flight control board 

First concept to understand is that INAV cannot work well with a plane that is out of trim.
Centre of Gravity, Aileron and Elevator throws, and trims must be sorted first without using the transmitter trims and rates. Adjust the pushrod lengths and connection holes as much as possible so the plane is easily controllable and correctly trimmed for level flight.


INAV Configurator 

This is the computer program used to load and configure INAV firmware on your flight control board.

Go to INAV configurator releases on Github, scroll down to the Assets list to see the latest release. Download and install the version that suits your computer system.

Note that this is not the INAV Firmware just the INAV Configurator.


USB drivers

Before you can connect a flight control board (FCB) to your computer you may need to install the correct USB drivers.

Links to the required drivers can be found on the INAV Configurator front page.

Download and install the relevant USB driver for your computer.



Open INAV configurator and connect your board via USB. Be careful with the delicate USB socket on your board. I usually add some epoxy glue around the base of the socket.

Select the correct port for your board. It should show up in the list  when the board is plugged in. This shows the port used on my iMac.

Now click Connect.



If the INAV firmware version and INAV configurator version are compatible then this is what you will see.

Otherwise you will get a message about what needs to be updated. You may need to update to a more recent INAV configurator or flash the board with more recent firmware.



Flashing new firmware to the flight control board

To flash new firmware the board needs to be in DFU mode. Matek boards, and most others, have a boot button. Hold down the boot button and reconnect the USB cable, then release the boot button. DFU should show in the port window. 

Or just type DFU in the CLI while plugged in.

Now click on Firmware Flasher.

Select the correct target for your board. The target may be written on the bottom of your board or on the product page.

Dont just guess, the target names are not always obvious. For example the Matek F405-Wing board needs the MATEKF405SE target.

Select the firmware version from the list

Click Load Firmware (Online).
Or Load Firmware (Offline) if you have the firmware file saved locally.

Click Flash Firmware
If all is working you will see the progress bar start moving. Once it's done the board will be updated and ready to configure.

If not you may need to try a more recent computer or ask for help on the INAV forums. I cant flash firmware with my 9yo MacBook but my 3yo iMac works fine.

Model setup in your transmitter

Another very important concept to understand is that you don't use any mixing in your transmitter, all the mixing work is handled by INAV and the flight control board. All you need is 100% weight on the first 4 channels for the sticks, and whatever mode switches you need. This model setup can be used for all INAV craft including airplanes, flying wings and multi rotors.

Here is my setup
Ch1 100 Ail
Ch2 100 Ele
Ch3 100 Thr
Ch4 100 Rud
Ch5 Nothing / Arm (2 pos switch)
Ch6 Nothing / Angle (2 pos switch)
Ch7 Nothing / Cruise / Position Hold  (3 pos switch)
Ch8 Nothing / Manual / RTH (3 pos switch)
Ch9 Nothing / Auto tune (2 pos switch)
Ch10 Nothing / OSD 1 / OSD 2 (left slider)


INAV Wiki on GitHub - Must read

This is where all the setup guides and tips are. It is the starting point for understanding how to setup INAV.

If you start asking basic questions on any INAV forum you will most likely be told to go back and read the INAV Wiki

Do yourself a favour and read the Fixed Wing Guide thoroughly, re-read relevant sections, and keep coming back. All the answers are here, including recommendations for flight control boards and GPS units.

Here are the sections you should study closely

Fixed Wing Guide Bookmark this page, you will come back here regularly

INAV Flight Modes This page describes all the non GPS modes.

iNav Navigation Modes These are all the GPS enabled navigation modes

Setting up Failsafe for RTH This shows how to setup the most important feature of INAV - Return to Home when RC signal is lost.

INAV CLI variables This shows all the internal workings of iNav. Something to study when you are more advanced in your INAV journey.

Also check out these excellent guides from the INAV Fixed Wing Facebook Group (scroll down to the pdfs)

https://github.com/iNavFlight/inav/blob/master/docs


Flight Control Board setup in INAV Configurator - Finally!

There is a fair bit to go through here so watch this video first, then I will explain the important bits. The configurator layout may be slightly different now but all the relevant sections are there.


Important - Click Save and Reboot at the bottom of the page to store any changes.

Setup Page
Board animation moves as you move the real board.
Heading, Pitch and Roll show the current angle of the board. 

Calibration Page
Every new board and new firmware requires this accelerometer calibration routine to be completed.
Compass calibration is only for quads. Connecting a compass or magnetometer is not recommended for planes. GPS can provide direction information.

Mixer  Page  
This is where any mixing happens, never in your transmitter
Choose Airplane in the Platform Configuration
Choose the correct Mixer Preset for your plane or wing. Note that default elevon mixing is 50% aileron 50% elevator.
Add new mixer lines for other functions like camera pan, flaps etc.

Outputs Page
Turn on - Enable Motor and servo output
Turn on - Stop motors on low throttle
This is where you can reverse any servos that are moving in the wrong direction, not in the transmitter.
Range and midpoints for each servo can be adjusted here if needed.

If you need to change Aileron and Elevator Rates use the Manual rates in the PID tuning page.

Presets Page
I prefer not to use any of these presets. Some of them are wrong and most likely won't suit your setup.

Ports Page
This is where you tell the board where you will connect the receiver and GPS. Also other devices like Smart Audio VTx control, Runcam camera control etc.

Configuration Page
Most settings will be already selected according to your board. Don't change anything unless you know what you are doing.

Setting that can be changed.

Board alignment
Pitch Degrees - If the plane doesn't fly level in Angle Mode this is where you make changes. I usually need about +3.0 degrees. Note this has nothing to do with Altitude Hold which is a GPS mode. This is to get the plane flying level just using the orientation of the board.
Yaw degrees - This is where you tell INAV if you mounted the board sideways (90 degrees) or backwards (180 degrees)

Receiver Mode
Select your Receiver Mode and Serial Receiver Provider. 

GPS
Turn on GPS for Navigation and Telemetry
GPS protocol should be pre-entered, but check your GPS product page for the correct protocol.

Other Features
"Stop Motors on low throttle" and "Enable Motor and servo outputs" will already be selected if you turned them on in the Outputs page
Analog RSSI - only enable if you are using a receiver with analog RSSI wire connection to the board  (eg L9R)
Turn OSD on - for OSD in your goggles
Permanent Airmode and Launch Mode are optional. I prefer to leave them off.

Failsafe Page
Select RTH

PID Tuning  Page 

PID Gains Tab (or PIFF Gains for fixed wing)
FeedForward or FF is the only value you need to change at this stage. P and I have much less effect on planes compared to quads. 

FF determines how much of your stick movement is forwarded on to the control surfaces when you are in any mode apart from Manual.

Increase FF if your servo throws are too small in Acro or Angle Modes. 

I like to increase (or decrease) FF until the throws in Acro Mode are about 80% of the throws in Manual Mode. That ensures you have adequate control from the sticks with some servo range left for stabilisation.

Autotune Mode can also be used to set P, I and FF values for your plane but I prefer to set them manually.

PIFFs for planes with a Rudder
If your plane has a rudder make sure your rudder throws are quite small, I recommend no more than 10º. Reduce mechanical throws or reduce Manual Yaw Rate to ensure the rudder doesn't overreact in RTH and POS Hold Modes. 

In ACRO mode Yaw is stabilised. This means the rudder will actively stop the plane turning unless you input some rudder stick. If you want to just bank and yank for turns, turn off yaw stabilisation by reducing Yaw P and I to zero, or select RC Yaw instead of Stabilised Yaw in the Mixer page.

Rates and Expo Tab
Maximum rotation rates are probably the most important number to get right for PIFF tuning. You need to determine the maximum Roll rate, Pitch rate and Yaw rate for your plane (in degrees per second) and enter them here. INAV needs to know these rotation rates for accurate stabilisation calculations. 

Note that we are talking about aircraft rotation rates here, not the usual control surface rates (or weights)

Fly your plane in Manual Mode and record how long it takes to do a full roll and a full loop (at a speed that allows loops and rolls). Divide 360 by the number of seconds. If a roll takes 2 seconds then the rate is 360 / 2 = 180 degrees/sec. 

It is important to set your maximum rotation rates slightly below the plane's performance, and definitely not higher. The number to enter should be about 10% lower.

Roll = 180, Pitch = 120 are good rates for my Ranger 1600, but all planes are different.

Yaw rate is difficult to determine but I use about 60. Ignore Yaw values if you dont have a rudder.

Roll Expo and Pitch Expo are the same as RC Expo in the Receiver page, and relates to all modes other than Manual.

According to the INAV Fixed Wing Guide Max ROLL angle and Max PITCH angle can be increased to 60 for sharper turns in any of the Flight Modes.

Manual ROLL rate, Manual PITCH rate, Manual YAW rate - This is where you can reduce control surface throws if you can't change pushrod connections. 

Filters and Mechanics 
Can be left alone

Advanced Tuning Page
Ignore Multirotor settings

RTH and Landing Settings
Choose a RTH altitude mode, I prefer "At Least, linear descent". Full explanation in the WIKI
Change RTH altitude from 1000 (10m) to something like 5000 (50m)
Change Land after RTH to "Never"

Fixed Wing Navigation Settings
These are the settings for GPS controlled flight modes. Think of them as Autopilot settings.

Cruise Throttle 
This is the throttle setting used for Altitude Hold and RTH flights. The default setting of 1400 is just below half throttle. Increase this value if it is too slow for safe cruising speed. Decrease if it's unnecessarily fast.

It's best not to change the other values at this stage.

Receiver Page
Check that channels are working as expected in this page.
Roll, Pitch, Yaw and Throttle graphs should increase when you push your transmitter sticks up and to the right.
If they decrease you need to reverse that channel on your transmitter. This ensures any stabilisation will be in the correct direction.
Also adjust the channel end points on your transmitter so that Roll Pitch and Yaw graphs go from minimum 1000 to maximum 2000. My Taranis requires end points to be adjusted to -97 and +97.

Manual RC Expo can be reduced here if you want. Default Manual Expo is 70 which is probably more that you are used to.

Select your RSSI channel if you have RSSI configured on a channel.

Modes Page
Here is where you setup all your mode channels and switch position

Commonly used Flight modes.

Air - Not really a mode but a modifier of other modes. Keeps stabilisation working when throttle is low. Best to turn on permanently if you use Presets and your aircraft is hard to glide or land without stabilisation.

Not required if you increase FF for more control in stabilised modes.

AIR shows as the mode in your goggles OSD rather than the actual mode, which is why I turn AIR mode off. NAV 2.6 will fix this bug.

Angle - self levelling, automatically enabled in all the GPS modes. Useful for checking board alignment, especially pitch degrees,  because it relies on board alignment and correct trim for level flight.

Acro or Rate - This is the default mode, always active when no other mode is selected. Stabilised but not self levelling. I use this mode most of the time for general cruising around.

Manual - No stabilisation, full control. Expo 70% and Rate 100% set by default in iNav. Useful to trim the plane and take to control if the board is faulty. Note that Manual is a mode like any other and has to be assigned to a switch position. 

Servo Autotrim - Attempts to set the servo subtrims for level flight in Manual mode during the first 2 seconds after being activated. Use this instead of transmitter trims and whenever needed to retrim the plane. 

Fly in Manual Mode, activate Autotrim and fly level for 2 seconds, keep Autotrim on, land and disarm to save the new subtrims. 

Autotune - Attempts to tune the P, I values for good stabilisation and FF values to give good stick control. 

Fly in Acro Mode, activate Autotune and fly around for a few minutes making full deflection roll and pitch changes. Turn Autotune off in the air. Land and disarm. Save the new PIFFs by pulling both sticks down and out.

Nav Launch - launch assist mode which delays motor spinup until acceleration from the throw is detected, then provides stabilised 5 sec climb out, then switches to whatever other mode is selected. eg. Nav Launch and RTH are a useful combination.

My GPS modes

Nav Cruise - Maintains current altitude and heading. 

Position Hold - Circles around the position at a set radius, 50m by default. Since INAV 2.5 it also holds Altitude as well.

Return to Home - Returns to the arm point then circles at a set height, 50m radius and 10m altitude by default. Must change this if 10m is too low in your area. I usually use 50m altitude.

Adjustments Page
Ignore this one

GPS Page
Check GPS function here. If the Total Messages number is counting up then your GPS is correctly connected. If not, make sure the GPS is getting power and try switching the GPS Tx and Rx connections. Satellite numbers will start showing up after a few minutes as long as you are outside or near a window.

OSD Page
This is where you can configure The OSD to your liking. Add, remove and position items on the screen where you want them.














CLI - Command Line Interface

Your entire setup can be seen by typing DUMP in the command entry space. 

Or type DIFF to see just what has been changed. 

You can save and share all this as a text file. Click Save to file.

All that text can be re-pasted into the "Write your command here" section for quick and easy setup of a new board.

There are many more commands and setup items available via the CLI than appear in the Configurator pages.


The Fixed Wing Wiki recommends a few extra settings that are not included in the previous pages. They need to be entered via the CLI.


Here are the extra setup commands I always add

 set max_angle_inclination_rll = 600

 set max_angle_inclination_pit = 600

(Increases the maximum pitch and roll angles to 60º for stabilised modes)


 set small_angle = 180

(Allows the board to be armed at any angle)


 set failsafe_throttle_low_delay = 0

(Prevents failsafe due to low throttle)


 set inav_reset_home = FIRST_ARM

(Keeps the first arm position as home if the board disarms)


 set nav_fw_allow_manual_thr_increase = ON

(Allows manual throttle above the cruise throttle setting) 

INAV groups and videos for more information