LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

unbundle registered events

Bonjour,
Je suis stagiaire en ce moment et je suis entrain de tester un detecteur de PIC "PKD01" alors pour cela j'ai réaliser un programme sur labview tout en utilisant un DAQmx ni usb 6009.
alors j'ai un problemme dans mon programme parce que je suis tout nouveau sur labview...
je voudrais lire les pic, les mettre dans un tableau puis les enregistrer dans un fichier excel. et à chaque fois que je lit un pic je dois renitialiser si non il me dectera pas le pic suivant s'il est plus petit.
Pour renisialiser je dois ecrire un 1sur les 2 pattes de commande du PKD01 .
Pour detecter je dois envoyer un 0.
vous trouverz si joint mon programme sur labview.
 
Merci d'avance
 
0 Kudos
Message 11 of 29
(1,221 Views)
Shane,

now i think i understand what you are up to:



But i am not sure if this is possible with simple user events. If you are able to solve this, i hope we will see another interesting nugget 🙂

Norbert


Message Edited by Norbert B on 06-02-2008 10:10 AM
Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 12 of 29
(1,213 Views)
Intaris, could you give a little diagram of what you are trying to do?
User events are very powerfull and never let me down.
A little scheme or handdrawing should be OK

Ton
Free Code Capture Tool! Version 2.1.3 with comments, web-upload, back-save and snippets!
Nederlandse LabVIEW user groep www.lvug.nl
My LabVIEW Ideas

LabVIEW, programming like it should be!
0 Kudos
Message 13 of 29
(1,207 Views)
Norbert,

I'm not aqll to familiar with DAQ-mx, but if the pic you show is allowing an event to be fired based on the choice of the drop-down list then yes, this is exactly what I was thinking.

Of course, we could go about it another way.  Here's a pretty simple example (using a counter as a "device driver").

The only possibility for misuse is the availability of a refnum for the just-fired event when catching a user event.  This actually shows that it IS possible to get at the event refnum from a "register for events" wire, it's just not public.  I have added a switch to trhe front panel of the following VI showing this mis-use.  Why do we have the event refnum exposed here?

Shane.

PS Forgot to add: LV 8.2.1


Message Edited by Intaris on 06-02-2008 10:32 AM
0 Kudos
Message 14 of 29
(1,207 Views)
You can group them like the attached if you only want one wire.
Randall Pursley
0 Kudos
Message 15 of 29
(1,205 Views)
TonP,

I just saw your response.  Have a look at the code for an example.  It's basically using pre-defined Events to define an interface between two parts of code.  The device driver generates the events (or registers them) whereas the application software uses them.  It's kind of a user-event based producer consumer architecture.  No queues.

Shane.
0 Kudos
Message 16 of 29
(1,207 Views)
rpursley8,

just saw your response too. Am I so slow in answering that everyone's answering before I post.... Smiley Surprised

If you look in the code I posted, this is exactly what I did.

Shane.
0 Kudos
Message 17 of 29
(1,205 Views)
I think I know of two existing tools which do what you want: LVx and the Active VI toolkit (which uses XNodes). I think that LVx actually does exactly what you want, but I didn't look deeply into either of them.

___________________
Try to take over the world!
0 Kudos
Message 18 of 29
(1,194 Views)
Intaris,
your code looks OK, I would move the register for the talk-back event into the Application Layer:


Ton



Message Edited by TonP on 06-02-2008 06:20 PM

Message Edited by TonP on 06-02-2008 06:24 PM
Free Code Capture Tool! Version 2.1.3 with comments, web-upload, back-save and snippets!
Nederlandse LabVIEW user groep www.lvug.nl
My LabVIEW Ideas

LabVIEW, programming like it should be!
0 Kudos
Message 19 of 29
(1,184 Views)
TonP,

I did that on purpose to ensure the events are "Read-only" so to speak.

Shane.
0 Kudos
Message 20 of 29
(1,177 Views)