SITL OSD question - where do I type in "--osd" in SITL to get the GUI to show up?

Hi folks…on this page:

http://ardupilot.org/copter/docs/common-osd-overview.html

Near the bottom of the page It says:

A graphical OSD simulation in a separate window can be opened by adding the following option to sim_vehicle.py:

–osd

How does a person “add the following option” to sim_vehicle.py ??

This is what I am doing…

  1. Start Mission Planner
  2. Select SIMULATION
  3. Click on MULTIROTOR
  4. Simulation starts

I have found the sim_vehicle_py file…I assume I am supposed to add the text “–osd” somewhere in that file? Then save the file and restart the simulator?

Or do I enter “–osd” into the EXTRA COMMAND LINE box at the bottom of the simulator page?

Neither of those have worked for me…so I am apparently missing something. (Sure wish the Ardupilot/OSD page could explain the process better for dolts like me.)

Thanks…

It goes on the sim_vehicle.py command line. And it’s two hyphens: - - o s d

Hi Anthony…

So I found this bit of code (below)…where do I add “- - osd” ?

Thanks…


define and run parser

parser = CompatOptionParser(
“sim_vehicle.py”,
epilog=""
"eeprom.bin in the starting directory contains the parameters for your "
"simulated vehicle. Always start from the same directory. It is "
"recommended that you start in the main vehicle directory for the vehicle "
"you are simulating, for example, start in the ArduPlane directory to "
“simulate ArduPlane”)

on the command line issue

python sim_vehicle.py --osd

So we are saying where it says EXTRA COMMAND LINE, to type in “python sim_vehicle.py --osd”

Is that correct?

Because it doesn’t seem to work…nothing changes (that I can tell)…I can’t find any kind of OSD screen inside Mission Planner in it’s simulation mode.

Thanks…

No, what I am saying to to use a command line. If you are using windows, use the cmd.exe program
If you are using linux use xterm

OK…got it…I think…is this what the command line should look like?

c:\users\etc\etc\mission planner\sitl>sim_vehicle.py --osd

Then Windows asks with what program I want to open.
I select Mission Planner.
Mission Planner opens.
I select the simulation tab, click on multicopter.
Mission Planner downloads the SITL software (I wonder why it does that every time?).
The simulation starts…

But the OSD display is nowhere to be found.

Look I guess there is something quite basic here that I am not understanding.

The other thing is that I’ve discovered the OSD GUI section in Mission Planner when my vehicle is plugged in/connected…so maybe there is no need to go down this command line road anymore?

Thanks…

Hi @wsalopek,

I hope this would be an answer for you.

I assume that you already installed all environments to start for a SITL simulation. Please see the Simulating On-Board OSD section on the link below:
https://ardupilot.org/dev/docs/using-sitl-for-ardupilot-testing.html#using-sitl-for-ardupilot-testing

  1. Please open ‘New terminal’ on Ubuntu

  2. type in this command on the terminal:

  • cd ~/ardupilot/ArduCopter
  1. press ‘Enter’ key

  2. And then please type in this command on the terminal:

  • sim_vehicle.py --console --map --osd