Mavsdk server cannot connect to other IP via UDP

Dear contributors,

According to the help of the mavsdk_server, it should be possible to connect to an external bind host:

Usage: backend_bin [-h | --help]
backend_bin [-p mavsdk_server_port] [Connection URL]

Connection URL format should be:
Serial: serial:///path/to/serial/dev[:baudrate]
UDP: udp://[bind_host][:bind_port]
TCP: tcp://[server_host][:server_port]

However, when trying to connect with a Herelink controller I get the following error:

venv/lib/python3.8/site-packages/mavsdk/bin/mavsdk_server -p 50040 udp://
[04:47:11|Info ] MAVSDK version: 0.28.0 (mavsdk_impl.cpp:26)
[04:47:11|Debug] New: System ID: 0 Comp ID: 0 (mavsdk_impl.cpp:377)
[04:47:11|Info ] Server started (grpc_server.cpp:43)
[04:47:11|Info ] Server set to listen on (grpc_server.cpp:44)
[04:47:11|Info ] Waiting to discover system on udp://… (connection_initiator.h:22)
[04:47:11|Error] bind error: Cannot assign requested address (udp_connection.cpp:85)
[04:47:11|Error] Connection failed: Bind error (connection_initiator.h:48)

I want to use this to connect multiple drones to a single computer. For each drone, I want to start a separate mavsdk_server. If I leave out the IP address of the Herelink, and just use udp://:14552, a connection is made, but then I would not be able to connect multiple systems. Do I use the correct bind address? Is this possible at all, as is suggested by the provided help? or is this a bug?

1 Like