{"action":"created","comment":{"url":"https://api.github.com/repos/mavlink/mavros/pulls/comments/25566663","id":25566663,"diff_hunk":"@@ -0,0 +1,120 @@\n+/**\n+ * @brief SetpointActuatorControl plugin\n+ * @file setpoint_actuator_control.cpp\n+ * @author Marcel Stüttgen <stuettgen@fh-aachen.de>\n+ *\n+ * @addtogroup plugin\n+ * @{\n+ */\n+/*\n+ * Copyright 2015 Marcel Stüttgen.\n+ *\n+ * This program is free software; you can redistribute it and/or modify\n+ * it under the terms of the GNU General Public License as published by\n+ * the Free Software Foundation; either version 3 of the License, or\n+ * (at your option) any later version.\n+ *\n+ * This program is distributed in the hope that it will be useful, but\n+ * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY\n+ * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License\n+ * for more details.\n+ *\n+ * You should have received a copy of the GNU General Public License along\n+ * with this program; if not, write to the Free Software Foundation, Inc.,\n+ * 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA\n+ */\n+\n+#include <mavros/mavros_plugin.h>\n+#include <pluginlib/class_list_macros.h>\n+\n+#include<std_msgs/Float32MultiArray.h>\n+#include<mavros/ActuatorControl.h>\n+\n+namespace mavplugin {\n+\n+/**\n+ * @brief Setpoint actuator control plugin\n+ *\n+ * Send setpoint actuator control to FCU controller.\n+ */\n+class ActuatorControlPlugin : public MavRosPlugin {\n+\n+ public:\n+\n+  //constructor\n+  ActuatorControlPlugin() : uas(nullptr) { };\n+\n+  //init function\n+  void initialize(UAS &uas_, ros::NodeHandle &nh, diagnostic_updater::Updater &diag_updater) {\n+\n+    uas = &uas_;\n+    sp_nh_ = ros::NodeHandle(nh, \"setpoint_actuator_control\");\n+    controls_sub_ = sp_nh_.subscribe(\"actuator_controls\", 10, &ActuatorControlPlugin::actuator_control_cb, this);\n+\n+  }\n+\n+  //name of object\n+  const std::string get_name() const {\n+    return \"SetpointActuatorControl\";\n+  }\n+\n+  const message_map get_rx_handlers() {\n+    return { /* Rx disabled */ };\n+  }\n+\n+private:\n+ \n+  UAS *uas;\n+\n+  ros::NodeHandle sp_nh_;","path":"mavros/src/plugins/actuator_control.cpp","position":69,"original_position":69,"commit_id":"c4aa5c6b9c51b931c07507e05c999c6a62f9fbd3","original_commit_id":"c4aa5c6b9c51b931c07507e05c999c6a62f9fbd3","user":{"login":"mhkabir","id":5557676,"avatar_url":"https://avatars.githubusercontent.com/u/5557676?v=3","gravatar_id":"","url":"https://api.github.com/users/mhkabir","html_url":"https://github.com/mhkabir","followers_url":"https://api.github.com/users/mhkabir/followers","following_url":"https://api.github.com/users/mhkabir/following{/other_user}","gists_url":"https://api.github.com/users/mhkabir/gists{/gist_id}","starred_url":"https://api.github.com/users/mhkabir/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mhkabir/subscriptions","organizations_url":"https://api.github.com/users/mhkabir/orgs","repos_url":"https://api.github.com/users/mhkabir/repos","events_url":"https://api.github.com/users/mhkabir/events{/privacy}","received_events_url":"https://api.github.com/users/mhkabir/received_events","type":"User","site_admin":false},"body":"Remove this too","created_at":"2015-03-01T11:58:10Z","updated_at":"2015-03-01T11:58:10Z","html_url":"https://github.com/mavlink/mavros/pull/230#discussion_r25566663","pull_request_url":"https://api.github.com/repos/mavlink/mavros/pulls/230","_links":{"self":{"href":"https://api.github.com/repos/mavlink/mavros/pulls/comments/25566663"},"html":{"href":"https://github.com/mavlink/mavros/pull/230#discussion_r25566663"},"pull_request":{"href":"https://api.github.com/repos/mavlink/mavros/pulls/230"}}},"pull_request":{"url":"https://api.github.com/repos/mavlink/mavros/pulls/230","id":30231922,"html_url":"https://github.com/mavlink/mavros/pull/230","diff_url":"https://github.com/mavlink/mavros/pull/230.diff","patch_url":"https://github.com/mavlink/mavros/pull/230.patch","issue_url":"https://api.github.com/repos/mavlink/mavros/issues/230","number":230,"state":"open","locked":false,"title":"inital draft for set_actuator_control plugin","user":{"login":"mstuettgen","id":10927858,"avatar_url":"https://avatars.githubusercontent.com/u/10927858?v=3","gravatar_id":"","url":"https://api.github.com/users/mstuettgen","html_url":"https://github.com/mstuettgen","followers_url":"https://api.github.com/users/mstuettgen/followers","following_url":"https://api.github.com/users/mstuettgen/following{/other_user}","gists_url":"https://api.github.com/users/mstuettgen/gists{/gist_id}","starred_url":"https://api.github.com/users/mstuettgen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mstuettgen/subscriptions","organizations_url":"https://api.github.com/users/mstuettgen/orgs","repos_url":"https://api.github.com/users/mstuettgen/repos","events_url":"https://api.github.com/users/mstuettgen/events{/privacy}","received_events_url":"https://api.github.com/users/mstuettgen/received_events","type":"User","site_admin":false},"body":"Hi there, here is my first draft for a setpoint actuator control plugin\r\n\r\nI still need to know the correct low level send command and if there is a special Mixin for setpoint actuator control.\r\n\r\n","created_at":"2015-02-28T22:05:37Z","updated_at":"2015-03-01T11:58:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"562e30ce27a1f769bfcf899f6b9357c99b59ed57","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mavlink/mavros/pulls/230/commits","review_comments_url":"https://api.github.com/repos/mavlink/mavros/pulls/230/comments","review_comment_url":"https://api.github.com/repos/mavlink/mavros/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mavlink/mavros/issues/230/comments","statuses_url":"https://api.github.com/repos/mavlink/mavros/statuses/c4aa5c6b9c51b931c07507e05c999c6a62f9fbd3","head":{"label":"mstuettgen:master","ref":"master","sha":"c4aa5c6b9c51b931c07507e05c999c6a62f9fbd3","user":{"login":"mstuettgen","id":10927858,"avatar_url":"https://avatars.githubusercontent.com/u/10927858?v=3","gravatar_id":"","url":"https://api.github.com/users/mstuettgen","html_url":"https://github.com/mstuettgen","followers_url":"https://api.github.com/users/mstuettgen/followers","following_url":"https://api.github.com/users/mstuettgen/following{/other_user}","gists_url":"https://api.github.com/users/mstuettgen/gists{/gist_id}","starred_url":"https://api.github.com/users/mstuettgen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mstuettgen/subscriptions","organizations_url":"https://api.github.com/users/mstuettgen/orgs","repos_url":"https://api.github.com/users/mstuettgen/repos","events_url":"https://api.github.com/users/mstuettgen/events{/privacy}","received_events_url":"https://api.github.com/users/mstuettgen/received_events","type":"User","site_admin":false},"repo":{"id":31431411,"name":"mavros","full_name":"mstuettgen/mavros","owner":{"login":"mstuettgen","id":10927858,"avatar_url":"https://avatars.githubusercontent.com/u/10927858?v=3","gravatar_id":"","url":"https://api.github.com/users/mstuettgen","html_url":"https://github.com/mstuettgen","followers_url":"https://api.github.com/users/mstuettgen/followers","following_url":"https://api.github.com/users/mstuettgen/following{/other_user}","gists_url":"https://api.github.com/users/mstuettgen/gists{/gist_id}","starred_url":"https://api.github.com/users/mstuettgen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mstuettgen/subscriptions","organizations_url":"https://api.github.com/users/mstuettgen/orgs","repos_url":"https://api.github.com/users/mstuettgen/repos","events_url":"https://api.github.com/users/mstuettgen/events{/privacy}","received_events_url":"https://api.github.com/users/mstuettgen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mstuettgen/mavros","description":"MAVLink to ROS gateway with UDP proxy for Ground Control Station","fork":true,"url":"https://api.github.com/repos/mstuettgen/mavros","forks_url":"https://api.github.com/repos/mstuettgen/mavros/forks","keys_url":"https://api.github.com/repos/mstuettgen/mavros/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mstuettgen/mavros/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mstuettgen/mavros/teams","hooks_url":"https://api.github.com/repos/mstuettgen/mavros/hooks","issue_events_url":"https://api.github.com/repos/mstuettgen/mavros/issues/events{/number}","events_url":"https://api.github.com/repos/mstuettgen/mavros/events","assignees_url":"https://api.github.com/repos/mstuettgen/mavros/assignees{/user}","branches_url":"https://api.github.com/repos/mstuettgen/mavros/branches{/branch}","tags_url":"https://api.github.com/repos/mstuettgen/mavros/tags","blobs_url":"https://api.github.com/repos/mstuettgen/mavros/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mstuettgen/mavros/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mstuettgen/mavros/git/refs{/sha}","trees_url":"https://api.github.com/repos/mstuettgen/mavros/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mstuettgen/mavros/statuses/{sha}","languages_url":"https://api.github.com/repos/mstuettgen/mavros/languages","stargazers_url":"https://api.github.com/repos/mstuettgen/mavros/stargazers","contributors_url":"https://api.github.com/repos/mstuettgen/mavros/contributors","subscribers_url":"https://api.github.com/repos/mstuettgen/mavros/subscribers","subscription_url":"https://api.github.com/repos/mstuettgen/mavros/subscription","commits_url":"https://api.github.com/repos/mstuettgen/mavros/commits{/sha}","git_commits_url":"https://api.github.com/repos/mstuettgen/mavros/git/commits{/sha}","comments_url":"https://api.github.com/repos/mstuettgen/mavros/comments{/number}","issue_comment_url":"https://api.github.com/repos/mstuettgen/mavros/issues/comments{/number}","contents_url":"https://api.github.com/repos/mstuettgen/mavros/contents/{+path}","compare_url":"https://api.github.com/repos/mstuettgen/mavros/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mstuettgen/mavros/merges","archive_url":"https://api.github.com/repos/mstuettgen/mavros/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mstuettgen/mavros/downloads","issues_url":"https://api.github.com/repos/mstuettgen/mavros/issues{/number}","pulls_url":"https://api.github.com/repos/mstuettgen/mavros/pulls{/number}","milestones_url":"https://api.github.com/repos/mstuettgen/mavros/milestones{/number}","notifications_url":"https://api.github.com/repos/mstuettgen/mavros/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mstuettgen/mavros/labels{/name}","releases_url":"https://api.github.com/repos/mstuettgen/mavros/releases{/id}","created_at":"2015-02-27T17:43:49Z","updated_at":"2015-03-01T02:15:30Z","pushed_at":"2015-03-01T02:15:29Z","git_url":"git://github.com/mstuettgen/mavros.git","ssh_url":"git@github.com:mstuettgen/mavros.git","clone_url":"https://github.com/mstuettgen/mavros.git","svn_url":"https://github.com/mstuettgen/mavros","homepage":null,"size":2780,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"mavlink:master","ref":"master","sha":"4db9cf38c0fd1afeddaa75bd4b5c498faf59797e","user":{"login":"mavlink","id":961247,"avatar_url":"https://avatars.githubusercontent.com/u/961247?v=3","gravatar_id":"","url":"https://api.github.com/users/mavlink","html_url":"https://github.com/mavlink","followers_url":"https://api.github.com/users/mavlink/followers","following_url":"https://api.github.com/users/mavlink/following{/other_user}","gists_url":"https://api.github.com/users/mavlink/gists{/gist_id}","starred_url":"https://api.github.com/users/mavlink/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mavlink/subscriptions","organizations_url":"https://api.github.com/users/mavlink/orgs","repos_url":"https://api.github.com/users/mavlink/repos","events_url":"https://api.github.com/users/mavlink/events{/privacy}","received_events_url":"https://api.github.com/users/mavlink/received_events","type":"Organization","site_admin":false},"repo":{"id":15189073,"name":"mavros","full_name":"mavlink/mavros","owner":{"login":"mavlink","id":961247,"avatar_url":"https://avatars.githubusercontent.com/u/961247?v=3","gravatar_id":"","url":"https://api.github.com/users/mavlink","html_url":"https://github.com/mavlink","followers_url":"https://api.github.com/users/mavlink/followers","following_url":"https://api.github.com/users/mavlink/following{/other_user}","gists_url":"https://api.github.com/users/mavlink/gists{/gist_id}","starred_url":"https://api.github.com/users/mavlink/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mavlink/subscriptions","organizations_url":"https://api.github.com/users/mavlink/orgs","repos_url":"https://api.github.com/users/mavlink/repos","events_url":"https://api.github.com/users/mavlink/events{/privacy}","received_events_url":"https://api.github.com/users/mavlink/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mavlink/mavros","description":"MAVLink to ROS gateway with UDP proxy for Ground Control Station","fork":false,"url":"https://api.github.com/repos/mavlink/mavros","forks_url":"https://api.github.com/repos/mavlink/mavros/forks","keys_url":"https://api.github.com/repos/mavlink/mavros/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mavlink/mavros/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mavlink/mavros/teams","hooks_url":"https://api.github.com/repos/mavlink/mavros/hooks","issue_events_url":"https://api.github.com/repos/mavlink/mavros/issues/events{/number}","events_url":"https://api.github.com/repos/mavlink/mavros/events","assignees_url":"https://api.github.com/repos/mavlink/mavros/assignees{/user}","branches_url":"https://api.github.com/repos/mavlink/mavros/branches{/branch}","tags_url":"https://api.github.com/repos/mavlink/mavros/tags","blobs_url":"https://api.github.com/repos/mavlink/mavros/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mavlink/mavros/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mavlink/mavros/git/refs{/sha}","trees_url":"https://api.github.com/repos/mavlink/mavros/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mavlink/mavros/statuses/{sha}","languages_url":"https://api.github.com/repos/mavlink/mavros/languages","stargazers_url":"https://api.github.com/repos/mavlink/mavros/stargazers","contributors_url":"https://api.github.com/repos/mavlink/mavros/contributors","subscribers_url":"https://api.github.com/repos/mavlink/mavros/subscribers","subscription_url":"https://api.github.com/repos/mavlink/mavros/subscription","commits_url":"https://api.github.com/repos/mavlink/mavros/commits{/sha}","git_commits_url":"https://api.github.com/repos/mavlink/mavros/git/commits{/sha}","comments_url":"https://api.github.com/repos/mavlink/mavros/comments{/number}","issue_comment_url":"https://api.github.com/repos/mavlink/mavros/issues/comments{/number}","contents_url":"https://api.github.com/repos/mavlink/mavros/contents/{+path}","compare_url":"https://api.github.com/repos/mavlink/mavros/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mavlink/mavros/merges","archive_url":"https://api.github.com/repos/mavlink/mavros/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mavlink/mavros/downloads","issues_url":"https://api.github.com/repos/mavlink/mavros/issues{/number}","pulls_url":"https://api.github.com/repos/mavlink/mavros/pulls{/number}","milestones_url":"https://api.github.com/repos/mavlink/mavros/milestones{/number}","notifications_url":"https://api.github.com/repos/mavlink/mavros/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mavlink/mavros/labels{/name}","releases_url":"https://api.github.com/repos/mavlink/mavros/releases{/id}","created_at":"2013-12-14T16:58:11Z","updated_at":"2015-03-01T09:37:16Z","pushed_at":"2015-03-01T09:37:57Z","git_url":"git://github.com/mavlink/mavros.git","ssh_url":"git@github.com:mavlink/mavros.git","clone_url":"https://github.com/mavlink/mavros.git","svn_url":"https://github.com/mavlink/mavros","homepage":null,"size":2780,"stargazers_count":17,"watchers_count":17,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":27,"mirror_url":null,"open_issues_count":32,"forks":27,"open_issues":32,"watchers":17,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mavlink/mavros/pulls/230"},"html":{"href":"https://github.com/mavlink/mavros/pull/230"},"issue":{"href":"https://api.github.com/repos/mavlink/mavros/issues/230"},"comments":{"href":"https://api.github.com/repos/mavlink/mavros/issues/230/comments"},"review_comments":{"href":"https://api.github.com/repos/mavlink/mavros/pulls/230/comments"},"review_comment":{"href":"https://api.github.com/repos/mavlink/mavros/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mavlink/mavros/pulls/230/commits"},"statuses":{"href":"https://api.github.com/repos/mavlink/mavros/statuses/c4aa5c6b9c51b931c07507e05c999c6a62f9fbd3"}}}}