Morse Code WAV File Generator

1. The WAVGEN Processor
2. WAVGEN and Morse Academy Files

The WAVGEN Processor

WAVGEN is a DOS program that will generate a CW audio WAV file from an input text file. It is a DOS processor, built to complement Morse Academy, with a command line format:

C:\WAVGEN   File/Ave,Speed,Frequency,Rise Time/
File is the text input file name(s). If the Extension is blank, .KB is assumed. The name can contain Alphabetic, numeric, - (minus), _ (underline), and the wild card symbols * and ?
the slash "/" is used as the separator after the File name and again at the end of the optional three sending control parameters
Ave is the average sending speed generated (Farnsworth method)
Speed is the character speed of the note generated, and
Frequency is the frequency of the note generated in the WAV file
Rise Time is the rise time in milliseconds (ms) used to shape the output sine wave to minimize key clicks. The parameter is optional and if it is not written, a 3 ms default is used.

For example,

C:\WAVGEN   1B*/13,18,730/

would generate WAV files for all input files with name starting with 1B (and with an assumed file extension of KB), at an average sending speed of 13 wpm, a character sending speed of 18 wpm, and with a 730 Hz note. These are the default values if the optional sending control parameters are omitted. (the first three must be present if parameters are used). The fourth parameter for rise time is optional. In this case the default value is 3 ms.

WAVGEN will also accept embedded triples in the text to control note frequency, and character and average sending speeds. The format is the same used with Morse Academy -- <s,c,f>, where the speeds can be from 05 to 99 wpm, and the note frequency is between 400 Hz and 1200 Hz. If an embeded triple is used to control sending, all three fields must be present and speeds should always be two digits, i.e. 5 wpm is written as 05. For example, the following test could be used to generate the audio of a simulated two-way contest QSO between two stations:

    <30,30,730,20>CQ CQ CQ DE VK9JS K
    <10,18,850>VK9JS DE W1AW W1AW K
    <30,30,730,20>W1AW DE VK9JS UR 579 3096 #

    • The first and third lines are sent at 30 wpm, with an audio tone of 730Hz and with a 20ms rise time wave form that simulates a DX station with a "ringing" note.
    • The second line is sent at an average speed of 10 wpm, at a "Farnsworth" character speed of 18 wpm, and with a note frequence of 850Hz (0.120 kHz higher in frequency).

WAVGEN and Morse Academy Files

WAVGEN works with any text file, including those generated by Morse Academy, to produce audio WAV files. When using Morse Academy generated examination files for input, WAVGEN generates WAV files from the Morse Academy's KB files. It also generates HTML versions of the TST and KEY files for use in practice testing. These files are stored in the same directory (folder) as the input text files. Using the outputs from WAVGEN, it is possible to administer a test using only a web browser.

To administer a test from these files:

  1. Use the Browser File, Open Page command and select the WAV file you want to play, e.g. 1A-1.WAV. (use a file name of  *.WAV   to force the browser to display the names of non-HTML files). Press OK to play the test.

  2. After the test is played you can access the test paper by opening it in the browser, e.g. File, Open Page for the file 1A-TEST1.HTM. You can then take the test right off the screen, or print the test paper. If you print, set all margins to zero (Top, Bottom, Left and Right) and deselect all print options (Document Title, Document Location URL, Page Number, Page Total, and Date Printed).

  3. After taking the test, access the key to see the correct answers, e.g. open the file 1A-Key1.HTM


The WAV files generated are large. A single five minute WAV file is about 1.66 MB, too large to fit on a discette. But because of the regularity of the data generated, PKZIP compresses these WAV files by a factor of 225 or more. A 1.66 MB WAVGEN file becomes 7,320 bytes and can easily be written to a floppy, along with the HTML TST and KEY files. A complete set of ten MA generated tests is less than 100 KB, but expands back to 24 MB using PKUNZIP. Other file compression utilities have not been tested with WAVGEN files, but may perform as well.

If a ZIP file containing a compressed WAV file is directly accessed by a browser, and WINZIP is configured by the browser to process files having a ZIP extention (i.e. WINZIP has been installed on the PC), the user is given the opportunity to "open" the WAV file and play it immediately. WINZIP contains its own audio PLAYER to control playing WAV files. This makes it possible to save WAVGEN generated WAV files in PKZIP compressed format and never having to uncompress them. PKWARE products are available for download at http://pkware.com/.

By Joe Speroni