The Designing and Realizing of the Satellite Navigation Simulation System

download The Designing and Realizing of the Satellite Navigation Simulation System

of 20

Transcript of The Designing and Realizing of the Satellite Navigation Simulation System

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    1/20

    The Designing and Realizing

    of the Satellite Navigation

    Simulation System

    Visualization Software

    Tao Liu, Yushan Zhao and Shijie Xu

    School of Astronautics

    Beihang University, BUAA

    Beij ing 100191, China

    [email protected]

    mailto:[email protected]:[email protected]
  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    2/20

    Abstract

    In order to visualize the satellite navigation simulation

    system, the framework of a distributed satellite navigation

    simulation system composed of multi-platform systems was

    analyzed. The composition and the functions of the satellite

    navigation simulation system visualization software were

    illuminated. Based on MFC, presented the designing and realizing

    methods of the system information display program and the 2D

    display program. The Vega Prime program designing methods,

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    3/20

    using the Visual C++, were introduced, and also the structure, the

    designing and realizing methods of the 3D display program were

    proposed. Based on OpenGL, Vega Prime and Visual C++, using

    the designing and developing methods discussed in this paper,the satellite navigation simulation system visualization software

    was developed. Practical application of the software shows that

    the visualization scheme proposed here is entirely feasible for

    practical engineering application.

    I. INTRODUCTIONModeling and simulation plays an essential role in the designing stage of

    the aerospace engineering. An accurate and vivid simulative description of a

    system provides the design engineer the possibility to expedite the design

    process. The visualization software, based on visual reality technology, can

    show the working states and mission progress of an astronautic system

    intuitively to users, and help them gain the general information about the

    system quickly, and is a useful tool for the design and analysis of the

    astronautic system.

    Until now, in china, almost all the visualization software for aerospace

    engineering are developed for one given mission, without flexibility, as in [1-

    3]. And the spacecraft simulation software developed by foreign commercial

    companies, e.g. Satellite Tool Kit (STK), comprehensive but not accurate

    enough for some special tasks. Take the satellite navigation system serving

    for ground users for example; the visual effect of STK is not good enough.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    4/20

    Under the background, the satellite navigation simulation system visualization

    software was developed, which has three kinds of functions, namely system

    information display, 2D display and 3D, could visualize realistically all of the

    working states of the satellite navigation simulation system and the whole

    procedures it serves for users. The software has sufficient flexibility and could

    be used for other aerospace visualization mission after little change.

    This paper discussed the structure of the satellite navigation simulation

    system and the functions of its subsystems To satisfy the needs of the

    satellite navigation simulation system, the satellite navigation simulation

    system visualization software was designed, which is composed of three

    programs, namely the system information display program, the 2D display

    program and the 3D display program. The design of the functions, the

    developing procedures, the data structures and the realizing methods of the

    system information display program as well as the 2D display program, basedon the Graphical Device Interface (GDI) of Microsoft Foundation Class

    (MFC), were presented. Then the techniques to design Vega Prime programs

    based on the Visual C++ were introduced, and also the functions, the

    structure, the developing procedures and realizing methods of the 3D display

    program were proposed. Finally, by simulating the process of navigating

    multiple users, this satellite navigation simulation system visualization

    software supplied vivid display effect, and it validated the feasibility of the

    designing methods and techniques discussed here.

    II. THE STRUCTURE OF SATELLITENAVIGATION SIMULATION SYSTEM

    In space mission simulation, a whole satellite navigation simulatIon

    system consists of multiple subsystems: navigation satellite simulator,

    constellation simulator, telecontrol and telemetry system simulator, user

    simulator, visualization software, data server and so on, as in [4].

    Navigation satellite simulator is used to simulate all the subsystems of a

    navigation satellite in semi-physical and mathematical manners.

    Constellation simulator can complete the mathematic simulation of the

    constellation, like the signal coverage percentage of the constellation,

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    5/20

    communications between the satellites of the constellation, the analysis of the

    navigation characteristics, and so on.

    Telecontrol and telemetry system simulator is used to simulate the

    management of the data flow of the satellite navigation system, the sending

    and management of the telecontrol instructions, the processing and

    management of the telemetry data.

    User simulator is used to generate the simulation data of the tracks, the

    attitude, the running states of all kinds of users which move on the ground, or

    fly in the air, or else sail the oceans. The visualization software provides a

    method to visualize all of the working states of the satellite navigation

    simulation system and verify the whole system in a visual manner. At the

    beginning of the virtualization simulation, across the local Ethernet, the

    visualization software firstly associates its virtual reality objects with thesimulation data in the database of the data server, and then the software

    receives packets from the data server and drives the virtual reality

    objects and updates the display.

    All the subsystems above communicate and are synchronized with each

    other through data server. Simultaneously, the data server also is responsible

    for the data stream of the satellite navigation simulation system under control,

    and has to preside over parameter setting for all of the simulation

    subsystems. These subsystems compose a distributed simulation condition

    as shown in Fig. 1.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    6/20

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    7/20

    III. THE DESIGNING AND REALIZING OFTHE

    VISUALIZATION SOFTWAREAs described in the introduction, the satellite navigation simulation system

    visualization software is composed of three programs, the system information display

    program, the 2D display program and the 3D display program. The functions, the

    structures, the designing and realizing methods of those programs will be discussed in

    detail in this chapter.

    A.System Information Display Program1)function

    This program is used to display the working information of the simulation

    system, including data sources, simulation time, and configuration information

    and so on. In order to improve visual effect and the flexibility of the program, itprovides a control library, which contains text control, curve control, radar control,

    and other basic controls. Utilizing the control library, users can design the most

    appropriate visual interfaces according to their requirements.

    2) The Design of Control Classes

    In order to manage controls efficiently, the interface designing module is

    designed and embedded in the program as a dynamic-link library (DLL). Pleaserefer to [5] for more details about DLL. The module encapsulates different types

    of controls, and interface functions for modifying the control properties. The

    structure of those control classes is shown in Fig. 2.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    8/20

    In accordance with object-oriented programming methods, all the controls

    and their interface functions are derived from the base class named

    CBaseControl, which provides a basic public data set and a set of functions

    which supports such operations as adjusting the location, size and other

    visualization properties of controls, updating the controls' states, and so on. Butthose functions of CBaseControl class are virtual and are not defined yet. All

    control classes derived from CBaseControl, for example, CMeterControl class for

    meter control and CCurveControl class for curve control, must provide the

    implementations of those virtual functions according to their own characters, by

    overloading the virtual member functions of the base class. As an illustration, the

    virtual function, Show (CDC* pDC), used to redrawing controls, has been

    differently implemented in different derived control classes. Besides virtual

    functions, the control classes also contain their own unique attributes and

    operations.

    3)structureThe system information display program is designed based on MFC. The

    Device Context (DC) and GDI are used. Please refer to [5] for more details about

    MFC, DC and GDI. By Windows message-mapping machinery, the program can

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    9/20

    update and redraw various controls simultaneously via the view class in the

    program, to achieve visualization capabilities.

    During the simulation process, the program is required to not only interact

    with the user, but also receive simulation packets across the Ethernet. Therefore,

    the program uses multi-threaded architecture. The first thread, called main

    thread, is started when the program is initiated, then creates the MFC frame

    window, after that users can design and save the visual interface which is used

    for the display of the system information. The design process is as follows. First,

    create a blank display interface, add controls and modify the controls' properties,

    and then, design the layout of the visual interface. After that, establish the

    mapping of control set to data-base data set, and then the system information

    interface is ready for displaying. The other thread, started in the main thread, is

    network client thread, which is made to receive packets and transmit useful data

    to the main thread via the shared memory. The working procedures of the twothreads are shown in Fig. 3.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    10/20

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    11/20

    B) 2d display programThe 2D display program is employed to draw planar images, such as the

    world map, the ground tracks, the coverage areas and the covering characters of

    the satellites or the constellation. Moreover, the program is also able to display

    the working states, orbit parameters and attitude parameters of various

    spacecrafts.

    The designing and realizing methods of the 2D display program are simIlar

    to those of the system information display program, also using the DC as well as

    the GDI of MFC and via Windows message-mapping machinery to fimsh ItSfunctions. Fig. 4 Illustrates the basic processing flow of the 2D display program.

    This program has two threads, the display thread and the network client thread.

    As shown in Fig. 4, the relationship between the two threads likes that of the

    system information display program. The GDI plotting loop is the core of the 2D

    display thread, and it responds to the user's inputs and uses the network packets

    to carry out the main functions of the program, such as drawing ground tracks,

    coverage areas of the satellites, drawing communicatIOn lmks between the

    ground stations and the satellites; besides, it makes use of the inside calculating

    module to finish the calculation and display of the covering characters of the

    satellites or the constellation.

    To keep the properties and operations for the objects that need to be

    plotted, the C++ classes have been designed, as shown m Fig. 5. The

    CBaseObject class is the base class which defines the general properties of all

    objects, such as name, position as well as data identification and so on. The

    CMobileObject class derived from the CBaseObject is designed for the moving

    objects, and it has functions of updating the properties and plotting, but those

    functions are virtual functions. The implementations of them are provided by the

    classes derived from the CMobileObject class; for instance, the CSatellite classis used to keep properties related to satellite, and provides functions for drawing

    the orbits, the coverage areas and so on. The CGroundStation class keeps

    properties for ground stations.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    12/20

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    13/20

    c) 3d display program1)function

    This program has the following functions: the 3D display of the movements

    of satellites, users (e.g., cars, planes, ships) and so on, which are built in 3D

    models; providing multiple scenes and various viewpoints display abilities

    building on the fundament of the 3D model library; could switch among the multi

    scenes, including: the launch phase of satellite, the working phase of satellite in

    orbit, the phase of the navigation constellation working in orbit and serving the

    users. The 3D display program also provides multi-window display for a certain

    simulation stage, in order to observe the simulation process from various

    viewpoints simultaneously.

    2)structure

    The 3D display program is a Vega Prime display program based on MFC, so

    when the program starts to run, it requires thee Vega Prime to start a thread for

    scene rendering, Which is independent from the user thread, as in [2]. Except

    for the two threads mentioned above, this program still needs to begin a network

    client thread to receive the simulation data. The framework of the program is

    shown in Fig. 6.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    14/20

    The 3D display program transmits the packets and user' s controlling

    instructions to the Vega Prime thread via the user thread, and then the Vega

    Prime thread completes the rendering of the 3D objects as well as the controlling

    of the movements of those objects, using the scene rendering interface functions

    provided by Vega Prime. The scene rendering effects are shown to users via the

    3D scenes in the view window. The program based on MFC could respond to

    keyboard and mouse messages, and that is what makes it is possible for the user

    to control the display of the 3D scenes by inputting the controlling instruments

    according to the operation of simulation.

    Fig 7 gives the basic processing flow chat of the program. The program finishes

    the tasks related to the display of the Vega Prime scenes in a separate thread.

    By this way, the scene rendering and processing speed could be accelerated;

    furthermore it could alleviate the burden of scene display for the user thread, so

    the responding to user's operations speeds up. The user thread is mainly

    responsible to respond to the messages from computer systems. Because the

    network client thread and the Vega Prime thread are separated, it is necessary

    that the program provides shared memory for the two threads to share mutual

    data with each other, and moreover, the message passing machinery is used to

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    15/20

    pass the user control instructions received by the user thread to the Vega Prime

    thread.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    16/20

    3)class designOn the basis of the structure design and the process analysis, in order to

    realize all of the functions mentioned above, the 3D display program needs many

    classes. The relationships among the main classes are shown in Fig. 8. As seen

    in Fig. 8, the chasses in the dashed frame are Vega Prime classes which are

    defined and realized by the Vega Prime, and the others are user-defined.

    Among all the user-defmed classes, the CDataBase class is the base class,

    which defines the general properties of all the objects, such as the name, theposition and so on. The CObject class, the CObserver class and the CDofDbj

    class are derived from the CDataBase class, and they are used to keep the

    information about 3D objects, viewpoints, and DOF nodes, respectively. The

    CScene class defmes all of the properties needed to render 3D scenes, such as

    the name, the locations and some Vega Prime objects. The CObsMgr class,the

    CObjMgr class, the CDofMgr class and the CSceneMgr class, called controlling

    classes, could control the viewpoints, the 3D objects, the DOF nodes and the 3D

    scenes respectively, by the function call of Vega Prime API. Based on OpenGL,

    the CVpOpenGL class is developed to get some special rendering effects, like

    orbit drawing, star field simulation, the rendering of rocket flame and radar wave,for example. Please refer to [6] for more details about OpenGL. The CVpOpenGL

    class functions are called via channel callback function mechanism, so these in-

    class functions of the CVpOpenGL class must subscribe to the channel events

    first.

    The CVpApp class is derived from vpApp---the Vega Prime core class. Besides

    aggregating the controlling classes and the CVpOpenGL class mentioned above,

    the CVpApp class calls the in-class functions of these aggregated classes to

    accomplish the rendering of all of the scenes, and the detailed works include the

    configuration of the 3D scenes, adding subscribers to channel events, the control

    of the object movement, updating the frames and so on.

    The 3D model database used in the scenes is established by applying the

    three-dimensional modeling software MultiGen Creator, and the model is formed

    by multiple tiny triangles.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    17/20

    IV. SIMULATION INSTANCE AND EFFECTAccording to the designing and realizing methods discussed above, using

    Visual C++ and Windows XP as the software developing platform, based on

    Vega Prime and OpenGL, the satellite navigation simulation system visualization

    software are developed. The running result of the software is shown in Fig. 9. Fig.

    9(a), (b) and (c) are the program running screenshots of the system information

    display program, the 2D display program and the 3D display program,

    respectively.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    18/20

    V. RESULTSAim the visualization of the satellite navigation simulation system, the

    structure of a distributed satellite navigation simulation system composed of

    multi-platform subsystems was analyzed. Then associating the techniques of

    visual simulation with the techniques of satellite navigation, designed the satellite

    navigation simulation system visualization software, and discussed the

    developing technique as well as the realizing methods.

    Based on the scheme and techniques mentioned above, the satellite

    navigation simulation system visualization software has been realized, and it has

    spectacular visual effect. After simulation verification, it is proved that the

    visualization scheme of the software stated above is feasible. Nowadays, the

    software has already been employed in engineering area, and facilitates the

    design and analysis of the aerospace system. Besides, the above-mentioned

    designing and realizing methods as well as the applied techniques are useful for

    developing the similar systems.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    19/20

    (a) (b)

    (c)

    Figure 9. Visualization softwares' display effects: (a) the running effect of the system

    information display program. (b) The running effect of the 2D display program. (c) Therunning effect of the 3D display program.

  • 8/3/2019 The Designing and Realizing of the Satellite Navigation Simulation System

    20/20

    REFERENCES[I] H. Zhang, Y. Li, "Design of a Moon Exploration Probe Simulation and Visualization

    System," Chin. 1. Space Sci. vol. 28, no. 3, pp. 236- 241,2008.

    [2] J.-Y. Zhou, Y.-F. Wang, and R.-B. Luo, "Design and Realization of Missile Attack andDefense Visual Simulation System," Journal of System Simulation vol. 21, no. 18, pp.5779-5782, Sep., 2009.

    [3] F.-L. Xia, Y.-S. Zhao, "Space Mission Simulation System Based on HLA," Journal ofSystem Simulation vol. 19, no. 24, pp. 5710-5714, Dec., 2007.

    [4] E.-D. Kaplan, C.-J. Hegarty, Understanding GPS: Principles and Applications,Second Edition, Beijing: Publishing House of Electronics Industry, 2007, in Chinese.

    [5] G. Shepherd, D. Kruglinski, Programming with Microsoft Visual C++.NET, SixthEdition (Core Reference), Beijing: Tsinghua University Press, 2004, in Chinese.

    [6] R.-S. Wright, B. Lipchak, N. Haemel, OpenGL superbible: comprehensive tutorialand reference, Fourth Edition, Boston, MA:Addison Wesley, 2007.