diff options
author | Thomas Gubler <thomasgubler@gmail.com> | 2015-02-10 23:34:26 +0100 |
---|---|---|
committer | Thomas Gubler <thomasgubler@gmail.com> | 2015-02-28 18:25:34 +0100 |
commit | 001575e740261acf9de68023ab8e8bd59a478ce3 (patch) | |
tree | 75cd8dc6e9b7ce317acb7775ae0f48732b2d01b3 /src/platforms/ros | |
parent | 2d0c5616cbc89f0621e2e8eb56b06635ecedfd90 (diff) | |
download | px4-firmware-001575e740261acf9de68023ab8e8bd59a478ce3.tar.gz px4-firmware-001575e740261acf9de68023ab8e8bd59a478ce3.tar.bz2 px4-firmware-001575e740261acf9de68023ab8e8bd59a478ce3.zip |
ros: mavlink node: add mavconn link
Diffstat (limited to 'src/platforms/ros')
-rw-r--r-- | src/platforms/ros/nodes/mavlink/mavlink.cpp | 2 | ||||
-rw-r--r-- | src/platforms/ros/nodes/mavlink/mavlink.h | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/src/platforms/ros/nodes/mavlink/mavlink.cpp b/src/platforms/ros/nodes/mavlink/mavlink.cpp index e64e576bd..b6413c3b4 100644 --- a/src/platforms/ros/nodes/mavlink/mavlink.cpp +++ b/src/platforms/ros/nodes/mavlink/mavlink.cpp @@ -49,6 +49,8 @@ using namespace px4; Mavlink::Mavlink() : _n() { + + _link = mavconn::MAVConnInterface::open_url("udp://localhost:14551@localhost:14552"); } int main(int argc, char **argv) diff --git a/src/platforms/ros/nodes/mavlink/mavlink.h b/src/platforms/ros/nodes/mavlink/mavlink.h index 2723df35c..5b3946887 100644 --- a/src/platforms/ros/nodes/mavlink/mavlink.h +++ b/src/platforms/ros/nodes/mavlink/mavlink.h @@ -41,6 +41,7 @@ */ #include "ros/ros.h" +#include <mavconn/interface.h> namespace px4 { @@ -55,6 +56,7 @@ public: protected: ros::NodeHandle _n; + mavconn::MAVConnInterface::Ptr _link; }; } |