03-24-2021 06:33 AM
Hello everyone
Would you please help me to know about my problem on attached VI
I programed a digital counter on my USB6009 with Daq assist and it was ok but with the same hardware it is not ok for the API program.
What is my fault?
03-24-2021 06:40 AM - edited 03-24-2021 06:41 AM
03-24-2021 07:08 AM
Hi GerdW
Thank you for your time, But I didn't quit catch. I used "CI counter edge" but there is still a problem.
Would you please see my attached VI and tell me where is the problem?
03-24-2021 07:10 AM
Hi sml,
@Sml2010 wrote:
I used "CI counter edge" but there is still a problem.
Would you please see my attached VI and tell me where is the problem?
Right now I cannot open your VI, see my signature line. Mind to convert to LV2017?
Which problem do oyu encounter? Any error messages?
(Delete the DAQAssistent before trying to access the very same channel using the DAQmx API!)
03-24-2021 07:24 AM
please try ne attached file (LV2017).
I have counter with Daq assist but with the same hardware and configuration I don't have any counter by API programming method. There is no error or massage.
I am new in Labview and I try to learn.
Thank you for your help
03-24-2021 08:48 AM
Hi Sml,
@Sml2010 wrote:I have counter with Daq assist but with the same hardware and configuration I don't have any counter by API programming method. There is no error or massage.
You cannot use the very same hardware resource in two DAQmx tasks!
Delete the DAQAssistent!
(Right now you try to access "ctr0" with the DAQmx functions and with your DAQAssistent. This will not work…)
@Sml2010 wrote:
I am new in Labview and I try to learn.
Did you notice those "Training resources" in the header of the LabVIEW board?
Did you learn from all those example VIs in the example finder?
Did you learn from converting the DAQAssistent by using the right-click menu entry "Generate NI-DAQmx code"?
03-24-2021 09:25 AM
Hi GerdW
Yes, I deleted the Daq assist already, but it still not working.
Yes, I passed one of NI training course.
With NI examples I have an error and with changing active change, the error is still existing.
03-24-2021 09:33 AM
Hi Basjong,
@Sml2010 wrote:
Yes, I deleted the Daq assist already, but it still not working.
With NI examples I have an error and with changing active change, the error is still existing.
Why don't you read the error message? It clearly tells what is wrong in your code…
You are using very simple, old, and cheap DAQ hardware with very limited capabilities. So it only allows to count for falling edges - as mentioned in the error message!
03-25-2021 02:55 AM
Dear GerdW
Thank you for your reply
in comparison with first reply, I just needed to define edge direction.
Thank you dear Gerdw 🌷