mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-16 06:33:34 +08:00
SITL: add multi-vehicle support to rcS
This also removes the HIGHRES_IMU mavlink stream to the GCS. I don't see why it's needed and it adds noticeable CPU load.
This commit is contained in:
@@ -142,7 +142,7 @@ void Simulator::parameters_update(bool force)
|
||||
int Simulator::start(int argc, char *argv[])
|
||||
{
|
||||
int ret = 0;
|
||||
int udp_port = 0;
|
||||
int udp_port = 14560;
|
||||
_instance = new Simulator();
|
||||
|
||||
if (_instance) {
|
||||
|
||||
@@ -669,12 +669,6 @@ void Simulator::pollForMAVLinkMessages(bool publish, int udp_port)
|
||||
// udp socket data
|
||||
struct sockaddr_in _myaddr;
|
||||
|
||||
if (udp_port < 1) {
|
||||
int32_t prt;
|
||||
param_get(param_find("SITL_UDP_PRT"), &prt);
|
||||
udp_port = prt;
|
||||
}
|
||||
|
||||
// try to setup udp socket for communcation with simulator
|
||||
memset((char *)&_myaddr, 0, sizeof(_myaddr));
|
||||
_myaddr.sin_family = AF_INET;
|
||||
|
||||
@@ -40,13 +40,6 @@
|
||||
*/
|
||||
#include <parameters/param.h>
|
||||
|
||||
/**
|
||||
* Simulator UDP port
|
||||
*
|
||||
* @group SITL
|
||||
*/
|
||||
PARAM_DEFINE_INT32(SITL_UDP_PRT, 14560);
|
||||
|
||||
/**
|
||||
* Simulator Battery drain interval
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user