Page: 77/81 User Manual PSU-CTRL-2D, Rev.1-00: Software Interface
Function COM_HVPSU2D_GetProductID
int COM_HVPSU2D_GetProductID
(WORD PortNumber, char * Identification);
Command: P
©
Response: P
ii
..
i
©
Saves the device's product identification in the variable
Identifica-
tion
and returns an error code according to Tab. 10.
The return value in the variable
Identification
is a null-
terminated character string with the product identification. The buffer
passed to the function must be created before the function call; it
should be 60 characters long.
The response to the direct command (
P
©
) contains a variable number
of characters (
ii
..
i
) for the variable
Identification
. Note that
the termination character of the string is not transmitted.
Function COM_HVPSU2D_GetUptime
int COM_HVPSU2D_GetUptime (WORD PortNumber,
DWORD & Seconds, WORD & Milliseconds,
DWORD & Optime);
Command: U
©
Response: U
SSSSSSSSMMOOOOOOOO
©
Saves the device uptime in the variables
Seconds
and
Millisec-
onds
, and the operating time in the variable
Optime
. The function re-
turn value is an error code according to Tab. 10.
The device uptime is the time elapsed from the last (re)start of the de-
vice, the operating time is the portion of the uptime in which the device
was activated. The function
can be used,
for instance, to see whether the device has restarted unexpectedly or
to check how long it has been operating.
The response to the direct command (
U
©
) contains 8 hexadecimal
digits (
SSSSSSSS
) for the variable
Seconds
, 2 hexadecimal digits
(
MM
) for the variable
Milliseconds
, and 8 hexadecimal digits
(
OOOOOOOO
) for the variable
Optime
. To convert the value of the vari-
CGC Instruments
Tel.: +49 (371) 355 098–55
Hübschmannstr. 18 | D–09112 Chemnitz
Fax: +49 (371) 355 098–60
internet: www.cgc-instruments.com
e–mail: [email protected]