From 5c849bfca30cc9de59174c6b05a2ba914acc8cc8 Mon Sep 17 00:00:00 2001 From: Kamal Mostafa Date: Fri, 15 Jul 2011 19:17:31 -0700 Subject: [PATCH] minimodem: man page enhancements --- configure | 3 ++- configure.ac | 1 + src/Makefile.am | 7 ++++++- src/Makefile.in | 12 +++++++++--- src/{minimodem.1 => minimodem.1.in} | 27 ++++++++++++++++++--------- 5 files changed, 36 insertions(+), 14 deletions(-) rename src/{minimodem.1 => minimodem.1.in} (84%) diff --git a/configure b/configure index 0cdce95..e9ab89b 100755 --- a/configure +++ b/configure @@ -3523,7 +3523,7 @@ fi # Checks for library functions. # AC_FUNC_FORK -ac_config_files="$ac_config_files Makefile src/Makefile" +ac_config_files="$ac_config_files Makefile src/Makefile src/minimodem.1" # testdata/Makefile cat >confcache <<\_ACEOF @@ -4247,6 +4247,7 @@ do "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; + "src/minimodem.1") CONFIG_FILES="$CONFIG_FILES src/minimodem.1" ;; *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5 ;; esac diff --git a/configure.ac b/configure.ac index 8446ab0..7f84d70 100644 --- a/configure.ac +++ b/configure.ac @@ -49,6 +49,7 @@ AC_SUBST(DEPS_LIBS) AC_CONFIG_FILES([ Makefile src/Makefile + src/minimodem.1 ]) # testdata/Makefile AC_OUTPUT diff --git a/src/Makefile.am b/src/Makefile.am index 876f3a3..71d704d 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -26,7 +26,7 @@ bin_PROGRAMS = minimodem dist_man_MANS = minimodem.1 -EXTRA_DIST = self-test testcases/* # run-test +EXTRA_DIST = minimodem.1.html self-test testcases/* # run-test TESTS = testcases/test.* @@ -45,3 +45,8 @@ BAUDOT_SRC = baudot.h baudot.c minimodem_LDADD = $(DEPS_LIBS) minimodem_SOURCES = minimodem.c $(BAUDOT_SRC) $(FSK_SRC) $(SIMPLEAUDIO_SRC) + +minimodem.1.html: minimodem.1 Makefile + man --html=cat ./minimodem.1 | sed '5,$$ s:\(http\:[^ &]*\):\1:g' > $@ + [ -s $@ ] || { rm $@; exit 1; } + diff --git a/src/Makefile.in b/src/Makefile.in index f149695..0f46afb 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -54,14 +54,14 @@ POST_UNINSTALL = : bin_PROGRAMS = minimodem$(EXEEXT) subdir = src DIST_COMMON = $(dist_man_MANS) $(srcdir)/Makefile.am \ - $(srcdir)/Makefile.in + $(srcdir)/Makefile.in $(srcdir)/minimodem.1.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(install_sh) -d CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = +CONFIG_CLEAN_FILES = minimodem.1 CONFIG_CLEAN_VPATH_FILES = am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" PROGRAMS = $(bin_PROGRAMS) @@ -204,7 +204,7 @@ top_srcdir = @top_srcdir@ AM_CFLAGS = -Wall # -Werror INCLUDES = $(DEPS_CFLAGS) dist_man_MANS = minimodem.1 -EXTRA_DIST = self-test testcases/* # run-test +EXTRA_DIST = minimodem.1.html self-test testcases/* # run-test TESTS = testcases/test.* SIMPLEAUDIO_SRC = \ simpleaudio.h \ @@ -252,6 +252,8 @@ $(top_srcdir)/configure: $(am__configure_deps) $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): +minimodem.1: $(top_builddir)/config.status $(srcdir)/minimodem.1.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @@ -667,6 +669,10 @@ uninstall-man: uninstall-man1 uninstall-man uninstall-man1 +minimodem.1.html: minimodem.1 Makefile + man --html=cat ./minimodem.1 | sed '5,$$ s:\(http\:[^ &]*\):\1:g' > $@ + [ -s $@ ] || { rm $@; exit 1; } + # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: diff --git a/src/minimodem.1 b/src/minimodem.1.in similarity index 84% rename from src/minimodem.1 rename to src/minimodem.1.in index cbf0316..5366b2f 100644 --- a/src/minimodem.1 +++ b/src/minimodem.1.in @@ -2,7 +2,7 @@ .\" First parameter, NAME, should be all caps .\" Second parameter, SECTION, should be 1-8, maybe w/ subsection .\" other parameters are allowed: see man(7), man(1) -.TH MINIMODEM 1 "June 22, 2011" +.TH MINIMODEM 1 "July 15, 2011" .\" Please adjust this date whenever revising the manpage. .\" .\" Some roff macros, for reference: @@ -77,7 +77,8 @@ print program version The required \fI{baudmode}\fR parameter may be any floating-point value to specify a baud rate, or the string "rtty". The \fI{baudmode}\fR also implies certain other parameter defaults -depending on the rate. +depending on the rate, including standard (or at least reasonable) +default mark and space tone frequencies. .TP .B 1200 : Bell202 1200 bps \-\-ascii @@ -85,14 +86,11 @@ depending on the rate. .B 300 : Bell103 300 bps \-\-ascii .TP -.B N>=100 - : Bellxxx N bps \-\-ascii -.TP -.B N<100 - : RTTY N bps \-\-baudot -.TP .B rtty - : RTTY 45.45 bps \-\-baudot + : RTTY 45.45 bps \-\-baudot \-\-txstopbits 1.5 +.TP +.B {any floating point value N} + : Bell-like N bps \-\-ascii .SH EXAMPLES .TP .B minimodem --tx 100 @@ -103,6 +101,12 @@ and receive 100 baud tones on another nearby computer. .TP .B minimodem --rx --auto-carrier rtty Decode amateur radio RTTY signals (listen near 14.085 MHz). +.TP +.B minimodem --tx 0.5 +Experiment with very low baud rates (works in noisy conditions). +.TP +.B minimodem --tx 12000 +Experiment with very high baud rates works (works with audio files). .SH NOTES .B minimodem does not decode AX.25 framed packets. @@ -110,6 +114,11 @@ does not decode AX.25 framed packets. .B minimodem does not support modem control ("AT") commands, nor does it produce DTMF telephone dialing tones. +.SH VERSION +This page documents +.B minimodem +version @PACKAGE_VERSION@. +The latest version is available at . .SH AUTHOR .B minimodem was written by Kamal Mostafa .