|
@@ -79,9 +79,9 @@ static void LOG_func(const char *msg) {
|
79
|
79
|
LOG(msg);
|
80
|
80
|
}
|
81
|
81
|
|
82
|
|
-static const char short_options[] = "i:d:N:Sl:L:F:I:RzM:T:W:O:o:t:rk:g:upwxyc:C:Y:Q:A:s:U:P:B:46eZ:Ef:a:X:H:G:KJ:D:jbhVn:m:";
|
|
82
|
+static const char short_options[] = "i:d:N:Sl:L:F:I:RzM:T:W:O:o:t:rk:g:upwxyc:C:Y:Q:A:s:U:P:B:46eZ:Ef:a:X:vqH:G:KJ:D:jbhVn:m:";
|
83
|
83
|
|
84
|
|
-// Unused short options: aqv01235789
|
|
84
|
+// Unused short options: a01235789
|
85
|
85
|
static const struct option long_options[] = {
|
86
|
86
|
{ "ident", required_argument, NULL, 'i' },
|
87
|
87
|
{ "daemon", required_argument, NULL, 'd' },
|
|
@@ -130,11 +130,14 @@ static const struct option long_options[] = {
|
130
|
130
|
{ "emm-filter", required_argument, NULL, 'a' },
|
131
|
131
|
|
132
|
132
|
{ "ecm-pid", required_argument, NULL, 'X' },
|
|
133
|
+ { "ecm-only", no_argument, NULL, 'v' },
|
133
|
134
|
{ "ecm-report-time", required_argument, NULL, 'H' },
|
134
|
135
|
{ "ecm-irdeto-type", required_argument, NULL, 'G' },
|
135
|
136
|
{ "ecm-no-log", no_argument , NULL, 'K' },
|
136
|
137
|
{ "cw-warn-time", required_argument, NULL, 'J' },
|
137
|
138
|
|
|
139
|
+ { "ecm-and-emm-only", no_argument, NULL, 'q' },
|
|
140
|
+
|
138
|
141
|
{ "debug", required_argument, NULL, 'D' },
|
139
|
142
|
{ "pid-report", no_argument, NULL, 'j' },
|
140
|
143
|
{ "bench", no_argument, NULL, 'b' },
|
|
@@ -231,6 +234,8 @@ static void show_help(struct ts *ts) {
|
231
|
234
|
printf("\n");
|
232
|
235
|
printf("ECM options:\n");
|
233
|
236
|
printf(" -X --ecm-pid <pid> | Force ECM pid. Default: none\n");
|
|
237
|
+ printf(" -v --ecm-only | Send only ECMs to CAMD, skipping EMMs and without\n");
|
|
238
|
+ printf(" . decoding the input stream.\n");
|
234
|
239
|
printf(" -H --ecm-report-time <sec> | Report each <sec> how much ECMs and CWs have been\n");
|
235
|
240
|
printf(" . processed/skipped. Set <sec> to 0 to disable\n");
|
236
|
241
|
printf(" . the reports. Default: %d sec\n", ts->ecm_report_interval);
|
|
@@ -239,6 +244,9 @@ static void show_help(struct ts *ts) {
|
239
|
244
|
printf(" -J --cw-warn-time <sec> | Warn if no valid code word has been received.\n");
|
240
|
245
|
printf(" . Set <sec> to 0 to disable. Default: %d sec\n", ts->cw_warn_sec);
|
241
|
246
|
printf("\n");
|
|
247
|
+ printf(" -q --ecm-and-emm-only | Send ECMs and EMMs to CAMD but do not decode\n");
|
|
248
|
+ printf(" . the input stream.\n");
|
|
249
|
+ printf("\n");
|
242
|
250
|
printf("Logging options:\n");
|
243
|
251
|
printf(" -S --syslog | Log messages using syslog.\n");
|
244
|
252
|
printf(" -l --syslog-host <host> | Syslog server address. Default: disabled\n");
|
|
@@ -525,6 +533,11 @@ static void parse_options(struct ts *ts, int argc, char **argv) {
|
525
|
533
|
case 'X': // --ecm-pid
|
526
|
534
|
ts->forced_ecm_pid = strtoul(optarg, NULL, 0) & 0x1fff;
|
527
|
535
|
break;
|
|
536
|
+ case 'v': // --ecm-only
|
|
537
|
+ ts->process_emm = 0;
|
|
538
|
+ ts->process_ecm = 1;
|
|
539
|
+ ts->output_stream = 0;
|
|
540
|
+ break;
|
528
|
541
|
case 'H': // --ecm-report-time
|
529
|
542
|
ts->ecm_report_interval = strtoul(optarg, NULL, 10);
|
530
|
543
|
if (ts->ecm_report_interval > 86400)
|
|
@@ -542,6 +555,11 @@ static void parse_options(struct ts *ts, int argc, char **argv) {
|
542
|
555
|
ts->cw_warn_sec = 86400;
|
543
|
556
|
ts->cw_last_warn= ts->cw_last_warn + ts->cw_warn_sec;
|
544
|
557
|
break;
|
|
558
|
+ case 'q': // --ecm-and-emm-only
|
|
559
|
+ ts->process_emm = 1;
|
|
560
|
+ ts->process_ecm = 1;
|
|
561
|
+ ts->output_stream = 0;
|
|
562
|
+ break;
|
545
|
563
|
|
546
|
564
|
case 'D': // --debug
|
547
|
565
|
ts->debug_level = atoi(optarg);
|