You are on page 1of 32

3D Network Visualizer

3D Network Visualizer
3D Network Visualizer (3DNV) functionality lets you create three-dimensional
animations based on topology information, node relationships, performance
statistics, and terrain data. You can, for example, use 3DNV to visualize network
characteristics such as node placement, line-of-sight restrictions, transmission
quality, throughput, delay, and message status information.

This tutorial provides a quick introduction to 3DNV. It shows how you can use
3DNV to do the following tasks:

Prepare a model for 3D animation.

View 3D animation of a network model in the OPNET Modeler workspace


(planning mode).

View 3D animation of a simulation in progress (simulation mode).

Save and replay a 3D animation.

Before You Begin


To do this tutorial, you must have the following licenses available:

OPNET Modeler

3D Network Visualizer GUI

Terrain Modeling Module

Wireless

Discrete Event Simulation

Note that, because OpenFlight terrain is not supported on Linux, you can do this
tutorial only on Windows platforms.

You should have the following software and hardware installed on your
computer:

OPNET Modeler 16.0 PL4 or later

3D Network Visualizer 3.0.0

3DNV Communications 3.0.0 (must be installed on every computer running


either OPNET Modeler or 3DNV)

128-bit video card with at least 256MB of video memory and support for
OpenGL 2.1 or later

TUT-9-1 OPNET Modeler/Release 16.1


3D Network Visualizer

This tutorial assumes you have a basic knowledge of how to use


OPNET Modeler to configure nodes and run simulations.

NoteIf you have problems with any of the 3DNV programs during this tutorial,
see Troubleshooting at the end of this tutorial.

Configuring OPNET Modeler


Before beginning this tutorial, you must configure OPNET Modeler by setting
three preference values.

Procedure 9-1 Configuring OPNET Modeler

1 Start OPNET Modeler.

2 Choose Edit > Preferences

The Preferences dialog box opens.

3 The 3DNV tutorial network uses custom icons. Set the Icon Databases preference
to specify their location, as follows:

3.1 Type Icon Databases in the Search box.

Figure 9-1 Preferences Dialog Box with Search Box Entry

3.2 Press <Enter> or click the Find button.

Figure 9-2 Preferences Dialog Box with Preference Located

3.3 Click in the Value cell of the Icon Databases preference.

The Icon Databases dialog box opens.

3.4 Select the <empty> row.

3.5 Click the Insert button, type wireless_corps, and press <Enter> to accept
the value.

OPNET Modeler/Release 16.1 TUT-9-2


3D Network Visualizer

3.6 Click OK to accept the changes and to close the Icon Databases dialog box.

4 The 3DNV tutorial uses custom node models. Set OPNET Modeler to recompile
models by removing any references to existing model repositories:

4.1 Type Network Sim in the Search box and press <Enter>.

4.2 If the Network Simulation Repositories preference value is not (), click in
the Value cell, delete all repository names, and close the
Network Simulation Repositories dialog box.

5 The 3DNV tutorial uses the same terrain database in OPNET Modeler and
3D Network Visualizer. To ensure that 3D positions are in synch between the two
programs, OPNET Modeler needs to use an ellipsoid representation of Earth
similar to the one used in 3D Network Visualizer. This replaces the default
spherical model (which is faster to compute):

5.1 Type Earth in the Search box and press <Enter>.

5.2 If the Earth Geocentric Model preference value is not ellipsoid, click in the
Value cell and choose ellipsoid.

6 Click OK to close the Preferences dialog box.

A dialog box appears indicating that the Earth Geocentric Model and
Icon Databases preferences require the tool to be restarted for the changes to
be taken into account. Click OK to dismiss this dialog box.

7 Quit and restart OPNET Modeler to make the icons available and to use the
ellipsoid earth model.

End of Procedure 9-1

Using Multiple Computers


The 3DNV module can be installed on the computer running OPNET Modeler
or on a different computer. A different computer (as shown in the following
figure) is recommended for best performance.

Figure 9-3 Running OPNET Modeler and 3DNV on Separate Computers

3D Network OPNET GUI


Visualizer or simulation

3DNV
Communications

If OPNET Modeler and 3DNV are installed on different computers, you must
configure the installation in two ways. (If they are on the same computer, skip
these steps and go to the Introduction.) First, edit the rid.mtl file on both
computers.

TUT-9-3 OPNET Modeler/Release 16.1


