Developer Center Blog

Community Browser
cancel
Showing results for 
Search instead for 
Did you mean: 

LabVIEW 2012 Project Templates and Sample Projects

RDR
NI Employee (retired)

The post below was taken from a blog post by Christina Rogers and highlights a new feature in LabVIEW 2012, Project Templates and Sample Projects.  You can take advantage of this LabVIEW feature and provide customers with a starting point for developing applications using your toolkits and APIs by creating your own project templates.

 

 

In LabVIEW 2012, new Project templates and Sample Projects help you get started with a project as quickly as possible.

 

Some of the best weapons against “spaghetti code” – diagrams that are hard to read and impossible to maintain – are design patterns such as the Simple State Machine and Queued Message Handler. The Project templates promote starting with one of these tried-and-true designs.

 

 

You can also create your own Project templates and Sample projects, but I’ll talk about that more in a future post.

 

To use the new Project Templates and Sample Projects, you’ll use the Create Project dialog. You can access this dialog by clicking the Create Project button on the LabVIEW 2012 Getting Started window. It’s also in the File menu and the Project menu.

 

 

The Create Project dialog lists the available Project templates and Sample Projects. I am only showing the core set; modules and toolkits can install additional items.

 

 

 

 

If necessary, you can narrow your choices by selecting a category in the left-hand column or typing keywords in the Search box.

 

 

After selecting your starting point, you click Next. Depending on the item you have chosen, you may see a different dialog than the one below. For the Simple State Machine, you need to decide your project’s name and location on disk. You can optionally prefix your file names (in case you want to make all your VI names unique across multiple projects) and define a custom icon overlay.

 

 

 

 

 

When you click Finish, you will have a new project to work with. This project is a customized copy of the template, so you don’t need to worry about edits to the VIs interfering with other applications (which can happen when people edit examples).

 

 

 

 

You can now open the Main VI and explore the contents of your project. Areas where you will probably want to focus on writing your own functionality are highlighted with blue comments. Here is the Main VI of the Simple State Machine template:

 

 

 

 

You may also want to review the Project Documentation, which explains the template (or Sample Project) in great detail.

 

 

We believe that the Project templates and Sample Projects will not only get you to a working application faster, but also lay the groundwork for applications that can be extended and maintained long into the future.


Originally posted by Christina at http://blog.eyesonvis.com/2012/08/15/labview-2012-project-templates-and-sample-projects/

 

 

This new feature can be used as a tool to help your customers begin developing with your API quickly and effectively by providing a framework for development.  Consider adding any required operations from your API (initialization, configuration, and cleanup routines) and any software framework a customer would duplicate in their application to a template to avoid duplicate effort or copying and pasting from shipping examples.  Add documentation to your templates to highlight default settings, algorithms, and places to add functionality & customize the configuration to meet different use cases.

 

Creating Custom Templates and Projects

DevZone: Using Custom Templates and Projects to Develop LabVIEW Projects

Creating and Distributing Custom Templates with the New Create Project Dialog