-
Notifications
You must be signed in to change notification settings - Fork 1.7k
MSP2 message exposing 3D attitude, position, and velocity #11032
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
base: master
Are you sure you want to change the base?
Conversation
…ition, and velocity.
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
PR Code Suggestions ✨Explore these optional code suggestions:
|
…TTITUDE' in favor of more accuracy.
The AI bot sometimes says dumb things. Sometimes, it has helpful suggestions. Also, has anyone tested this with an actual aircraft, or can someone do so, please? |
@sensei-hacker, thank you for taking a look at this PR. Sure, I'll comment on AI bot suggestions.
I only tested these changes in SITL. |
User description
This PR implements a recent issue.
I believe the community working on autonomous navigation would benefit from the proposed message.
The implementation breaks attitude format compatibility with
MSP_ATTITUDE
message in favor of more accuracy.Once the PR is accepted, I could add the documentation on
MSP2_INAV_FULL_LOCAL_POSE
in the corresponding Wiki page.The changes have been tested using SITL. Compilation:
mkdir -p build/sitl cmake -S . -B build/sitl -G Ninja -DSITL=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo cmake --build build/sitl -j
SITL was started with
build/sitl/inav_9.0.0_SITL
.A Python script was run to ensure the message is being read and decoded
Output:
I believe further testing can be omitted since the essence of the changes lies in just reading from the variables into a buffer, similar to what other MSP messages do.
PR Type
Enhancement
Description
This description is generated by an AI tool. It may have inaccuracies
Add new MSP2 message for full 3D pose data
Expose attitude, position, and velocity in single message
Refactor attitude payload writing into reusable function
Support autonomous navigation use cases
Diagram Walkthrough
File Walkthrough
fc_msp.c
Add full pose MSP message handler
src/main/fc/fc_msp.c
mspWriteAttitudePayload()
functionMSP_ATTITUDE
case to use new helper functionMSP2_INAV_FULL_LOCAL_POSE
case handlermsp_protocol_v2_inav.h
Define new MSP2 command constant
src/main/msp/msp_protocol_v2_inav.h
MSP2_INAV_FULL_LOCAL_POSE
command constant