3D Network Visualizer

Procedure 9-2 Configuring for Multiple Computers

1 Use the installation CD to install 3DNV_RTI_3.0.0 (the 3DNV Communications


program) on the computer running OPNET Modeler.
NoteThe RTI was installed on the 3DNV computer as part of the 3DNV
installation.

2 On the OPNET Modeler computer, use a text editor to open the file
<install_dir>\3DNV\3.0.0\configs\rid.mtl, where <install_dir> is the path to the
software (for example, C:\Program Files\OPNET).

3 Confirm that the file contains the following line:

(setqb RTI_tcpForwarderAddr "<ip_addr>")

where <ip_addr> is the IP address of the other computer (on which the 3DNV
Communications program will be run).

4 If necessary, add or edit the line and save the file.

5 Repeat steps 24 on the 3DNV computer, verifying that the line exists and has the
IP address of the 3DNV computer.

End of Procedure 9-2

When this tutorial asks you to run 3DNV programs (for example, 3DNV
Communications and 3D Network Visualizer), run them on one computer and
OPNET Modeler on the other.

Introduction
The 3DNV_Tutorial network consists of 20 mobile MANET nodes located in the
vicinity of Monterey, California. These nodes are clustered in four groups
representing tanks, troop carriers, airplanes, and helicopters.

OPNET Modeler/Release 16.1 TUT-9-4


3D Network Visualizer

Figure 9-4 3DNV_Tutorial Network

F-16 Falcon airplanes

M1A2 Abrams tanks

M-113 armored personnel carriers

UH-60A Black Hawk helicopters

During the course of a simulation, each group of nodes follows a trajectory


across the terrain, converging on a point near the center of the map. As they
move, the nodes communicate with each otherinitially with other nodes of the
same group and then with other groups as they get closer.

3D Animation Architecture
OPNET Modeler and 3DNV work together as members of an HLA federation.
HLA (High-Level Architecture) is a protocol that allows two or more programs to
exchange data and run in time-step together.

Figure 9-5 Sample 3D Animation Federation

Data RTI Data


Generator Receiver

TUT-9-5 OPNET Modeler/Release 16.1


3D Network Visualizer

There are three parts to the federation used to display 3D animation.

Table 9-1 Parts of a 3D Animation Federation


Part Purpose Program

Data generator Produce animation data OPNET Modeler GUI, simulation


process, or Multi-Federate
Logger for 3DNV

Run-time infrastructure Moderate communications 3DNV Communications


(RTI) within the federation

One or more data Display or record the 3D Network Visualizer or


receivers animation data Multi-Federate Logger for 3DNV

3DNV and OPNET Modeler work together as members of an HLA federation.

Preparing a Model for 3D Animation


Before you can view 3D animation of a network model, you must configure the
model to work with 3DNV. There are two basic requirements:

The network model must have a terrain database specified.

The nodes to be animated must be mapped to specific shapes (called entities


in 3DNV) using a 3DNV mapping library.
(In this tutorial, we use the default mapping library, which relies on the 3DNV
Mapping attribute definition discussed later.)

Typically, you will also assign trajectories to mobile nodes, so that their
movement can be visualized. This is not a requirement for using 3DNV,
however.

Animation with 3DNV requires a network model with a terrain database and
nodes mapped to 3DNV entities.

Youll begin this tutorial by modifying a sample network model to specify a


terrain database, add the necessary attribute, and map the nodes to the
appropriate 3DNV entities.

Procedure 9-3 Specifying a Terrain Database

1 Start OPNET Modeler, if it is not already running.

2 Choose File > Open

OPNET Modeler/Release 16.1 TUT-9-6


3D Network Visualizer

3 In the file browser, go to the


<install_dir>\16.1.A\models\std\tutorial_req\module\3dnv directory, where
<install_dir> is the path to the software (for example, C:\Program Files\OPNET).
Then open the 3dnv_tutorial project.

The 3dnv_tutorial network (baseline scenario) opens in the Project Editor.

4 Choose File > Save As and save the project in your default model directory as
<your_initials>_3dnv_tutorial.

The network model uses an elevation map of the Monterey region. A matching
terrain database must be specified. You will specify a terrain database in
OpenFlight format, which is the preferred type for 3DNV.

5 Choose Topology > Terrain > Specify Terrain Data Directory

The Terrain Data Directory Preferences dialog box opens.

6 In the Format pull-down menu, select OpenFlight.

