|
|
@ -354,7 +354,6 @@ int main(int argc, char **argv) |
|
|
|
|
|
|
|
|
|
|
|
if (argc < optind) |
|
|
|
if (argc < optind) |
|
|
|
usage(); |
|
|
|
usage(); |
|
|
|
|
|
|
|
|
|
|
|
#else |
|
|
|
#else |
|
|
|
if(argc < 6) |
|
|
|
if(argc < 6) |
|
|
|
usage(); |
|
|
|
usage(); |
|
|
@ -364,8 +363,6 @@ int main(int argc, char **argv) |
|
|
|
port = atoi(argv[2]); |
|
|
|
port = atoi(argv[2]); |
|
|
|
addr = argv[1]; |
|
|
|
addr = argv[1]; |
|
|
|
#endif |
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
printf("listen addr %s:%d\n", addr, port); |
|
|
|
|
|
|
|
device_count = rtlsdr_get_device_count(); |
|
|
|
device_count = rtlsdr_get_device_count(); |
|
|
|
if (!device_count) { |
|
|
|
if (!device_count) { |
|
|
|
fprintf(stderr, "No supported devices found.\n"); |
|
|
|
fprintf(stderr, "No supported devices found.\n"); |
|
|
@ -440,6 +437,11 @@ int main(int argc, char **argv) |
|
|
|
|
|
|
|
|
|
|
|
while(1) { |
|
|
|
while(1) { |
|
|
|
printf("listening...\n"); |
|
|
|
printf("listening...\n"); |
|
|
|
|
|
|
|
printf("Use the device argument 'rtl_tcp=%s:%d' in OsmoSDR " |
|
|
|
|
|
|
|
"(gr-osmosdr) source\n" |
|
|
|
|
|
|
|
"to receive samples in GRC and control " |
|
|
|
|
|
|
|
"rtl_tcp parameters (frequency, gain, ...).\n", |
|
|
|
|
|
|
|
addr, port); |
|
|
|
listen(listensocket,1); |
|
|
|
listen(listensocket,1); |
|
|
|
|
|
|
|
|
|
|
|
while(1) { |
|
|
|
while(1) { |
|
|
|