I'm using a PXI-4065 multimeter with MS Visual C#.NET 4.0 and NI-DMM. I have a test that requires a sort of closed-loop feedback system and I need to take DC voltage readings with an interval of every 5 ms or better (software controlled) for a period of 1 second. It needs to be software controlled so that the application can adjust a second parameter in response, ie. I can't use a multipoint measurement function. I have read all the NI-DMM documentation regarding aperture times, settling times, etc, and adjusted my function accordingly to read 4.5 digits, no settling time, and a discrete value of 0 for trigger delay (accuracy is not very important...I need the speed here). With the caveat of understanding that an RTOS might be better suited to do this, if money and time were no object, I need to make it work with what I've currently got.
I inserted a start time/finish time measurement before and after calling the read function (using DateTime.Now.Ticks; 1 tick = 100ns) and I'm measuring around 30 ms. Even with some processing overhead, I can't believe it should take that long to process this function with all the delay stuff on the meter turned off. Am I missing something? My NI-DMM function calls are as follows:
...
...
PXI4065_Session1.ConfigureMeasurementDigits(DmmMeasurementFunction.DCVolts, 300, 4.5);
PXI4065_Session1.Trigger.DelayAuto = false;
TimeSpan triggerDelay = new TimeSpan(0);
PXI4065_Session1.Trigger.Delay = triggerDelay;
PXI4065_Session1.Trigger.Source = DmmTriggerSource.Immediate;
PXI4065_Session1.Advanced.SettleTime = 0;
measuredReading = PXI4065_Session1.Measurement.Read();
...
...
Please help!