Programming guidelines -
Measurement and control with LabVIEW
These guidelines/rules should be followed as closely as possible in the finalized, individual project. Use them as a help during discussions and suggestions of improvement.
- Name all indicators and controls
- Only update settings that need to be updated - use event structures
- Don't use Wait(ticks) to make things work
- Keep the amount of inputs and outputs low (max about 4 each) - use structures or refnums
- Never hard-code parameters that could change, such as VISA addresses
- Design a simple, uncluttered icon for each .vi
- Use threading when possible
- Don't show any internal structures or variables
Questions suitable for group discussions
- What is the main goal of the project?
- Which communication protocols does the project use? Are there any alternatives?
- How are commands sent? How is the information received?
- What part takes the most time to execute?
- What happens if the communication is lost?
- Is the program structure suitable for extension to several commands/measurements/instruments?