mavlink: option to specify the UDP remote port

This enables using several mavlink instances for SITL.
This commit is contained in:
Julian Oes
2016-02-01 11:15:21 +01:00
committed by Lorenz Meier
parent 3d282e4ee8
commit b44f20d705
2 changed files with 23 additions and 7 deletions
+3
View File
@@ -337,6 +337,8 @@ public:
unsigned short get_network_port() { return _network_port; }
unsigned short get_remote_port() { return _remote_port; }
int get_socket_fd () { return _socket_fd; };
#ifdef __PX4_POSIX
struct sockaddr_in * get_client_source_address() { return &_src_addr; }
@@ -441,6 +443,7 @@ private:
int _socket_fd;
Protocol _protocol;
unsigned short _network_port;
unsigned short _remote_port;
struct telemetry_status_s _rstatus; ///< receive status