60 Pamux User’s Guide
USING THE PAMUX DRIVER UNDER DOS
INSTALLATION
The Pamux driver is provided on one disk. You should make a backup copy of this disk before installing
the driver. (For instructions on copying disks, refer to your DOS manual.)
The Pamux driver disk includes DOS and WIN directories. To use the driver under DOS, you will need to
copy the contents of the DOS directory to an appropriate directory on your hard drive.
For complete installation instructions, view the README.TXT file on the driver disk.
PAMUX DRIVER PARAMETERS
Every call to the Pamux driver must include five parameters. These parameters provide the driver with all
information needed to fully specify the command to be sent. Data and error codes are also passed back
to the application program through these parameters.
Below is an example of a call to the driver in a Microsoft Interpreted BASIC program:
CALL Pamux(ERRCOD%, ADDRESS%, COMMAND%, POSITION%, VALUE%(0))
All parameters passed to the driver must be 16-bit integers. Notice that all variable names in the
command above end with a percent sign (%). In BASIC, the % indicates that a variable is a 16-bit
integer.
The five Pamux parameters are:
1. ERRCOD — An integer variable that contains an error code. A value of zero returned in this
parameter indicates that no errors occurred and the command was successfully executed. A
value less than zero indicates that the driver detected an error and the command was not
executed. The value indicates the type of error encountered. For example, -1 represents
“Configuration Required,” indicating that a Pamux analog board has lost its configuration
due to a reset or a power loss.
2. ADDRESS — An integer variable that contains the address of the intended Pamux unit
(0–63 decimal).
3. COMMAND — An integer variable that contains the number of the desired command.
4. POSITION — An integer variable that contains either the module position or bank number to
be affected by the command. A bank is a group of eight positions. Each bank takes one
address position.
5. VALUE ARRAY — An eight-element integer array used to hold data values that help describe
the command’s execution. Also used to hold all returned data.
PROGRAMING WITH THE PAMUX DRIVER