LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

DAQmxRegisterSignalEvent

Hi all,

       What I want is to update a high refresh rate monitor using a hardware clock set exactly at 120 Hz. For that, I think that the easiest y to configure a counter to count digital edges and register an arbitrary function to the hardware event. The arbitrary function would read te counter value (or just increment a variable) and update the screen depending on the value (actually I want to display a revolving clock).

 

The problem is that I can't get my program to work with a NI USB-6215, because of hardware incompatibility with hardware timed edge detection (or something like that). Any idea to do this, hopefyllu using only one counter?

 

I also have a PCI-4461 and PCI-6071E

 

Thanks!!

0 Kudos
Message 1 of 15
(4,288 Views)

Hi,

 

What's the problem about using the PCI-6071E ? (2 counters) I guess that it should work ! 🙂

0 Kudos
Message 2 of 15
(4,272 Views)
If you gess that will work, then I will try it. That card is in anothr pc I haven't tried, but I suspected it wouldn't work because that card is not listed where Hardware timed single point supportings cards are. I have NULL experience on this cards so maybe there is other way but, again, id like a counter to set the rate with which a control in the UIR refresh.

Thanks!
0 Kudos
Message 3 of 15
(4,267 Views)

I have tried to configure a simulated PCI-6071E device in "HW-timed single point", and it seems to work (no error returned by the DAQmx function...and as you said previously, it doesn't work for USB-6215).

 

 

0 Kudos
Message 4 of 15
(4,249 Views)

Another point is that you will need to use counter output (and not counter input !), as explained here :

http://forums.ni.com/t5/Multifunction-DAQ/DAQmxRegisterSignalEvent-for-Counter-Output-Event/td-p/112...

 

0 Kudos
Message 5 of 15
(4,249 Views)
What is the purpose of a simulated device? I have a real PCI-6071E, so the simulate concept, which still i dont get, confuses me. It was just a tet you ran?? I guess so.

Many thanks!!
0 Kudos
Message 6 of 15
(4,234 Views)
The 6071E card is installed on a pc with NIDAQ 6.9 drivers. I,ve been looking for a function to register a callback function associated with hardware events, and think I found it:

Config_DAQ_Event_Message

However, it is a bit complicated because it has a lot of parameters.

Can you lend me the code you used to try what you succesfully tried. Now I'm looking how to run
Legacy cards with NIDAQ mx drivers...


Actually, I want the counter direction to depend on the state of a digital line. So, I could connect a counter output to external hardware (just for synchronization) and a counter input of the same card. Each time the output (or input, as they should be virtually simultaneous) events occur, I would read the input counts and refresh a 120 Hz monitor according to that.


0 Kudos
Message 7 of 15
(4,232 Views)

While I cannot give you any help on your original question, I'm pretty sure that you cannot use Config_DAQ_Event_Message (which is part of Traditional NI-DAQ package) in a program that uses NI-DAQmx driver, as those environments cannot be mixed in the same application.

Let's see if Julien can share its code with you.

 

With reference to one of your previous questions, a simulated device permits you to start developing an application making references to hardware resources even without having the actual board installed. Simulated devices mimic the operation of real devices supplying in some case a test signal for you to test the application (e.g. they give you a sine-pattern signal on analog inputs). A code that compiles and runs on a simulated device can be ported to a real board to terminate development with actual hardware and signals, with a reasonable confidence that it does not need deep rearrangments to work correctly.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 8 of 15
(4,217 Views)

I've not used any "Config_DAQ_Event_Message" for testing. I have used "DAQmxRegisterSignalEvent" and there is no error returned by the function (see both screenshots).

 

But there is something that I don't understand. "Counter Output" does not seem to have the expected signification. I mean : events are not generated when counter value change.

As explained here, "The Counter Output Event is an event that occurs when the counter reaches its terminal count."

http://www.ni.com/white-paper/5387/en/

 

So I begin to wonder wether or not using counter output signal is relevant for your application !

Download All
0 Kudos
Message 9 of 15
(4,212 Views)

Here is a link on LabVIEW forum that maybe can help you :

http://forums.ni.com/t5/LabVIEW/Using-DAQ-to-trigger-non-DAQ-event/td-p/2579469

 

If counter input does not work with "change detection event" signal, maybe you can try with a digital input, as suggested by Norbert in the last post.

 

I'm sorry because I try to find some solution but I have not any HW to try it before. So, I might suggest some bad solutions, but it's worth trying. ^^

0 Kudos
Message 10 of 15
(4,185 Views)