Using PC soundcards as PR modems |
|
This document describes software and hardware installation of Thomas Sailers Soundmodem modules for PC/FlexNet under Windows95 Contents
Introduction
PC/FlexNet allows standard PC soundcards to be used as Packet Radio modems. Different modulation formats are realised in software. Advantages of the software solution
But there's no such thing as a free lunch. A few disadvantages should not be left unmentioned.
Features/Requirements
Preparing Windows95
It would have been too easy if the standard Windows sound drivers could have been used for the purpose. But unfortunately, this is not possible. Using a soundcard as a packet radio modem requires very low latencies. The data must not pass through a buffer which delays it for several seconds. This would render any channel access algorithm useless. DirectSound has been developed to provide low latency output for games. Gamers want to hear the burst and the flash of the missile detonnating at the same time. But unfortunately, sound or voice input is uncommon for games, so DirectSound does not, as far as I could find documentation, support sound input. The design philosophy of PC/FlexNet was to have as few differences between the DOS and the Windows version apparent for the user. In addition, almost all soundcards are either Soundblaster or WSS compatible, but many only after they have been initialized with a very proprietary tool from the soundcard manufacturer. Practical and legal consideration prevent the FlexNet driver from including these routines. These reasons exclude the use of a PnP (Plug and Play or better Plug and Pray) driver. Both the Windows system sound drivers and the PC/FlexNet soundcard packet radio driver access the same hardware. To prevent conflicts, the windows drivers should be turned off whenever you want to do packet radio. A convenient way is to use multiple hardware profiles. The following list shows the steps how to do this:
The next time you reboot Windows, it presents the following menu: Windows 95 is starting... Loading PC/FlexNet
One design goal of PC/FlexNet was to hide most of the differences of the Windows and DOS versions from the user. Loading the PC/FlexNet drivers therefore takes place the same way under both DOS and Windows95. If you are using Windows95, you need to boot the command line first. To do this:
Some soundcards require a vendor specific tool to initialize the card. This must happen before PC/FlexNet is loaded. PnP soundcards must have resources allocated. This is best done with an utility provided by the soundcard vendor. For example, Soundblaster 16 PnP and Vibra16 chips can be configured using the DIAGNOSE.EXE /s utility or cards containing a Crystal CS423x chip are setup using the CS4232C.EXE program. Some modern BIOS may also configure ISA PnP cards. My AWARD BIOS does this, but unfortunately I know of no method to display the resource allocation done by the BIOS. This renders the method useless. A third possibility is to use a general purpose ISA configuration utility such as Intel's ICU. However these programs are complicated to use and to set up, so their use is justified only if everything else fails. FlexNet's soundcard modem drivers consist of several modules. The modules SMSBC, SMSBCFDX, SMWSS and SMWSSFDX drive the soundcards, while the modules SMAFSK12 and SMFSK96 implement the modem code. The soundcard drivers need to be loaded before FLEX, the modem modules after FLEX. An example loading sequence looks like this: LH FLEXNET LH SMSBC -tc:1 FLEX LH SMAFSK12 FSET MODE 0 1200 FSET TXDELAY 0 20 SMMIXER -i:0 -o:0 -s:line This sequence starts PC/FlexNet with driver support for a soundblaster compatible card and 1200 baud AFSK. The -tc:1 switch tells the driver to output the PTT signal on the COM1 port. Please refer to the apropriate .DOC file (mainly FLEXNET.DOC and SM.DOC included in the archives) for a list of supported command line switches. SMMIXER configures the audio input and output levels and sources. Now PC/FlexNet is set up and running, and you should verify with a terminal program such as bct if everything works ok. There is no point in starting Windows if it does not work now! If it does not work, recheck the resource settings, especially IRQ and DMA numbers. Also try to swap the DMA numbers if you are using a fullduplex driver. Windows95 may now be started using WIN. The files FLEXNET.VXD and VSMD.VXD need to be in the same directory as the other FlexNet files. FlexNet automatically notices the startup of Windows and adapts itself to the changing environment. After the graphical FlexNet administration tool has started up, the soundcard driver is ready again. The diagnostic tools SMMIXER and SMDIAG can be used the same way in a Windows DOS box as under plain old DOS. The "Device Manager" marks the deactivated Windows drivers by a red cross (see above). If you have forgotten to deactivate a driver, the error message looks like the one in the pictures below. You should deactivate these drivers. Automating the startup
The procedure described above looks quite longish. Of course you may write the necessary commands in a batch file. An elegant method is to use a startup menu in CONFIG.SYS. The example below shows how this works. The [menu] section contains the menu items. The first parameter of the menuitem command specifies which section contains the commands belonging to this menu, and the second parameter sets the name which appears in the menu. If this "long" name matches the name of a hardware profile and if this profile is selected, the menu item is automatically selected without displaying a menu. The [common] section contains the programs that are to be loaded regardless of the menu item selected. The previous contents of CONFIG.SYS belong there. [menu] menuitem=std,Ausgangskonfiguration menuitem=pcfsm,Ohne Soundkartentreiber [common] rem start of previous contents of CONFIG.SYS rem for example: device=c:\windows\himem.sys dos=high,umb country=041,850,c:\windows\command\country.sys device=c:\windows\command\emm386.exe noems rem end of previous contents of CONFIG.SYS (just an example!!) [std] [pcfsm] installhigh=C:\PCF\FLEXNET.EXE installhigh=C:\PCF\SMSBC.EXE -b:0x220 -i:5 -d:1 -tc:1 installhigh=C:\PCF\FLEX.EXE installhigh=C:\PCF\SMAFSK12.EXE installhigh=C:\PCF\FSET.EXE MODE 0 1200 installhigh=C:\PCF\FSET.EXE TXDELAY 0 20 installhigh=C:\PCF\SMMIXER.EXE -i:0 -o:0 -s:line The chosen menu item may also be queried in AUTOEXEC.BAT. The environment variable CONFIG contains the (short) name of the chosen configuration. The example below, appended to AUTOEXEC.BAT, starts Windows automatically if the hardware profile "Ohne Soundkartentreiber" was chosen. rem ... previous contents of AUTOEXEC.BAT Connecting the transceiver
PC soundcards normally do not contain DC coupled outputs which could serve as a PTT signal. Therefore, connecting PTT to the transceiver is not quite straight forward. Several people expressed their uncertainty how to do this, so I collected a few example schematic diagrams on how to do this. The soundcard modem drivers offer four different possibilities on how to output PTT: PTT keying using a COM port
PTT keying using a LPT port
PTT keying using the game port
This solution only works with MPU-401 compatible MIDI ports. The MIDI port of old soundblasters cannot be used. PTT keying using a VOX circuitry
This solution is not recommended for 9600 baud operation. The circuit requires high audio drive levels not every soundcard is able to produce. |