Getting Started on Programming the HP 4155A/4156A
Programming for Data Extraction
Transferring Specic HP 4155/56 Data to a File
To transfer data from the HP 4155A/56A to a le, do as follows:
1. Create a data le.
You can create three types of data les: DOS, LIF ASCII, or BDATas
follows:
CREATE "data_file",1 ! Creates a DOS file.
CREATE ASCII "ascii_file",100 ! Creates a LIF ASCII file.
CREATE BDAT "binary_file",100 ! Creates a BDAT file.
DOS les are compatible with MS-DOS, which are easy to transfer to PCs
and other computers.
LIF ASCII les are compatible with HP computers that support this le
type, so this type is best is you are transferring les among HP computers
that support this le type.
BDAT (binary data) les provide more exibility (can specify both number
of records and record length) and faster transfer rate
. But BDAT les
cannot be interchanged with as many other systems.
The rst parameter of each statement species the le name to create
.
The second parameter species number of records to allocate for the le as
follows:
DOS Second parameter species how many records are to
be
initially
allocated for the le. A DOS le system
automatically allocates additional space for the le as new
data is written to it, so you can always specify
1
for this
parameter.
LIF ASCII Second parameter species
total
number of records to
allocate for the le, so you must specify a sucient
number of records. The length of one record is 256 bytes.
For example, the following statement would create a le
with 100 records (each record is 256 bytes):
CREATE ASCII "File",100
3-18