7 Click the Browse button and use the file browser to choose the file
<install_dir>\16.1.A\models\std\tutorial_req\module\3dnv\N36_45_0W121_30
_0.flt.

8 Click OK to close the dialog box.

End of Procedure 9-3

To display sites (nodes and subnets) properly in 3D Network Visualizer,


OPNET Modeler must know how to map each one to a 3D entity model that
3D Network Visualizer can display. This is done by assigning a value to the
3DNV Mapping attribute on each site to be animated. 3DNV is shipped with a
default mapping library that uses the value of this attribute to determine how to
map node and subnet instances to 3D entities.

In most cases, you will need to add the 3DNV Mapping attribute to each site to
be displayed. A public attribute definition named 3DNV_Mapping comes with
OPNET Modeler. You can use this definition to add the 3DNV Mapping attribute
to most node models and to node and subnet instances.

TUT-9-7 OPNET Modeler/Release 16.1


3D Network Visualizer

You will now add a 3DNV Mapping extended attribute to each of the mobile
nodes in the model. You could do this by modifying the underlying node model,
but this requires OPNET Modeler and the ability to freely change node models
that might be shared by many users. Also, although a single node model is used
in this tutorial, it is much simpler to add an extended attribute to a set of nodes
without having to modify all of their models.

Procedure 9-4 Adding and Configuring the 3DNV Mapping Extended Attribute on
Each Mobile Node

1 Choose 3DNV > Manage 3DNV Entities

The Manage 3DNV Entities and Associated Visualizations dialog box opens.

Figure 9-6 Manage 3DNV Entities and Associated Visualizations Dialog Box

Each node has a corresponding row in the table to the right. Because none of the
nodes have a 3DNV Mapping attribute yet, no values are shown in the table.

2 Select the five F16 nodes in the tree.

3 Under the Set 3DNV Mapping Attribute tab, choose Air - Plane - F-16 Falcon from
the Type pull-down menu.

4 Click the Apply to Selected Nodes button.

A 3DNV Mapping extended attribute is added to each of the selected nodes, with
values based on the selected fields on the Set 3DNV Mapping Attribute page.

OPNET Modeler/Release 16.1 TUT-9-8


3D Network Visualizer

Figure 9-7 Planes with 3DNV Mapping Attribute Added

The F16 nodes will now look like F-16s in the 3DNV animation.

5 Repeat steps 24 to set the mapping of the remaining nodes, as follows:

M113 nodes set Type to Land - Vehicle - M113 Armored Personnel Carrier

M1A2 nodes set Type to Land - Vehicle - M1A2 Abrams

UH60A nodes set Type to Air - Helicopter - UH-60A Black Hawk

6 Click OK to commit the changes to the modified nodes.

The network model is now configured for use with 3D Network Visualizer. Save it
and continue with the tutorial.

7 Choose File > Save.

End of Procedure 9-4

Viewing 3D Animation in Planning Mode


When you have a network model that is configured for 3D animation, you can
use 3DNV to examine the placement of nodes in the surrounding terrain and to
visualize movement along trajectories. The mode in which you view animations
of the GUI workspace is called planning mode.

Planning mode lets you visualize node placement and movement from the
workspace, without running a simulation.

Viewing Node Placement


First, open project and scenario that has been configured for 3D animation.
Then start the 3D animation software, select a terrain database for the
animation background, and start communications between OPNET Modeler
and 3D Network Visualizer.

TUT-9-9 OPNET Modeler/Release 16.1


3D Network Visualizer

Procedure 9-5 Opening the Project and Starting the 3D Animation Software

1 If necessary, open the project <your_initials>_3dnv_tutorial. Make sure the


current scenario is baseline.

2 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 3.0.0 >
3DNV Communications 3.0.0.

3DNV Communications is the RTI that controls the transfer of data from
OPNET Modeler to 3DNV. It starts with no window. Instead, you should see an
icon in the Windows Tray. You can right-click on that icon to view information
about the HLA Federation.

Figure 9-8 RTI Icon

Figure 9-9 Pop-Up Menu for RTI Icon

3 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 3.0.0 >
OPNET 3D Network Visualizer 3.0.0.

After a short delay, the 3D Network Visualizer window opens. At first, no terrain
or objects are displayed, as shown in Figure 9-10.

OPNET Modeler/Release 16.1 TUT-9-10


3D Network Visualizer

