
HLPRX_Errors HLPRX_ApiErrors[] = 
{
	{HLPRX_OK,															"HLPRX OK"},
	{RQ_InvalidCardNumber,												"Invalid cardIndex number"},
	{RQ_Initialise_AlreadyInitialised,									"RQ_Initialise fail: already initialised"},
	{RQ_Initialise_FindPCIDeviceFail,									"RQ_Initialise fail: PCIDeviceFind error"},
	{RQ_Initialise_PCIDeviceOpenFail,									"RQ_Initialise fail: PCIDeviceOpen error"},
	{RQ_Initialise_PCIBarMapFail,										"RQ_Initialise fail: PCIBarMap error"},
	{RQ_Initialise_PCICommonBufferPropertiesFail,						"RQ_Initialise fail: PCICommonBufferProperties error"},
	{RQ_Initialise_PCICommonBufferMapFail,								"RQ_Initialise fail: PCICommonBufferMap error"},
	{RQ_Initialise_SampleClockNotStabilised,							"RQ_Initialise fail: sample clock would not stablise"},
	{RQ_Calibrate_OffsetComputationFail,								"RQ_Calibrate fail: offset computation fail"},
	{RQ_Calibrate_GainComputationFail,									"RQ_Calibrate fail: gain computation fail"},
	{RQ_Uninitialise_IsInitialisedFail,									"RQ_Uninitialise fail not initialised"},
	{RQ_Uninitialise_IsPCIInitialisedFail,								"RQ_Uninitialise fail: PCI not initialised"},
	{RQ_Uninitialise_PCIBarUnmapFail,									"RQ_Uninitialise fail: PCIBarUnmap error"},
	{RQ_Uninitialise_PCIDeviceCloseFail,								"RQ_Uninitialise fail: PCIDeviceClose error"},
	{RQ_OpenDMAChannel_IsPCIInitialisedFail,							"RQ_OpenDMAChannel fail: PCI not initialised"},
	{RQ_OpenDMAChannel_DMAChannelAlreadyOpen,							"RQ_OpenDMAChannel fail: DMA channel already open"},
	{RQ_OpenDMAChannel_PCIDmaBlockChannelOpenFail,						"RQ_OpenDMAChannel fail: PCIDmaBlockChannelOpen error"},
	{RQ_CloseDMAChannel_IsPCIInitialisedFail,							"RQ_CloseDMAChannel fail: PCI not initialised"},
	{RQ_CloseDMAChannel_IsDMAChannelOpenFail,							"RQ_CloseDMAChannel fail: DMA channel not open"},
	{RQ_CloseDMAChannel_PCIDmaBlockChannelCloseFail,					"RQ_CloseDMAChannel fail: PCIDmaBlockChannelClose error"},
	{RQ_PerformDMATransfer_IsPCIInitialisedFail,						"RQ_PerformDMATransfer fail: PCI not initialised"},
	{RQ_PerformDMATransfer_IsDMAChannelOpenFail,						"RQ_PerformDMATransfer fail: DMA channel not open"},
	{RQ_PerformDMATransfer_PCIDmaBlockTransferFail,						"RQ_PerformDMATransfer fail: PCIDmaBlockTransfer error"},
	{RQ_DumpBinFiles_SamplingFirmwareOpenFail,							"RQ_DumpBinFiles fail: could not open sampling firmware file"},
	{RQ_DumpBinFiles_PeripheralFirmwareOpenFail,						"RQ_DumpBinFiles fail: could not open peripheral firmware file"},
	{RQ_DumpBinFiles_SamplingFirmwareReadFail,							"RQ_DumpBinFiles fail: could not read sampling firmware file"},
	{RQ_DumpBinFiles_SamplingFirmwareCloseFail,							"RQ_DumpBinFiles fail: could not close sampling firmware file"},
	{RQ_DumpBinFiles_PeripheralFirmwareReadFail,						"RQ_DumpBinFiles fail: could not read peripheral firmware file"},
	{RQ_DumpBinFiles_PeripheralFirmwareCloseFail,						"RQ_DumpBinFiles fail: could not close peripheral firmware file"},
	{RQ_SetSamplingFrequency_InvalidFrequency,							"RQ_SetSamplingFrequency fail: invalid sampling frequency (must be between 40-100MHz)"},
	{RQ_GetSamples_QueryTimerFail,										"RQ_GetSamples fail: timer could not be queried"},
	{RQ_GetSamples_MissingTrigger,										"RQ_GetSamples fail: trigger not present (use RQ_SetForceAScanTrigger or supply external trigger"},
	{RQ_GetSamples_DataFull,											"RQ_GetSamples fail: data full error (select alternative storage mode or reduce scan size parameters)"},
	{RQ_GetSamples_TriggerOccurredBeforeProcessComplete,				"RQ_GetSamples fail: new trigger occurred before sampling complete (use RQ_SetRepetitionRate with reduced parameter)"},
	{RQ_GetSamples_SampleIncomplete,									"RQ_GetSamples fail: sampling started but did not finish"},
	{RQ_GetSamples_TimeOut,												"RQ_GetSamples fail: polling time-out, samples are not available"},
	{RQ_GetSamples_PerformDMATransferFail,								"RQ_GetSamples fail: DMA transfer fail"},
	{RQ_GetSamples_InvalidHeader,										"RQ_GetSamples fail: invalid sample data header"},
	{RQ_SetRegister_IsPCIInitialisedFail,								"RQ_SetRegister fail: PCI not initialised"},
	{RQ_SetRegister_OffsetOutOfRange,									"RQ_SetRegister fail: offset out of range"},
	{RQ_GetRegister_IsPCIInitialisedFail,								"RQ_GetRegister fail: PCI not initialised"},
	{RQ_GetRegister_OffsetOutOfRange,									"RQ_GetRegister fail: offset out of range"},
	{RQ_SetSystemRegister_OutOfRange,									"RQ_SetSystemRegister fail: offset out of range"},
	{RQ_GetSystemRegister_OutOfRange,									"RQ_GetSamplingRegister fail: offset out of range"},
	{RQ_SetSamplingRegister_OutOfRange,									"RQ_SetSamplingRegister fail: offset out of range"},
	{RQ_GetSamplingRegister_OutOfRange,									"RQ_GetSamplingRegister fail: offset out of range"},
	{RQ_SetPeripheralRegister_OutOfRange,								"RQ_SetPeripheralRegister fail: offset out of range"},
	{RQ_GetPeripheralRegister_OutOfRange,								"RQ_GetPeripheralRegister fail: offset out of range"},
	//{RQ_GetFPGAPairChipSelectInvalidData,								"RQ_GetFPGAPairChipSelect fail: invalid FPGA pair data"},
	{RQ_GetSamplingSystemIRQFlag_InvalidSamplingSystemIndex,			"RQ_GetSamplingSystemIRQFlag fail: invalid sampling system index (must be 0)"},
	{RQ_SetCurvedGateData_InvalidFirmwareVersion,						"RQ_SetCurvedGateData fail: invalid firmware version"},
	{RQ_SetCurvedGateData_InvalidThresholdValue,						"RQ_SetCurvedGateData fail: invalid threshold value (must be 0 to 2047)"},
	{RQ_GetNumberOfBScansInSRAM_NoDataAvailable,						"RQ_GetNumberOfBScansInSRAM fail: no sample data available"},
	{RQ_SetRectifierMode_InvalidMode,									"RQ_SetRectifierMode fail: invalid mode (must be a member if RQ_Rectification enumerated type)"},
	{RQ_SetStartDelay_InvalidDelay,										"RQ_SetStartDelay fail: invalid start delay (must be 0 to RQ_SRAM_MAXIMUM_START_DELAY)"},
	{RQ_SetTriggerSelect_InvalidTrigger,								"RQ_SetTriggerSelect fail: invalid trigger (must be a member of RQ_Trigger enumerated type"},
	{RQ_SetNumberOfSamples_InvalidNumberOfSamples,						"RQ_SetNumberOfSamples fail: invalid number of samples (must be 0 to RQ_SRAM_MAXIMUM_NUMBER_OF_SAMPLES)"},
	{RQ_SetDropNumberOfSamples_InvalidNumberOfSamples,					"RQ_SetDropNumberOfSamples fail: invalid number of drop samples (must be 0 to 15)"},
	{RQ_SetSampleStorageMode_InvalidStorageMode,						"RQ_SetSampleStorageMode fail: invalid storage mode (must be a member of RQ_SampleSize enumerated type)"},
	{RQ_SetForceAScanTrigger_InvalidTriggerSource,						"RQ_SetForceAScanTrigger fail: invalid trigger locale (must be internal)"},
	{RQ_SetDDSRegister_InvalidRegisterValue,							"RQ_SetDDSRegister fail: invalid register value (must be 0 to 255)"},
	{RQ_SetDDSRegister_InvalidAddressBusValue,							"RQ_SetDDSRegister fail: invalid address bus value (must be 0 to 63)"},
	{RQ_DDSWait_QueryTimerFail,											"RQ_DDSWait fail: timer could not be queried"},
	{RQ_DDSWait_TimeOut,												"RQ_DDSWait fail: polling time-out"},
	{RQ_SetTCGTriggerGate_InvalidGateIndex,								"RQ_SetTCGTriggerGate fail: invalid gate index (must be a member of RQ_TCGTriggerEvent enumerated type"},
	{RQ_SetTCGEnable_InvalidFlag,										"RQ_SetTCGEnable fail: invalid flag (must be a member of NDTS_Boolean enumerated type)"},
	{RQ_SetTCGEnable_NoTCGCurve,										"RQ_SetTCGEnable fail: no TCG curve has been programmed"},
	{RQ_GetTCGTriggerGate_InvalidTriggerFlags,							"RQ_GetTCGTriggerGate fail: invalid gate index flags"},
	{RQ_SetIsSampleDataAvailable_InvalidAvailableValue,					"RQ_SetIsSampleDataAvailable fail: invalid available value (must be a member of NDTS_Boolean enumerated type)"},
	{RQ_SetRequestEarlySampleData_NoSampleData,							"RQ_SetRequestEarlySampleData fail: no sample data available"},
	{RQ_SetCScanBaseSRAMAddress_InvalidAddress,							"RQ_SetCScanBaseSRAMAddress fail: invalid address (must be 0 to RQ_SYSTEM_RAM_OFFSET - 4 and multiple of 4)"},
	{RQ_SetScanStorageOptions_InvalidStorageOptions,					"RQ_SetScanStorageOptions fail: invalid storage options (must be a member of RQ_ScanStorage enumerated type)"},
	{RQ_SetNumberOfBScansPerBank_InvalidNumber,							"RQ_SetNumberOfBScansPerBank fail: invalid number of scans (must be 1 to RQ_SRAM_MAXIMUM_NUMBER_OF_BSCANS)"},
	{RQ_SetNumberOfAScansPerBScan_InvalidNumber,						"RQ_SetNumberOfAScansPerBScan fail: invalid number of scans (must be 1 to RQ_SRAM_MAXIMUM_NUMBER_OF_ASCANS_PER_BSCAN)"},
	{RQ_SetTCGValues_InvalidNumberOfValues,								"RQ_SetTCGValues fail: invalid number of values (must be 0 to RQ_MAXIMUM_NUMBER_OF_TCG_VALUES)"}, 
	{RQ_SetTCGValues_InvalidValue,										"RQ_SetTCGValues fail: invalid value (must be 0 to 255)"},
	{RQ_SetInputCoupling_InvalidCoupling,								"RQ_SetInputCoupling fail: invalid input coupling (must be a member of RQ_InputCoupling enumerated type)"},
	{RQ_SetInputImpedance_InvalidInputImpedance,						"RQ_SetInputImpedance fail: invalid input impedance (must a member of RQ_InputImpedance enumerated type)"},
	{RQ_SetAnalogueInput_InvalidAnalogueInput,							"RQ_SetAnalogueInput fail: invalid analogue input (must a member of RQ_AnalogueInput enumerated type)"},
	{RQ_GetAnalogueInput_InvalidInputFlags,								"RQ_GetAnalogueInput fail: analogue input flags"},
	{RQ_SetAnalogueInputRange_InvalidAnalogueGain,						"RQ_SetAnalogueInputRange fail: invalid analogue gain (must be a member of RQ_AnalogueInputRange enumerated type)"},
	{RQ_SetAnalogueInputRange_InvalidGainFlags,							"RQ_SetAnalogueInputRange fail: invalid analogue gain flags"},
	{RQ_SetAToDOutputPortFormat_InvalidPortFormat,						"RQ_SetAToDOutputPortFormat fail: invalid output port format (must be 0 or 1)"},
	{RQ_SetAToDOutputDataFormat_InvalidDataFormat,						"RQ_SetAToDOutputDataFormat fail: invalid output data format (must be 0 or 1)"},
	{RQ_SetAToDInputVoltageRange_InvalidInputVoltageRange,				"RQ_SetAToDInputVoltageRange fail: invalid input voltage range (must be 0 or 1)"},
	{RQ_SetAToDVrefInputCharacteristics_InvalidInputCharacteristics,	"RQ_SetAToDVrefInputCharacteristics fail: invalid Vref input characteristics (must be 0 or 1)"},
	{RQ_SetDDSKEY_InvalidDDSKEY,										"RQ_SetDDSKEY fail: invalid DDSKEY (must be 0 or 1)"},
	{RQ_SetDDSKEY_InvalidDDSFSK,										"RQ_SetDDSFSK fail: invalid DDSFSK (must be 0 or 1)"},
	{RQ_SetCalibrationVoltage_InvalidCalibrationVoltage,				"RQ_SetCalibrationVoltage fail: invalid calibration voltage (must be a member of RQ_CalibrationVoltage enumerated type"},
	{RQ_SetAuxInput_InvalidAuxInput,									"RQ_SetAuxInput fail: invalid calibration voltage (must be 0 to 3)"},
	//{RQ_SetDynamicImagingDataInvalidData,								"RQ_SetDynamicImagingData fail: invalid data (must be 0 to 255)"},
	//{RQ_SetDynamicImagingDSELECTInvalidDSELECT,						"RQ_SetDynamicImagingDSELECT fail: invalid DSELECT (must be 0 or 1)"},
	//{RQ_SetDynamicImagingAPERInvalidAPER,								"RQ_SetDynamicImagingAPER fail: invalid APER (must be 0 to 3)"},
	//{RQ_SetDynamicImagingDATACLKInvalidDATACLK,						"RQ_SetDynamicImagingDATACLK fail: invalid DATACLK (must be 0 or 1)"},
	{RQ_SetTransducerPulseWidth_InvalidFirmwareVersion,					"RQ_SetTransducerPulseWidth fail invalid firmware version"},
	{RQ_SetTransducerPulseWidth_InvalidWidth,							"RQ_SetTransducerPulseWidth fail: invalid pulse width (must be 0 to RQ_MAXIMUM_GENERATOR_PULSE_LENGTH)"},
	{RQ_GetTransducerPulseWidth_InvalidFirmwareVersion,					"RQ_GetTransducerPulseWidth fail invalid firmware version"},
	{RQ_SetCalibrationOffset_InvalidDToAWord,							"RQ_SetCalibrationOffset fail: invalid D to A word (must be 0 to 4095)"},
	{RQ_SetCalibrationOffset_TimerFail,									"RQ_SetCalibrationOffset fail:  timer could not be queried"},
	{RQ_SetCalibrationOffset_TimeOut,									"RQ_SetCalibrationOffset fail: polling time-out"},
	{RQ_SetCalibrationGain_InvalidDToAWord,								"RQ_SetCalibrationGain fail: invalid D to A word (must be 0 to 4095)"},
	{RQ_SetCalibrationGain_TimerFail,									"RQ_SetCalibrationGain fail:  timer could not be queried"},
	{RQ_SetCalibrationGain_TimeOut,										"RQ_SetCalibrationGain fail: polling time-out"},
	{RQ_SetCalibrationDToADestination_InvalidDestination,				"RQ_SetCalibrationDToADestination fail: invalid D to A destination (must be 0 to 3)"},
	{RQ_SetNumberOfPeriodsBetweenAScanTriggers_InvalidNumberOfPeriods,	"RQ_SetNumberOfPeriodsBetweenAScanTriggers fail: invalid number of periods (must be 1 to 131072)"},
	{RQ_SetNumberOfAScansToInterleave_InvalidNumberToInterleave,		"RQ_SetNumberOfAScansToInterleave fail: invalid number of A-scans to interleave (must be 0 to 3)"},
	{RQ_SetSensorArrayNumberOfElements_InvalidNumberOfElements,			"RQ_SetSensorArrayNumberOfElements fail: invalid number of elements (must be 1 to 128)"},
	{RQ_SetSensorArrayApertureSize_InvalidApertureSize,					"RQ_SetSensorArrayApertureSize fail: invalid aperture size (must be a member of RQ_ApertureSize enumerated type"},
	{RQ_SetSensorArrayDIUnitEnableOutputs_InvalidFirmwareVersion,		"RQ_SetSensorArrayDIUnitEnableOutputs fail: invalid firmware version"},
	{RQ_SetSensorArrayDIUnitEnableOutputs_InvalidEnableFlag,			"RQ_SetSensorArrayDIUnitEnableOutputs fail: invalid flag (must be a member of NDTS_Boolean enumerated type"},
	{RQ_GetSensorArrayDIUnitEnableOutputs_InvalidFirmwareVersion,			"RQ_GetSensorArrayDIUnitEnableOutputs fail: invalid firmware version"},
	{RQ_SetSensorArrayDisableAperturePositionWrites_InvalidFirmwareVersion,	"RQ_SetSensorArrayDisableAperturePositionWrites fail: invalid firmware version"},
	{RQ_SetSensorArrayDisableAperturePositionWrites_InvalidEnableFlag,	"RQ_SetSensorArrayDisableAperturePositionWrites fail: invalid disable flag (must be a member of NDTS_Boolean enumerated type)"},
	{RQ_GetSensorArrayDisableAperturePositionWrites_InvalidFirmwareVersion, "RQ_GetSensorArrayDisableAperturePositionWrites fail: invalid firmware version"},
	{RQ_SetSensorArrayDisableApertureDelayWrites_InvalidFirmwareVersion,	"RQ_SetSensorArrayDisableApertureDelayWrites: invalid firmware version"},
	{RQ_SetSensorArrayDisableApertureDelayWrites_InvalidEnableFlag,		"RQ_SetSensorArrayDisableApertureDelayWrites fail: invalid disable flag (must be a member of NDTS_Boolean enumerated type)"},
	{RQ_GetSensorArrayDisableApertureDelayWrites_InvalidFirmwareVersion,	"RQ_GetSensorArrayDisableApertureDelayWrites fail: invalid firmware version"},
	{RQ_SetIsBScanModeEnabled_InvalidFirmwareVersion,					"RQ_SetIsBScanModeEnabled fail: invalid firmware version"},
	{RQ_SetIsBScanModeEnabled_InvalidFlag,								"RQ_SetIsBScanModeEnabled fail: invalid flag (must be a member of NDTS_Boolean enumerated type)"},
	{RQ_SetPingPongSequenceElement_InvalidElementNumber,				"RQ_SetPingPongSequenceElement fail: invalid element number (must be 0 to 255)"},
	{RQ_SetPingPongSequenceElement_InvalidSequencePosition,				"RQ_SetPingPongSequenceElement fail: invalid sequence position (must be 0 to 127)"},
	//{RQ_SetPingPongSequenceElementBScanModeEnabled,					"RQ_SetPingPongSequenceElement fail: B-scan mode is enabled (must be disabled)"},
	{RQ_SetNumberOfEncoderClicksPerBScan_InvalidNumberOfClicks,			"RQ_SetNumberOfEncoderClicksPerBScan fail: invalid number of clicks (must be 1 to 65536)"},
	{RQ_SetForceBScanTrigger_InvalidTriggerSource,						"RQ_SetForceBScanTrigger fail: invalid trigger locale (must be internal)"},
	{RQ_SetEncoderSelect_InvalidEncoderIndex,							"RQ_SetEncoderSelect fail: invalid encoder index (must be 0 to 5)"},
	{RQ_SetResetEncoderOutput_InvalidEncoderIndex,						"RQ_SetResetEncoderOutput fail: invalid encoder index (must be 0 to 5)"},
	{RQ_GetEncoderOutput_InvalidEncoderIndex,							"RQ_GetEncoderOutputInvalidEncoderIndex fail: invalid encoder index (must be 0 to 5)"},
	{RQ_AddGate_InvalidStartCount,										"RQ_AddGate fail: invalid start count (must be -32764 to 32771)"},
	{RQ_AddGate_InvalidEndCount,										"RQ_AddGate fail: invalid end count (must be -32764 to 32771)"},
	{RQ_AddGate_InvalidThreshold,										"RQ_AddGate fail: invalid threshold (must be 0 to 2047)"},
	{RQ_AddGate_InvalidTriggerIndex,									"RQ_AddGate fail: invalid trigger gate (must be a member of RQ_GateTrigger enumerated type and not focus gate index)"},
	{RQ_AddGate_InvalidThresholdPolarity,								"RQ_AddGate fail: invalid threshold polarity (must be a member of RQ_GateThresholdPolarity enumerated type)"},
	{RQ_AddGate_InvalidTriggerMode,										"RQ_AddGate fail: invalid trigger mode (must be a member of RQ_GateTriggerMode enumerated type)"},
	{RQ_AddGate_InvalidDistanceMetric,									"RQ_AddGate fail: invalid distance metric (must be a member of RQ_GateDistanceMetric enumerated type)"},
	{RQ_AddGate_InvalidEnable,											"RQ_AddGate fail: invalid enable (must be a member of RQ_GateTriggerMode enumerated type)"},
	{RQ_AddGate_InvalidAmplitudePeakSelect,								"RQ_AddGate fail: invalid amplitude peak select (must be a member of RQ_GateAmplitudePeakSelect enumerated type)"},
	{RQ_AddGate_InvalidDistancePeakSelect,								"RQ_AddGate fail: invalid distance peak select (must be a member of RQ_GateDistancePeakSelect enumerated type)"},
	{RQ_AddGate_InvalidGateIndex,										"RQ_AddGate fail: invalid gate index (must be 0 to RQ_MAXIMUM_NUMBER_OF_GATES - 1"},
	{RQ_AddGate_QueryTimerFail,											"RQ_AddGate fail: timer could not be queried"},
	{RQ_AddGate_SetupTimeOut,											"RQ_AddGate fail: polling time-out"},
	{RQ_RemoveGate_InvalidIndex,										"RQ_RemoveGate fail: invalid gate index (must be member of RQ_GateIndex enumerated type)"},
	{RQ_RemoveGate_GateDoesNotExist,									"RQ_RemoveGate fail: gate does not exist"},
	{RQ_GetGate_InvalidIndex,											"RQ_GetGate fail: invalid index (must be a member of the RQ_GateIndex enumerated type"},
	{RQ_GetGateOutput_InvalidBScanIndex,								"RQ_GetGateOutput fail: invalid B-scan index (insufficient B-scans in memory)"},
	{RQ_GetGateOutput_InvalidAScanIndex,								"RQ_GetGateOutput fail: invalid A-scan index (insufficient A-scans per B-scan"},
	{RQ_GetGateOutput_GateIsNotPresent,									"RQ_GetGateOutput fail: invalid gate index (gate is not present"},
	{RQ_GetGateOutput_GateIsNotEnabled,									"RQ_GetGateOutput fail: invalid gate index (gate is not enabled"},
	{RQ_SetValue_InvalidPropertyName,									"RQ_SetValue fail: invalid property name (see documentation for valid strings)"},
	{RQ_LoadFPGAFromFile_ReadError,										"RQ_LoadFPGAFromFile fail: malformed settings file (missing value for property)"},
	{RQ_LoadFPGAFromFile_OversizedStringLength,							"RQ_LoadFPGAFromFile fail: oversized string length (line must be less than or equal to 512 characters)"},
	{RQ_LoadGatesFromFile_OversizedStringLength,						"RQ_LoadGatesFromFile fail: oversized string length (line must be less than or equal to 512 characters)"},
	{RQ_LoadGatesFromFile_ReadError,									"RQ_LoadGatesFromFile fail: cannot read from file"},
	{RQ_LoadTCGCurveFromFile_OversizedStringLength,						"RQ_LoadTCGCurveFromFile fail: oversized string length (line must be less than or equal to 512 characters)"},
	{RQ_LoadTCGCurveFromFile_InvalidTCGValue,							"RQ_LoadTCGCurveFromFile fail: invalid TCG value (must be 0 to 32767)"},
	{RQ_LoadTCGCurveFromFile_InvalidIndex,								"RQ_LoadTCGCurveFromFile fail: invalid sequence index (must be 0 to RQ_MAXIMUM_NUMBER_OF_TCG_VALUES - 1)"},
	{RQ_LoadTCGCurveFromFile_InvalidIndexPrefix,						"RQ_LoadTCGCurveFromFile fail: invalid index prefix (must be \"TCG\")"},
	{RQ_LoadTCGCurveFromFile_ReadError,									"RQ_LoadTCGCurveFromFile fail: cannot read from file"},
	{RQ_LoadPingPongSequenceFromFile_OversizedStringLength,				"RQ_LoadPingPongSequenceFromFile fail: oversized string length (line must be less than or equal to 512 characters)"},
	{RQ_LoadPingPongSequenceFromFile_InvalidSequenceIndex,				"RQ_LoadPingPongSequenceFromFile fail: invalid sequence index (must be 0 to RQ_PINGPONG_SEQUENCE_LENGTH - 1)"},
	{RQ_LoadPingPongSequenceFromFile_InvalidElementIndex,				"RQ_LoadPingPongSequenceFromFile fail: invalid element index (must be 0 to RQ_PINGPONG_ARRAY_SIZE - 1)"},
	{RQ_LoadPingPongSequenceFromFile_InvalidIndexPrefix,				"RQ_LoadPingPongSequenceFromFile fail: invalid index prefix (must be \"PP\")"},
	{RQ_LoadPingPongSequenceFromFile_ReadError,							"RQ_LoadPingPongSequenceFromFile fail: cannot read from file"},
	{RQ_LoadCurvedGateDataFromFile_OversizedStringLength,				"RQ_LoadCurvedGateDataFromFile fail: oversized string length (line must be less than or equal to 512 characters)"},
	{RQ_LoadCurvedGateDataFromFile_InvalidSequencePosition,				"RQ_LoadCurvedGateDataFromFile fail: invalid sequence index (must be 0 to 2047)"},
	{RQ_LoadCurvedGateDataFromFile_ReadError,							"RQ_LoadCurvedGateDataFromFile fail: cannot read from file"},
	{RQ_LoadCurvedGateDataFromFile_InvalidValue,						"RQ_LoadCurvedGateDataFromFile fail: invalid element index (must be 0 to RQ_CURVED_GATE_NUMBER_OF_VALUES - 1)"},
	{RQ_LoadCurvedGateDataFromFile_InvalidIndexPrefix,					"RQ_LoadCurvedGateDataFromFile fail: invalid index prefix (must be \"CG\")"},
	{RQ_LoadState_CannotOpenFile,										"RQ_LoadState fail: cannot open file (check filename)"},
	{RQ_LoadState_CannotReadFromFile,									"RQ_LoadState fail: cannot read from file"},
	{RQ_LoadState_OversizedSectionHeaderStringLength,					"RQ_LoadState fail: oversized section header string length (invalid section header)"},
	{RQ_LoadState_CannotCloseFile,										"RQ_LoadState fail: cannot close file"},
	{RQ_LoadState_MissingSystemParameters,								"RQ_LoadState fail: missing system parameters"},
	{RQ_LoadState_MissingSamplingParameters,							"RQ_LoadState fail: missing sampling parameters"},
	{RQ_LoadState_MissingPeripheralParameters,							"RQ_LoadState fail: missing peripheral parameters"},
	{RQ_LoadState_MissingGates,											"RQ_LoadState fail: missing system parameters"},
	{RQ_LoadState_MissingTCG,											"RQ_LoadState fail: missing TCG curve"},
	{RQ_LoadState_MissingPingPong,										"RQ_LoadState fail: missing ping-pong table"},
	{RQ_LoadState_MissingCurvedGate,									"RQ_LoadState fail: missing curved gate data"},
	{RQ_SaveState_CannotCreateFile,										"RQ_SaveState fail: cannot create file"},
	{RQ_SaveState_CannotWriteToFile,									"RQ_SaveState fail: cannot write to file"},
	{RQ_SaveState_CannotCloseFile,										"RQ_SaveState fail: cannot close file"},
	{RQ_SaveState_CannotDeleteInvalidFile,								"RQ_SaveState fail: cannot delete invalid file"},
	{RQ_SaveState_MissingTCG,											"RQ_SaveState fail: TCG has not been initialised"},
	{RQ_SaveState_MissingPingPong,										"RQ_SaveState fail: ping-pong has not been initialised"},
	{RQ_SaveState_MissingCurvedGate,									"RQ_SaveState fail: curved gate has not been initialised"},
	{RQ_SetFocusingUnitControl_InvalidFirmwareVersion,					"RQ_SetFocusingUnitControl fail: invalid firmware version"},
	{RQ_SetFocusingUnitControl_InvalidControlBus,						"RQ_SetFocusingUnitControl fail: invalid control bus (must be 0 to 7)"},
	{RQ_SetFocusingUnitControl_InvalidData,								"RQ_SetFocusingUnitControl fail: invalid data (must be 0 to 255)"},
	{RQ_SetFocusingUnitControl_QueryTimerFail,							"RQ_SetFocusingUnitControl fail: timer could not be queried"},
	{RQ_SetFocusingUnitControl_TimeOut,									"RQ_SetFocusingUnitControl fail: polling time-out"},
	{RQ_HandleSRAM_InsufficientSRAM,									"RQ_HandleSRAM fail: insufficient SRAM"},
	{RQ_CheckSRAM_InsufficientSRAM,										"RQ_CheckSRAM fail: insufficient SRAM"},
	//{RQ_GetCScan_InternalDataFormatError,								"RQ_GetCScan fail: internal data format error"},
	{RQ_GetBScan_NoBScansStored,										"RQ_GetBScan fail: single A-scan mode (use RQ_SetScanStorageOptions)"},
	{RQ_GetBScan_QueryTimerFail,										"RQ_GetBScan fail: timer could not be queried"},
	{RQ_GetSamples_MissingTrigger,										"RQ_GetBScan fail: trigger not present (use RQ_SetForceAScanTrigger or supply external trigger"},
	{RQ_GetSamples_DataFull,											"RQ_GetBScan fail: data full error (select alternative storage mode or reduce scan size parameters)"},
	{RQ_GetSamples_TriggerOccurredBeforeProcessComplete,				"RQ_GetBScan fail: new trigger occurred before sampling complete (use RQ_SetRepetitionRate with reduced parameter)"},
	{RQ_GetSamples_SampleIncomplete,									"RQ_GetBScan fail: sampling started but did not finish"},
	{RQ_GetBScan_TimeOut,												"RQ_GetBScan fail: polling time-out"},
	{RQ_GetBScan_InternalDataFormatError,								"RQ_GetBScan fail: internal data format error"},
	{RQ_GetBScan_InvalidNumberOfBScansPerBank,							"RQ_GetBScan fail: invalid number of B-scans per bank (must be 1, use RQ_SetNumberOfBScansPerBank"},
	{RQ_GetRawScan_QueryTimerFail,										"RQ_GetRawScan fail: timer could not be queried"},
	{RQ_GetRawScan_MissingTrigger,										"RQ_GetRawScan fail: trigger not present (use RQ_SetForceAScanTrigger or supply external trigger"},
	{RQ_GetRawScan_DataFull,											"RQ_GetRawScan fail: data full error (select alternative storage mode or reduce scan size parameters)"},
	{RQ_GetRawScan_TriggerOccurredBeforeProcessComplete,				"RQ_GetRawScan fail: new trigger occurred before sampling complete (use RQ_SetRepetitionRate with reduced parameter)"},
	{RQ_GetRawScan_SampleIncomplete,									"RQ_GetRawScan fail: sampling started but did not finish"},
	{RQ_GetRawScan_TimeOut,												"RQ_GetRawScan fail: polling time-out"},
	{RQ_GetRawScan_MemoryAllocationFail,								"RQ_GetRawScan fail: memory allocation fail"},
	{RQ_FreeRawScanData_DataNotPresent,									"RQ_FreeRawScan fail: argument does not correspond to allocated data"},
	{RQ_ExtractAScan_InvalidBScanIndex,									"RQ_ExtractAScan fail: invalid B-scan index (use RQ_GetNumberOfBScansPerBank to query maximum)"},
	{RQ_ExtractAScan_InvalidAScanIndex,									"RQ_ExtractAScan fail: invalid A-scan index (use RQ_GetNumberOfAScansPerBScan to query maximum)"},
	{RQ_ExtractAScan_InternalDataFormatError,							"RQ_ExtractAScan fail: internal data format error"},
	{RQ_ExtractBScan_InvalidBScanIndex,									"RQ_ExtractBScan fail: invalid B-scan index (use RQ_GetNumberOfBScansPerBank to query maximum)"},
	{RQ_ExtractBScan_InternalDataFormatError,							"RQ_ExtractBScan fail: internal data format error"},
	{RQ_ExtractRawCScan_MissingCScan,									"RQ_ExtractRawCScan fail: raw scan does not contain C-scan data (use RQ_SetScanStorageOptions)"},
	{RQ_ExtractRawCScan_InvalidGate,									"RQ_ExtractRawCScan fail: gate in RPN sequence does not exist"},
	{RQ_ExtractRawCScan_InvalidRPNSequence,								"RQ_ExtractRawCScan fail: invalid RPN sequence (see documentation for details)"},
	{RQ_SetAcquisitionMode_InvalidMode,									"RQ_SetAcquisitionMode fail: invalid acquisition mode (must be a member of )"},
	{RQ_ExtractRawGateValues_InvalidBScanIndex,							"RQ_ExtractRawGateValues fail: invalid B-scan index (insufficient B-scans in memory)"},
	{RQ_ExtractRawGateValues_InvalidAScanIndex,							"RQ_ExtractRawGateValues fail: invalid A-scan index (insufficient A-scans per B-scan"},
	{RQ_LastError,														"Unknown"}
} ;


