03-21-2021 01:09 PM
Hello NI community! I am having this problem trying to get analog data from 32 channels to the queue message '9205', where it get stuck and i dont get the mean output what i wanna have in my main GUI. However those are photos describing more about my problem.
I am working with LabVIEW since 3 months and i think i can do it already good but i dont know how i can solve this problem.
Probe 3 is the Enqueue Element where the data get stucked. Thanks for anyone who helps 🙂
Solved! Go to Solution.
03-21-2021 01:22 PM - edited 03-21-2021 01:24 PM
No, we cannot debug truncated images full of overlapping code. Please attach your VI.
(This looks like a candidate for the Rube Goldberg thread! 😄 I am sure this could be rewritten using 5% of the current code)
03-22-2021 02:17 AM
I can't share the whole VI. I would describe my whole problem again though.
The mean functions you have seen can be corrected and made easier to visualize, i just made it so chaotic because i didn't think of a way to get the 32 channels to be getting inside the 'mean' function in seperate arrays.
However, the problem is not with this chaotic structre my friend. On the one hand, you can see that the Enqueue Element gets data from my measurment loop and sends them to the main loop of this SubVI. But on the other hand, this data get stuck in the queue and when i end my main VI, i get this shown error. i am asking just for a bit more guidance than a whole solution.
03-22-2021 02:21 AM - edited 03-22-2021 02:31 AM
Hi Mahmoud,
@MahmoudNajamy wrote:
The mean functions you have seen can be corrected and made easier to visualize, i just made it so chaotic because i didn't think of a way to get the 32 channels to be getting inside the 'mean' function in seperate arrays.
Then see this:

No need to convert/split an array to 32 DDT wires, to throw in 32 FromDDT node, 32 instances of mean and a huge BuildArray…
As Christian said: <5% code size!
(You could have avoided a lot of "side discussions" if you would have placed that mess into its own subVI!)
@MahmoudNajamy wrote:
But on the other hand, this data get stuck in the queue and when i end my main VI, i get this shown error. i am asking just for a bit more guidance than a whole solution.
This error most often comes from an invalid input parameter - as written in the error description!
Is your queue reference still valid?
@MahmoudNajamy wrote:
I am working with LabVIEW since 3 months and i think i can do it already good but i dont know how i can solve this problem.
I think you are not "already good" when you miss simple debugging techniques (likes probes) to test your code. And see that Rube-Goldberg mess in your images!
(Don't take that as an insult, we all started with writing simple and "not as good as possible" code in LabVIEW. But I wouldn't describe myself as "already good" after just 3 month of learning a new programming language…)
03-22-2021 02:21 AM
Sooo you should maybe focus on my description than just feel confused of my chaotic signals.
32 wave signals --> 32 mean functions ---> 32 new arrays ---> bundled. don't be afraid to look ;). if you have a good way to handle 32 signals at the same time, then please inspire me 😉
03-22-2021 02:24 AM
@GerdW Hey there, thanks i will use it. but what about my problem?
03-22-2021 02:44 AM
It's very hard to debug something without contex. I have seen this error mostly when the Queue refenrece was not valid anymore....
Check if the VI that made the Queue Ref is still in Memory, otherwise the Ref will be also deleted.
Check also the error Wire after the Queue creation in case there is a problem creating the Queue and thus getting a invalid Reference.
03-22-2021 02:47 AM
you can see that i made the change ;)! However the array of waveforms is not reached to that point, but you can see the signal of my waveorms are in the graph shown in the loop before. but my Enqueue Element doesn't send it forward. I can't see the problem.
03-22-2021 02:49 AM - edited 03-22-2021 02:50 AM
Hi Mahmoud,
@MahmoudNajamy wrote:
I can't see the problem.
Did you read my previous message? (And please don't send PMs when you already got answers here in your thread!)
Did you read ypi's message?
Did you implement some more error handling/checking?