GX5290, GX5295, File
Sets the specified condition value.
DioRealTimeCompareSetupConditionValue (nHandle, nCondition, dwValue, pnStatus)
Name |
Type |
Comments |
nHandle |
SHORT |
Board or File Board handle. |
nCondition |
SHORT |
Condition:0. DIO_RTC_CONDITION_FAILURE_COUNT: the DIO domain will PAUSE/HALT once the number of detected errors equals the condition count value.1. DIO_RTC_CONDITION_DATA: the DIO domain will PAUSE/HALT once the vector data matches the condition data value.2. DIO_RTC_CONDITION_PROGRAM_COUNTER: the DIO domain will PAUSE/HALT once the vector step number matches the condition address value. |
dwValue |
DWORD |
Condition value.If nCondition is set to DIO_RTC_CONDITION_FAILURE_COUNT then the condition value can be 1 to 1024.If nCondition is set to DIO_RTC_CONDITION_DATA then the condition value can be between 0 to 0xFFFFFFFF.If nCondition is set to DIO_RTC_CONDITION_PROGRAM_COUNTER then the condition value can be between 0 to last step of 67108863, or higher if number of channels was set to less than 32. |
pnStatus |
PSHORT |
Returned status: 0 on success, negative number on failure. |
Each DIO in the domain can have its own active condition to stop on as it was set by calling DioRealTimeCompareSetupStopMode function.
The board has to be in Real Time Compare operating mode prior calling this function. See the DioDomainSetupOperatingMode function for more details.
Note: the Real Time Compare functionality is supported by GX529x boards with firmware versions 0x8A00 and above.
The following example sets the condition count value to 10:
SHORT nStatus;
DioRealTimeCompareSetupConditionValue (nHandle, DIO_RTC_CONDITION_FAILURE_COUNT, 10, pnStatus);
DioRealTimeCompareSetupConditionValue, DioRealTimeCompareSetupDataDelay, DioRealTimeCompareSetupInputDataClockEdge, DioRealTimeCompareSetupResultsDataType, DioRealTimeCompareSetupStopCondition, DioRealTimeCompareWriteExpectedMemory, DioRealTimeCompareWriteMaskMemory, DioRealTimeCompareReadResults