キャンセル
次の結果を表示 
次の代わりに検索 
もしかして: 

Small Problem with Simple Labview Code. Please Help :(

Can you upload the VI in 2011

--------------------------------------------------------------------------------------------------------
Kudos are always welcome if you got solution to some extent.

I need my difficulties because they are necessary to enjoy my success.
--Ranjeet
0 件の賞賛
メッセージ11/22
1,055件の閲覧回数

Hi Zoneator,

 

You currently have the maximum queue size set to one and an infinite timeout on your enqueue element.  Once you enqueue the first element, your loop waits indefinitely for the one spot to become available. Due to dataflow dependencies (you shouldn't be wiring that stop button through to the parallel loop), your bottom while loop cannot execute until the first has finished and exited. You'll need to use a different mechanism (such as a local variable or a separate control) to stop your second loop.

 

Regards,

Tom L.
メッセージ12/22
1,054件の閲覧回数

How do i do that? Sorry this is my first time.

0 件の賞賛
メッセージ13/22
1,053件の閲覧回数

First i can't see any reson why upper while loop will execute only 2 times.

Second you need to learn dataflow ( you can not stop lower while loop with stop button wired like that )

third if you are not using event structure you are not doing your assignment correctly.

fourth read about every function from LabVIEW help before using it and see some example also.

Many more............

But most important is don't expect any code from as because it is your assignment. 

 Edit..

May be i saw it too quickly yes your bottom loop will not start executing until upper stops.

and you queue size is one so without dequeue it will stuck.

0 件の賞賛
メッセージ14/22
1,052件の閲覧回数

I've got it to work! Thank you so much tom. This is my solution. Tom and Ranjeet, do you guys think there is a way to incorporate an event structure into this?

0 件の賞賛
メッセージ15/22
1,041件の閲覧回数

Hi neos,

 

I found out the mistake. The wiring of the stops was a very amateur mistake (I don't know why i did that :/) I wasn't expecting any actual labview code, just verbal directions. My college research project involves labview and a ton of queueing (this assignment was just a verbal assignment from my grad student). I'm having a difficult time incorporating event structure for this. I don't see how to incorporate the value signaling property node into the event. Thanks

0 件の賞賛
メッセージ16/22
1,034件の閲覧回数

@Zoneator wrote:

I've got it to work! Thank you so much tom. This is my solution. Tom and Ranjeet, do you guys think there is a way to incorporate an event structure into this?


Yes better use event structure because in your case you gonna need to interact with user.

--------------------------------------------------------------------------------------------------------
Kudos are always welcome if you got solution to some extent.

I need my difficulties because they are necessary to enjoy my success.
--Ranjeet
メッセージ17/22
1,033件の閲覧回数

Ranjeet,

 

It doesn't need any user interaction. The event structure just needs to be triggered by a value change from the random number generator, so it can do its function which should be to multiply the random number by 3. I think this is supposed to be the purpose.

0 件の賞賛
メッセージ18/22
1,029件の閲覧回数

As you said multiplier can be changed

--------------------------------------------------------------------------------------------------------
Kudos are always welcome if you got solution to some extent.

I need my difficulties because they are necessary to enjoy my success.
--Ranjeet
0 件の賞賛
メッセージ19/22
1,026件の閲覧回数

Zoneator,

Now it is the time to learn the link Tom has given about Producer Consumer.

Make some actions like Start, Stop, Pause in producer loop with event structure and in consumer use a state machine.

Read it and give a try.

You can use user events.

0 件の賞賛
メッセージ20/22
1,024件の閲覧回数