LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can somebody have a look at my mock CLD exam (Security System)

Hi folks,

 

I have my CLD exams in 2 days and I just sat for almost 4 hours straight working on this old exam.

I would appreciate it if someone can sort psuedo-mark my exam and give me any feedback.

I am aware that I it is not 100% complete as that is all that I could finish in the given time.

 

Thanks in advance.

0 Kudos
Message 1 of 9
(3,828 Views)

Mark required inputs.  Not a big fan of breaking second loop on any error condition.  Would be best to send a stop command to break second loop with creating an error.

 

Matthew Fitzsimons

Certified LabVIEW Architect
LabVIEW 6.1 ... 2013, LVOOP, GOOP, TestStand, DAQ, and Vison
0 Kudos
Message 2 of 9
(3,817 Views)

I don't know the grading standards, but here are some very general observations (They may not coincide with NI!).

  1. The code looks very clean in is nicely laid out and documented.
  2. I don't know the requirements. Are the colors correct for all 8 possible states?
  3. For some reason, the diagram windows are all maximized to the screen. I don't like that because I tend to work on multiple diagrams in parallel. On large monitors, it is distracting to see code the size of a postcard surrounded by oceans of whitespace. 😉
  4. In the "process zones" subVI, you should use a FOR loop. Show the conditional terminal so you can terminate early on error condition, but at least you don't need to count iterations.
  5. Personally, I don't like that series of select statements and all these seperate diagram constants. You could make the three boleans into a 3bit number and use it to index into a 2D array of colors, for example.
  6. You could also use an array of color LEDs for the indicator. Less convoluted code. (This might be too exotic until LabVIEW ships with a color LED!) 🙂 In this case you could have the subVI simply return an array of colors and wire directly to the indicator, eliminating the need for references and all that associated baggage, such as property nodes.
  7. You don't properly initialize the status indicator. If I would manually color one to purple, it will stay that way when the program is run until one of the buttons is pressed. (This is not a problem once the code is built into an application).

This is free advice. Don't blame me if you get deductions based on my ideas. 😄

 

Oh, and if you like my color LED suggestion, feel free to give it a vote here. Thanks! 😄

Message Edited by altenbach on 06-18-2009 04:38 PM
Message 3 of 9
(3,811 Views)

Thanks for the feedback Mr. altenbach & Mr. Fitzsimons.

 

altenbach, I figured you would be one of the early ones to comment on my code and thanks for the detailed feedback.

What a nice feature is the "conditional terminal"for a for-loop! I never knew about it.

Btw, sorry for the maximized screens. Since I was in a rush, I figured the bigger my window the less cluter I have to deal with when writing my code.

 

 

Mr. Fitzsimons,

What do you mean by "Mark required inputs"?

Is it for the VI Documentation or in the block diagram?

0 Kudos
Message 4 of 9
(3,791 Views)

Right click the terminal and set to Required.  You VI won't run right unless you have an input.  Required causes LabVIEW to not allow the code to run unless the terminal is connected.  Good coding pratice and that is what the test is all about.   Good Luck!

 

 

Matthew Fitzsimons

Certified LabVIEW Architect
LabVIEW 6.1 ... 2013, LVOOP, GOOP, TestStand, DAQ, and Vison
Message 5 of 9
(3,775 Views)

Understood. I generally do define required/optional inputs but I figured that woudn't be required based on the previous exam solutions.

Nevertheless, thanks and I will stick to my regular practice.

0 Kudos
Message 6 of 9
(3,773 Views)

The LabVIEW style guide should be your reference.  This is what they use to grade you.

 

http://www.ni.com/pdf/manuals/321393d.pdf#labview_style_guide

 

Matthew Fitzsimons

Certified LabVIEW Architect
LabVIEW 6.1 ... 2013, LVOOP, GOOP, TestStand, DAQ, and Vison
0 Kudos
Message 7 of 9
(3,741 Views)

Just to prove my point for the need of color LEDs, here's how the subVI would look like if we had an array of color LED on the FP.

 

 

This is significantly simpler than to iterate over the controls of a cluster via reference. 😉 Agreed?

 

(I am not saying you should do that for the CLD exam! :D)

 

Message Edited by altenbach on 06-19-2009 11:23 AM
0 Kudos
Message 8 of 9
(3,714 Views)

I just did my exam today and altough I didn't finish it I am very confident that I will pass by the mercy of the Lord.

Like most CLD exams it had a FILE I/O section but I decided from the get go that I will not do it since it would hamper my over progress.

Hence, I completed the 80% of the project and from that I think I got 95% of it working with proper style & Full documentation.

 

Thanks for the reference Mr. Fitzsimons. It seems like I am on the rigth track and we'll find out in a month.

 

Mr. altenbach, suprisingly that's how I did the first time about a year ago.

Instead of boolean LEDs in the Front Panel, I actually put those color boxes as indicators.

Hopefully, NI folks will implement color LEDs like you mentioned and I voted on your LabVIEW IDEA exchange post.

 

Once again, thanks for the feedback folks. 

0 Kudos
Message 9 of 9
(3,693 Views)