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

[WIP] Add Makefile and source changes for macOS build #4

Merged
merged 1 commit into from
Apr 1, 2024

Conversation

Jamil
Copy link
Contributor

@Jamil Jamil commented Mar 31, 2024

This successfully builds the plugin for macOS; I haven't tested things end-to-end yet actually controlling things with QGC but will update this if I do. The Makefile should be similar for Linux as well, but I haven't tested it (nor how to properly link XPLM on Linux).

The plugin shows up fine in X-Plane 12 on macOS Catalina:
image

@Jamil
Copy link
Contributor Author

Jamil commented Mar 31, 2024

Things seem to work fine end-to-end, but I think I'm getting a lot of EKF errors. The flight is quite unstable and it keeps going into failsafe mode because the estimate is unstable. Have you seen this before @alireza787b?
image

@alireza787b
Copy link
Owner

Things seem to work fine end-to-end, but I think I'm getting a lot of EKF errors. The flight is quite unstable and it keeps going into failsafe mode because the estimate is unstable. Have you seen this before @alireza787b? image

Hi
thanks for the make files. I will test and merge it today.
for the EKF errors. what is your FPS? and what drone you are using?
If the frame rate is too slow, EKF won't get enough data and will fail.

@alireza787b alireza787b merged commit b7e6dfc into alireza787b:master Apr 1, 2024
1 check failed
@Jamil
Copy link
Contributor Author

Jamil commented Apr 1, 2024

Things seem to work fine end-to-end, but I think I'm getting a lot of EKF errors. The flight is quite unstable and it keeps going into failsafe mode because the estimate is unstable. Have you seen this before @alireza787b? image

Hi thanks for the make files. I will test and merge it today. for the EKF errors. what is your FPS? and what drone you are using? If the frame rate is too slow, EKF won't get enough data and will fail.

About 70-100 FPS and I’ve set the model updates to max. I also made sure the config.ini has the right aircraft and the parameters in QGC are uploaded - I’m using your fork of PX4 as well.

Trying with the erhang quad and while i can get the errors to go away most of the time, the flight is really unstable and it’ll “overshoot” the intended flight path. It can fly for short periods of stability but then as soon as there’s a small movement, it goes out of control.

@alireza787b
Copy link
Owner

Things seem to work fine end-to-end, but I think I'm getting a lot of EKF errors. The flight is quite unstable and it keeps going into failsafe mode because the estimate is unstable. Have you seen this before @alireza787b? image

Hi thanks for the make files. I will test and merge it today. for the EKF errors. what is your FPS? and what drone you are using? If the frame rate is too slow, EKF won't get enough data and will fail.

About 70-100 FPS and I’ve set the model updates to max. I also made sure the config.ini has the right aircraft and the parameters in QGC are uploaded - I’m using your fork of PX4 as well.

Trying with the erhang quad and while i can get the errors to go away most of the time, the flight is really unstable and it’ll “overshoot” the intended flight path. It can fly for short periods of stability but then as soon as there’s a small movement, it goes out of control.

are you using the latest pull of the repo? in latest I have added easy airframe selection from menu and withlates forked px4 repo all parameters are automatically synced with airframe setup. if sth be wrong with parameters it will be unstable

@Jamil
Copy link
Contributor Author

Jamil commented Apr 4, 2024

I just pulled and tried again. Same issue, but seeing this error now in the PX4 logs as well, which might be related:

WARN  [mc_pos_control] invalid setpoints
WARN  [mc_pos_control] Failsafe: blind land
WARN  [failsafe] Failsafe activated

In QGC, I see:

[19:27:41.146] Critical: Failsafe, triggering Descend
- No valid local position estimate
- No valid global position estimate
- No manual control input

Full logs from takeoff:

INFO  [commander] Ready for takeoff!
INFO  [tone_alarm] notify positive
INFO  [commander] Armed by external command
INFO  [tone_alarm] arming warning
INFO  [navigator] Executing Mission
INFO  [navigator] Climb to 3.0 meters above home
INFO  [commander] Takeoff detected
WARN  [mc_pos_control] invalid setpoints
WARN  [mc_pos_control] Failsafe: blind land
WARN  [failsafe] Failsafe activated
INFO  [tone_alarm] battery warning (fast)
INFO  [navigator] Executing Mission
INFO  [navigator] Climb to 3.0 meters above home
WARN  [mc_pos_control] invalid setpoints
WARN  [mc_pos_control] Failsafe: blind land
WARN  [failsafe] Failsafe activated
INFO  [tone_alarm] battery warning (fast)
INFO  [commander] Landing detected
INFO  [commander] Disarmed by landing
INFO  [tone_alarm] notify neutral

@alireza787b
Copy link
Owner

make sure you select correct airframe config from the menu of the plugin.
and just in case this invalid setpoitns be a problem with px4 configs, run make clean and make distclean and rebuild the px4_sitl xplane_ehang184

@Jamil
Copy link
Contributor Author

Jamil commented Apr 4, 2024

make sure you select correct airframe config from the menu of the plugin. and just in case this invalid setpoitns be a problem with px4 configs, run make clean and make distclean and rebuild the px4_sitl xplane_ehang184

Do you have time to take a quick look at my ulog? I've tried those steps but still run into the same issues; might be a platform-specific bug on Mac. Shot you an email (with the email on your profile) if you get a chance to take a quick look :)

If you have any pointers on where to look or what might be the issue I can dig into the code and figure out what's wrong

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.

2 participants