12-07-2009 01:22 AM
It looks for me that there is a bug in the trigger level limit check functions for the AUX INput of the tkdpo4k driver for Labwindows/CVI (Version 4.3.1 , released 16-JUL-2009) when using a DPO4032 scope.
The instruments manual tells us (see http://www2.tek.com/cmsreplive/marep/14938/071212103web_2009.02.10.14.36.48_14938_EN.pdf , page 77) : AUX IN: Trigger Level Range is adjustable from +8V to -8V.
However if I try to set the level to 1.5V with tkdpo4k_ConfigureEdgeTriggerSource () it returns always IVI_ERROR_INVALID_VALUE.
Looking into the source shows the following code in tkdpo4kAttrTriggerLevel_CheckCallback() :
[...]
if (!strcmp (tSource, TKDPO4K_VAL_EXTERNAL))
ext = 1.0;
if (ext != 0.0)
{
/*- Trigger source is External -*/
checkErr( tkdpo4k_CheckRangeWithPrecision (vi, attributeId, value, -1.0 * ext, 1.0 * ext));
}
[...]
which limits the trigger level setting to +/- 1.0 V.
The same code can also be found in tkdpo4kAttrTriggerLevelByCh_WriteCallback() and in tkdpo4kAttrDelayTriggerLevel_CheckCallback() it is even limited to +/- 0.8 V (factor used in tkdpo4k_CheckRangeWithPrecision () is 0.8 instead of 1.0) .
As minimal workaround I just changed the value of ext to 10.0 and the factor in tkdpo4k_CheckRangeWithPrecision () to 0.8 in all variants and now it accepts the 1.5V without problems on the DPO4032.
Can someone @NI make sure that this problem is fixed in the next release of the that driver ?
However I'am not sure that my workaround is right for all scopes supported by this driver. I did't check all manuals. You might need to introduce a model dependant limit check here.
Solved! Go to Solution.
12-07-2009 08:46 PM
Hi markus,
I am investigating the issue you request. The process may takes one or two days and I'll tell you the result once we have a result.
Thanks.
12-09-2009 07:23 PM
Hi Markus,
I have updated the source code and attached bellow. You can replace the file to the old one and test to see whether there are other issues.
Thanks.
12-14-2009 12:50 AM