summaryrefslogtreecommitdiff
path: root/util_tx_continuous
diff options
context:
space:
mode:
authorHarsh Sharma <harsh.sharma@multitech.com>2020-02-03 14:39:58 -0600
committerHarsh Sharma <harsh.sharma@multitech.com>2020-02-03 14:39:58 -0600
commit9eb0233d94d05b89d8dab1ad192f5010d1282341 (patch)
tree5030fc6ad8743b4d86e1e91b7672d46335542b01 /util_tx_continuous
parent24cd1e066310ebabe6968c28d9ee2cd87bd28e26 (diff)
downloadlora_gateway_mtac_full-9eb0233d94d05b89d8dab1ad192f5010d1282341.tar.gz
lora_gateway_mtac_full-9eb0233d94d05b89d8dab1ad192f5010d1282341.tar.bz2
lora_gateway_mtac_full-9eb0233d94d05b89d8dab1ad192f5010d1282341.zip
Changed getopt path option to conform with other utilities
Diffstat (limited to 'util_tx_continuous')
-rw-r--r--util_tx_continuous/src/util_tx_continuous.c54
1 files changed, 27 insertions, 27 deletions
diff --git a/util_tx_continuous/src/util_tx_continuous.c b/util_tx_continuous/src/util_tx_continuous.c
index 6cf2999..aeaae8d 100644
--- a/util_tx_continuous/src/util_tx_continuous.c
+++ b/util_tx_continuous/src/util_tx_continuous.c
@@ -293,35 +293,35 @@ int main(int argc, char **argv)
}
break;
- case 'f':
- i = sscanf(optarg, "%f", &arg_f);
- if ((i != 1) || (arg_f < 1)) {
- printf("ERROR: argument parsing of -f argument. Use -h to print help\n");
- return EXIT_FAILURE;
- }
- else {
- freq_hz = (uint32_t)((arg_f * 1e6) + 0.5);
- }
- break;
-
- case 'r':
- i = sscanf(optarg, "%u", &arg_u);
- switch (arg_u) {
- case 1255:
- radio_type = LGW_RADIO_TYPE_SX1255;
- break;
- case 1257:
- radio_type = LGW_RADIO_TYPE_SX1257;
- break;
- default:
- printf("ERROR: argument parsing of -r argument. Use -h to print help\n");
+ case 'f':
+ i = sscanf(optarg, "%f", &arg_f);
+ if ((i != 1) || (arg_f < 1)) {
+ printf("ERROR: argument parsing of -f argument. Use -h to print help\n");
return EXIT_FAILURE;
- }
- break;
+ }
+ else {
+ freq_hz = (uint32_t)((arg_f * 1e6) + 0.5);
+ }
+ break;
- default:
- printf("ERROR: argument parsing options. Use -h to print help\n");
- return EXIT_FAILURE;
+ case 'r':
+ i = sscanf(optarg, "%u", &arg_u);
+ switch (arg_u) {
+ case 1255:
+ radio_type = LGW_RADIO_TYPE_SX1255;
+ break;
+ case 1257:
+ radio_type = LGW_RADIO_TYPE_SX1257;
+ break;
+ default:
+ printf("ERROR: argument parsing of -r argument. Use -h to print help\n");
+ return EXIT_FAILURE;
+ }
+ break;
+
+ default:
+ printf("ERROR: argument parsing options. Use -h to print help\n");
+ return EXIT_FAILURE;
}
}