Programming Additional ARM Microcontrollers with LabVIEW (without the LabVIEW Microprocessor SDK)
Overview
The 32-bit RISC ARM processor architecture developed by ARM Limited is widely used across many embedded designs due to its low price, low power consumption, and wide variety of peripherals for many of the major silicon vendors. Today, the ARM family accounts for more than 75 percent of all 32-bit RISC CPUs. You can use the NI LabVIEW Embedded Module for ARM Microcontrollers for programming ARM microcontrollers with the RTX embedded operating system.
This document offers a general outline for targeting LabVIEW code to any custom ARM target using only the LabVIEW Embedded Module for ARM Microcontrollers. For additional information, read the LabVIEW Embedded for ARM Porting Guide.
Table of Contents
Integration of LabVIEW and Keil Toolchains
To port an ARM target to LabVIEW, the target must support the RTX Real-Time Kernel. For an ARM target to support live front panel debugging, the target must also work with the Real-Time Agent module.
To determine if your target already supports the RTX Real-Time Kernel, browse to the \Keil\ARM\Startup directory, then browse to the folder that corresponds to the manufacturer of your ARM microcontroller. If there is an RTX_Conf*.c file for your target, then the RTX Real-Time Kernel has already been ported for your ARM device. If no such file exists, go to The LabVIEW for ARM Porting Guide - Chapter 4 for more information on the RTX Real-Time Kernel and a guide for porting RTX to your ARM microcontroller.
To determine if your target already supports the Real-Time Agent module, browse to the \Keil\ARM\RT Agent\RTX directory, and locate the device that corresponds to your ARM microcontroller. If you are able to locate your device in this directory, then the Real-Time Agent module has already been configured for your device. If your device does not exist in this directory, read the The LabVIEW for ARM Porting Guide - Chapter 5 for more information about the Real-Time Agent module and a guide for adding the module to your application.
If the RTX Real-Time Kernel and Real-Time Agent module have already been developed for your ARM microcontroller, continue with this chapter to create a new embedded target in LabVIEW. Creating the target entails modifying a template μVision project to a form that LabVIEW recognizes, incorporating all of the driver source code for the essential peripherals, and integrating the Keil toolchain.
If support for the RTX Real-Time Kernel and Real-Time Agent module has not already been developed for your ARM microcontroller, such as the case with the LPC3180, see chapters 4 and 5 for more information on how to accomplish this.np
Create Your Target Folder
All of the ARM targets for LabVIEW use the same plug-in VIs. Therefore, to ease the process of adding a new ARM target to LabVIEW, a generic target has already been provided that contains a TgtSupp.xml file configured with the correct plug-in VIs, folder structure, and placeholder driver files. Creating a new target for LabVIEW involves creating a new folder and modifying two ini files.
- Navigate to labview\Targets\Keil\Embedded\RealView\Generic.
- Make a copy of the LPC2378 folder in the Generic folder.
- Rename the new folder to LPC3180.
- Open labview\Targets\Keil\Embedded\RealView\Generic\TgtSupp.ini in a text editor.
- Add the following line that specifies the folder name and the target name to appear in LabVIEW:
LPC3180 = Phytec LPC3180
- Save and close TgtSupp.ini.
- Open labview\Targets\Keil\Embedded\RealView\Generic\ LPC3180\TargetConfig.ini in a text editor.
- Add any necessary paths, #defines, and libraries for any additional drivers here.
- Save and close TargetConfig.ini.
- Update the µVision template files in the labview\Targets\Keil\Embedded\RealView\Generic\LPC3180\Template folder. For a tutorial that includes updating the template file, view the LabVIEW Embedded for ARM porting Guide - Chapter 2.
Using the “Other” Target
If you followed the steps above (including updating the template files), the next time that you run LabVIEW, you will be able to program the new microcontroller using the Other target. To do so, follow these steps:
1. Launch LabVIEW, and start the ARM project wizard by selecting ARM project and clicking Go.

2. Follow the onscreen prompts. When you are asked to select the ARM target type, choose Other as the target processor.

3. On the subsequent screen, you will see the LPC3180 as a processor option.

Reader Comments | Submit a comment »
Legal
This tutorial (this "tutorial") was developed by National Instruments ("NI"). Although technical support of this tutorial may be made available by National Instruments, the content in this tutorial may not be completely tested and verified, and NI does not guarantee its quality in any way or that NI will continue to support this content with each new revision of related products and drivers. THIS TUTORIAL IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND AND SUBJECT TO CERTAIN RESTRICTIONS AS MORE SPECIFICALLY SET FORTH IN NI.COM'S TERMS OF USE (http://ni.com/legal/termsofuse/unitedstates/us/).
