Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with ReadDigChan_ChangeDetection_Events VB example...

Following is based on the ReadDigChan_ChangeDetection_Events VB.NET example (with hard-coded channel strings)...
 
myTask = New Task()

myTask.DIChannels.CreateChannel("Dev1/Port1/Line0", "myChannel", ChannelLineGrouping.OneChannelForAllLines)

myTask.Timing.ConfigureChangeDetection("Dev1/Port1/Line0",  "Dev1/Port1/Line0", SampleQuantityMode.ContinuousSamples, 1000)

...but ConfigureChangeDetection throws an exception:

   Requested value is not a supported value for this property.

Property: NationalInstruments.DAQmx.Timing.SampleTimingType
You Have Requested: NationalInstruments.DAQmx.SampleTimingType.ChangeDetection
You Can Select: NationalInstruments.DAQmx.SampleTimingType.OnDemand

Task Name: _unnamedTask<0>

Status Code: -200077" String

 

0 Kudos
Message 1 of 4
(3,474 Views)

This is being used with a 6008 , if that makes any difference.

David

PS: don't know what happened with my post to cause it to listed 3 times!

 

 

0 Kudos
Message 2 of 4
(3,470 Views)
Hi David,

The digital lines on the USB-6008 do not support change detection.  Usually if your error mentions that you have request a supported value, it may indicate your hardware does not support the feature that you are programming with the driver calls.  Take a look at the KnowledgeBase here for a list of NI devices that does support this feature.  There may be a work-around for what you are trying to do, so if you can give details on what you are trying to accomplish, we may be able to help.

Thaison V
Message 3 of 4
(3,457 Views)
Yes, I found that the 6008 doesn't do change detection. But for my app, I can get by with using a counter on a digital line. But I can't get that to work either (see my post titled "Can't get 6008 counter to work with DAQmx 8.0 in VB.NET app ")
 
Thanks.
0 Kudos
Message 4 of 4
(3,453 Views)