Figure 9-10 Initial 3D Network Visualizer Window

4 From the 3D Network Visualizer menu bar, choose File > Open > Terrain

A file browser opens with a list of available terrain configuration (.mtf) files.
These files specify various types of information needed by
3D Network Visualizer, including a reference to an OpenFlight terrain database.

5 Select Monterey.mtf and click Open.

This configuration file references the same terrain database specified earlier in
OPNET Modeler. 3D Network Visualizer displays the terrain.

TUT-9-11 OPNET Modeler/Release 16.1


3D Network Visualizer

Figure 9-11 3D Network Visualizer Window with Terrain Loaded

6 In OPNET Modeler, choose 3DNV > Display 3D Network View.

A checkmark appears in front of the Display 3D Network View menu item,


showing that it is enabled. OPNET Modeler establishes communications with
3D Network Visualizer.

End of Procedure 9-5

Now you can select the node you want to watch in the animation. For this
tutorial, well follow one of the Black Hawk helicopters.

Procedure 9-6 Selecting the Node to Watch for the Animation

1 In 3D Network Visualizer, look at the Objects List Panel on the left-hand side of
the window.

You will see a treeview listing all of the nodes in the connected model.

OPNET Modeler/Release 16.1 TUT-9-12


3D Network Visualizer

Figure 9-12 Objects List Panel

Objects
List Panel

Black
Hawks

2 Right-click on the first Black Hawk object (UH60A_1) in the Objects List Panel and
choose Attach Tether in the pop-up menu.

The view mode is now tethered to the UH60A_1 object and will follow that object
if it moves. The entity name and view mode are listed in the Attachment Panel.

End of Procedure 9-6

You can now see UH60A_1 in the 3D Network Visualizer window. It looks like a
helicopter, as specified by the DIS Entity Type attribute of the 3DNV Mapping
compound attribute (Air - Helicopter - UH-60A Black Hawk).

TUT-9-13 OPNET Modeler/Release 16.1


3D Network Visualizer

Figure 9-13 UH60A_1 in 3D Network Visualizer Window

You should see a large blue circle in the center of the Black Hawk model, as well
as several others on the horizon. Each circle represents the location of an entity
and can be used to view information and perform right-click operations as in the
Objects List Panel.

If you move the cursor over the helicopters blue circle, you will see information
about the entity.

Figure 9-14 UH60A_1 Entity Information

You can rotate the view around the associated tethered entity with the arrow
keys. For example, press the left-arrow key a few times to rotate the view to the
right and youll see two of the other Black Hawks.

OPNET Modeler/Release 16.1 TUT-9-14


3D Network Visualizer

Figure 9-15 Rotated View

Press the space bar to reset the viewpoint to its default position (in the case of
Tether, this is behind the entity, looking ahead).

You can use planning mode to help place nodes at desired points in the terrain.
As you move a node in the OPNET Modeler workspace, the animation view
changes correspondingly.

Procedure 9-7 Placing a Node

1 In OPNET Modeler, zoom in on the Black Hawk group and some of the surrounding
terrain.

TUT-9-15 OPNET Modeler/Release 16.1


3D Network Visualizer

2 Find UH60A_1 and drag it to a new location in the workspace.

The node moves in the 3D Network Visualizer window and the surrounding
landscape changes accordingly.

3 Drag UH60A_4 to a position close to directly above the UH60A_1 icon.

You will see several blue circles near UH60A_4. These represent the positions
of other nodes in the model. You can move the cursor near or over a circle to
display information about that object.

End of Procedure 9-7

Viewing Node Movement


Planning mode is also useful for visualizing the trajectories of mobile nodes.
3DNV lets you see the relative positions of multiple nodes as they move.

To see this, you must first add trajectories to the mobile nodes by editing their
Trajectory attributes. To save time here, you will use a scenario pre-configured
with four different trajectories.

OPNET Modeler/Release 16.1 TUT-9-16


3D Network Visualizer

Procedure 9-8 Adding Trajectories to the Mobile Nodes

1 In OPNET Modeler, choose 3DNV > Display 3D Network View.

This toggles 3D display off. The current scenario is disconnected from 3DNV
and all node objects disappear from the 3D Network Visualizer window.

2 Choose Scenarios > Switch To Scenario > configured.

A scenario that has been pre-configured with mobile node trajectories opens.

3 Connect the new scenario to 3DNV: choose 3DNV > Display 3D Network View.

