Skip to content

Viewing the GMAT GUI

Harry Goldschmitt edited this page Nov 1, 2020 · 6 revisions

Now that you've built GMAT, how do you view it? GMATConsole is great for debugging GMAT scripts. It is not much fun to watch, but the display version will give you access to an interesting GUI. There are 4 ways to display the GMAT GUI. The list, below is in the order recommended:

  • RDP - this is the easiest to use on Windows and OSx hosts. It is supported by Vagrant. An add_rdpserver.sh script file is included in the repository file to install and configure gmat2020a_box's RDP server.
  • VNC - this is almost as easy to use as RDP, but has to be invoked from your host OS's VNC viewer. An add_vncserver.sh script file is included in the repository file to install and configure gmat_build's VNC server.
  • Virtual Box Console - You will have to modify the Vagrantfile and your Ubuntu box via both VBoxManage and the VirtualBox GUI.
  • X - if you are comfortable with configuring the X Windowing System and your host's X server and SSH daemon, X will work, over ssh the command, and run on all supported hosts.

RDP

RDP was primarily a Windows feature, but its server and viewer will run on all supported OSs.

Install the Viewer for Your Host OS

Windows

RDP comes installed with all modern versions of Windows.

OSx

For OSx, download and install "Microsoft Remote Desktop" from the Mac App Store.

Linux

Although there a quite a few RDP clients supported on Linux systems, vagrant supports either xfreerdp or rdesktop to access RDP from the vagrant command. Both require X client support to be installed, also.

Install the RDP Server On the gmat2020a_box

From a Vagrant ssh console issue:

 /vagrant/add_rdpserver.sh

Connect To the gmat2020a_box Via RDP

From the gmat2020a_box directory on your host machine, issue:

vagrant rdp

Logging Into gmat2020a_box Via RDP

After connecting to the gmat_build box you will see the following login page:

The vagrant user password is vagrant. The Ubuntu desktop will appear, running the Initial Setup Application.

Quit the Initial Setup Application by clicking on "Initial Setup" in the upper left of the screen and selecting Quit.

The GMAT.Desktop icon may appear on the upper left of the window as shown or may just say GMAT. In either case, double click on the icon. Depending on the Ubuntu Gnome level, the following dialog box may appear next:

Click on the "Trust and Launch" button. The icon will transform as shown, below, and the GMAT GUI will launch. The dialog box will only appear once.

VNC

VNC is an older communication protocol for viewing desktops. Several VNC viewers are available on all supported OSs. Like git, install one you are familiar with or like.

Install the VNC Server On the gmat2020a_box

From a Vagrant ssh console issue:

 /vagrant/add_vncserver.sh

Connect To the gmat2020a_box Via a VNC Client

Enter "localhost:5901" to specify the gmat2020a_box IP address and port in your VNC client. The vagrant user password is vagrant.

Logging Into gmat2020a_box Via VNC

After connecting to the gmat_build box you will see the following Desktop:

Select "Use default config".

The GMAT icon will appear on the Desktop. Double click on it to launch GMAT.

VirtualBox Provided Console

Your gmat2020a_box console is also available on all supported OSs via the VirtualBox GUI by performing the following steps.

Modify the Vagrantfile

Add the following statements after the Vagrantfile vb.name statement:

vb.gui = true
vb.customize modifyvm, :id, --vram [desired vramsize in MB]

A vramsize of 128 is a good number.

As always after modifying and saving the Vagrantfile, issue:

 vagrant validate

from the gmat2020a_box directory on your host system to make sure your Vagrantfile is correct.

Use VBoxManage to Modify gmat2020a_box Display Settings

From your host machine, issue:

vagrant up
VBoxManage setextradata gmat2020a_box CustomVideoMode1 1920x1080x32

Use the VirtualBox GUI to Modify Display Settings

Finally, modify the VirtualBox GUI to change the display settings to increase the scale factor.

Bring up the Virtual Box GUI by double clicking on the VirtualBox icon. The Virtual Box GUI will appear. Select your GMAT2020a_box virtual machine. Then select Settings from the top panel and then Display from the dialog box. The following window will appear.

Set the Scale Factor to 200% and click OK.

Logging Into gmat2020a_box Via the VirtualBox Console

From your host machine, issue:

vagrant halt  
vagrant up

Then log into gmat2020a_box using the VirtualBox provided GUI. The following desktop will appear:

The GMAT.Desktop icon may appear on the upper left of the window as shown or may just say GMAT. In either case, double click on the icon. Depending on the Ubuntu Gnome level, the following dialog box may appear next:

Click on the "Trust and Launch" button. The icon will transform as shown, below, and the GMAT GUI will launch.

Using X To Open the GMAT GUI

Install an X Server On Your Host

Windows 10 Hosts

Follow the instructions on the CygwinX Installation Page to install and start CygwinX.

OSx

Go to the XQuartz install page to install XQuartz).

Linux

Use your distribution's package manager to install xorg, xfce4 and xfce4-goodies.

Invoking GMAT

From the host's terminal/console app, issue:

vagrant up
vagrant ssh

From the vagrant ssh session issue:

./gmat/GMAT-R2020a-Linux-x64/bin/GMAT

The GMAT GUI application should start and display on your host.