pciAPIErrors pciApiErrors[] =
{
    { ApiSuccess,                   "PCISuccess"                   },
    { ApiFailed,                    "PCIFailed"                    },
    { ApiAccessDenied,              "PCIAccessDenied"              },
    { ApiDmaChannelUnavailable,     "PCIDmaChannelUnavailable"     },
    { ApiDmaChannelInvalid,         "PCIDmaChannelInvalid"         },
    { ApiDmaChannelTypeError,       "PCIDmaChannelTypeError"       },
    { ApiDmaInProgress,             "PCIDmaInProgress"             },
    { ApiDmaDone,                   "PCIDmaDone"                   },
    { ApiDmaPaused,                 "PCIDmaPaused"                 },
    { ApiDmaNotPaused,              "PCIDmaNotPaused"              },
    { ApiDmaCommandInvalid,         "PCIDmaCommandInvalid"         },
    { ApiDmaManReady,               "PCIDmaManReady"               },
    { ApiDmaManNotReady,            "PCIDmaManNotReady"            },
    { ApiDmaInvalidChannelPriority, "PCIDmaInvalidChannelPriority" },
    { ApiDmaManCorrupted,           "PCIDmaManCorrupted"           },
    { ApiDmaInvalidElementIndex,    "PCIDmaInvalidElementIndex"    },
    { ApiDmaNoMoreElements,         "PCIDmaNoMoreElements"         },
    { ApiDmaSglInvalid,             "PCIDmaSglInvalid"             },
    { ApiDmaSglQueueFull,           "PCIDmaSglQueueFull"           },
    { ApiNullParam,                 "PCINullParam"                 },
    { ApiInvalidBusIndex,           "PCIInvalidBusIndex"           },
    { ApiUnsupportedFunction,       "PCIUnsupportedFunction"       },
    { ApiInvalidPciSpace,           "PCIInvalidPCISpace"           },
    { ApiInvalidIopSpace,           "PCIInvalidIopSpace"           },
    { ApiInvalidSize,               "PCIInvalidSize"               },
    { ApiInvalidAddress,            "PCIInvalidAddress"            },
    { ApiInvalidAccessType,         "PCIInvalidAccessType"         },
    { ApiInvalidIndex,              "PCIInvalidIndex"              },
    { ApiMuNotReady,                "PCIMuNotReady"                },
    { ApiMuFifoEmpty,               "PCIMuFifoEmpty"               },
    { ApiMuFifoFull,                "PCIMuFifoFull"                },
    { ApiInvalidRegister,           "PCIInvalidRegister"           },
    { ApiDoorbellClearFailed,       "PCIDoorbellClearFailed"       },
    { ApiInvalidUserPin,            "PCIInvalidUserPin"            },
    { ApiInvalidUserState,          "PCIInvalidUserState"          },
    { ApiEepromNotPresent,          "PCIEepromNotPresent"          },
    { ApiEepromTypeNotSupported,    "PCIEepromTypeNotSupported"    },
    { ApiEepromBlank,               "PCIEepromBlank"               },
    { ApiConfigAccessFailed,        "PCIConfigAccessFailed"        },
    { ApiInvalidDeviceInfo,         "PCIInvalidDeviceInfo"         },
    { ApiNoActiveDriver,            "PCINoActiveDriver"            },
    { ApiInsufficientResources,     "PCIInsufficientResources"     },
    { ApiObjectAlreadyAllocated,    "PCIObjectAlreadyAllocated"    },
    { ApiAlreadyInitialized,        "PCIAlreadyInitialized"        },
    { ApiNotInitialized,            "PCINotInitialized"            },
    { ApiBadConfigRegEndianMode,    "PCIBadConfigRegEndianMode"    },
    { ApiInvalidPowerState,         "PCIInvalidPowerState"         },
    { ApiPowerDown,                 "PCIPowerDown"                 },
    { ApiFlybyNotSupported,         "PCIFlybyNotSupported"         },
    { ApiNotSupportThisChannel,     "PCINotSupportThisChannel"     },
    { ApiNoAction,                  "PCINoAction"                  },
    { ApiHSNotSupported,            "PCIHSNotSupported"            },
    { ApiVPDNotSupported,           "PCIVPDNotSupported"           },
    { ApiVpdNotEnabled,             "PCIVpdNotEnabled"             },
    { ApiNoMoreCap,                 "PCINoMoreCap"                 },
    { ApiInvalidOffset,             "PCIInvalidOffset"             },
    { ApiBadPinDirection,           "PCIBadPinDirection"           },
    { ApiPciTimeout,                "PCITimeout"					},
    { ApiDmaChannelClosed,          "PCIDmaChannelClosed"          },
    { ApiDmaChannelError,           "PCIDmaChannelError"           },
    { ApiInvalidHandle,             "PCIInvalidHandle"             },
    { ApiBufferNotReady,            "PCIBufferNotReady"            },
    { ApiInvalidData,               "PCIInvalidData"               },
    { ApiDoNothing,                 "PCIDoNothing"                 },
    { ApiDmaSglBuildFailed,         "PCIDmaSglBuildFailed"         },
    { ApiInvalidDriverVersion,      "PCIInvalidDriverVersion"      },
    { ApiWaitTimeout,               "PCIWaitTimeout"               },
    { ApiWaitCanceled,              "PCIWaitCanceled"              },
    { ApiLastError,                 "Unknown"                      }
} ;

