JKI

You are currently browsing the archive for the JKI category.

team

We love NIWeek.  It’s a great opportunity for us to connect with the LabVIEW community and share ideas.   We’re busily finishing our preparations for NIWeek 2009 and want to call your attention to some of the can’t-miss events that excite us the most.

twitter-logoNote: You can also follow JKI Software on Twitter to stay up-to-date on any schedule changes or last-minute plans throughout the week (including impromptu foosball tournaments!). We look forward to seeing everyone in Austin in a few days!


JKI NIWeek 2009 Schedule

All Week

JKI Booth, (#335) by the Robotics Pavilion (see expo floor plan).  We’ll be there all week showing off our commercial products, like VI Package Manager, the JKI TortoiseSVN Tool for LabVIEW, EasyXML, and the JKI State Machine, as well as JKI Labs tools like VI Tester and the new JKI Right Click Framework. Drop by for a demo, or to get answers to your questions, or just to chat about whatever is going on at JKI and in the LabVIEW world!

Sunday

Evening/Night: Pre-conference warmup at The Ginger Man. If you’re in town Sunday night, drop by and grab a few beers before things get hectic! Note that The Ginger Man has moved since last year — it’s only a half-block away, but check their website for the new address.

Tuesday

12:00 PM (Tech Theater): LabVIEW Experts Panel – Jim Kring will be answering LabVIEW questions, with other LabVIEW experts.

8:00 PM: LAVA/OpenG NIWeek BBQ 2009 at Stubb’s BAR-B-Q. The yearly tradition. Come enjoy great BBQ with dozens of LAVA, OpenG, and NI personalities. (Special note from LAVA: Please pay via PayPal ASAP; see the linked LAVA thread for details.)

Wednesday

8:30 AM (Ballroom G): NIWeek Keynote – you definitely want to see this one!  And, make sure to keep your eye out for a world-premier demo of some amazing new tools from JKI Software.

10:30 AM-11:30 AM (Room 16B): TS1238-SW – LabVIEW Code Reuse for Teams and Large Projects, presented by Jim Kring. Abstract >> LabVIEW code reuse is a key component of team-based development, large project work, and knowledge sharing within an organization. Learn how to create a shared repository of reusable VIs and use analytics tools to report your organization’s software reuse metrics.

I’m terrible at remembering important details.  I’m great at relatively useless stuff, like powers of 2 and the lyrics to songs my parents used to sing.  I even remember the phone number of a girl I had to call once in fifth grade, to get homework from her because I missed school that day.  It had two consecutive zeroes in it, which I thought was cool.  Come to think of it, I should see if she’s on Facebook.  Anyway, my point is this:  I forget stuff that matters.  One example of something I forget, which matters a lot, is how to build my customers’ applications.

That’s why I create a one-click build VI for every project.

The idea of a one-click build VI is that anyone should be able to check my code out of SVN, open build.vi, hit Run, and build the application (or the VI Package, or whatever).

Example One-Click Build VI

Example One-Click Build VI (Front Panel)

Some smart people whose work I respect are big on this, and a one-click build VI offers several immediate advantages as soon as you start using it:

  1. It helps you document your build process,
  2. It makes it easy to build early and build often, and
  3. It lays the foundation for other good software engineering techniques.

I’m going to elaborate on each of these items, and then at the end I’ll show you how easy it is to get started with your own one-click build VI.


1) It helps you document your build process

For complicated applications that have multiple, separate pieces, an automated build is essential.  But even for small projects, the cycle of releasing an application can be surprisingly long:

  1. Build the EXE.  …and wait for it to finish.
  2. Build the Installer.   …and wait for it to finish.
  3. Find the installer on disk and zip it up.  What’s the convention I use for naming the ZIP?  Oh, yeah, I remember.
  4. Upload the installer to the FTP site.  What directory does it go in?  Oh, there it is.
  5. Copy the installer ZIP to the archives. Where are those archives again?
  6. Commit the project file to SVN, because the build process modified it.  Did I do that already?  Maybe after #2?  I don’t remember.  Oh, OK, I already did that.

The point is that even for simple applications, this process is long and error-prone, and you should write it down so you do it exactly the same way every time (because you’re a good engineer, and you care about repeatability).  So if you need to write it down anyway, why not write it in code?  Then, those 6 steps above collapse to

  1. Open build.vi and click Run.

That makes it easy for you to build your app whenever you feel like it.  How about over lunch?  Or when you leave your desk every night?  Or during that otherwise time-wasting meeting with your boss?

Not only that, when you use a one-click build VI, anyone can build your app exactly the same way.  It decreases the amount of tribal knowledge in your organization, because the build process is captured in the code, even if code itself is terrible (have you considered the JKI State Machine?).  Decreasing tribal knowledge is important because you might get hit by a bus.  Don’t laugh, it happens.

Example One-Click Build VI (Block Diagram)

Example One-Click Build VI (Block Diagram)


2) It makes it easy to build early and build often

If your build process is easy, you’ll want to build your application.  Or looking at it another way, if your build process isn’t easy, you won’t want to build your application.  We already know that it’s a good habit to build your EXE on day one, and keep it working.  But building is a mental context switch, and it takes you away from whatever other really important stuff you’re doing.  That’s why the act of building your EXE should be so trivial that it’s kind of fun.  Opening build.vi and clicking Run is pretty fun, as far as crummy, repetitive tasks go.


3) It lays the foundation for other good software engineering techniques

A one-click build VI is a type of automated build.  And an automated build is a core piece of a successful continuous integration system.  But continuous integration isn’t just for big companies with big products.  Imagine if you had a one-click build VI for your project, and you set it up to run every night at midnight.  Then you could come to work every morning, and a shiny, brand-new build of your current app would be waiting for you to test.  Or, if the build is broken, you’d know it immediately.  This allows you to have trust in your system, and in your software, throughout the development cycle.


