API Functions
28
Copyright © 2006–2022 Pico Technology Ltd. All rights reserved.
ps2000pg.en-12
PicoScope 2000 Series Programmer's Guide
5.8
ps2000_get_unit_info
int16_t ps2000_get_unit_info
(
int16_t handle,
int8_t *string,
int16_t string_length,
int16_t line
)
This function writes oscilloscope information to a character string. If the oscilloscope failed to
open, only
line
types 0 and 6 are available to explain why the last open unit call failed.
Applicability
All modes
Arguments
handle
: the handle of the oscilloscope from which information is required.
If an invalid handle is passed, the error code from the last oscilloscope that
failed to open is returned.
string
: a pointer to the character string buffer in the calling function where
the function will write the oscilloscope information string selected with
line
.
If string is
NULL,
no information will be written.
string_length
: the length of the character string buffer. If the string is
not long enough to accept all of the information, only the first
string_length
characters are returned.
line
: a value selected from enumerated type
PS2000_INFO
(see table
below) specifying what information is required from the driver
Returns
The length of the string written to the
string
buffer
0: if one of the parameters is out of range or string is NULL
PS2000_INFO
value
Example
PS2000_DRIVER_VERSION (0),
the version number of the DLL
used by the oscilloscope driver.
"1, 0, 0, 2"
PS2000_USB_VERSION (1),
the type of USB connection that is
being used to connect the oscilloscope to the computer.
"1.1" or "2.0"
PS2000_HARDWARE_VERSION (2),
the hardware version of the
attached oscilloscope.
"1"
PS2000_VARIANT_INFO (3),
the variant of PicoScope 2000 PC
Oscilloscope that is attached to the computer.
"2203"
PS2000_BATCH_AND_SERIAL (4),
the batch and serial number of
the oscilloscope.
"CMY66/052"
PS2000_CAL_DATE (5),
the calibration date of the oscilloscope.
"14Jan08"
PS2000_ERROR_CODE (6),
one of the
.
"4"
PS2000_KERNEL_DRIVER_VERSION (7),
the version number of the
kernel driver.
"1,1,2,4"
Summary of Contents for PicoScope 2000 Series
Page 1: ...Programmer s Guide ps2000pg en 12 PC Oscilloscopes PicoScope 2000 Series ...
Page 2: ......
Page 67: ......