Skip to content
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

BLHeli: fixed build without BLHeli with sim on hw #26122

Merged
merged 7 commits into from
Mar 18, 2024

Conversation

tridge
Copy link
Contributor

@tridge tridge commented Feb 1, 2024

this build was failing:
Tools/scripts/sitl-on-hardware/sitl-on-hw.py --board Pixhawk6X --vehicle plane --frame QuadPlane --simclass QuadPlane

Copy link
Collaborator

@andyp1per andyp1per left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure this is correct, would need to look more closely

@@ -117,7 +118,7 @@ void AP_IOMCU::thread_main(void)
uart.begin(1500*1000, 128, 128);
uart.set_unbuffered_writes(true);

#if HAL_WITH_IO_MCU_BIDIR_DSHOT
#if HAVE_AP_BLHELI_SUPPORT && HAL_WITH_IO_MCU_BIDIR_DSHOT
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd have to look more closely but I don't think this is correct - I don't think we compile blheli into iomcu

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AP_IOMCU does use AP_BLHeli, and that is the issue. It doesn't build with sim-on-hw

@@ -33,9 +33,7 @@
#include <AP_Baro/AP_Baro.h>
#include <AP_RTC/AP_RTC.h>
#include <AP_SerialManager/AP_SerialManager.h>
#ifdef HAVE_AP_BLHELI_SUPPORT
#include <AP_BLheli/AP_BLHeli.h>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't you need a define guard in the header if you do this?

@tridge
Copy link
Contributor Author

tridge commented Mar 16, 2024

@andyp1per AP_BLHeli::telem_data doesn't exist in AP_Spektrum_Telem::calc_esc()
I suspect this was an incomplete changeover in this PR: #16725

@tridge tridge requested a review from andyp1per March 16, 2024 22:27
@andyp1per
Copy link
Collaborator

Can't push - here is a fixup - #26554

Copy link
Collaborator

@andyp1per andyp1per left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See my fixup branch

@tridge tridge force-pushed the pr-fixed-sim-on-hw-build branch from 98cec29 to e973fea Compare March 17, 2024 20:27
@tridge
Copy link
Contributor Author

tridge commented Mar 17, 2024

@andyp1per thanks!

@tridge tridge merged commit e019488 into ArduPilot:master Mar 18, 2024
91 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants