summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormattf <mattf@5390a7c7-147a-4af0-8ec9-7488f05a26cb>2005-02-25 22:09:23 +0000
committermattf <mattf@5390a7c7-147a-4af0-8ec9-7488f05a26cb>2005-02-25 22:09:23 +0000
commit956601883f4e7ed0398fd4fd1851f934f13ce632 (patch)
treea071da485cb4a740721ada6e632875994b19816c
parentd82a4fd0f404af903f95b15d46982ba1afd6a41a (diff)
Make the digit configurable again to break dialtone.
git-svn-id: http://svn.digium.com/svn/zaptel/trunk@597 5390a7c7-147a-4af0-8ec9-7488f05a26cb
-rwxr-xr-xREADME.fxotune4
-rwxr-xr-xfxotune.c6
2 files changed, 7 insertions, 3 deletions
diff --git a/README.fxotune b/README.fxotune
index 99a5430..9e7ac24 100755
--- a/README.fxotune
+++ b/README.fxotune
@@ -5,7 +5,7 @@ still nothing works. What can I do?
A. Use the fxotune utility.
To use:
-Just run the fxotune utility with the -i option. (`fxotune -i`) It should
+Just run the fxotune utility with the -i option. (`fxotune -i 4`) It should
discover which zap channels are FXO modules and tune them accordingly. Be warned
however, it takes a significant amount of time for EACH module to test, I would
say somewhere around 2-3 minutes. But you only have to initialize it once for
@@ -16,6 +16,8 @@ affect, so essentially if each time you reboot the machine you need to run
`fxotune -s`. You might consider putting it in your startup scripts some time
after the module loads and before asterisk runs.
+NOTE: The digit after the -i option is the digit that will break dialtone on the line.
+
As always, if you have any questions, you can email me at creslin@NOSPAMdigium.com
Matthew Fredrickson
diff --git a/fxotune.c b/fxotune.c
index 45186f4..d9dd442 100755
--- a/fxotune.c
+++ b/fxotune.c
@@ -509,7 +509,7 @@ set:
}
if (!strcasecmp(argv[1], "-i")) {
- if (argc != 2) {
+ if (argc != 3) {
/* Show usage */
fputs(usage, stdout);
return -1;
@@ -531,7 +531,7 @@ set:
continue;
}
- res = acim_tune(fd, "4"); /* Shouldn't matter what digit we press */
+ res = acim_tune(fd, argv[2]); /* Shouldn't matter what digit we press */
close(fd);
if (res > -1) {
@@ -561,5 +561,7 @@ set:
goto set;
}
+ fputs(usage, stdout);
+
return 0;
}