OPNET Modeler reconnects to 3DNV.

4 In the 3D Network Visualizer window, right-click UH60A_4 in the Objects List


Panel and select Tether.

End of Procedure 9-8

To move the nodes automatically, you must use the OPNET Modeler time
controller. This will step through a specified time range, updating the position of
each mobile node at each time step.

Procedure 9-9 Defining Movement to a Mobile Node

1 In OPNET Modeler, choose View > Show Time Controller (or press Ctrl+Alt+T).

The time controller appears.

Figure 9-16 Time Controller Dialog Box

In your networks, you will need to set the time range and step size to useful values.
In this tutorial, however, the start and stop times have been preset to match the
duration of the mobile node trajectories. The time step needs some adjustment,
however.

2 Set the time controller for a smaller time step, to produce smoother-looking
animation:

2.1 In the time controller, click the Configure button.

The Time Controller Settings dialog box appears.

TUT-9-17 OPNET Modeler/Release 16.1


3D Network Visualizer

Figure 9-17 Time Controller Settings Dialog Box

2.2 Change the time step value to 5 seconds (0h0m5.000s).

2.3 Notice that the Loop checkbox is selected. This will cause the time controller
to loop repeatedly through the specified time range.

2.4 Click OK to close the Time Controller Settings dialog box.

3 In the time controller, click the Play ( ) button.

The time controller steps through its time range. At each time step, node
positions are updated in the OPNET Modeler workspace and
3D Network Visualizer shows the node movement between positions.

4 In the time controller, click the Pause ( ) button to stop the animation.

End of Procedure 9-9

Moving the Observer


3DNV uses the concept of an observer to represent the position from which you
view an animation. Using various keyboard controls, you can move the observer
in three-dimensional space and change the direction in which the observer
looks. Table 9-2 lists a few common controls; for a complete set, refer to the
3D Network Visualizer Quick Reference Card.

Table 9-2 Common Observer Movement Keys


Movement Function Key

Move forward w

Move back s

Move right d

Move left a

Move up q, Ctrl + q

Move down e, Ctrl + e

OPNET Modeler/Release 16.1 TUT-9-18


3D Network Visualizer

3DNV lets you view an animation from any location in or around the network
terrain. To get a different view of the node movement, change the animation
window to look down on the terrain.

Procedure 9-10 Viewing the Animation from Overhead

1 Press the up arrow key repeatedly until you are looking straight down at the
helicopter.

TUT-9-19 OPNET Modeler/Release 16.1


3D Network Visualizer

2 Using the mouse wheel or the s key, zoom out until you can see all five
helicopters.

3 In the OPNET Modeler time controller, click the Play ( ) button.

The time controller resumes stepping through its time range and you can see all
five helicopters moving over the terrain.

4 Let the animation run for a while, then click the Pause ( ) button to stop the
animation.

End of Procedure 9-10

This overhead view will be useful later. 3D Network Visualizer lets you both
capture a view for reuse during the current run and also save sets of captured
views for use in later runs. A captured view includes the attached object, view
mode, observer location, and look direction.

Procedure 9-11 Capturing and Saving the Overhead View

1 In the Observer Views Panel of the 3D Network Visualizer window, click the Add
Current Observer View icon.

OPNET Modeler/Release 16.1 TUT-9-20


3D Network Visualizer

The view is captured and a default name appears in the list.

2 Double-click on the name of the captured view, type Overhead, and press
<Enter>.

The view is renamed.

3 In the Observer Views Panel, click on the Export All Views icon.

A Save As dialog box opens.

4 Type <your_initials>_views and click Save.

End of Procedure 9-11

There are many other ways to view an animation. If you want, try moving the
observer and look direction for different views of the animation. You can also try
some shortcuts. For example:

Shift + left-click on a node makes that node the attached entity. (Press Space
to reset the attach position and orientation for a default view of the entity.)

Shift + left-click on the terrain teleports to that location. This changes the view
to a close-up of that location.
NoteThe functions of the navigation controls change in different view
modes. If you lose the attached node, press Space to return to the default
view for the current mode.

One interesting view is to attach to an object and press the left and right arrow
keys to orbit around the object.

This ends our look at using 3DNV in planning mode. Perform the following
procedure to disconnect the scenario and quit 3DNV.

Procedure 9-12 Disconnecting the Scenario and Quitting 3DNV

