Skip to content

Autotest for new auto mode "wait for yaw" option#1

Open
Mcluky wants to merge 27 commits into
ja51d:auto-wait-for-yawfrom
Mcluky:master
Open

Autotest for new auto mode "wait for yaw" option#1
Mcluky wants to merge 27 commits into
ja51d:auto-wait-for-yawfrom
Mcluky:master

Conversation

@Mcluky

@Mcluky Mcluky commented Jun 24, 2026

Copy link
Copy Markdown

Summary

Classification & Testing (check all that apply and add your own)

  • Checked by a human programmer
  • Non-functional change
  • No-binary change
  • Infrastructure change (e.g. unit tests, helper scripts)
  • Automated test(s) verify changes (e.g. unit test, autotest)
  • Tested manually, description below (e.g. SITL)
  • Tested on hardware
  • Logs attached
  • Logs available on request

Description

Hi @ja51d, I finally gotten around to update the branch and point it towards your change. I rebased my branch to the latest master so maybe it makes sense for you to do that as well

peterbarker and others added 27 commits June 4, 2026 10:38
this was not rotating the delta-velocity into NED except when EKF2 or EKF3 was involved.  That's definitely not a good thing!
we may not be able to get the base measurement for this from AP_InertialSensor
includes a fix for precision_loiter_to_pos for recent EKF changes
Cover arming and Loiter when the compass is enabled but not an EK3 yaw
source (EK3_SRC1_YAW=0):

- LoiterNoCompassYaw: optical flow, no GPS. The EKF runs in relative
  aiding with a free-running yaw, so arming directly in Loiter works.
- LoiterNoCompassYawGPS: GPS, no optical flow. The GSF yaw estimator
  only aligns once moving, so Loiter cannot be entered on the ground;
  the test arms in AltHold, flies forward to align yaw, then Loiters.
recent fix to deconflict caused an issue
register_read() returns false without writing *value when the SPI
response fails its CRC check.  Several callers ignored that return and
then used the output:

 - validate_register_configuration() compared an uninitialised value
   against the expected register contents, so a corrupted read produced
   an undefined comparison (could wrongly pass or fail validation);
 - read_product_id() relied on its values being zero-initialised;
 - configure_registers() read-modify-wrote a control register from an
   uninitialised value, potentially writing garbage to the hardware.

Honour the return value at each of these sites (a failed read now fails
the relevant init step), use UNUSED_RESULT() for the intentional dummy
reads, and mark the bool status methods WARN_IF_UNUSED so future callers
cannot silently ignore a failed read.

Clears one clang-scan-build "garbage value" finding, so the expected
count drops from 30 to 29.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Replace the Copter callers of the watch_altitude_maintained helper with
direct wait_altitude calls and remove the now-unused base-class method.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants