iNav issues with Alt Hold/Pos hold - Need Advice

Hi All, first “real” drone build finished, a Holybro X500 with some modifications. I have a background in robotics so went with a Naze32 (I realis this is an ancient board) which is ROS (Robotics Operating System) compatible so I can use it for automation later.

To test my build I installed the latest iNav I could before moving on to the integration with my other stuff.

I’m running Baro, Magnetometer and GPS sensors alongside the usual Accelerometer.

In NAV ALTHOLD it’s rock solid, I mean literally - no oscillations, it just sits where I leave it! Switch to NAV POSHOLD (which in theory is ALTHOLD plus X/Y?) and it rockets skyward at an epic rate! I can’t see any real reason for this when ALT HOLD works so flawlessly.

I’m waiting for an F7 board in the post as I realised after finishing my build that there’s a MAVLINK module for ROS and the later iNav versions support bidirectional MAVLINK - lesson learned!!

Matthew

1 Like

Hey dude. Can you confirm which version of inav and can you provide a diff of your config please?

Cheers

I think I’ve seen this one or two times in the past, not with iNav but earlier code versions for Pixhawk/APM.

The issue is when switching from AltHold, where the barometer’s output is used to auto control the throttle, into position hold when there is an insufficient Satellite lock, low Sat count or high HDOP, the flight controller will default to stabilise mode. In stabilise mode the throttle position has a lower value for maintaining a hover, so if your stick position is in the centre when switching modes this will be interpreted as an increase in throttle input causing the craft to quickly ascend.

Again I have little knowledge of iNav but today the Pixhawk will not switch to any guided mode unless a suitable GPS lock has been obtained. However if I switch from a PosHold(GPS) mode to a pure stabilised mode without reducing the throttle input the model will ascend, fairly quickly, until it is reduced to a suitable level to manually control altitude.

If you have a means to replay any stored flight logs this could provide an indication of what the probable cause could be.

Again I have to stress I have very little in the way of a working knowledge of iNav, and it’s about time I acquired a suitable board to play with it, but I understand there is a lot of common ground between the iNav system and that of the APM/Pixhawk environment.

Nidge.

Thanks guys!

I’m stuck on iNav 1.7.3 as the F1 processor is only supported up to 1.7.3 :frowning: Diff below

Hopefully Royal Mail get my F7 to me today - I ordered a Matek F722, but it looks like RM deliveries in my area are on a go slow.

# diff
# INAV/NAZE 1.7.3 Sep  9 2017 / 09:59:03 (974440df)
feature MOTOR_STOP
feature SOFTSERIAL
feature GPS
feature PWM_OUTPUT_ENABLE
serial 1 2 115200 9600 0 115200
serial 31 256 115200 38400 9600 115200
aux 0 0 0 1700 2100
aux 1 1 0 1700 2100
aux 2 3 2 1300 1700
aux 3 9 2 1700 2100
aux 4 22 3 1700 2100
set gyro_sync = ON
set gyro_hardware_lpf = 188HZ
set acc_hardware = MPU6500
set acczero_x = 29
set acczero_y = -13
set acczero_z = 72
set accgain_x = 4090
set accgain_y = 4085
set accgain_z = 4075
set mag_hardware = QMC5883
set mag_declination = -40
set magzero_x = -166
set magzero_y = -379
set magzero_z = 379
set baro_hardware = BMP280
set motor_pwm_rate = 1000
set motor_pwm_protocol = ONESHOT125
set i2c_speed = 200KHZ
profile 1

set mc_p_pitch = 90
set mc_i_pitch = 34
set mc_d_pitch = 54
set mc_p_roll = 90
set mc_i_roll = 34
set mc_d_roll = 54
set mc_p_yaw = 70
set mc_i_yaw = 20
set heading_hold_rate_limit = 30
set roll_rate = 60
set pitch_rate = 60
set yaw_rate = 60

My F7 board just arrived!! Will try the latest firmware on the F7 and see if it helps