Development of a Distributed, Cross-Platform Simulator

Development of a Distributed, Cross-Platform Simulator

Development of a Distributed, Cross-Platform Simulator Thomas C. Brooke Titan Corporation 5350 Tomah Dr. Colorado Springs, CO 80908 [email protected] ABSTRACT We were developing an application for direct control of a satellite ground terminal, targeted to a laptop running In developing real-time mission control software for termi- 23 nals in a large satellite communications system, my team Windows NT (see figure 1). realized that a script-based stimulus/response tool was inad- equate for developmental testing and training. As an initial Terminal Satellite Terminal proof-of-concept, we first designed a monolithic, single-user Terminal system simulator for engineering development. During the project, the requirements expanded to include the addition of a multi-user, cross-platform capability, and later distri- Terminal bution in a two-tier client/server system. Categories and Subject Descriptors TC I.6 [Simulation and Modeling]: Applications; C.2.4 [Com- puter-Communication Networks]: Distributed Systems— client/server, distributed applications; D.1.5 [Programming Figure 1: Terminal Control Application Context Techniques]: Object-Oriented Programming; D.2.13 [Soft- ware Engineering]: Reusable Software—reusable libraries; The key functional areas of the TC (Terminal Control) C.3 [Special-Purpose and Application-Based Systems]: software are Real-Time and Embedded Systems • Controlling satellite antennas General Terms • Managing communications networks Design, Performance, Experimentation, Standardization • Monitoring networks and terminals Keywords The interface between TC and the terminal is message based. TC sends a command message to the terminal, and Ada, distributed, linux, portability, satellite, simulation, test- the terminal sends one or more response messages back. The ing, training, windows terminal may spontaneously send an “unsolicited” message to TC, but it expects no message in response. 1. BACKGROUND The physical connection between TC and the terminal is a basic RS-232 serial line [4]. There is also a provision for run- Our group builds software applications for satellite com- ning TCP/IP (Transport Control Protocol / Internet Proto- munications systems. Our products are mainly ground based1 col) over this line, via PPP (Point-to-Point Protocol), and planning and execution tools. Appendix A contains a more 4 exchanging the messages through a socket. detailed description of the system involved in this project. The problem we were experiencing was that real terminals 1 are expensive, and satellite resources are scarce. So, finding As much fun as it would be, we don’t have any software flying on the satellites themselves. Yet. terminals, locating baseband equipment, and coordinating satellite time for day-to-day testing is practically impossible. What we needed was something to stand in for the rest of the system—everything above-the-line in figure 1. Since the messaging interface was so simple, our first ap- Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are proach was to use an off-the-shelf terminal emulator (like not made or distributed for profit or commercial advantage and that copies 2Windows NT is a registered trademark of Microsoft Cor- bear this notice and the full citation on the first page. To copy otherwise, to poration republish, to post on servers or to redistribute to lists, requires prior specific 3 permission and/or a fee. Yes, it’s dated. But it was the platform that the customer had already fielded. SIGAda’02, December 8–12, 2002, Houston, Texas, USA. 4 Copyright 2002 ACM 1-58113-611-0/02/0012 ...$5.00. This would come in very handy later on. 12 HyperTerminal.5 We manually constructed binary response The following sections describe the evolution of TSim and messages,6 and concatenated them into response scripts. the lessons learned during its development. But it’s impor- During testing, when TC sent a message to the “terminal,” tant to keep the lessons in context. we would manually transfer a prepared response file back. The first priority was to make things work. Towards that While this method worked, after a fashion, developing the end, we used what we knew—except where we were experi- individual messages and scripts was extraordinarily labor menting. Due to the constraints, we spent little or no effort intensive. scouring the literature (or web resources) for elegant solu- Our second approach was a more sophisticated, locally tions: we would apply the first tool/technique that looked developed tool, which featured hierarchical scripts, default workable, or we’d just figure something out on our own. responses,7 message templates, and helper functions for con- Furthermore, despite a strong Ada83 background, we had structing response messages dynamically at run-time, based only limited Ada95 experience. As a result, some of the on data in the request itself. Although the new tool re- lessons “learned” on this project are probably obvious. And duced test preparation effort by an order of magnitude, it some of them are probably wrong—or at least suboptimal. was still a difficult, time-consuming process. A basic test One thing to keep in mind that TSim is a low-fidelity sim- scenario consists of hundreds of messages (excluding default ulator. It does not need to comprehensively and accurately responses) and dozens of scripts. Devising the test suite for model the full system behavior;8 it only needs to simulate a new scenario remained very expensive. the Terminal/TC interface. We did consider more detailed The fundamental difficulty turns out to be managing ter- simulation standards, such as IEEE 1278 [6], but concluded minal and system state. First of all, messages and scripts that they were overkill for this particular application. have to accommodate the expected system state: they have to account for prior commands which may have affected net- 2. ROUND 1 works, antennas, or terminals. For example, if a command TS moves an antenna, then subsequent requests for antenna in- Initially, the im requirements were fairly simple: build TC formation have to reflect the new location. Second, response a basic stimulus/response engine which would simplify scripts must be sequenced in the expected order of execu- testing by maintaining state and automating responses to commands. tion. For example, the response tool should not be waiting 9 for an antenna information request when TC is trying to ac- It would be a monolithic, console-based application (no GUI tivate a network. Due to the complexity of the TC software, (Graphical User Interface)) which would simulate just TC determining this ordering is often a trial and error process. a single terminal—the one “connected” to . Figure 2 de- A script-based tool can be invaluable for testing error picts the general block architecture and relative source code paths and impossible conditions, because it’s very easy to sizes of the major software components. produce exactly the desired behavior. But we also needed a less labor intensive way to perform nominal path and day- TSim to-day developmental testing. EIF TC 1.1 The Project Sat Term I was fed up with generating the “same old scripts” for the “same old scenarios.” So, I decided to initiate a low-level IR&D (Internal Research and Development) project to build Messages a simple system simulator. The TSim (Terminal Simulator) would serve as a proof-of-concept, with the hope that it could be expanded into a complete testing solution. There was really only one constraint: it had to be inex- Figure 2: Round-1 Block Diagram pensive. As an internal, unfunded project, I had to keep the costs down. This meant minimizing time, effort, and Anticipating future needs, most of the effort went into the capital. EIF (External Interface) and the Messages hierarchy. The My goals for the project were: EIF provides message-level communication with TC. It sends and receives messages on the serial port (or socket), and • Make it work. TSim was to be a tool for our use, not implements the alternating bit protocol used for elementary an academic exercise. error detection. Correct behavior of the EIF is critical to the realism of TSim. The Messages hierarchy not only defines • Explore Ada95. Because it was an independent project, the actual message formats, but also the message framing there was an opportunity to experiment with new tech- and serialization (streaming). A good design here would niques in a forgiving environment. pay dividends when scaling up TSim, as adding the dozens • Employ third-party tools, packages, and components of new messages needed would be much easier. wherever possible. This was a direct result of the cost At this stage, the result was an application which looked constraint. like figure 3. The EIF implementation used sockets for Terminal/TC 5 HyperTerminal is c 1998 by Hilgraeve, Inc. communication, mainly because it was more convenient than 6 We built some crude tools to format the messages and at- hanging a loopback null-modem cable off the back of the tach the framing. 8 7Where the most common response sequence to a message Not yet, anyway. would be sent automatically, unless a specific response were 9Where “monolithic” here denotes a single executable, not pending one-big-subprogram. 13 with record Satellite Worker : Processor ; end record ; Terminal end Task_Termination ; Where the actual work is done in task type Processor, and the Agent wrapper exists solely for termination. package body Task_Termination is TC task body Processor is begin Figure 3: Round-1 Application Context loop select computer—or stringing (and re-stringing) null-modem ca- accept Stop ; bles between computers. For this, we used the AdaSockets exit ; else package developed by Samuel Tardieu [11], and adapted for −− , Win3210 by Jerry van Dijk [12]. do something useful −− . Even in this relatively simple application, we still used the like read some data Booch Components [13] for message buffering.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    10 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us