Connect SITL on Vagrant to Flight Gear

Hi,

I am having trouble connecting flight gear running on my host OS to my SITL instance running in a Vagrant (linux) virtual machine. I think the problem is SITL automatically outputs the relevant packets over the localhost connection (127.0.0.1) which is happening within the guest OS. The host OS can’t connect to this address as it is in the guest OS. However the mavlink data is transferred from the guest to host OS using the address 10.0.2.2 which can be connected to using the host OS through the localhost address. SITL usually outputs Flight Gear compatible data on 127.0.0.1:5503 therefore I think within the guest OS this data needs to be changed to be transmitted on 10.0.2.2:5503 then Flight Gear running on the host OS could connect to 127.0.0.1:5503. I attempted to do this by editing the sim_vehicle.py file to pass the ‘–sitl’ tag for mavproxy to be 10.0.2.2:5503 but this doesnt seem to have worked.

Any help or advice would be appreciated

Thanks