LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

retrieve win32 event handle

Hi
 
I am interfacing an Andor iXon camera through calls to the driver dll. I want now to log the end of each image grab. For that, the way is to give a win32 event handle to the driver via a function of the dll; this event will be triggered at each end of frame. But I find no way to retrieve the win32 event handle corresponding to an event created in labview!
 
Thanks for the help
0 Kudos
Message 1 of 5
(3,418 Views)
Hi,

You need to create an event handle with CreateEvent. You can then wait for the event with WaitForSingleObject. both are in Kernel32.dll.

Regards,

Wiebe.

"petitprince" <x@no.email> wrote in message news:1132566041656-290842@exchange.ni.com...
Hi
&nbsp;
I am interfacing an Andor iXon camera through calls to the driver dll. I want now to log the end of each image grab. For that, the way is to give a win32 event handle to the driver via a function of the dll; this event will be triggered at each end of frame. But I find no way to retrieve the win32 event handle corresponding to an event created in labview!
&nbsp;
Thanks for the help
0 Kudos
Message 2 of 5
(3,415 Views)

Message Edited by petitprince on 11-21-2005 04:52 AM

0 Kudos
Message 3 of 5
(3,412 Views)
Hi,

thanks for your answer.

From your answer it looks to me that I have to do it in the C like fashion calling dll function. Then I will have the opposite problem : Once I have my event handle, how can I wire it to a event processing structure?

The ideal solution would be to create event in labview? Maybe I will ask a newbie question (I'm quite new to labview and mainly used C/C++ (visual)), but I need the value of the win32 event handle to pass to the dll. Is it directly the "event registration refnum"? out of "register for events" icon? or the "user event refnum" out of "create user event". Shall I do some conversion?

Thanks
0 Kudos
Message 4 of 5
(3,410 Views)
Hi,


If you have to have an LV event structure handle the event, it gets a bit more complicated...


Make a dynamic event (LV), register it (LV). Make an event case for it (LV). Then, create the event handle (dll) and start a dynamic vi (LV) that waits for it (dll). When it's done, trigger the event (generate user event).


Regards,


Wiebe.


"petitprince" <x@no.email> wrote in message news:1132571458323-290878@exchange.ni.com...
Hi, thanks for your answer. From your answer it looks to me that I have to do it in the C like fashion calling dll function. Then I will have the opposite problem : Once I have my event handle, how can I wire it to a event processing structure?The ideal solution would be to create event in labview? Maybe I will ask a newbie question (I'm quite new to labview and mainly used C/C++ (visual)), but I need the value of the win32 event handle to pass to the dll. Is it directly the "event registration refnum"? out of "register for events" icon? or the "user event refnum" out of "create user event". Shall I do some conversion?Thanks
0 Kudos
Message 5 of 5
(3,406 Views)