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
Offboard Review #9273
Comments
For the outer loop, it's that the attitude control needs the yaw/yaw_rate as input. |
Ok, but still don't understand why position and velocity is required... |
You can send "body_rates", "roll pitch yaw thrust" or even "actuator control" commands over OFFBOARD mode. Therefore, depending on the input, we have to enable controls depending on the lowest level control. If you receive body_rate from the offboard companion, You will not run the attitude control which outputs body_rate setpoints or lower. Indeed there is one problem. If you ignore everything in your offboard message (SET_TARGET_LOCAL_NED) with a flag ignoring everything, the copter just shuts down the motors, because the different controls are not in one message, so we cannot check the consistency of the command. A solution to it was proposed here, to only allow 4 degrees of freedom in the fancy you prefer: http://discuss.px4.io/t/idea-for-a-more-versatile-offboard-control/4721 Yet, it did not go further as the offboard mode is currently reworked using Flight Tasks (see the PR about it https://github.com/PX4/Firmware/pulls?utf8=%E2%9C%93&q=is%3Apr+flighttask) The idea is to give a single channel where people use OFFBOARD commands, thus you don't have race conditions on the control and you can only control 4 degrees at the same time (X, Y, Z, Yaw). |
I think we are talking about the same thing, but I am questioning the implementation.
I know that there is a PR because I opened it. However, there is no reason to not continue to clean up the offboard implementation as you suggested here http://discuss.px4.io/t/idea-for-a-more-versatile-offboard-control/4721, although with Flighttask it can be farther simplified. |
@Stifael At the end of this process can we please review and update: |
I am trying to understand the offboard mode on my side as well ans I would like to clarify the following points: |
|
Thank you Alexis. I am using the USB port to communicate with the FCU. I am trying to understand how the offboard is working because so far, I do not succeed in my experiments. |
Hi,
Doesn't this lead to is_loiter_sp being true when the type mask starts with 0x1000 (= 0b1 00...) or 0x2000 (= 0b10 00..) (take_off or land), and to is_land_sp and is_take_off_sp being true when the type mask is 0x3000(= 0b11 00..)?
Which would only return true when the leading 4 bits are exactly identical. |
i would confirm that the is_takeoff_sp and is_land_sp dont work becuase of the reason mentioned above i.e. the '& 0x3000' condition gets true whenever either landing or takeoff bits are set, and since loiter is the first condition in the if else statement, it always put the drone in that state. as work around i have disabled the loiter functionality by
|
This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions. |
@julianoes Is this still relevant? |
No idea. |
@julianoes , @Jaeyoung-Lim , I do think it is still relevant or at least I have some questions about the implementation...
Here it is stated by @AlexisTM that you can send actuator control commands, and that all controllers won't run if you do so. It is quite interesting because in the .msg file for offboard_control_mode there is actually a field |
@sstroobants I don't think this issue is relevant to the current offboard architecture In the new offboard architecture, the actuator setpoint support was only added back in #18581 |
@Jaeyoung-Lim, Thanks for the quick response, I've just found that commit 20 minutes ago... Sorry. |
@sstroobants I don't think this issue is relevant anymore for this discussion. Could you either post a new issue or post the question on discuss.px4.io ? |
The offboard implementation is very confusing for several reason:
I wanted to do some offboard refactor for flighttask, but then I realized that there are a few code implementation that are difficult to understand.
A few missing pieces:
The text was updated successfully, but these errors were encountered: