Skip to content

Commit

Permalink
Merge pull request #3693 from microsoft/clovett/fix_px4_wsl2_docs
Browse files Browse the repository at this point in the history
fix  "ControlPortLocal"
  • Loading branch information
zimmy87 authored May 14, 2021
2 parents fa87bfe + 03d3737 commit e7a3142
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
6 changes: 4 additions & 2 deletions docs/px4_sitl.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,9 @@ The default ports have changed recently, so check them closely to make sure AirS
bit too much noise generation. This setting clamps that down a bit which allows PX4 to achieve
GPS lock more quickly.
6. Now run your Unreal AirSim environment and it should connect to SITL PX4 via TCP. You should see
6. Open incoming TCP port 4560 and incoming UDP port 14540 using your firewall configuration.
7. Now run your Unreal AirSim environment and it should connect to SITL PX4 via TCP. You should see
a bunch of messages from the SITL PX4 window. Specifically, the following messages tell you that
AirSim is connected properly and GPS fusion is stable:
```
Expand All @@ -102,7 +104,7 @@ The default ports have changed recently, so check them closely to make sure AirS
If you do not see these messages then check your port settings.
7. You should also be able to use QGroundControl with SITL mode. Make sure there is no Pixhawk
8. You should also be able to use QGroundControl with SITL mode. Make sure there is no Pixhawk
hardware plugged in, otherwise QGroundControl will choose to use that instead. Note that as we
don't have a physical board, an RC cannot be connected directly to it. So the alternatives are
either use XBox 360 Controller or connect your RC using USB (for example, in case of FrSky
Expand Down
5 changes: 3 additions & 2 deletions docs/px4_sitl_wsl2.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export PX4_SIM_HOST_ADDR=172.31.64.1
**Note:** Be sure to update the above address `172.31.64.1` to match what you see from your
`ipconfig` command.

Open incoming port 4560 using your Windows Firewall settings.
Open incoming TCP port 4560 and incoming UDP port 14540 using your firewall configuration.

Now on the linux side run `ip address show` and copy the `eth0 inet` address, it should be something
like `172.31.66.156`. This is the address Windows needs to know in order to find PX4.
Expand All @@ -57,7 +57,8 @@ This resolves to the WSL 2 remote ip address found in the TCP socket.
"UseTcp": true,
"TcpPort": 4560,
"ControlIp": "remote",
"ControlPort": 14580,
"ControlPortLocal": 14540,
"ControlPortRemote": 14580,
"LocalHostIp": "172.31.64.1",
"Sensors":{
"Barometer":{
Expand Down

0 comments on commit e7a3142

Please sign in to comment.