char RQ_SystemFPGAString[] = "SystemSubsystem" ;
char RQ_SamplingFPGAString[] = "SamplingSubsystem" ;
char RQ_PeripheralFPGAString[] = "PeripheralSubsystem" ;

char RQ_GateString[] = "Gates" ;
char RQ_GateIdentifierPrefixString[] = "Gate" ;
char RQ_TCGString[] = "TCG" ;
char RQ_TCGIndexPrefixString[] = "TCG" ;
char RQ_NumberOfTCGValuesString[] = "NumberOfValues" ;
char RQ_PingPongString[] = "PingPong" ;
char RQ_PingPongElementPrefixString[] = "PP" ;
char RQ_CurvedGateString[] = "CurvedGate" ;
char RQ_CurvedGateElementPrefixString[] = "CG" ;

char RQ_SystemIOBank0String[] = "SystemIOBank0" ;
char RQ_SystemDDR0String[] = "SystemDDR0" ;
char RQ_SystemIOBank1String[] = "SystemIOBank1" ;
char RQ_SystemDDR1String[] = "SystemDDR1" ;
char RQ_SystemFirmwareRevisionString[] = "SystemFirmwareRevision" ;
char RQ_SampleFrequencyString[] = "SampleFrequency" ;
char RQ_RectifierModeString[] = "RectifierMode" ;
char RQ_StartDelayString[] = "StartDelay" ;
char RQ_NumberOfSamplesString[] = "NumberOfSamples" ;
char RQ_DropNumberOfSamplesString[] = "DropNumberOfSamples" ;
char RQ_SampleStorageModeString[] = "SampleStorageMode" ;
char RQ_TCGTriggerEventString[] = "TCGTriggerEvent" ;
char RQ_TCGEnableString[] = "TCGEnable" ;
char RQ_CScanBaseSRAMAddressString[] = "CScanBaseSRAMAddress" ;
char RQ_ScanStorageOptionsString[] = "ScanStorageOptions" ;
char RQ_NumberOfBScansPerBankString[] = "NumberOfBScansPerBank" ;
char RQ_NumberOfAScansPerBScanString[] = "NumberOfAScansPerBScan" ;
char RQ_SamplingFirmwareRevisionString[] = "SamplingFirmwareRevision" ;
char RQ_SamplingFirmwareVersionString[] = "SamplingFirmwareVersion" ;
char RQ_InputCouplingString[] = "InputCoupling" ;
char RQ_InputImpedanceString[] = "InputImpedance" ;
char RQ_AnalogueInputString[] = "AnalogueInput" ;
char RQ_AnalogueInputRangeString[] = "AnalogueInputRange" ;
char RQ_AToDOutputPortFormatString[] = "AToDOutputPortFormat" ;
char RQ_AToDOutputDataFormatString[] = "AToDOutputDataFormat" ;
char RQ_AToDInputVoltageRangeString[] = "AToDIutputVoltageRange" ;
char RQ_AToDVrefInputCharacteristicsString[] = "AToDVrefInputCharacteristics" ;
char RQ_DDSKEYString[] = "DDSKEY" ;
char RQ_DDSFSKString[] = "DDSFSK" ;
char RQ_CalibrationVoltageString[] = "CalibrationVoltage" ;
char RQ_AuxInputString[] = "AuxInput" ;
char RQ_TriggerSelectString[] = "TriggerSelect" ;
char RQ_TransducerPulseWidthString[] = "TransducerPulseWidth" ;
char RQ_NumberOfPeriodsBetweenAScanTriggersString[] = "NumberOfPeriodsBetweenAScanTriggers" ;
char RQ_NumberOfAScansToInterleaveString[] = "NumberOfAScansToInterleave" ;
char RQ_SensorArrayNumberOfElementsString[] = "SensorArrayNumberOfElements" ;
char RQ_SensorArrayApertureSizeString[] = "SensorArrayApertureSize" ;
char RQ_SensorArrayEnableBScanModeString[] = "SensorArrayEnableBScanMode" ;
char RQ_SensorArrayDisableAperturePositionWrites[] = "SensorArrayDisableAperturePositionWrites" ;
char RQ_SensorArrayDisableApertureDelayWrites[] = "SensorArrayDisableApertureDelayWrites" ;
char RQ_NumberOfEncoderClicksPerBScanString[] = "NumberOfEncoderClicksPerBScan" ;
char RQ_EncoderSelectString[] = "EncoderSelect" ;
char RQ_PeripheralIOBank0String[] = "PeripheralIOBank0" ;
char RQ_PeripheralDDR0String[] = "PeripheralDDR0" ;
char RQ_PeripheralFirmwareRevisionString[] = "PeripheralFirmwareRevision" ;
char RQ_PeripheralFirmwareVersionString[] = "PeripheralFirmwareVersion" ;

char RQ_GateStartString[] = "Start" ;
char RQ_GateEndString[] = "End" ;
char RQ_GateThresholdString[] = "Threshold" ;
char RQ_GateTriggerString[] = "TriggerGate" ;
char RQ_GateThresholdPolarityString[] = "ThresholdPolarity" ;
char RQ_GateTriggerModeString[] = "TriggerMode" ;
char RQ_GateDistanceMetricString[] = "DistanceMetric" ;
char RQ_GateEnableString[] = "Enabled" ;
char RQ_GateAmplitudePeakSelectString[] = "AmplitudePeakSelect" ;
char RQ_GateDistancePeakSelectString[] = "DistancePeakSelect" ;

#endif