StarlingUAS / ProjectStarling

BRL Flight Arena Infrastructure 2.0
Other
16 stars 3 forks source link

Add host-based lookups for ArduPilot/Gazebo #117

Closed rob-clarke closed 2 years ago

rob-clarke commented 2 years ago

Allows the use of the ArduPilot/Gazebo simulator in non-network=host mode.

Should allow StarlingUAS/FenswoodScenario#4 to be resolved. Potentially eliminates the need for separate Windows/Linux versions there.

Details

When not operating with network host, the SITL and plugin need to be told the IP addresses of each other. This PR adds the ability to configure the IPs either through AP_{SITL,SIM}_ADDRESS for direct IP address setting, or using _HOST variants which will perform a lookup to resolve the IP.

Further work will be needed to support different port numbers for multiple instances.

rob-clarke commented 2 years ago

Yes, providing a service name (subtly different from a container name) to AP_{SITL,SIM}_HOST will perform the IP lookup.

Has been tested on Linux using the updated windows compose file in StarlingUAS/FenswoodScenario#6 (i.e. no network host). Everything appeared to connect properly. Ideally test on Windows too before merging.

Unfortunately the xacro stuff is likely to have collided so there will be some unpicking to do.

mhl787156 commented 2 years ago

Okay let me check on windows before merging https://github.com/StarlingUAS/FenswoodScenario/pull/6 and this one.

mhl787156 commented 2 years ago

LGTM All good to merge.

We should fix #110 and merge that, then we should do a release.