source: trunk/ewdoc/WEB_DOC/cmd/tankplayer_cmd.html @ 2166

Revision 2166, 10.5 KB checked in by withers, 14 years ago (diff)

Updated to v7

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
Line 
1<HTML>
2<HEAD>
3<TITLE>Earthworm Modules: Tankplayer commands</TITLE>
4</HEAD>
5
6<BODY TEXT="#000000" BGCOLOR="#FADFAF" LINK="#0000EE" VLINK="#551A8B" ALINK="#FF
70000">
8
9<CENTER><H1>Tankplayer Configuration File Commands</H1>
10<I>(last revised 19 May 2006)</I></CENTER>
11                                                         
12Page Index:<BR>
131.  <A HREF=#example>Example configuration file</A><BR>
142.  <A HREF=#function>Functional command listing</A><BR>
153.  <A HREF=#alphabet>Alphabetic command listing & description</A>
16<P>
17<!-- ADD HERE: Paragraph "On startup, xxxx reads the..." -->
18Tankplayer reads file(s) containing waveform messages (of either TYPE_ADBUF,
19TYPE_TRACEBUF, or TYPE_TRACEBUF2) from a single data source.  It places the
20waveform messages
21into shared memory in simulated real time, using the delta-t between
22time-stamps in successive message headers to determine its timing.
23
24On startup, tankplayer reads the configuration file named on the command
25line.  Commands in this file set up all parameters used in playing back
26waveform messages from a file to a shared memory ring.  In the control file,
27lines may begin with a valid tankplayer command (listed below) or with one
28of 2 special characters:
29
30<BLOCKQUOTE><PRE>
31#  marks the line as a comment (example: # This is a comment).<BR>   
32@  allows control files to be nested; one control file can be
33   accessed from another with the command "@" followed by
34   a string representing the path name of the next control file
35   (example: @model.d).
36</BLOCKQUOTE></PRE>
37Command names must be typed in the control file exactly as shown in this
38document (upper/lower case matters!).
39<P>
40<A NAME="example">
41<H2>1.  EXAMPLE CONFIGURATION FILE</H2>
42<P>
43<PRE>
44
45# tankplayer config file for playing TYPE_TRACEBUF2 waveforms
46# tankplayer config file for playing waveform files
47
48RingName      WAVE_RING        # play waveforms into this ring
49MyModuleId    MOD_ADSEND_A     # as this module id
50PlayMsgType   TYPE_TRACEBUF2   # msg type to read from file
51LogFile       1                # 0=no log; 1=keep log file
52HeartBeatInt  30               # seconds between heartbeats
53Pause         10               # seconds to pause between wavefiles
54StartUpDelay  10               # seconds to wait before playing 1st file
55ScreenMsg     1                # (optional) if non-zero, informational messages will be
56                               #   written to the screen as data is played
57# SendLate      10.0           # (optional) if present, packets will be
58                               #   timestamped this many seconds before
59                               #   current time;
60                               # if absent, packets will have original time
61                               #   stamps
62                               #
63Debug         1                # for verbosity
64
65# List of files to play (up to 50 allowed):
66WaveFile      e:\QAnew\900819a.ew1.tbuf
67
68# IgnoreTBVersionNumbers -
69# Prevents tankplayer from objecting to tracebuf2 packets that don't have
70# the correct version field.  Not recommended.
71#IgnoreTBVersionNumbers 0
72</PRE>
73<P>
74<A NAME="function">
75<H2>2.  FUNCTIONAL COMMAND LISTING</H2>
76<P> 
77<!-- ADD HERE: Paragraph "Below are the commands recognized..." -->
78Below are the commands recognized by tankplayer, grouped by the function
79they influence.  All of the commands are required; they must be specified
80in the control file in order for tankplayer to operate.
81
82<!-- ADD HERE: The pre-formatted functional command listing      -->
83<!-- To make an anchor for each command, surround it with these: -->
84
85<PRE>   Earthworm system setup:
86                <A HREF=#HeartBeatInt>HeartBeatInt</A>          required
87                <A HREF=#MyModuleId>MyModuleId</A>              required
88                <A HREF=#RingName>RingName</A>          required
89
90        Waveform Playback:
91                <A HREF=#Pause>Pause</A>                        required
92                <A HREF=#PlayMsgType>PlayMsgType</A>            required
93                <A HREF=#StartUpDelay>StartUpDelay</A>          required
94                <A HREF=#WaveFile>WaveFile</A>          required
95                <A HREF=#IgnoreTBVersionNumbers>IgnoreTBVersionNumbers</A>      optional
96   
97        Output Control:
98                <A HREF=#LogFile>LogFile</A>                    required
99
100</PRE>
101
102<A NAME="alphabet">
103<H2>3.  ALPHABETIC COMMAND LISTING & DESCRIPTION</H2>
104<P>
105In the following section, all configuration file commands are listed
106in alphabetical order.  Listed along with the command (bold-type) are
107its arguments (in red), the name of the subroutine that processes the
108command, and the function within the module that the command influences.
109A detailed description of the command and is also given.  Default values
110and the values used by Calnet are listed after each command description.
111<PRE><B>
112command <font color=red>arg1</font>                             processed by            function
113</PRE></B>
114<HR>
115
116<!-- ADD HERE: all commands; below is a sample command blank: -->
117
118<A NAME="HeartBeatInt">  <!-- command name as anchor inside quotes --> 
119<PRE><B>HeartBeatInt <font color=red>nsec</font>                        tankplayer_config       Earthworm setup</B><!-- command args ... -->           
120</PRE>
121<BLOCKQUOTE> <!-- command description goes here -->
122Defines the number of seconds <font color=red>nsec</font> between TYPE_HEARTBEAT messages
123issued by tankplayer.
124<PRE><!-- Default and example go here   -->
125Default:  none                          Calnet:  HeartBeatInt 15
126</PRE>
127</BLOCKQUOTE>
128<HR>
129
130<A NAME="IgnoreTBVersionNumbers">
131<PRE><B>IgnoreTBVersionNumbers <font color=red>switch</font>            tankplayer_config       Playback</B>
132</PRE>
133<BLOCKQUOTE>
134Prevents tankplayer from objecting to tracebuf2 packets that don't have
135the correct version field.  Not recommended.
136<PRE>
137Default: 0      False
138</PRE>
139</BLOCKQUOTE>
140<HR>
141
142<A NAME="LogFile">  <!-- command name as anchor inside quotes -->       
143<PRE><B>LogFile <font color=red>switch</font>                           tankplayer_config       output</B><!-- command args ... -->             
144</PRE>
145<BLOCKQUOTE> <!-- command description goes here -->
146Sets the on-off switch for writing a log file to disk.  If <font color=red>switch</font>
147is 0, no log file will be written.  If <font color=red>switch</font> is 1, tankplayer
148will write a daily log file(s) called tankplayerxx.log_yymmdd
149where xx is tankplayer's module id (set with "MyModuleId" command)
150and yymmdd is the current UTC date (ex: 960123) on the system clock. 
151The file(s) will be written in the EW_LOG directory (environment
152variable). 
153<PRE><!-- Default and example go here   -->
154Default:  none
155</PRE>
156</BLOCKQUOTE>
157<HR>
158
159<A NAME="MyModuleId">  <!-- command name as anchor inside quotes -->   
160<PRE><B>MyModuleId <font color=red>mod_id</font>                        tankplayer_config       Earthworm setup</B><!-- command args ... -->           
161</PRE>
162<BLOCKQUOTE> <!-- command description goes here -->
163Sets the module id for labeling all outgoing messages. <font color=red>mod_id</font> is
164a character string (valid strings are listed in earthworm.d) that
165relates (in earthworm.d) to a unique single-byte number.  Tankplayer
166also places this module id in the module id field of each waveform
167message header before it puts the message into shared memory.
168<PRE><!-- Default and example go here   -->
169Default:  none                         
170Example:  MyModuleId MOD_ADSEND_A
171</PRE>
172</BLOCKQUOTE>
173<HR>
174
175<A NAME="Pause">  <!-- command name as anchor inside quotes --> 
176<PRE><B>Pause <font color=red>nsec</font>                               tankplayer_config       Playback</B><!-- command args ... -->           
177</PRE>
178<BLOCKQUOTE> <!-- command description goes here -->
179Defines the integer number of seconds <font color=red>nsec</font> to pause after completing
180the playback of one waveform file before starting the playback of
181the next.  Tankplayer will continue to issue its heartbeat while
182it is in pause-mode.
183<PRE><!-- Default and example go here   -->
184Default:  none
185Example:  Pause 15
186</PRE>
187</BLOCKQUOTE>
188<HR>
189
190<A NAME="PlayMsgType">  <!-- command name as anchor inside quotes -->   
191<PRE><B>PlayMsgType <font color=red>type</font>                 tankplayer_config       Playback</B><!-- command args ... -->           
192</PRE>
193<BLOCKQUOTE> <!-- command description goes here -->
194Tells tankplayer what type of message the waveform file(s) contain. 
195<font color=red>type</font> is a character string (valid strings are listed in earthworm.d)
196that relates (in earthworm.d) to a unique single-byte number.  By the
197message-type, tankplayer knows the format of the waveform message;
198currently tankplayer only knows how to read and manipulate TYPE_ADBUF
199TYPE_TRACEBUF, and TYPE_TRACEBUF2 waveform messages.
200<PRE><!-- Default and example go here   -->
201Default:  none
202Example:  PlayMsgType TYPE_TRACEBUF2
203</PRE>
204</BLOCKQUOTE>
205<HR>
206
207<A NAME="RingName">  <!-- command name as anchor inside quotes -->     
208<PRE><B>RingName <font color=red>ring</font>                            tankplayer_config       Earthworm setup</B><!-- command args ... -->           
209</PRE>
210<BLOCKQUOTE> <!-- command description goes here -->
211Tells tankplayer which shared memory region to use for output.
212<font color=red>ring</font> is a character string (valid strings are listed in earthworm.d)
213that relates (in earthworm.d) to a unique number for the key to the
214shared memory region.
215<PRE><!-- Default and example go here   -->
216Default:  none                          Calnet:  RingName WAVE_RING
217</PRE>
218</BLOCKQUOTE>
219<HR>
220
221<A NAME="StartUpDelay">  <!-- command name as anchor inside quotes --> 
222<PRE><B>StartUpDelay <font color=red>xsec</font>                        tankplayer_config       Playback</B><!-- command args ... -->           
223</PRE>
224<BLOCKQUOTE> <!-- command description goes here -->
225Defines the integer number of seconds <font color=red>xsec</font> to wait on startup
226before beginning the playback of the first waveform file. 
227Tankplayer will continue to issue its heartbeat while it is in
228startup-delay mode.
229<PRE><!-- Default and example go here   -->
230Default:  none
231Example:  StartUpDelay 45
232</PRE>
233</BLOCKQUOTE>
234<HR>
235
236<A NAME="WaveFile">  <!-- command name as anchor inside quotes -->     
237<PRE><B>WaveFile <font color=red>path-file</font>                       tankplayer_config       Playback</B><!-- command args ... -->           
238</PRE>
239<BLOCKQUOTE> <!-- command description goes here -->
240Gives the name <font color=red>path-file</font> of one waveform file that tankplayer should
241play back.  <font color=red>path-file</font> is a character string up to 45 characters long.
242Up to 50 "WaveFile" commands may be issued.  Tankplayer will play
243the files in the order that they were listed in the configuration
244file, pausing between files by amount of time set in the "Pause"
245command.  All files must contain the same type of waveform message
246(specified in the "PlayMsgType" command).
247<PRE><!-- Default and example go here   -->
248Default:  none
249Example:  WaveFile  event1.waves</PRE>
250</BLOCKQUOTE>
251<HR>
252
253<CENTER> 
254<A HREF="../modules.html">Module Index</A> |
255<A HREF="../ovr/tankplayer_ovr.html">Tankplayer Overview</A>
256</CENTER>
257
258
259<!-- USGS-required stuff at the end -->
260<HR>
261<ADDRESS>
262The URL of this page is  <B>[http://gldbrick.cr.usgs.gov/ew-doc/cmd/tankplayer_cmd.html]</B><BR>
263Contact: <B>dietz@usgs.gov</B><BR>
264</ADDRESS>
265</BODY>
266</HTML>
Note: See TracBrowser for help on using the repository browser.