Commit 5191b963 authored by Matteo Quintiliani's avatar Matteo Quintiliani

Set mschan=0/0 when timeoutrec > 0


git-svn-id: file:///home/quintiliani/svncopy/nmxptool/trunk@985 3cd66e75-5955-46cb-a940-c26e5fc5497d
parent f6a93526
...@@ -43,7 +43,7 @@ MaxTolerableLatency 120 # Max tolerable latency for each channe ...@@ -43,7 +43,7 @@ MaxTolerableLatency 120 # Max tolerable latency for each channe
# It is equivalent to the option -M. # It is equivalent to the option -M.
#TimeoutRecv 30 # Time-out in seconds for flushing queued data of each channel. #TimeoutRecv 30 # Time-out in seconds for flushing queued data of each channel.
# (Default 0. No time-out) [10..300]. # It sets mschan to 0/0 ((Default 0. No time-out) [10..300].
# Useful for retrieving Data On Demand with minimum delay. # Useful for retrieving Data On Demand with minimum delay.
# 'tsec' in nmxptool.desc should be greater than 'TimeoutRecv'. # 'tsec' in nmxptool.desc should be greater than 'TimeoutRecv'.
# It is equivalent to the option -T. # It is equivalent to the option -T.
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
* Istituto Nazionale di Geofisica e Vulcanologia - Italy * Istituto Nazionale di Geofisica e Vulcanologia - Italy
* quintiliani@ingv.it * quintiliani@ingv.it
* *
* $Id: nmxptool_getoptlong.c,v 1.94 2008-03-28 20:07:28 mtheo Exp $ * $Id: nmxptool_getoptlong.c,v 1.95 2008-03-29 12:49:11 mtheo Exp $
* *
*/ */
...@@ -252,7 +252,7 @@ DEFAULT_USEC / 1000, DEFAULT_N_CHANNEL, NMXP_MAX_MSCHAN_MSEC / 1000); ...@@ -252,7 +252,7 @@ DEFAULT_USEC / 1000, DEFAULT_N_CHANNEL, NMXP_MAX_MSCHAN_MSEC / 1000);
of the file Naqs.ini set RetxRequest to Enabled.\n\ of the file Naqs.ini set RetxRequest to Enabled.\n\
If RetxRequest is not enabled then -M is ineffective.\n\ If RetxRequest is not enabled then -M is ineffective.\n\
-T, --timeoutrecv=SECs Time-out for flushing queued packets of each channel.\n\ -T, --timeoutrecv=SECs Time-out for flushing queued packets of each channel.\n\
(default %d, no time-out) [%d..%d].\n\ It sets --mschan=0/0 (default %d, no time-out) [%d..%d].\n\
-T is useful for retrieving Data On Demand with minimum delay.\n\ -T is useful for retrieving Data On Demand with minimum delay.\n\
-M, -T are usable only with Raw Stream, -S=-1.\n\ -M, -T are usable only with Raw Stream, -S=-1.\n\
In general, -M and -T are not used together.\n\ In general, -M and -T are not used together.\n\
...@@ -345,7 +345,8 @@ Signal handling:\n\ ...@@ -345,7 +345,8 @@ Signal handling:\n\
INT QUIT TERM Sending these signals to %s causes it\n\ INT QUIT TERM Sending these signals to %s causes it\n\
to immediately attempt to gracefully terminate.\n\ to immediately attempt to gracefully terminate.\n\
It may take several seconds to complete exiting.\n\ It may take several seconds to complete exiting.\n\
ALRM Report info about data buffer.\n\ Using -T, it could wait up to SECs seconds.\n\
ALRM Print current info about Raw Stream buffer.\n\
HUP PIPE Ignored. (SIG_IGN)\n\ HUP PIPE Ignored. (SIG_IGN)\n\
\n", NMXP_LOG_STR(PACKAGE_NAME)); \n", NMXP_LOG_STR(PACKAGE_NAME));
...@@ -1019,6 +1020,13 @@ int nmxptool_check_params(NMXPTOOL_PARAMS *params) { ...@@ -1019,6 +1020,13 @@ int nmxptool_check_params(NMXPTOOL_PARAMS *params) {
nmxp_log(NMXP_LOG_WARN, NMXP_LOG_D_ANY, "nC in <mschan> has to be within [%d..%d] or equal to zero if 0/0.\n", nmxp_log(NMXP_LOG_WARN, NMXP_LOG_D_ANY, "nC in <mschan> has to be within [%d..%d] or equal to zero if 0/0.\n",
DEFAULT_N_CHANNEL_MINIMUM, DEFAULT_N_CHANNEL_MAXIMUM); DEFAULT_N_CHANNEL_MINIMUM, DEFAULT_N_CHANNEL_MAXIMUM);
} }
if(params->timeoutrecv > 0 &&
(params->usec != 0 || params->n_channel != 0)) {
params->usec = 0;
params->n_channel=0;
nmxp_log(NMXP_LOG_WARN, NMXP_LOG_D_ANY, "<mschan> can not be used with <timeoutrecv>. <mschan> set to 0/0.\n");
}
/* /*
if( params->stc == -1 ) { if( params->stc == -1 ) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment