ICS Advent PCI-DIO48 Series Product Manual page 23

Table of Contents

Advertisement

PCI-DIO48(S)(S) Manual
OutPort
Function:
Declaration:
Peek
Function:
Declaration:
Poke
Function:
Declaration:
Note that in all of the above functions, an inherent limitation of BASIC in general and
VisualBASIC in particular makes the values sent less intuitive. All integers in BASIC are signed
numbers, wherein data are stored in two's complement form. All bit patterns must be converted
to-and-from this two's complement form if meaningful display is required. Otherwise, values
returned from the InPortb function will be -128 to 127, rather than 0 to 255. An alternative is to
perform all assignments in hexadecimal, rather then decimal form.
Before the program will execute, the .GBL file must be modified to include the path to the
VBACCES.DLL as appropriate for your system. Merely replace the statement "VBACCES.DLL"
with "drive:path\VBACCES.DLL".
As an alternative to changing the source code, you can copy the VBACCES.DLL file into your
Windows directory. This will allow multiple programs to find the same .DLL without having to
know where it is located. Just leave off all references to a path in the .GBL file as shown in the
sample.
Page 5-4
Writes all 16 bits of value to the hardware port at address. This function returns
the value output.
function
OutPort(byval
value as integer) as integer
Reads a byte from main memory (DRAM).
function Peek(byval segment as integer, byval offset
as integer) as integer
Writes the lower eight bits of value to segment:offset.
function Poke(byval segment as integer, byval offset
as integer, byval value as integer) as integer
address
as
integer,
Manual 00650-529-1
byval

Advertisement

Table of Contents
loading

This manual is also suitable for:

Pci-dio48s seriesPci-dio48ss series

Table of Contents