LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Event structure following While loop

I suspect because your initialise state on the case selector is set as "Default" case.

That means anything else that is not covered by your case statements will be handled by this case.

Unfortunately you can't delete the Default case but what you can do is create a new case only for Default which you process as you like (maybe stop VI or display message for error).

 

Message 41 of 52
(1,149 Views)
About the error you have to connect an 'error in' cluster in your front panel leave it empty-string and pass that to your first 'Obtain Queue' function. (I think not sure - try i can't run your VI)
0 Kudos
Message 42 of 52
(1,145 Views)

Although it is set as Default case, this default case shouldn't execute although if there is nothing else in the queue as the error out of "Dequeue Element" shouldn't give anything before it has something to dequeue.. it's really strange, and happens only when an error occur.

Maybe the default case is selected by Dequeue Element when there is an error in.. I will try your advice!

 

About the error in : it doen't work as their is no error in the producer loop, only in the consummer loop. But I did succeed by creating a constant to the error shift register. thanks


J.D.
French Labview beginner
N'oubliez pas de complimenter les bonnes réponses - Don't forget Kudos for good answers
0 Kudos
Message 43 of 52
(1,133 Views)
oh... ofcourse shift registers if not initialised keep the last value in the memory. Have a look at the topic 'Functional Globals'. I didn't see that you left it uninitialised.
0 Kudos
Message 44 of 52
(1,130 Views)

Yes I knew it too, just failed 😛

 

maybe you can explain me the error which happens there :

 

error 1077.png

 

The error is 1077 (property nodes : invalid property value at arg 3).

I think the problem is plot color. It works, but not every time. Do you know how I could generate random color ? Or maybe random choise between 5 or 6 chosen colors ?

 

Thanks

Message Edité par JDlabview le 06-16-2010 05:13 PM

J.D.
French Labview beginner
N'oubliez pas de complimenter les bonnes réponses - Don't forget Kudos for good answers
0 Kudos
Message 45 of 52
(1,125 Views)
One fundamental mistake you are making is passing a dbl to the color property (arguement 3 as the error message says). The coercion dot is a pretty good clue.
0 Kudos
Message 46 of 52
(1,120 Views)

Yes Dennis I know this but I didn't know how to choose a random color by another way. And about coercion dot : i've got one on each property node argument, do you know why ?

thanks

Message Edité par JDlabview le 06-16-2010 05:22 PM

J.D.
French Labview beginner
N'oubliez pas de complimenter les bonnes réponses - Don't forget Kudos for good answers
0 Kudos
Message 47 of 52
(1,116 Views)
Yes, I know why - you are passing data that is not the correct representation. That is always the reason for the coercion dot. Just stick the appropriate conversion function in between or use the correct representation in the first place.
Message 48 of 52
(1,106 Views)
Childish solution but works.
Message 49 of 52
(1,103 Views)

Great solution Dimitrios, thanks 🙂

 

And Dennis, ok, but it is very demanding, a I32 instead of a I16 would create a coercion dot, but works 🙂

thanks too


J.D.
French Labview beginner
N'oubliez pas de complimenter les bonnes réponses - Don't forget Kudos for good answers
0 Kudos
Message 50 of 52
(1,091 Views)