Writing Software To Support Easier Configuration Management

By James McNally | Software Engineering

system configuration management

As well as the system installation concepts we have discussed in the last few articles I wanted to cover a couple of software features I put into most of the software I write to ease longer-term support and easy setup.

Create Required Directories and Configurations

When I started writing software, I would often end up doing an install and then setting up the file system. Now I avoid that.

The software itself will create any directories it depends on and creates a sensible default configuration.

Creating directories can be done as part of the installer, but I tend to end up putting it in the software itself as it usually integrates well with other features. 

With this setup, when you complete the installation, the software will just run.

Version and Upgrade Configurations

I will include a version number with configuration formats and ensure that the software can at least take one previous version and migrate it to the new format. Conversion generally means handling:

  • Name changes
  • New items with default values.
  • Removed items (this one is pretty easy!)

Again, this is about ease of upgrading. The last thing you want to do is hand-tweak ten config files (and the likely typos and syntax errors that come with it!). If you need others to do an upgrade, this is also likely to generate many support calls.

Instead for a small investment in coding time, you can make that upgrade process seamless.

Auto-Detect Hardware

Did you remember to rename the DAQ card? Relying on hardware names is essentially another external dependency to remove.

Unless your software expected to sit on a very general-purpose system – I use the system configuration API to auto-detect all the hardware I can. For DAQmx, FPGA and VISA-USB you probably shouldn’t have to type a name in a configuration again.

I use the code example below on a system designed to support multiple FlexRIO cards:

LabVIEW Code of FlexRIO Detection

By auto-detecting this we remove a step from every system setup and any debugging session looking at hardware.

Summary of Articles

That’s all the articles on configuration management for now. We’ve gone from why configuration management through to looking at platforms and now software configuration. The full list of items is below or get in touch if you have questions.

Part 1: Why Plan For Keeping Measurement Systems Up To Date

Part 2: How Do I Keep My Windows Systems Up To Date

Part 3: How Do I Keep My Real-Time Systems Up To Date

Part 4: Writing Software to Support Easier Configuration Management

Follow

About the Author

I founded Wiresmith Technology to help engineers improve their systems and products with quality measurement systems. I'm a Certified LabVIEW Architect, Certified LabVIEW Embedded Developer and LabVIEW Champion.

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close