Pico TC08 USB THERMOELEMENT DATA LOGGER PP222 Manual Do Utilizador

Códigos do produto
PP222
Página de 42
USB TC-08 Help
21
Copyright 2004 Pico Technology Limited. All rights reserved.
This routine gets the unit information and copies it to the  USBTC08_INFO structure, declared in the
usbtc08.h header file. If zero is passed to the function as the handle, only the driver version member will
be valid, but the function will return 1 (success.)
Arguments:
handle
- Specifies the TC-08 unit.
info
- A pointer to a structure containing unit information.
Returns:
0
- Use 
1
- Routine was successful.
3.3.2.9
usb_tc08_get_formatted_info
short usb_get_formatted_info ( short handle,
char * unit_info,
short string_length)
This function is similar to the 
 routine, however, the unit information is returned in the
form of a formatted character string. The string is separated into the following elements, each
appearing on a different line: driver version; hardware version; variant info; serial number; calibration
date.
Arguments:
handle
- Specifies the USB TC-08 unit.
unit_info
- A string where the unit info is to be placed.
string_length
- Length of the string to be copied. Should be at least 256
(USBTC08_MAX_INFO_CHARS) characters long.
Returns:
0
- Too many bytes to copy, will copy as many full lines as
possible.
1
- Routine was successful.
3.3.2.10 usb_tc08_get_last_error
short usb_tc08_get_last_error (short handle)
This routine returns the last error for the unit specified by handle. If zero is passed instead of a handle,
the function returns the error associated with the last call to 
 or
.
Note: If an invalid handle is passed to a function, the function will fail. The error code, however, cannot
be associated with a unit so  usb_tc08_get_last_error will not retain an error code in this
instance. usb_tc08_get_last_error will also fail if the invalid handle is passed to it.
The error codes, also found in the C header file, are as follows: