ATHENA User's Guide

Version 5.0 (March 26, 1996)

The following is a description of the Athena data handling system available for use on the research vessels of the Woods Hole Oceanographic Institution. The intention is to provide enough information to allow ship users to utilize the capability effectively with the help of a ship technician; system operating instructions are not included.

The Athena system is a combination of hardware and software having a reasonable degree of consistency between various ship installations. It provides a variety of data handling capabilities, including polled and continuous data collection, timed and "on event" data logging, formatted local and remote data displays, and polled, continuous and "on event" data output.

Since it was originally designed to handle polled data acquisition utilizing sensors attached to a single "data loop", the software is not multi-tasking and data transaction cycles occur at one hertz or slower. Present installations utilize a variety of data input ports and techniques but the one second cycle time remains the practical limit.

The principal Athena system component is an IBM PC-compatible computer running the Athena data collection, logging, distribution and display software. A second, identical computer is provided as a backup which can be used for system performance monitoring and some amount of data display and analysis. Both of these machines are connected to a Sun SPARC Station via a PC/TCP ethernet connection. This allows the Athena software to log data to files in a subdirectory on the SPARC's hard disk so they may be accessed from anywhere on the ship served by the network. Additionally, software on the Sun can transmit to designated destinations or broadcast data added to any of the log files. The primary PC and its spare are typically 486 66MHz or faster machines with at least one large hard drive, an ethernet adapter and an intelligent (microprocessor-based) serial port expansion card. They are frequently configured to share a single keyboard and color VGA monitor, using a selector switch to shift between machines.

The Athena system computers utilize a GPS based clock to maintain an accurate GMT time base. In some cases, the computers contain real time clocks having an IRIG-B input from the ship's GPS clock. In other cases the IRIG signal maintains the Sun's clock and the Athena PCs obtain the time via a network time server.

Data collection is done primarily with a polling technique over an 9600 baud RS485 data loop which reaches most areas of the ship. Adding additional data collection instruments to this loop is reasonably easy provided they are configured for RS485 multidrop protocol. Sensors on the loop must respond to a unique polling "address" quickly - other sensors cannot be interrogated during the wait. To meet this requirement, sensors of various types are typically interfaced to the RS485 loop using a commercial interface module such as those marketed by MetraByte. Devices with RS232 outputs require special effort and are frequently handled using a WHOI-designed interface module or independently connected directly to one of the serial ports of the Athena computer.

Data is collected at regular time intervals, usually determined by the requirements of the intended utilization. As an example, if ship's heading is to be recorded in a log file every 15 seconds, the heading information will be acquired from the ship's gyro every 15 seconds, just prior to its output to the log file. If the requirement to output heading on a serial port at 10-second intervals is then added, the collection rate will be increased to 5 seconds: the largest common dominator. In this way, each output transaction is provided with recently acquired data but the heading data collection process is not duplicated when both the log file and serial output requirements coincide. There are alternates to this input timing methodology available to meet the requirements of some instruments or interface arrangements. The most common allows the input process timing for a given data item to be set to a constant interval. This is useful for sensors having lengthy data collection cycles (i.e. IMET), where little is gained by frequent data requests, and also for direct serial inputs to insure that the input buffers are read frequently enough to prevent overflow. Interrupt driven serial I/O, available for data items having a defined termination character, is another example of an alternate timing solution.

"Events" can also cause data input transactions. A small number of items have been defined as Athena system "events" and can cause most forms of data logging and output to occur, preceded by the collection of the necessary data. The collection processes are simply added to the normal, timed input processes (except for those sensors having a predefined constant input time interval).

There are two primary types of Athena data log files, both of which are simple ASCII and have identical structures. The most common is a timed file for which a data record is added at a specified time interval. The second type is an event file for which data is added only when a specified event occurs. At any time, any number of either type of file can be active. The content of both file types is easily specified and a file header provides date, time and content information. Each data item in a file is preceded by a three digit item number and the "|" symbol to facilitate automated data extraction (a single data item may include an arbitrary number of CR/LFs so counting file lines does not work). Data item numbers are permanently assigned for each ship and therefore automated data extraction, display and analysis programs can be easily written which will work with all of the Athena generated data files.

There is actually little difference between the two basic data file types. Timed files are automatically named (providing an indication of the time interval) and, optionally, a new file is established at midnight. "Events" can result in the addition of data records to timed files, including an event comment string. Event files are named by the user, do not contain timed data records and are always continuous (not re-established at midnight). Also, since time is usually critically important for events, the initial definition of an event file automatically includes Julian seconds as part of each data record (this can be eliminated if desired). Appendix I provides examples of both timed and event data files.

The Athena system has three data display capabilities: PC console, serial terminal (or equivalent) and NTSC video overlay. The format and content for the three types can be easily specified using a "display builder" feature of the Athena program and the data update rate is also easily defined. At present the system does not provide a real time data graphing capability but, instead, this functionality is obtained by providing a data output stream to other programs running on the spare PC or the Sun workstation.

The Athena system provides a versatile data distribution capability. Individual data items or lists of items can be output from the RS232 serial ports at predefined time intervals or on demand. In the case of data lists, the data item separator can be specified when the list is defined. The data distribution feature allows a program running on a computer anywhere on the ship to obtain information from the central system simply by asking for it by name. As an example, a machine collecting XBT data could incorporate the ship's position at the time of the launch into its data file by outputing the string "GPS_TP" from a serial port and accepting the Athena system response of GPS time and position. Carrying this a step further, using the XBT machine's output as a "station event", the Athena system could be configured such that when the XBT computer output a string such as "XBT Station #28", the time and position would be returned and a data record would be added to designated Athena data log files. The first line of the added record would contain "XBT Station #28" and the remaining lines would contain the data normally logged as part of these files.

