LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to become a bad labview developer - According to ChatGPT

 


💀 How to Become Bad at LabVIEW


1. Use Only Flat Sequence Structures

Because nothing says "professional" like a 3-screen-wide sequence with 50 frames and no comments.

  • Completely ignore state machines, events, or QMH.

  • Use "Frame 32" to control logic instead of meaningful state names.


2. Spaghetti Wires Everywhere

Why route wires cleanly when you can just cross them 100 times?

  • Don’t label wires.

  • Cross wires over front panel terminals and structures.

  • Use random colors for signal wires to make it "artistic".


3. Never Use Typedefs

Just create 17 copies of that enum and update them individually.

  • Bonus points for different ordering of the same enum in different VIs.


4. Global Variables for EVERYTHING

Who needs data flow when you can have data chaos?

  • Use global variables to pass data between states, loops, even parallel VIs.

  • Watch your code randomly break when race conditions occur!


5. Write One Giant VI

1000x1000 pixels. One VI. One love.

  • Don’t modularize.

  • Put all logic in one huge block diagram.

  • Nest structures 10 levels deep.


6. No Error Handling

Just wire errors into a constant and move on. YOLO.

  • Errors are suggestions, right?


7. Poll Everything in a Tight Loop

Efficiency? Never heard of it.

  • Check every button and sensor every millisecond, in a greedy polling loop.

  • Who needs event structures or timing?


8. Don't Use Documentation

Comments are for the weak.

  • Use cryptic abbreviations like xxRTCB_Ctrl.vim with no explanation.

  • Bonus: Delete all front panel labels and captions.


9. Ignore LabVIEW Style Guides

Standards stifle creativity!

  • Use different styles in every VI.

  • Mix camelCase, snake_case, and CAPSLOCK.


10. Save Everything on Desktop, No Version Control

If you lose your code, that’s fate.

  • No Git, no SCC, no backups. Overwrite previous versions with "final2.vi", "reallyFinal.vi", "NEWfinal(3).vi".


11. Hardcode Everything

Make sure every path, value, and constant is typed manually. Preferably in multiple places.

  • Forget INI files or config clusters.

  • Want to change the baud rate? Go find it buried in 12 different places.


12. Ignore User Events, Producer-Consumer, or Queued Message Handlers

Use one loop. One big loop. Forever.


🎯 Result:

Your boss cries. Your co-workers quit. LabVIEW crashes. NI sends a representative to ask what you've done. 🤣

 

Message 1 of 5
(236 Views)

Other possible result: The hacker gets the code limping along; and the boss, never looking under the hood, thinks it's a job well done.

Message 2 of 5
(200 Views)

@paul_a_cardinale wrote:

Other possible result: The hacker gets the code limping along; and the boss, never looking under the hood, thinks it's a job well done.


Sad to say this is what happens most often. Early in my career I was handed some LabVIEW code that was heralded as one of R&D's greatest achievements and told to modify it for the V&V lab. The code was one big loop (OBL) full of locals and flat sequences. To read it you had to follow the Error Cluster squiggling around the block diagram like following a treasure map. (facepalm)

 

I put my foot down and flat out refused. Then wrote a better more modular program that fit our lab's needs from scratch in less time that I estimated it would have taken to fix that code. 

========================
=== Engineer Ambiguously ===
========================
Message 3 of 5
(182 Views)

@RTSLVU wrote:
To read it you had to follow the Error Cluster squiggling around the block diagram like following a treasure map. (facepalm)



At least he had an error line, you can give him that 😄

Message 4 of 5
(95 Views)

Spot on! Except the singular VI should be at least 10k x 10k!

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 5 of 5
(55 Views)