TDS - Shock Tunnel Data Server and Browser
P. A. Jacobs
Report 2002/08
Department of Mechanical Engineering
The University of Queensland
Brisbane Qld 4072
Contents
The shock tunnel data server and browser consist of a collection
of programs and scripts that read and display the data collected by
the MONC program.
The programs include:
- defrock: a Pascal program that
reads the binary data files generated by a recent version of MONC
and writes an equivalent set of text files.
- td_server.tcl: the data server
script that reads the text-based data files and delivers the data
to stdout.
A query string is supplied to td_server to indicate which particular
data are to be sent.
See the source code for more details on specifying this string.
The output may be caught by either a web server that invoked
td_server as a CGI script or by one of the client scripts that invoked
td_server via the command line.
When accessed via http, basic authorization
(using a username and password)
is checked by the web server.
This is set up with a .htaccess file.
- td_web_client.tcl:
a client script that can be called to request data
from the td_server script via a web server.
The script accepts the shot specification via command-line arguments,
formulates a query string which it sends to td_server and,
upon receiving the text data as the CGI response,
saves the data in a local temporary file.
This local file may then be read by any suitable program
(e.g. MATLAB, Octave or GNUPlot).
- get_data.m:
a sample Octave function that can
be used to get the shot data via the td_web_client script.
- td_browser.tcl:
a self-contained browser
that can read local data files or request the data from a web server.
The data is displayed graphically and may be filtered, plotted to a
postscript file, or selectively
written to another local file for further processing.
If you want to access data via the web, you'll need to arrange for
a username and password on the serving computer.
- td_scan.tcl:
a script for the maintenance of the ASCII data files.
This script automates the application of the defrock program to
a set of shots.
The essential documentation is in the usage message
that is printed when the script is run with no arguments.
- td_archive.tcl:
this script automates the process
of making tar files, one for each shot.
The essential documentation is in the usage message that is printed when
the script is run with no arguments.
More detailed documentation is written into the source code.
Go ahead and take a look, it's not that scary.
All of the Tcl scripts require the Tcl interpreter, as expected.
Although most Linux systems will include Tcl,
Windows users will most likely have to install Tcl themselves.
A suitable Tcl distribution is the one from
ActiveState.
This distribution of Tcl includes the CGI library needed for sending data
across the web.
Note that the td_browser script needs the BLT extension for Tcl.
This can also be found at the the ActiveState site.
Most users will be interested only in the td_browser program.
For MS-Windows, just make a shortcut to the script and adapt the
initialization file td_browser.ini
to suit the local conditions.
PJ, 10-Jan-2002, updated 26-May-02.