10-11-2015 12:56 AM
Hi,
I'm new in LabVIEW and being mini project, I got template before, but I don't know how to add next sequence command.
Attached screen capture and vi files for easy review and comment.
Many thanks for help!
10-11-2015 01:55 AM
That's not a "command", these are local variables. You can make copies by ctrl+dragging them but try to find a better architecture.
Your curent architecture is very poor. You can do the same without sequences and local variables. Think "state machine"! Look at the design templates that ship with LabVIEW.
10-11-2015 01:56 AM
10-11-2015 02:04 AM
Easiest would be to use an array of boolean, e.g. as attached.
See if it can give you some ideas.
10-11-2015 08:18 AM
Hi Altenbach,
Thanks for your help.
My mini-project is simulate current flow condition in power protection scheme,
I have no idea use sequence or array function simulate attached schematic.
Could you help me advise comment on it.
Thanks!
10-11-2015 09:23 AM - edited 10-11-2015 09:26 AM
What does the attached schematic have to do with the "simulation"? How should the LEDs behave as a function of time?
The VI is currently broken because you show the enable terminal of the feedback node, but it is not wired.
You still have way too much duplicate code. Why do you think you need to convert the same number to a boolean array twice in parallel? Once is enough! You can branch the boolean wire after the conversion and wire it to the two indicators
It might be simpler to initialize the shift register with a boolean array containing one true and 15 false, then simply use "rotate array" in the loop. Now you have more flexibility in the boolean pattern.
It is not clear what kind of help you want/need.
10-11-2015 09:54 AM
Hi altenbach,
Many thanks for your comment.
My purpose of mini project is use LEDs to simulate current flowing, then LEDs will be overlap wiring position of schematic, flashing alternately from left to right, signaling from protective device run to controller, as well as current and signals are flowing on wiring schematic. Like a block diagram when running progamme, I click the icon "Highlight Execution" which will showing the signal "running" on the wiring, but I would like to done this condition on Front Panel. Simply, use LEDs sketch schematic and show the current flow condition.
Thanks for your help
10-11-2015 10:34 AM
Hi altenbach,
I attached vi file which is I wanted to do (not yet completed) for your easy comment.
Thanks your time to help me.
10-11-2015 10:47 AM - edited 10-11-2015 10:50 AM
@ikchan wrote:
Hi altenbach,
I attached vi file which is I wanted to do (not yet completed) for your easy comment.
Thanks your time to help me.
OK, Perhaps another thing you should consider. A whole bunch of boolean scalar indicators might not be the "Best" way of displaying information to your users.
Just to get you thinking about other options, think on this code
That is a "Snipette" drag n drop to a blank LabVIEW Block Diagram and you can run the code. (On some Windows Platforms you may have to drag to the desktop first then drag to the LabVIEW BD)
10-11-2015 10:54 AM - edited 10-11-2015 10:56 AM
@ikchan wrote:
I attached vi file which is I wanted to do (not yet completed) for your easy comment.
The code you have attached does not explain what you want to do.
Why dod you go back to individual LEDs? An array of LEDs seems much more reasonable. (look at your diagram! 80% of the diagram space is taken up by terminals!) You can use one array per trace, some vertical and some horizontal.
What is the purpose of the timing source, relay, and timed inner loop? Why do you think you need to create the timing source with every iteration of the outer loop? Wouldn't once be sufficient? And yes, I have no idea why you would need that.
Your timed loop will never work because you wire a hardcoded error into it. Why?