1 In the time controller, click the Close button.

The time controller closes and all nodes return to their starting positions.

TUT-9-21 OPNET Modeler/Release 16.1


3D Network Visualizer

2 In OPNET Modeler, choose 3DNV > Display 3D Network View to disconnect the
scenario.

3 From the 3D Network Visualizer menu bar, choose File > Exit and click Yes in the
confirmation dialog box.

4 Right-click on 3DNV Communications 3.0.0 in the Windows task bar and select
Shut Down All.

End of Procedure 9-12

Viewing 3D Animation in Simulation Mode


In addition to viewing node movement and terrain in 3DNV, you can visualize
simulation results while a simulation is running. This is called simulation mode.
In simulation mode, you can view the following types of simulation data in 3DNV:

Packet transmission and reception statistics

Membership of nodes in specific receiver groups

Successful and failed transmissions

You can use the APIs in the 3D Network Visualizer Package to create custom
visualizations of other types of simulation data as well, such as:

The effect of terrain on wireless communications

Individual packet transmissions

Antenna transmission and reception areas for mobile nodes

Directional networking antenna patterns

Interference levels for individual frequencies

Simulation mode lets you view a 3D animation showing data generated by a


simulation as the simulation runs.

To use simulation mode, you must first configure the network model for 3D
animation, as you did in the first part of this tutorial.

Procedure 9-13 Opening the Project

1 If necessary, start OPNET Modeler and open the project


<initials>_3dnv_tutorial. Make sure the current scenario is configured.

End of Procedure 9-13

OPNET Modeler/Release 16.1 TUT-9-22


3D Network Visualizer

Next, specify the kinds of simulation data to visualize. OPNET Modeler provides
several utility objects that are pre-configured for certain kinds of simulation data.
The utility objects you will use in this tutorial are:

ovis_anim_comm_linesgenerates 3DNV animation visualization of


successful and failed packet transmissions by drawing a line between the
transmitting and receiving nodes

ovis_anim_pkstatgenerates 3DNV animation visualization of the packet


transmission and reception statistics for each node containing transmitters
and receivers

ovis_anim_sim_time_displaygenerates 3DNV animation visualization of


the simulation time

OPNET Modeler users can develop their own utility objects using the 3DNV
API, a extensive collection of functions that support custom 3D animation. You
can double-click on these utility objects to drill down to the process model and
examine the code used to generate the animation (primarily in the enter execs
and header block).

OPNET Modeler provides utility objects pre-configured to animate specific kinds


of simulation data. Developers can modify these or create their own.

Add some animation utility objects to the network model.

Procedure 9-14 Adding Animation Utility Objects to the Network Model

1 Click on the Open Object Palette tool button.

The object palette opens.

2 Scroll the palette tree till you see the 3DNV_Animations tree node, then expand
that node to display the content of the palette.

A selection of 3DNV utility objects appear in a Node Models tree sub-node.

TUT-9-23 OPNET Modeler/Release 16.1


3D Network Visualizer

Figure 9-18 3DNV_Animations Object Palette

3 Drag an instance of the ovis_anim_comm_lines object into the workspace near


the rx_groups object (the exact location is not important).

4 Right-click on the ovis_anim_comm_lines object, select Edit Attributes, and set


the following attribute values:

name > comm_lines

Transmission Line Color > green

Click OK to close the Attributes dialog box.

5 Drag an instance of the ovis_anim_pkstat object into the workspace and set its
attributes as follows:

name > pk_stats

Reception Statistic Color > white

Transmission Statistic Color > white

Click OK to close the Attributes dialog box.

6 Drag an instance of the ovis_anim_sim_time_display object into the workspace


and set its attributes as follows:

name > sim_time

Color > yellow

Click OK to close the Attributes dialog box.

7 Close the object palette.

8 Save your changes to the model.

End of Procedure 9-14

OPNET Modeler/Release 16.1 TUT-9-24


3D Network Visualizer

Next, start the 3D animation software and prepare it to receive animation data
from a simulation.

Procedure 9-15 Starting the 3D Animation Software

1 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 3.0.0 >
3DNV Communications 3.0.0.

2 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 3.0.0 >
OPNET 3D Network Visualizer 3.0.0.

3 From the 3D Network Visualizer menu bar, choose File > Open > Terrain

4 Select Monterey.mtf and click Open.

End of Procedure 9-15

