LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

semaphore

hi
I am just trying to learn the use of semaphore. in my application i am making a VI just same as the inbuild example given in Labview. When I stopped the Main VI  then the two sub  vi were also stopped but with an error message code : 1111 ,  description : Release Semaphore.vi.
I am not getting the reason for this  error message
 
I am attaching the code.Please help me on this issue.
Thanxs
Raman 
0 Kudos
Message 1 of 5
(3,750 Views)
This is the LabWindows/CVI Forum not LabView!
 
LabView is differently!
Grüsse aus Deutschland

(GMT +01:00)
0 Kudos
Message 2 of 5
(3,744 Views)

Hi,

Error 1111 means "Release Semaphore called on a semaphore that was not currently acquired".  You can find more information on errors by right-clicking on the error number and selecting "explain error".  Taking a quick look at your code, there is no dataflow enforced between your subVIs and your main VI.  It is possible that the main VI could finish and destry the semaphore while your subVIs are still trying to use it.  I am also not sure that you want to acquire and release the semaphore inside the while loops in your subVIs.  Usually it makes more sense for applications to acquire and release the semaphore outside of loops.

You may find this tutorial, Using Semaphores, helpful.

Good luck,
Megan B.
National Instruments

0 Kudos
Message 3 of 5
(3,710 Views)
Hi
Thanxs Megan B
I am not able to find the bug.I am using semaphore first time.The attached zip file code is same as given in the  Labview Examples.Please help
 
Raman
0 Kudos
Message 4 of 5
(3,695 Views)

This was answered by Chris C. in the LabVIEW discussion forums.

 

0 Kudos
Message 5 of 5
(3,658 Views)