On startup, q3302ew reads the configuration file named on the command line. As always, the configuraton file contains comments:
Command names must be typed in the control file exactly as shown in this document (upper/lower case matters!).# marks the line as a comment (example: # This is a comment).
#
# q3302ew configuration file
#
# This code receives MiniSEED records from COMSERV, converts them into
# Earthworm trace buf messages, and stuffs them into a wave ring.
#
#
ModuleId MOD_Q3302EW # module id for this import,
RingName WAVE_RING # transport ring to use for input/output,
HeartbeatInt 10 # Heartbeat interval in seconds
# this should be half the q3302ew.desc heartbeat!
LogFile 1 # If 0, don't write logfile at all,
## The following config items are from the Q330 side
## of Mountainair. Their names have been preserved for
## consistancy
udpaddr 192.168.1.165 # The IP address of the Q330
ipport 6000 # A port on the local machine. This port
# and this port+1 must be unused.
baseport 5330 # The base port of the Q330 (5330 is default)
dataport 2 # Which dataport on the Q330 to connect to
serialnumber 0x010000069A37E501 # The serial number of the Q330
authcode 0x0 # The authentication code for the Q330
verbosity 0 # global verbosity level
# 0 : silent
# 1 : major items
# 2 : major and minor items
# 3 : everything
# Values for "diagnostic" (for debugging purposes only) can be found
# in the qmaserv/include/QmaDiag.h file.
diagnostic 0 # Particular diagnostic messages that should
# always be displayed
startmsg "Q3302EW Starting" # Sent to the Q330 via user message
# when q3302ew starts
statusinterval 5 # time in seconds between status checks.
# this defines both state of health checking,
# as well as status output
# State Of Health Thresholds
# Minimum acceptable clock quality. Set to zero to never warn
# about this.
MinClockQuality 80 # If the clock quality falls below this value,
# an error is generated.
## These two are measured in mv
MinInputPower 10000 # An error is generated if input power falls
# below this value
MaxInputPower 14000 # An error is generated if input power goes
# higher than this value
# There is a seperate MassPosition range defined for each channel. These
# values are MinMass1Position through MinMass6Position, and MaxMass1Position
# through MaxMass6Position. An error is inserted into the ring for each
# mass position that is outside of it's acceptable range.
MaxMass1Position 30
MinMass1Position -10
MaxMass2Position 30
MinMass2Position -10
MaxMass3Position 30
MinMass3Position -10
MaxMass4Position 30
MinMass4Position -10
MaxMass5Position 30
MinMass5Position -10
MaxMass6Position 30
MinMass6Position -10
Earthworm system setup:
MyModuleId required
RingName required
ComservSeqBuf required
HeartbeatInt required
Output Control:
LogFile required
Communications setup:
udpaddr required
ipport required
baseport required
serialnumber required
authcode required
verbosity required
Monitoring setup:
startmsg required
statusinterval required
MinClockQuality required
MinInputPower required
MaxInputPower required
MinMassNPosition required
MaxMassNPosition required
command arg1
authcode auth
Default: required field
Example: authcode 0x0
baseport port
Default: defaults to 5330
baseport 5330
HeartbeatInt beat
ipport port
This is the UDP port 1-65536, on the local host that will be used to communicate to the 330. This port and port+1 must be open on the localhost.
Default: none, required optionipport 192.168.1.100
LogFile switch
Sets the on-off switch for writing a log file to disk. If switch is 0, no log file will be written. If switch is 1, q3302ew will write a daily log file(s) called q3302ewxx.log_yymmdd where xx is q3302ew's config filename and yymmdd is the current UTC date (ex: 960123) on the system clock. The file(s) will be written in the EW_LOG directory (environment variable).
Default: none
MinClockQuality num
Default: none, its required
Example: MinClockQuality 80
MinInputPower volts_mv
MaxInputPower volts_mv
Default: none, its required
Example: MinInputPower 110000
MaxInputPower 17000
MinMassNPosition counts
MaxMassNPosition counts
Default: none, its required for each channel
Example: MinMass1Position -30
MaxMass1Position 30
MyModuleId mod_id
Sets the module id for labeling all outgoing messages. mod_id is a character string (valid strings are listed in earthworm.d) that relates (in earthworm.d) to a unique single-byte number.
Default: none
Calnet: MyModuleId MOD_Q2EW
RingName ring
This is the ring into which the waveforms and messages are sent.Default: none, required option
Example: RingName WAVE_RING
serialnumber num
Default: none, required option
Example: 0x010000069A37E501
startmsg "message in quotes"
Default: none, this is required
Example: "Start of q3302ew at ISTI"
statusinterval secs
Default: none, this is required
Example: statusinterval 600
udpaddr addr
This is the UDP address, in numeric dotted notation, of the Q330 to be accessed.
Default: none, required option
udpaddr 192.168.1.100
verbosity num
Default: none, required option
Example: verbosity 0
Here is a copy of the q3302ew.desc file as implemented.
modName q3302ew
modId MOD_Q3302EW
instId INST_UNKNOWN
restartMe # restart
#
# Heartbeat Specification. If the status manager does not receive
# a heartbeat message every <tsec> seconds from this module, an
# error will be reported (client module dead). <page> is the maximum
# number of pager messages that will be reported and <mail> is the
# maximum number of email messages that will be reported. If the
# page or mail limit is exceeded, no further errors will be reported
# until the status manager is restarted.
#
tsec: 20 page: 0 mail: 99
# WARNINGS
err: 0 nerr: 1 tsec: 0 page: 5 mail: 20
text: "Clock Quality out of range"
err: 1 nerr: 1 tsec: 0 page: 5 mail: 20
text: "Input power too low"
err: 2 nerr: 1 tsec: 0 page: 5 mail: 20
text: "Input power too high"
err: 3 nerr: 1 tsec: 0 page: 5 mail: 20
text: "Mass position too low"
err: 4 nerr: 1 tsec: 0 page: 5 mail: 20
text: "Mass position too high"
#