OK, so how do I make a one-click build VI for myself?

The VI you see above is a typical one-click build VI for a project with an EXE and installer, built using NI’s application builder in LabVIEW.  It also includes some ancillary features, like zipping up the installer, making some changes to the project file XML, and committing the modified project file to SVN.  It incorporates some switches so I can enable & disable some of these features as required.

But you don’t have to go to that level of detail to get started with a one-click build.  NI gives you everything you need:

BuildTargetBuildSpecification.vi from vi.lib

BuildTargetBuildSpecification.vi from vi.lib

The VI highlighted above is located on your system at <LabVIEW>\vi.lib\AppBuilder\BuildTargetBuildSpecification.vi.  NI has a couple of reference pages on the topic here and here.  You pass it your EXE and/or installer build scripts as shown, and in seconds you’ll be on your way to forgetting everything about how to build your customers’ applications, just like I have.

In the future, I’m going to talk more about specific ways you can use a one-click build VI in your projects.  In fact, I’ll probably write those articles while a one-click build is running in the background!

Recently, National Instruments has been vocal about wanting to provide better support for third-party LabVIEW add-ons.  A huge demonstration of this commitment, recently, was allowing JKI to integrate VI Tester into the LabVIEW project environment.  In fact, it might seem surprising or even foolish for NI to do this, considering that it just released a competing product, the NI LabVIEW Unit Test Framework Toolkit.  But, if you look deeper, you’ll see that NI’s support of a competing third-party add-on for LabVIEW is a very smart, mature, and strategic move.

For a long time, I have had concerns about whether NI would be able to nurture a viable market and ecosystem for third-party add-ons for LabVIEW, because of the fact that NI sells its own add-ons for LabVIEW.  This creates a huge, short-term incentive for NI to compete directly against third-parties (like JKI).

But also, NI has a huge incentive to encourage third parties to innovate on its platform.  The more tools and solutions that exist on the LabVIEW platform to help users efficiently create working systems, the better it is for NI.  If NI were to compete aggressively against third-party LabVIEW add-on providers, it would starve the ecosystem and send third-parties running for the hills.  Small companies simply cannot compete against NI head-to-head.

At JKI, we are very excited about LabVIEW becoming an even more powerful, open platform for 3rd party tools.   As you might know, we love to create toolkits for LabVIEW, and our flagship product, VI Package Manager, is a powerful tool for packaging, distributing, and installing add-ons for LabVIEW.  We hope that NI continues to open up LabVIEW and we’ll try hard to provide them with both our feedback and support.  And, of course we’ll work hard to create more great add-ons for LabVIEW.

At JKI, we like to “eat our own dog food”, which is just a fancy way of saying that we use our own products.  Specifically, we use our own products to help us create our products.  I’ve alluded to this before, but now I’ll explain in more detail, now.

We Use VI Package Manager (VIPM) to Package, Distribute, and Install our Tools

At JKI, we use VIPM in the following ways during our LabVIEW development efforts:

  • We create VI Packages of both our internal reuse libraries and our commercial toolkits.
  • We share our VI Packages with the JKI team over the Internet using VIPM Enterprise Edition.
  • We distribute our commercial toolkits to the community through the VI Package Network.
  • We install VI Packages into LabVIEW (using VIPM) for use in our projects and products.
  • We manage each of our project’s VI Package Configuration files.

We use our Internal Reuse Libraries and Commercial Toolkits in our Products’ Source  Code

JKI’s Software products, including VIPM, are written in LabVIEW.  In these projects, we use our in-house software reuse library and commercial toolkits.  For example, in VIPM’s source code we do the following:

  • We use our extensive reuse library for image, file, array, and all sorts of other common tasks.
  • We use EasyXML for parsing and generating XML files used by VIPM.
  • We use the JKI State Machine nearly everywhere that you might expect to find a while loop.

In a nutshell: We use our internal reuse library and commercial toolkits in nearly every product that we develop.

We use VI Tester to Test and Validate all our Products

VI Tester is a critical tool for validating that our software works correctly and helps us identify problems before we ship the software to customers.  We use this powerful software testing framework in the following ways:

  • We use it to test nearly every aspect of VIPM’s source code.
  • We use it to validate that EasyXML meets it’s functional requirements and the XML specification.
  • We use it to test and validate VI Tester.

Closing the Loop — Using our Products to Create our Products

An interesting thing happened once we started using our products to help us create our products.  We created a cycle where incremental improvements in one tool (product) had an amplified effect — all of the other tools that were using it benefited from the improvements.  This created a flywheel effect, building inertia with each improvement to our tools.

In some cases a tool became critical to the development of the tool itself.  If that sounds confusing, I’ll give you an example:

  • We use VIPM to help us develop VIPM
  • We use VI Tester to help us test VI Tester

It took us quite a while to get to this point.  We’ve been working on VIPM for about 5 years and each release has gotten better and better.  At some point we realized that VIPM was critical to the development of VIPM itself and, now, we couldn’t imagine life without it.

Eating our own dogfood at JKI means that we have a lot of confidence in our tools and that we’re invested in seeing them succeed.  As a customer and user of JKI software, we hope this gives you confidence in our products, too.

What’s Next?

It’s hard to say for sure, but what I can say is that we’ve got a LOT of great tools in the pipeline.  Our tools provide us with a very powerful platform for developing other LabVIEW tools and we’re planning on releasing more of them soon.  These new releases will most likely start out in the JKI Labs, so stay tuned.

Do you have any questions or thoughts about this article?  Please feel free to leave a comment or contact us.  We’re looking forward to hearing your feedback.