Now prepare the OPNET Modeler simulation to send animation data to 3DNV.

Procedure 9-16 Preparing the Simulation to Send Animation Data to 3DNV

1 In OPNET Modeler, choose DES > Configure/Run Discrete Event Simulation


(or click the running man button).

The Configure/Run DES dialog box appears.

2 Make sure the Use OPNET Simulation Debugger (ODB) checkbox is not
selected.

3 In the treeview, select Inputs > Terrain Modeling.

The dialog box displays the Terrain Modeling tabbed page.

4 Make sure the selected Propagation model is not TIREM. If it is and you do not
have a TIREM license:

4.1 Select the Other radio button.

4.2 Choose Longley-Rice from the pull-down menu.

5 In the treeview, select Outputs > Animation > 3D.

The dialog box displays the 3D animation tabbed page.

6 Select the Use 3DNV Module checkbox.

This tells the simulation to generate 3DNV data. The other 3DNV controls
become enabled.

One of these controls is Record history in file with an appropriately-named file.

TUT-9-25 OPNET Modeler/Release 16.1


3D Network Visualizer

All 3DNV data generated by the simulation via Ovis APIs will be recorded in this
file for later playback. This is independent of actually sending live 3DNV updates
to the 3D Network Visualizer during the simulation. This allows you to replay the
3DNV visualization afterwards from the graphical environment.

7 Select the Live output via 3DNV Communication checkbox.

This tells the simulation to send generated animation data directly to the
3D Network Visualizer.

8 In the treeview, select Execution > Advanced > Kernel Preferences.

The dialog box displays the Kernel Preferences tabbed page.

9 In the Real-time execution ratio field, enter 5.

This tells the simulation to run at up to five times real-time speed. In other words,
the simulation will pace events so that the run takes about 6 minutes of clock
time (30 minutes of simulation time divided by the real-time ratio of 5).

End of Procedure 9-16

Finally, run the simulation and view the animation in 3D Network Visualizer.

NoteIf the simulation and 3D Network Visualizer are running on the same
computer, they might run quite slowly. Typically, you should either run
OPNET Modeler and 3D Network Visualizer on different computers or capture
the simulation output and replay it in 3D Network Visualizer later (as you will do
in the next part of this tutorial).

For best results, quit all programs on your computer except those needed by this
tutorial.

Procedure 9-17 Running the Simulation

1 In the Configure/Run DES dialog box, click the Run button.

The simulation starts up.

After a delay, the simulation connects to 3DNV. (The delay will be longer the first
time the simulation is run, while OPNET Modeler compiles some of the models.)

2 After the node list appears, right-click on UH60A_3 in the Objects List Panel and
select Attach Tether.

The selected object appears in the 3D Network Visualizer window. The


simulation data you specified also appears, as shown in the following figure.

OPNET Modeler/Release 16.1 TUT-9-26


3D Network Visualizer

Figure 9-19 Visualization Showing Simulation Data

Packet statistics for an object appear in associated text boxes around the entity. To
avoid an overly crowded and confusing display, these text boxes are not shown
initially. Instead, they are represented by small triangles near each entity. Moving
the cursor inside one of these triangles will display the information for that entity.
Clicking on a triangle toggles between displaying the information permanently or
only when the cursor is inside the triangle.
NoteYou might need to use the left or right arrow keys to rotate the view to
separate UH60A_3s information triangle from those of other entities.

Green lines connect transmitting and receiving nodes to show successful


communications. Red lines represent failed communications.

The simulation time appears in the lower-left corner of the window. The simulation
time is updated when a packet is transmitted or received.
NoteUpdates to the animation display occur only when animation events are
generated by the simulation; for example, when packet broadcasts force node
position updates. As a result, updates occur at irregular intervals and the animation
can appear choppy at times.

3 After watching the animation for a while, you can switch to the overhead view you
saved; this provides a better view of the communication lines:

3.1 From the Observer Views Panel, click the Import and Replace Views icon.

TUT-9-27 OPNET Modeler/Release 16.1


3D Network Visualizer

3.2 Select <your_initials>_views.osrx in the file list and click Open.

The saved view appears in the Observer Views Panel.

3.3 Click Overhead in the View List.

The animation changes to the overhead view you saved earlier, showing
UH60A_3 and near-by objects.

Figure 9-20 Visualization Showing Simulation DataOverhead View

4 When the simulation completes:

4.1 In the Simulation Sequence dialog box, click the Close button.