Most of the Athena data handling transactions can be triggered by "events" of which there are three general types "startup", "input" and "station". "Startup" is the least useful and is provided primarily as a system analytical tool. It allows a data transactions such as a log file entry or data list output to occur whenever the Athena system is started. The Athena system self initializes; it will recover from a power failure and continue with the previously defined data handling tasks. As a result, a "startup" triggered event can be useful in unattended operations for signaling the existence of breaks in a data stream and providing an indication of the cause.

"Input" and "station" events are considerably more useful; they allow most data handling transactions to be triggered by a serial port input and, for "stations", the input text (or data) can be incorporated into multiple transactions. As examples, if a serial port is configured for input and the name of a data item is entered, the value of that item will be returned. If the name of the data item is followed by the name of an output port, the value of the item will be output from the specified port rather than the input port. The input can be the name of a list of data items and each of the items will be output with separators as specified when the list was defined. It can also be the name of a data log file in which case a record will be added, including a leading comment string if one was provided following the file name. This capability allows a computer anywhere on the ship to obtain data on demand or cause data to be provided to a second computer, display or file.

If a "station" variable name is associated with an input port, the input from that port is assigned to the variable when it is received and all transactions which involve the variable are conducted. This allows a text string input to trigger the addition of a record to a data file and the new record to include the text string. It also allows output of a data item or list with a preceding text string to any output port. Unlike the case of an "input event", both of these transactions can result from a single serial port entry (see the XBT example given above).

The principal difference between "Input" and "Station" events is that the Athena system treats an "input event" text string as a command which it attempts to act upon while a "station event" input is assigned to a variable and is available for use with other transactions. An "input event" typically results in a single transaction determined by the input string. A "station event" can trigger multiple, previously designated transactions which incorporate the input string. Due to the manner in which these two events are implemented, it is not possible for a single input port to be used for both types simultaneously.

The Athena system includes a few auxiliary data conversion and distribution programs which can be run independently to enhance its capabilities. A program is available on the SPARC station used for the Athena data files which will monitor a selected file and transmit new entries to other machines via the ship's network. This supplements the normal ability of computers on the network to view and copy the Athena data files at any time. A program is available for PCs to change the content and format of single or groups of Athena data files.

This program allows selecting data items from a menu of those contained in a data file and choosing a data item separator (i.e. tab, ";", cr/lf). It will then construct a new file having the requested format from the original file or a group of files having the same content; the original files remain unchanged. A similar PC program is provided which allows Athena data files having different content to be merged on a date and time basis. The format of the resulting file is that normally used for Athena ASCII files and therefore each data item is preceded by a unique sensor identifying number. A program is available which will convert Athena ASCII data files to NetCDF format. Since the header portion of a normal Athena data file does not contain sufficient information, the Athena system maintains an additional sensor information file containing data necessary for the NetCDF conversion. The ship's technician oversees adding or modifying entries to this secondary file and a copy must be obtained from him if a NetCDF conversion is to be attempted.

Appendix I
Typical ATHENA time interval file

R/V OCEANUS Data Log - 1 minute log file
Time interval file (ASCII)
08/10/95 00:00:04
ATHENA V5.0

003| CTIME     Computer time
012| GYROSPLG  Ship's heading & speed
024| SSCND     Sea surface conductivity (mmho/cm)
025| SSTMP     Sea surface temperature (C)
045| GPS_TP    GPS time & position
047| IMET_AIR  Air temperature (degrees C)
048| IMET_BPR  Barometric pressure (millibars)
050| IMET_HUM  Relative humidity (percent)
053| IMET_PRC  Precipitation (millimeters)
055| IMET_SWR  Short wave radiation (watts/sq m)
056| IMET_WNC  Compass reading (degrees)
057| IMET_WND  Wind direction (ship relative)
058| IMET_WNS  Wind speed (m/s, ship relative)

003| 00:00:00
012| 206.1, -00.0
024| +45.2988
025| +22.3075
045| 000000.551,3925.2438,N,07313.3982,W,3
047| 21.178
048| 1016.64
050| -3.451
053| 29.30
055| 1.7
056| 0.0
057| 250.5
058| 2.6

003| 00:01:00
012| 207.0, +00.0
024| +45.2956
025| +22.3042
045| 000058.551,3925.2495,N,07313.3960,W,3
047| 21.205
048| 1016.82
050| -3.004
053| 29.30
055| 1.3
056| 0.0
057| 246.5
058| 2.3

Typical ATHENA event data log file

R/V OCEANUS Event Log File
XBT Station Log File
04/18/96 23:22:51
ATHENA V5.0

000| Event comment string
002| CDATE     Computer date
003| CTIME     Computer time
016| JSECONDS  Time & date (Julian seconds)
045| GPS_TP    GPS time & position

000| Station #112
002| 04/18/96
003| 23:24:30
016| 13049162670
045| 232430.551,3925.2438,N,07313.3982,W,3

000| Station #113
002| 04/18/96
003| 23:24:42
016| 13049162682
045| 232442.231,3925.2495,N,07313.3960,W,3

000| Lunch break
002| 04/18/96
003| 23:25:04
016| 13049162704
045| 232504.452,3925.2555,N,07313.3957,W,3