-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
After intalling MTF-01 optic flow althold does not work. #10487
Comments
I think the simplest way is do not report new altitude if distance strength or precision is low. Then agl engine decrease the surface reliability automatically. The same way it decrease surface reliability when altitude is higher than nav_max_terrain_follow_alt |
IMHO it shouldn't be using AGL at all if the pilot has AGL turned off (surface mode off). If I say I don't want it to dive into a ravine, I mean it. If I choose to fly MSL altitude, it shouldn't kinda mix in a little AGL behind my back and dive into a ravine. |
But I can land in surface mode instead. So surface mode can replace old behavior. |
Nobody need rangefinder here? |
Is the way disable rangefinder from switch? |
Turning off surface should turn off (use of) the rangefinder, except for autoland. Unless I'm mistaken. |
I think I got it. The rangefinder readings are not used directly to calculate the position. When the quality of the readings is high, they are used to calculate the correction for the inertial engine, when the quality is low, this correction is simply a constant. What is the difference between the following parameters? |
If I set to zeroes |
Yes, that would disable the sensor that measures the distance to the surface. Which would make surface mode not work.
They are almost the same. max_terrain_follow_altitude is the maximum altitude it will go in surface mode. Your "throttle" (altitude) input is scaled based on this value. It often makes sense to set them to the same value. |
If somebody can fast recompile corrected source for matek 722 mini se, I can give it a try |
It seems so to me as well. At least, in the case of that particular type of sensor. I wonder if the same applies to others? See also the similar line around inav/src/main/sensors/rangefinder.c Line 250 in 1c15fcc
Are you familiar with how to make a pull request? |
That rangefinder is connected via MSP, right? inav/src/main/io/rangefinder_msp.c Line 68 in 1c15fcc
Above, you wrote "About 16m rangefinder report zero altitude", but your screenshot shows 1 rather than 0. |
That means the problem is somewhere else. |
I think I found the real problem. The rangefinder was installed incorrectly. |
Glad you found the problem! |
There was nothing directly below it. But it has a field of diffusive light of almost 180 degrees. Any object that hits it scatters light and becomes decisive at high altitudes, when the main signal becomes weak. The sensitivity of this simple devise is amasing. It is necessary to have a switch to turn off the rangefinder, since any scattering from dust or fog can disrupt stabilization and lead to a sharp change in altitude |
Ok. I remove the optical flow and return to the working combination of GPS + barometer + compass. If anyone in the future is interested in finishing the optical flow and rangefinder, contact me. |
Inav 8.0.0
Althold was tuned before installing optflow. Worked normal.
After installing optflow.
Under approx 2m - work normal.
Higher does not work.
Testing in field over flat surface (snow). Sunny day.
Surface mode = OFF
nav_max_terrain_follow_alt = 100
inav_max_surface_altitude = 100
Max altitude where rangefinder measure reliable data 120cm.
Max altitude where rangefinder measure something about 3m.
About 16m rangefinder report zero altitude
At the same time surface reliability = 1000.
Log
blackbox_log_2024-11-28_131957.TXT
The text was updated successfully, but these errors were encountered: