wiki:Internal/newTraceGenExtension

Version 3 (modified by jkol, 7 years ago) ( diff )

METIS II 5G Visualization - Trace Extension

TODO Brief intro…

Adding the Trace Extension code to METIS II 5G Visualization source

The following documentation gives an overview of the changes that have to be made to the original METIS II simulator for it to have the ability to generate pairwise attenuation traces for selected objects in the simulator.

  1. Adding an empty object to the scene:
    1. Under the Hierarchy tab, select the ‘Stage’ object, right click on it and choose ‘Create Empty’.
    2. Rename it to Tracker and under the Inspector tab of Unity, click Add Component button.
    3. Select Scripts and add the TrackObject_Test.cs file
    4. Alternatively, add a new script and paste the code from Track Object_Test.cs after renaming the class Track Object_Test to whatever name was given to the script.
  1. Adding tags to GameObjects:
    1. Under the project tab, search for the object Antenna5G_01
    2. In the inspector tab, click on the Tag dropdown and choose ‘Add Tag..’.
    3. In the Tags and Layers window, inside the Inspector tab, click on ‘+’ and add the tag “Antenna”.
    4. Now, select Antenna5G_01 from the Project tab and the tag ‘Antenna’ should be available. Click on Antenna to add that tag to the GameObject.
    5. Repeat the same steps for the following objects
      1. Person, StaticPerson – Pedestrian
      2. MadridGrid, MadridGridRectangle8, MadridGridRectangle10, MadridGridSquare – Building
      3. Sensor – Sensor
      4. lamp-single-ap-002 – Lightpole
      5. CarSedan01 – Car
      6. Bus – Bus
  1. Adding Collider to GameObjects:
    1. For getting a list of the objects the ray hits between the source and the destination object, it is necessary to add Box Colliders to each of the objects that the ray might pass through.
    2. For the models MadridGrid, MadridGridRectangle8, MadridGridRectangle10, Person, StaticPerson and Sensor, add Box Collider components
    3. For adding it, select the model from the Project tab and in the Inspector tab, select AddComponent → Physics → Box Collider.
  1. Generating a build:
    1. Once all of the above has been done, generate a build by selecting File → Build Settings
    2. Choose the Target Platform, Architecture and hit Build.
    3. Make sure that the config file “config.xml” is located in the running directory. In its absence, the simulator runs normally.

XML Configuration File

Sample XML configuration: config.xml

Below is a brief overview of the different sections of the XML config file and how they function.

<?xml version="1.0" encoding="utf-8"?>
<config>
<links>
    <link name="1" default_attn="9999" max_obj="9" />
    <link name="2" default_attn="9999" max_obj="5" />
</links>

The links section defines how many independent sets of connections objects in the simulator may have (eg. multi-homing). It can be thought of in terms of Sandbox 4 as the number of available attenuator matrices. Each matrix (ie. each link set) is independent of the other. The default attenuation per matrix (link set) is defined in this section and used in cases where maximum attenuation is calculated between a pair of objects or an object pair is not defined. The maximum number of objects per matrix (link set) is also defined here for proper generation of the trace file.

Attachments (2)

Download all attachments as: .zip

Note: See TracWiki for help on using the wiki.