Returns the error string associated with the specified error number.
GxFpgaGetErrorString (nError, pszMsg, nErrorMaxLen, pnStatus)
Name |
Type |
Comments |
nError |
SHORT |
Error number. |
pszMsg |
PSRT |
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. |
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:
0 |
No error has occurred. |
-1 |
Unable to open the HW driver. Check if HW is properly installed. |
-2 |
Board does not exist in this slot/base address. |
-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. |
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. |
VISA Errors
-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. |
Miscellaneous Errors
-41 |
Unable to enable interrupt or event. |
-42 |
Unable to disable interrupt or event. |
-43 |
Event or interrupt timeout. |
-44 |
Event or interrupt wait error. |
Board Specific Errors
-50 |
Offset is out of range. |
-51 |
File Name is not valid. |
-52 |
Programming file could not be opened. |
-53 |
User FPGA Volatile Programming error. |
-54 |
User FPGA EEPROM Programming error. |
-55 |
Cannot program through software, External Programmer Detected. |
-56 |
FPGA or EEPROM is currently being loaded and is busy. |
-57 |
FPGA could not be reloaded with the EEPROM data. |
-58 |
Size and Offset must be multiple of 4. |
-59 |
Expansion board required for function not found. |
The following example initializes the board. If the initialization failed, the following error string is printed:
CHAR sz[256];
SHORT nStatus, nHandle;
..
GxFpgaInitialize (3, &Handle, &Status);
if (nStatus<0)
{
GxFpgaGetErrorString(nStatus, sz, sizeof sz, &nStatus);
printf(sz); // prints the error string returns
}