Closed Ryanf55 closed 6 months ago
Is your feature request related to a problem? Please describe.
You can only connect real hardware to a companion computer over serial, which is slow.
Describe the solution you'd like
Allow using the new network stack to connect to the companion computer over network, which is much faster
Platform [ x] All
More info
Here's the interface that we already met for the UDP in AP_DDS: https://github.com/eProsima/Micro-XRCE-DDS-Client/blob/master/include/uxr/client/profile/transport/custom/custom_transport.h
It was implemented here: https://github.com/ArduPilot/ardupilot/blob/5bd5aa87a728ebae468e3c3247467d8971a5d6fa/libraries/AP_DDS/AP_DDS_UDP.cpp#L12
As far as I can tell, the ArduPilot DDS over UDP is implemented as a UDP Client on Port 2019. No multicast is used right now. We currently hard code the address to 127.0.0.1 , so it only works in SITL. This is the address for the server address for the DDS agent on the companion computer. It needs to be exposed through a parameter. https://github.com/ArduPilot/ardupilot/blob/5bd5aa87a728ebae468e3c3247467d8971a5d6fa/libraries/AP_DDS/AP_DDS_Client.h#L140
The port is already has a parameter: https://github.com/ArduPilot/ardupilot/blob/5bd5aa87a728ebae468e3c3247467d8971a5d6fa/libraries/AP_DDS/AP_DDS_Client.cpp#L63
This should work. Ready to validate on hardware now.
It's part of 4.5 now.
Feature request
Is your feature request related to a problem? Please describe.
You can only connect real hardware to a companion computer over serial, which is slow.
Describe the solution you'd like
Allow using the new network stack to connect to the companion computer over network, which is much faster
Platform [ x] All
More info
Here's the interface that we already met for the UDP in AP_DDS: https://github.com/eProsima/Micro-XRCE-DDS-Client/blob/master/include/uxr/client/profile/transport/custom/custom_transport.h
It was implemented here: https://github.com/ArduPilot/ardupilot/blob/5bd5aa87a728ebae468e3c3247467d8971a5d6fa/libraries/AP_DDS/AP_DDS_UDP.cpp#L12
As far as I can tell, the ArduPilot DDS over UDP is implemented as a UDP Client on Port 2019. No multicast is used right now. We currently hard code the address to 127.0.0.1 , so it only works in SITL. This is the address for the server address for the DDS agent on the companion computer. It needs to be exposed through a parameter. https://github.com/ArduPilot/ardupilot/blob/5bd5aa87a728ebae468e3c3247467d8971a5d6fa/libraries/AP_DDS/AP_DDS_Client.h#L140
The port is already has a parameter: https://github.com/ArduPilot/ardupilot/blob/5bd5aa87a728ebae468e3c3247467d8971a5d6fa/libraries/AP_DDS/AP_DDS_Client.cpp#L63