GxDmmGetErrorString

Purpose

Returns the error string associated with the specified error number

Syntax

GxDmmGetErrorString (nError, pszMsg, nErrorMaxLen, pnStatus)

Parameters

Name
Type
Comments
nError
SHORT
Error number.
pszMsg
PSTR
Buffer to the returned error string.
nErrorMaxLen
SHORT
The size of the error string buffer.
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

The function returns the error string associated with the nError as returned from other driver functions.

The following table displays the possible error values; not all errors apply to this board type:

Resource Errors
0
No error has occurred
-1
Unable to open the HW driver. Check if HW is properly installed
-2
Unable to open the HW driver. Check if HW is properly installed
-3
Different board exist in the specified PCI slot/base address
-4
PCI slot not configured properly. You may configure using the PciExplorer from the Windows Control Panel
-5
Unable to register the PCI device
-6
Unable to allocate system resource for the device
-7
Unable to allocate memory
-8
Unable to create panel
-9
Unable to create Windows timer
-10
Bad or Wrong board EEPROM
-11
Not in calibration mode
-12
Board is not calibrated
-13
Function is not supported by the specified board
General Parameter Errors
-20
Invalid or unknown error number
-21
Invalid parameter
-22
Illegal slot number
-23
Illegal board handle
-24
Illegal string length
-25
Illegal operation mode
-26
Parameter is out of the allowed range
-30
Unable to Load VISA32/64.DLL, make sure VISA library is installed
-31
Unable to open default VISA resource manager, make sure VISA is properly installed
-32
Unable to open the specified VISA resource
-33
VISA viGetAttribute error
-34
VISA viInXX error
-35
VISA ViMapAddress error
-37
Unable to create synchronization object
-38
This function is not available under LabView/Real-Time
-39
Unable to lock a board resource, resource is used by another process or thread
-40
Unable to execute this function. The function requires special license to be installed
Board Specific Errors
-90
Reading Aborted
-91
Could not start a new reading because board is busy
-92
DAQ was passed an invalid array
-93
Buffer pointer is past the number captured
-94
Buffer is empty
-95
Min/max has not been set yet
-96
The previous data was not read and has been overwritten
-97
Unspecified General Warning
-101
Unspecified General Error
-102
One or more of the parameter values is bad
-103
SPI is busy
-104
Not Found
-105
Internal Error Timer by name
-106
Function is not supported
-107
Failed to alter the state of the timer
-108
Device is Busy
-109
A read operation encountered an unspecified error
-110
The flash failed, did not come out of self timed operation
-111
The flash failed, did not come out of self timed operation
-112
The Measurement Board failed to return the serial clock, not present
-113
The embedded controller has timed out
-114
Exceeded end of buffer
-115
The flash signature of the calibration sector was bad
-116
Invalid Calibration Set Header Checksum
-117
The selected calibration set does not exist in the flash
-120
Software Generated Timeout
-121
Communication Error
-122
Invalid Function Selection
-123
Invalid Range Selection
-124
Invalid Resolution Selection
-125
Invalid Trigger Reading Selection
-126
Invalid Trigger Timer Rate Selection
-127
Invalid Trigger Timer Rate Selection
-128
Invalid DAQ Buffer Count Selection
-129
Invalid HIRES Buffer Pointer Selection
-130
Invalid HIRES Buffer Pointer Selection
-131
Invalid Aperture Selection
-132
Invalid DAQ Math Type Selection
-133
Invalid Calibration Selection
-134
Invalid Calibration Selection
-135
Invalid Calibration Set Selection
-136
Invalid Minimum AC Frequency
-137
No calibration license installed
-138
Invalid AC Line Frequency Selection
-139
Invalid Digitizer Clock Divisor Selection
-140
Invalid Buffer Type
-141
Controller Timeout
-142
No Calibration Found In EEPROM
-143
Invalid Auto Zero Mode Selection
-200
Failed Memory Data Test
-201
Failed Memory Address Test
-202
Failed 16-bit or 8-bit Access Test
-203
Failed bit Access Test
Board Specific Warnings
100
Warning Overflow has Occurred
101
Warning Reading Aborted

 

Example

The following example initializes the board. If the initialization failed, the following error string is printed:

 

CHAR sz[256];

SHORT nStatus, nHandle;

GxDmmInitialize (3, &Handle, &Status);

if (nStatus<0)

{

GxDmmGetErrorString(nStatus, sz, sizeof sz, &nStatus);

printf(sz); // prints the error string returns

}

 

See Also

GxDmmInitialize, GxDmmInitializeVisa, GxDmmReset, GxDmmGetBoardSummary