LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

system wide semaphore

This is the only reference I could find on system wide synchronization (i.e. between processes):

  http://zone.ni.com/devzone/cda/epd/p/id/4490

but it seems a bit dated, and one of the comments points to a potential bug.

 

Should I use the zip file attached there, write my own wrappers to Win32 mutexes, or is there a better library somewhere?

 

Advance thanks,

 

0 Kudos
Message 1 of 4
(2,885 Views)

The DevZone is a little old, but I just ran the code in LV 2009 SP1 on my Windows 7 machine and it worked just fine.

 

James West, is correct that the CloseHandle is not called, but I do not know enough about the WIN32 semaphores to know if that would cause an issue.

 

It would be easy enough though to add a call the the CloseHandle function to destroy the semaphore if you were worried about it.  Just makea new VI that calls the dll and have it run after you hit the stop button.

Justin Parker
National Instruments
Product Support Engineer
0 Kudos
Message 2 of 4
(2,846 Views)

I already added the CloseHandle and cleaned up the code a bit.  Haven't tried it yet, though. Still seems that it should be something that LabVIEW should offer, in case one wants to synchronize different executables.

 

0 Kudos
Message 3 of 4
(2,836 Views)
We really appriciate this type of feedback.  We have our feedback page or our new LabVIEW Idea Exchange.  Both get evaluated by R&D and are used to help shape our future releases. 
Justin Parker
National Instruments
Product Support Engineer
0 Kudos
Message 4 of 4
(2,813 Views)