4
Fork 0
This commit is contained in:
Artem Prilutskiy 2017-05-23 14:26:18 +03:00
parent 34084f1791
commit 43fdae655b

View file

@ -56,6 +56,7 @@ int main(int argc, char* argv[])
{ "server-port", required_argument, NULL, 'p' }, { "server-port", required_argument, NULL, 'p' },
{ "source-id", required_argument, NULL, 'i' }, { "source-id", required_argument, NULL, 'i' },
{ "group-id", required_argument, NULL, 'g' }, { "group-id", required_argument, NULL, 'g' },
{ "talker-alias", required_argument, NULL, 't' },
{ NULL, 0, NULL, 0 } { NULL, 0, NULL, 0 }
}; };
@ -63,7 +64,7 @@ int main(int argc, char* argv[])
int control = 0; int control = 0;
int selection = 0; int selection = 0;
while ((selection = getopt_long(argc, argv, "w:c:s:p:i:g:", options, NULL)) != EOF) while ((selection = getopt_long(argc, argv, "w:c:s:p:i:g:t:", options, NULL)) != EOF)
switch (selection) switch (selection)
{ {
case 'w': case 'w':
@ -102,6 +103,10 @@ int main(int argc, char* argv[])
control |= 0b10000; control |= 0b10000;
} }
break; break;
case 't':
strncpy(header.sourceCall, optarg, REWIND_CALL_LENGTH);
break;
} }
if (control != 0b11111) if (control != 0b11111)
@ -115,6 +120,7 @@ int main(int argc, char* argv[])
" --server-port <service port for BrandMeister DMR Server>\n" " --server-port <service port for BrandMeister DMR Server>\n"
" --source-id <ID to use as a source>\n" " --source-id <ID to use as a source>\n"
" --group-id <TG ID>\n" " --group-id <TG ID>\n"
" --talker-alias <text to send as Talker Alias>\n"
"\n", "\n",
argv[0]); argv[0]);
return EXIT_FAILURE; return EXIT_FAILURE;