4.2 In OPNET Modeler, choose File > Save.

4.3 From the 3D Network Visualizer menu bar, choose File > Exit and click Yes
in the confirmation dialog box.

End of Procedure 9-17

OPNET Modeler/Release 16.1 TUT-9-28


3D Network Visualizer

Replaying 3D Animation
During the simulation all the 3DNV outputs were recorded in a 3DNV history file,
as well as sent out to the 3D Network Visualizer. The recorded history can be
played back later to show part or all of the 3D visualization.

Now you can play back the recorded animation and view it in
3D Network Visualizer.

Procedure 9-18 Replaying the 3D Animation

1 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 3.0.0 >
OPNET 3D Network Visualizer 3.0.0.

2 From the 3D Network Visualizer menu bar, choose File > Open > Terrain

3 Select Monterey.mtf and click Open.

4 In the Project Editor, choose 3DNV > Play 3DNV History

A file browser opens.

Figure 9-21 Choose 3DNV History File

5 Verify that the listed file matches the current scenario and click OK.

The 3DNV History playback dialog box appears.

Figure 9-22 3DNV History Playback Dialog Box

The treeview shows the Ovis entities and decorations that are defined after all
operations taking place during events at simulation time 0 have been applied.

TUT-9-29 OPNET Modeler/Release 16.1


3D Network Visualizer

At this point, none of the Ovis entities or decorations have been made known to
3D Network Visualizer. When this happens, any object with a checkmark will be
made known.

Unchecking items allows you to reduce the amount of traffic sent to


3D Network Visualizer and focus your attention to the items of interest. In this
tutorial, lets focus on the communications between helicopters.

6 Uncheck all of the M1A2 tanks, F-16 planes, and M-113 armored carriers.

7 Click on the Enable RTI button.

This creates appropriate Ovis entities for the five Black Hawk helicopters and
their associated entities.

8 After the node list appears, right-click on UH60A_3 in the Objects List Panel and
select Attach Tether.

9 Click the Play button.

As the time value increases, the corresponding Ovis changes for checked
objects are sent to the 3D Network Visualizer, exactly as happened in simulation
mode.

10 At some point, press the Pause button to stop the playback.

NoteAfter you stop the playback, 3D Network Visualizer will continue to display
animation until it catches up to the simulation time at which you paused the
playback.

11 Close the 3DNV history playback dialog box.

The Ovis entities and decorations disappear from the 3D Network Visualizer.

12 Close the project, 3D Network Visualizer, and 3DNV Communications.

End of Procedure 9-18

Troubleshooting
This section provides solutions to some common problems that can occur when
using 3D Network Visualizer.

If you have successfully completed this tutorial, skip to Summary.

3D Network Visualizer no longer updates its display when nodes move in OPNET Modeler
Communications between OPNET Modeler and 3D Network Visualizer time out
after a period of disuse. To reestablish communications:

1) Disconnect the current scenario from 3DNV (in OPNET Modeler, choose
3DNV > Display 3D Network View).

OPNET Modeler/Release 16.1 TUT-9-30


3D Network Visualizer

2) Quit the 3D Network Visualizer and 3DNV Communications programs.

3) Restart the 3DNV programs, as follows:


a) In Windows, choose Start > Programs >
OPNET 3D Network Visualizer 3.0.0 >
3DNV Communications 3.0.0.
b) In Windows, choose Start > Programs >
OPNET 3D Network Visualizer 3.0.0 >
OPNET 3D Network Visualizer 3.0.0.
c) From the 3D Network Visualizer menu bar, choose File > Open >
Terrain
d) Select Monterey.mtf and click Open.

4) Reconnect the OPNET Modeler scenario (choose 3DNV >


Display 3D Network View).

5) Attach an object in 3D Network Visualizer.

While moving the observer, you lose sight of the attached object and cant find it again
Press Space to reset the view.

TUT-9-31 OPNET Modeler/Release 16.1


3D Network Visualizer

Summary
This tutorial has presented a quick introduction to 3DNV. You have seen how to:

Prepare a model for 3D animation.

View 3D animation of a network model in the workspace (planning mode).

View 3D animation of a simulation in progress (simulation mode).

Save and replay a 3D animation.

For more information about using 3D animation in OPNET Modeler, see the
Animation Viewers documentation.

OPNET Modeler/Release 16.1 TUT-9-32

You might also like