News Archive (1999-2012) | 2013-current at LinuxGizmos | Current Tech News Portal |    About   

Hands on with LabVIEW and Embedded Linux (Part 3)

Oct 14, 1997 — by Rick Lehrbaum — from the LinuxDevices Archive — 1 views

Why use a desktop OS to build an embedded system?

An embedded computer system is one where the computer (and of course its software) is hidden away inside of an overall instrument or system. The problem with embedded computer systems is that they're generally not as easy to develop software for as a desktop system. Embeddable computers often lack many of the features you're used to on the desktop, and require an external development system or host computer on which to write and debug the code. Furthermore, you're almost always forced to write your programs in C, or maybe something worse. It's an arcane world staffed by those of us who get a kick out of very low-level hardware and software interfacing challenges.

High-volume consumer products will always need custom hardware and software. Many other embedded systems will need special hardware and real-time support that can only be delivered by a custom embedded operating system. But increasingly many of the functions needed by the next generation of embedded devices can be filled by using application-specific software on a small form factor PC running a desktop operating system.

Why Linux?

There are so many reasons why Linux is becoming a force in the embedded world it would be impossible to list them all. Linux is free but, more important, it's also crash resistant and modular. It can be adapted to run on almost any hardware from a super computer to an embedded computer. The source code for Linux is open-available for anyone to inspect, modify, and distribute.

There are many different versions of Linux that you can download for free from the Internet or purchase for a modest cost at a store. All of them are based on the kernel source available from kernel.org and include applications built from many other open source projects around the web. The biggest difference between most of the distributions is where the configuration files are stored, how automated the configuration is, and what additional tools and applications the vendor may have provided.

The embedded Linux system that comes on our book's CD has been made with PeeWeeLinux. PeeWeeLinux is based on RedHat Linux and the version at the time we wrote our book was RedHat 6.2. If you've looked around the web in search of a small Linux distribution, you've seen many different ones, each one designed for a different purpose. This malleability is making Linux the ruler of embedded systems but it can make choosing the best embedded Linux version for your LabVIEW application tough!

Fortunately for us PeeWeeLinux has everything we need to let us build a small embedded distribution that can run LabVIEW.

PeeWeeLinux is a dynamic project that is dedicated to providing “an environment that makes the configuration and installation of a Linux operating system on an embedded platform as easy and painless as possible”. We evaluated many embedded Linux tools before deciding on PeeWeeLinux.

What is real-time Linux?

For some time critical tasks you may need a real-time version of Linux. There are two main choices, RTLinux or RTAI. Each consists of a small microkernel that abstracts hardware interrupts from the Linux kernel and runs normal Linux as the lowest priority task. The microkernel responds to any hardware interrupts and runs the real-time task that is associated with the interrupt. If you think you need hard-real time support then look at Chap. 24 , “Interfacing LabVIEW to Real-time Linux,” and we'll tell you more about using LabVIEW with real-time Linux.

It's important to note that LabVIEW itself does not become a real-time application under real-time Linux. Instead, you write real-time tasks in C and run them independently, with efficient communications between the real-time kernel space and the non-real-time user (LabVIEW) space. Chapter 24 covers those communications techniques as well as a discussion of the process of building a real-time Linux system. However, it's outside the scope of our book to cover real-time programming in C.

Continued



Story navigation . . .

 
This article was originally published on LinuxDevices.com and has been donated to the open source community by QuinStreet Inc. Please visit LinuxToday.com for up-to-date news and articles about Linux and open source.



Comments are closed.