{"action":"opened","number":9441,"pull_request":{"url":"https://api.github.com/repos/ArduPilot/ardupilot/pulls/9441","id":216153386,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE2MTUzMzg2","html_url":"https://github.com/ArduPilot/ardupilot/pull/9441","diff_url":"https://github.com/ArduPilot/ardupilot/pull/9441.diff","patch_url":"https://github.com/ArduPilot/ardupilot/pull/9441.patch","issue_url":"https://api.github.com/repos/ArduPilot/ardupilot/issues/9441","number":9441,"state":"open","locked":false,"title":"Plane: Collapse some quadplane code","user":{"login":"WickedShell","id":567688,"node_id":"MDQ6VXNlcjU2NzY4OA==","avatar_url":"https://avatars2.githubusercontent.com/u/567688?v=4","gravatar_id":"","url":"https://api.github.com/users/WickedShell","html_url":"https://github.com/WickedShell","followers_url":"https://api.github.com/users/WickedShell/followers","following_url":"https://api.github.com/users/WickedShell/following{/other_user}","gists_url":"https://api.github.com/users/WickedShell/gists{/gist_id}","starred_url":"https://api.github.com/users/WickedShell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WickedShell/subscriptions","organizations_url":"https://api.github.com/users/WickedShell/orgs","repos_url":"https://api.github.com/users/WickedShell/repos","events_url":"https://api.github.com/users/WickedShell/events{/privacy}","received_events_url":"https://api.github.com/users/WickedShell/received_events","type":"User","site_admin":false},"body":"This patch is primarily aimed at less repetition in the code. With one exception in tailsitter all calls to `QuadPlane::motors_output(void)` are preceded by `QuadPlane::run_rate_controller(void)`. This was addressed by moving the run_rate controller inside the `motors_output()` and using a default argument to allow tail sitters to not run the rate controllers.\r\n\r\nThis also moves all the motor outputs to be at the end of `QuadPlane::update_transition(void)` which I found to improve readibility, as well as correct a single loop error where the first time the `TRANSITION_AIRSPEED_WAIT` loop is run the vehicle hasn't called `AC_Attitude_Control_Multi::set_throttle_mix_max(void)`.\r\n\r\nFinally this removes an unneeded `AC_Attitude_Control_Multi::reset_rate_controller_I_terms(void)` when relaxing in quadplane, and uses this helper instead of trying to update all the rates directly when starting a landing. Given that we now have the `check_attitude_relax()` helper do we still want to explicitly reset the I terms when starting landing? I think this is actually now a bad idea, since the I term may have been valid if you already were in a VTOL mode, and `check_attitude_relax()` should be managing this for us I think this whole block of resetting can be discarded.","created_at":"2018-09-18T00:45:44Z","updated_at":"2018-09-18T00:45:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":349433650,"node_id":"MDU6TGFiZWwzNDk0MzM2NTA=","url":"https://api.github.com/repos/ArduPilot/ardupilot/labels/VTOL-Plane","name":"VTOL-Plane","color":"e99695","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/ArduPilot/ardupilot/pulls/9441/commits","review_comments_url":"https://api.github.com/repos/ArduPilot/ardupilot/pulls/9441/comments","review_comment_url":"https://api.github.com/repos/ArduPilot/ardupilot/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ArduPilot/ardupilot/issues/9441/comments","statuses_url":"https://api.github.com/repos/ArduPilot/ardupilot/statuses/9980073e01377426294167632e719484f3aa4f0f","head":{"label":"WickedShell:wickedshell/quadplane-cleanup","ref":"wickedshell/quadplane-cleanup","sha":"9980073e01377426294167632e719484f3aa4f0f","user":{"login":"WickedShell","id":567688,"node_id":"MDQ6VXNlcjU2NzY4OA==","avatar_url":"https://avatars2.githubusercontent.com/u/567688?v=4","gravatar_id":"","url":"https://api.github.com/users/WickedShell","html_url":"https://github.com/WickedShell","followers_url":"https://api.github.com/users/WickedShell/followers","following_url":"https://api.github.com/users/WickedShell/following{/other_user}","gists_url":"https://api.github.com/users/WickedShell/gists{/gist_id}","starred_url":"https://api.github.com/users/WickedShell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WickedShell/subscriptions","organizations_url":"https://api.github.com/users/WickedShell/orgs","repos_url":"https://api.github.com/users/WickedShell/repos","events_url":"https://api.github.com/users/WickedShell/events{/privacy}","received_events_url":"https://api.github.com/users/WickedShell/received_events","type":"User","site_admin":false},"repo":{"id":33838710,"node_id":"MDEwOlJlcG9zaXRvcnkzMzgzODcxMA==","name":"ardupilot","full_name":"WickedShell/ardupilot","private":false,"owner":{"login":"WickedShell","id":567688,"node_id":"MDQ6VXNlcjU2NzY4OA==","avatar_url":"https://avatars2.githubusercontent.com/u/567688?v=4","gravatar_id":"","url":"https://api.github.com/users/WickedShell","html_url":"https://github.com/WickedShell","followers_url":"https://api.github.com/users/WickedShell/followers","following_url":"https://api.github.com/users/WickedShell/following{/other_user}","gists_url":"https://api.github.com/users/WickedShell/gists{/gist_id}","starred_url":"https://api.github.com/users/WickedShell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WickedShell/subscriptions","organizations_url":"https://api.github.com/users/WickedShell/orgs","repos_url":"https://api.github.com/users/WickedShell/repos","events_url":"https://api.github.com/users/WickedShell/events{/privacy}","received_events_url":"https://api.github.com/users/WickedShell/received_events","type":"User","site_admin":false},"html_url":"https://github.com/WickedShell/ardupilot","description":"APM Plane, APM Copter, APM Rover source","fork":true,"url":"https://api.github.com/repos/WickedShell/ardupilot","forks_url":"https://api.github.com/repos/WickedShell/ardupilot/forks","keys_url":"https://api.github.com/repos/WickedShell/ardupilot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/WickedShell/ardupilot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/WickedShell/ardupilot/teams","hooks_url":"https://api.github.com/repos/WickedShell/ardupilot/hooks","issue_events_url":"https://api.github.com/repos/WickedShell/ardupilot/issues/events{/number}","events_url":"https://api.github.com/repos/WickedShell/ardupilot/events","assignees_url":"https://api.github.com/repos/WickedShell/ardupilot/assignees{/user}","branches_url":"https://api.github.com/repos/WickedShell/ardupilot/branches{/branch}","tags_url":"https://api.github.com/repos/WickedShell/ardupilot/tags","blobs_url":"https://api.github.com/repos/WickedShell/ardupilot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/WickedShell/ardupilot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/WickedShell/ardupilot/git/refs{/sha}","trees_url":"https://api.github.com/repos/WickedShell/ardupilot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/WickedShell/ardupilot/statuses/{sha}","languages_url":"https://api.github.com/repos/WickedShell/ardupilot/languages","stargazers_url":"https://api.github.com/repos/WickedShell/ardupilot/stargazers","contributors_url":"https://api.github.com/repos/WickedShell/ardupilot/contributors","subscribers_url":"https://api.github.com/repos/WickedShell/ardupilot/subscribers","subscription_url":"https://api.github.com/repos/WickedShell/ardupilot/subscription","commits_url":"https://api.github.com/repos/WickedShell/ardupilot/commits{/sha}","git_commits_url":"https://api.github.com/repos/WickedShell/ardupilot/git/commits{/sha}","comments_url":"https://api.github.com/repos/WickedShell/ardupilot/comments{/number}","issue_comment_url":"https://api.github.com/repos/WickedShell/ardupilot/issues/comments{/number}","contents_url":"https://api.github.com/repos/WickedShell/ardupilot/contents/{+path}","compare_url":"https://api.github.com/repos/WickedShell/ardupilot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/WickedShell/ardupilot/merges","archive_url":"https://api.github.com/repos/WickedShell/ardupilot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/WickedShell/ardupilot/downloads","issues_url":"https://api.github.com/repos/WickedShell/ardupilot/issues{/number}","pulls_url":"https://api.github.com/repos/WickedShell/ardupilot/pulls{/number}","milestones_url":"https://api.github.com/repos/WickedShell/ardupilot/milestones{/number}","notifications_url":"https://api.github.com/repos/WickedShell/ardupilot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/WickedShell/ardupilot/labels{/name}","releases_url":"https://api.github.com/repos/WickedShell/ardupilot/releases{/id}","deployments_url":"https://api.github.com/repos/WickedShell/ardupilot/deployments","created_at":"2015-04-12T23:49:21Z","updated_at":"2018-07-18T15:43:59Z","pushed_at":"2018-09-18T00:36:15Z","git_url":"git://github.com/WickedShell/ardupilot.git","ssh_url":"git@github.com:WickedShell/ardupilot.git","clone_url":"https://github.com/WickedShell/ardupilot.git","svn_url":"https://github.com/WickedShell/ardupilot","homepage":"http://ardupilot.com/","size":113128,"stargazers_count":1,"watchers_count":1,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0","node_id":"MDc6TGljZW5zZTk="},"forks":0,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"ArduPilot:master","ref":"master","sha":"0e0d847f7f8b1a3f79ca173ccccb919345b69190","user":{"login":"ArduPilot","id":17919847,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE3OTE5ODQ3","avatar_url":"https://avatars3.githubusercontent.com/u/17919847?v=4","gravatar_id":"","url":"https://api.github.com/users/ArduPilot","html_url":"https://github.com/ArduPilot","followers_url":"https://api.github.com/users/ArduPilot/followers","following_url":"https://api.github.com/users/ArduPilot/following{/other_user}","gists_url":"https://api.github.com/users/ArduPilot/gists{/gist_id}","starred_url":"https://api.github.com/users/ArduPilot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ArduPilot/subscriptions","organizations_url":"https://api.github.com/users/ArduPilot/orgs","repos_url":"https://api.github.com/users/ArduPilot/repos","events_url":"https://api.github.com/users/ArduPilot/events{/privacy}","received_events_url":"https://api.github.com/users/ArduPilot/received_events","type":"Organization","site_admin":false},"repo":{"id":7512484,"node_id":"MDEwOlJlcG9zaXRvcnk3NTEyNDg0","name":"ardupilot","full_name":"ArduPilot/ardupilot","private":false,"owner":{"login":"ArduPilot","id":17919847,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE3OTE5ODQ3","avatar_url":"https://avatars3.githubusercontent.com/u/17919847?v=4","gravatar_id":"","url":"https://api.github.com/users/ArduPilot","html_url":"https://github.com/ArduPilot","followers_url":"https://api.github.com/users/ArduPilot/followers","following_url":"https://api.github.com/users/ArduPilot/following{/other_user}","gists_url":"https://api.github.com/users/ArduPilot/gists{/gist_id}","starred_url":"https://api.github.com/users/ArduPilot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ArduPilot/subscriptions","organizations_url":"https://api.github.com/users/ArduPilot/orgs","repos_url":"https://api.github.com/users/ArduPilot/repos","events_url":"https://api.github.com/users/ArduPilot/events{/privacy}","received_events_url":"https://api.github.com/users/ArduPilot/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/ArduPilot/ardupilot","description":"ArduPlane, ArduCopter, ArduRover source","fork":false,"url":"https://api.github.com/repos/ArduPilot/ardupilot","forks_url":"https://api.github.com/repos/ArduPilot/ardupilot/forks","keys_url":"https://api.github.com/repos/ArduPilot/ardupilot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ArduPilot/ardupilot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ArduPilot/ardupilot/teams","hooks_url":"https://api.github.com/repos/ArduPilot/ardupilot/hooks","issue_events_url":"https://api.github.com/repos/ArduPilot/ardupilot/issues/events{/number}","events_url":"https://api.github.com/repos/ArduPilot/ardupilot/events","assignees_url":"https://api.github.com/repos/ArduPilot/ardupilot/assignees{/user}","branches_url":"https://api.github.com/repos/ArduPilot/ardupilot/branches{/branch}","tags_url":"https://api.github.com/repos/ArduPilot/ardupilot/tags","blobs_url":"https://api.github.com/repos/ArduPilot/ardupilot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ArduPilot/ardupilot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ArduPilot/ardupilot/git/refs{/sha}","trees_url":"https://api.github.com/repos/ArduPilot/ardupilot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ArduPilot/ardupilot/statuses/{sha}","languages_url":"https://api.github.com/repos/ArduPilot/ardupilot/languages","stargazers_url":"https://api.github.com/repos/ArduPilot/ardupilot/stargazers","contributors_url":"https://api.github.com/repos/ArduPilot/ardupilot/contributors","subscribers_url":"https://api.github.com/repos/ArduPilot/ardupilot/subscribers","subscription_url":"https://api.github.com/repos/ArduPilot/ardupilot/subscription","commits_url":"https://api.github.com/repos/ArduPilot/ardupilot/commits{/sha}","git_commits_url":"https://api.github.com/repos/ArduPilot/ardupilot/git/commits{/sha}","comments_url":"https://api.github.com/repos/ArduPilot/ardupilot/comments{/number}","issue_comment_url":"https://api.github.com/repos/ArduPilot/ardupilot/issues/comments{/number}","contents_url":"https://api.github.com/repos/ArduPilot/ardupilot/contents/{+path}","compare_url":"https://api.github.com/repos/ArduPilot/ardupilot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ArduPilot/ardupilot/merges","archive_url":"https://api.github.com/repos/ArduPilot/ardupilot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ArduPilot/ardupilot/downloads","issues_url":"https://api.github.com/repos/ArduPilot/ardupilot/issues{/number}","pulls_url":"https://api.github.com/repos/ArduPilot/ardupilot/pulls{/number}","milestones_url":"https://api.github.com/repos/ArduPilot/ardupilot/milestones{/number}","notifications_url":"https://api.github.com/repos/ArduPilot/ardupilot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ArduPilot/ardupilot/labels{/name}","releases_url":"https://api.github.com/repos/ArduPilot/ardupilot/releases{/id}","deployments_url":"https://api.github.com/repos/ArduPilot/ardupilot/deployments","created_at":"2013-01-09T00:58:52Z","updated_at":"2018-09-17T15:07:16Z","pushed_at":"2018-09-18T00:19:08Z","git_url":"git://github.com/ArduPilot/ardupilot.git","ssh_url":"git@github.com:ArduPilot/ardupilot.git","clone_url":"https://github.com/ArduPilot/ardupilot.git","svn_url":"https://github.com/ArduPilot/ardupilot","homepage":"http://ardupilot.org/","size":113803,"stargazers_count":3466,"watchers_count":3466,"language":"C++","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":6913,"mirror_url":null,"archived":false,"open_issues_count":1261,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0","node_id":"MDc6TGljZW5zZTk="},"forks":6913,"open_issues":1261,"watchers":3466,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ArduPilot/ardupilot/pulls/9441"},"html":{"href":"https://github.com/ArduPilot/ardupilot/pull/9441"},"issue":{"href":"https://api.github.com/repos/ArduPilot/ardupilot/issues/9441"},"comments":{"href":"https://api.github.com/repos/ArduPilot/ardupilot/issues/9441/comments"},"review_comments":{"href":"https://api.github.com/repos/ArduPilot/ardupilot/pulls/9441/comments"},"review_comment":{"href":"https://api.github.com/repos/ArduPilot/ardupilot/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ArduPilot/ardupilot/pulls/9441/commits"},"statuses":{"href":"https://api.github.com/repos/ArduPilot/ardupilot/statuses/9980073e01377426294167632e719484f3aa4f0f"}},"author_association":"CONTRIBUTOR","merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"maintainer_can_modify":true,"commits":1,"additions":11,"deletions":26,"changed_files":3}}
{"actor":{"display_login":"WickedShell"}}