{"action":"created","issue":{"url":"https://api.github.com/repos/mavlink/mavros/issues/574","repository_url":"https://api.github.com/repos/mavlink/mavros","labels_url":"https://api.github.com/repos/mavlink/mavros/issues/574/labels{/name}","comments_url":"https://api.github.com/repos/mavlink/mavros/issues/574/comments","events_url":"https://api.github.com/repos/mavlink/mavros/issues/574/events","html_url":"https://github.com/mavlink/mavros/issues/574","id":165596091,"number":574,"title":"Send MAVLink messages to QGroundControl","user":{"login":"pablogarciaaunon","id":13102869,"avatar_url":"https://avatars.githubusercontent.com/u/13102869?v=3","gravatar_id":"","url":"https://api.github.com/users/pablogarciaaunon","html_url":"https://github.com/pablogarciaaunon","followers_url":"https://api.github.com/users/pablogarciaaunon/followers","following_url":"https://api.github.com/users/pablogarciaaunon/following{/other_user}","gists_url":"https://api.github.com/users/pablogarciaaunon/gists{/gist_id}","starred_url":"https://api.github.com/users/pablogarciaaunon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pablogarciaaunon/subscriptions","organizations_url":"https://api.github.com/users/pablogarciaaunon/orgs","repos_url":"https://api.github.com/users/pablogarciaaunon/repos","events_url":"https://api.github.com/users/pablogarciaaunon/events{/privacy}","received_events_url":"https://api.github.com/users/pablogarciaaunon/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/mavlink/mavros/labels/question","name":"question","color":"cc317c"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-07-14T15:54:48Z","updated_at":"2016-07-15T11:29:53Z","closed_at":null,"body":"Hi!\r\n\r\nI have an airplane simulator, which sends some flight information through ROS topics. I would like to take it and send it to the QGroundControl using MAVLink.\r\n\r\nTo start testing how it works, I tried to send one message with a fake battery status (mavros_msgs/BatteryStatus.msg):\r\n\r\n1 - First, I run the mavros_node with gcs_url = udp://:14570@127.0.0.1:14551.\r\n2 - I run my node, which is supposed to send the battery message:\r\n\r\n```\r\n#include <ros/ros.h>\r\n#include <mavros_msgs/BatteryStatus.h>\r\n\r\nint main(int argc, char *argv[])\r\n\r\n{\r\n    ros::init(argc, argv, \"battery_node\");\r\n    ros::NodeHandle n;\r\n    ros::Publisher battery_pub = n.advertise<mavros_msgs::BatteryStatus>(\"/mavros/battery\", 1000);\r\n    ros::Rate loop_rate(10);\r\n\r\n    while (ros::ok())\r\n    {\r\n        mavros_msgs::BatteryStatus baterry_msg;\r\n\r\n        baterry_msg.voltage = 5;\r\n        baterry_msg.current = 0.5;\r\n        baterry_msg.remaining = 0.36;\r\n\r\n        battery_pub.publish(baterry_msg);\r\n\r\n        ros::spinOnce();\r\n        loop_rate.sleep();\r\n    }\r\n    return 0;\r\n}\r\n\r\n```\r\n\r\n3 - I connect QGroundControl to UDP: 127.0.0.1:14551\r\n\r\n... and nothing happens =/\r\n\r\nI am sure that the connexion between mavros and the QGC works, because if I run a simulation with MAVProxy though 127.0.0.1:14540, using mavros as a \"bridge\", the airplane is recognized.\r\n\r\nWhat am I doing wrong? \r\n\r\nI am using Ubuntu 14, ROS Indigo and QGC 2.9.7.\r\n\r\nThank you very much in advance,\r\nPablo\r\n\r\n\r\n\r\n "},"comment":{"url":"https://api.github.com/repos/mavlink/mavros/issues/comments/232928631","html_url":"https://github.com/mavlink/mavros/issues/574#issuecomment-232928631","issue_url":"https://api.github.com/repos/mavlink/mavros/issues/574","id":232928631,"user":{"login":"vooon","id":1023568,"avatar_url":"https://avatars.githubusercontent.com/u/1023568?v=3","gravatar_id":"","url":"https://api.github.com/users/vooon","html_url":"https://github.com/vooon","followers_url":"https://api.github.com/users/vooon/followers","following_url":"https://api.github.com/users/vooon/following{/other_user}","gists_url":"https://api.github.com/users/vooon/gists{/gist_id}","starred_url":"https://api.github.com/users/vooon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vooon/subscriptions","organizations_url":"https://api.github.com/users/vooon/orgs","repos_url":"https://api.github.com/users/vooon/repos","events_url":"https://api.github.com/users/vooon/events{/privacy}","received_events_url":"https://api.github.com/users/vooon/received_events","type":"User","site_admin":false},"created_at":"2016-07-15T11:29:53Z","updated_at":"2016-07-15T11:29:53Z","body":"`mavlink/to` sends message **to** FCU, not GCS.\r\n\r\nBut you may use `gcs_bridge` node and `mavlink/from` topic."}}
{"actor":{"display_login":"vooon"}}