Academic Company Events NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Document Type: Tutorial
NI Supported: Yes
Publish Date: Sep 6, 2006


Feedback


Yes No

Related Categories

Related Links - Developer Zone

NI-1394 External Drive Support

10 ratings | 3.70 out of 5
Print

Overview

The NI-1394 External Drive Support driver provides support for external FireWire® disk drives on LabVIEW Real-Time systems with IEEE 1394, such as the NI CVS-1450 Series compact vision system. External FireWire drives are hot swappable and can easily extend disk storage capacity on an embedded system. External FireWire disk drives are readily available as consumer products and are relatively inexpensive.

NI-1394 External Drive Support implements the Serial Bus Protocol (SBP-2) for storage devices. SBP-2 is a protocol abstraction layer that transports SCSI packets from one node to another. Packets are transferred from the host node, which is a LabVIEW Real-Time (RT) Module controller, such as a PXI chassis or an NI CVS-1450 Series device, with the OHCI Host Controller, over the physical layer, which is a FireWire cable, to the target node, which is an SBP-2 external FireWire drive. A typical FireWire drive has a desktop IDE drive and a coprocessor that converts the SBP-2 protocol to IDE commands. The translated IDE commands are sent to the drive, and data is transferred in a similar fashion.

Requirements

The following list includes system requirements for using NI-1394 External Drive Support:
  • LabVIEW 7.1 RT for ETS or later
  • NI-1394 External Drive Support 1.2 or later
  • An OHCI compliant IEEE 1394 Host Controller such as the NI PCI/PXI-8252 or NI CVS-1450 Series compact vision system
  • SBP-2 External FireWire drive formatted FAT32

    Hardware Installation

Complete the following steps to install the PCI/PXI device you use with NI-1394 External Drive Support:
  1. Install the NI PCI/PXI-8252 into an available slot in the system.
  2. Connect the external FireWire drive with the FireWire cable.
  3. Power on the external FireWire drive with an external power source, if necessary.

Note: The NI CVS-1450 Series device does not require any hardware installation.

Software Installation


Complete the following steps to install software on the remote device you use with NI-1394 External Drive Support:
  1. Launch Measurement & Automation Explorer (MAX).
  2. In the configuration tree, expand Remote Systems, and select the device you want to configure.
  3. Expand the device, and select Software.
  4. Click Install Software.
  5. In the LabVIEW Real-Time Install Software Wizard, select the following software:
    • LabVIEW RT 7.1 or later
    • NI-1394 External Drive Support 1.2 or later
  6. Select any other software you want to install on the device.
  7. Use the Next button to navigate through the remainder of the LabVIEW Real Time Install Software Wizard.

Note: NI-1394 External Drive Support ships on the May 2004 Driver CD or with NI-IMAQ for IEEE 1394 Cameras version 1.5.2. Later versions of the CDs may have an updated version of the External Drive Support.

Using NI-1394 External Drive Support


Because external FireWire drives are hot swappable, the system can detect a drive that is added while the system is powered on. When a new external FireWire drive is detected by the operating system, it is assigned a drive letter. The first drive letter is G. If another drive is connected, the operating system assigns the drive letter H, and so on. The drive letter assignments are stored in a text configuration file, which is stored in c:\ni-rt\system\partititions.ini. The driver letter assignments persist between reboots regardless of plug and play order. To change the drive letter for a storage unit, you must edit the configuration file manually and reboot the system.

Note: Drive letters A-F are reserved by the operating system and cannot be used.

Access drives using the standard LabVIEW File I/O primitives. Open a file with the appropriate drive letter. If the drive is an internal device (C), requests are dispatched to the local system. If the drive is an external device (G or above), requests are dispatched over the external FireWire cable. The same VIs are used for an internal or external storage application.

Refer to the External FireWire Drive Enumeration example program link below for an example VI that uses the NI-1394 External Drive Support driver.

The external drives are also available through the NI FTP server running on the LabVIEW RT target. If a target has an IP address of 192.168.1.101 and the FireWire drive is connected to drive letter G, you can access the drive directly by entering ftp://192.168.1.101/g: in a web browser.

See Also:
NI-1394 External Drive Enumeration

Troubleshooting


The following sections include common questions regarding using NI-1394 External Drive Support.

Why am I unable to access the FireWire drive using the LabVIEW File I/O primitives?

  • Ensure the external FireWire drive is connected to the OHCI Host Controller.
  • Ensure the external FireWire drive is powered on correctly.
  • Install the LabVIEW RT 7.1 and NI-1394 External Drive Support 1.2 or later. Check to determine if the drive letter configuration file is on the remote target. This file is created when the SBP-2 driver loads.
  • If the drive letter configuration file is present on the remote target, ensure you are using the correct drive letter. Attempt to connect to all drive letters that are listed in the configuration file.
  • If you are still unable to access the drive, attempt to power cycle the external FireWire drive.
  • If all else fails, the drive may be malfunctioning. Connect the FireWire drive to a PC to determine if the device is visible.

When I first access the device, it takes a long time to respond and eventually fails with an error message. What is wrong?

The drive is probably incorrectly formatted. LabVIEW RT 7.1 for ETS only supports DOS compatible FAT file system. Reformat the drive appropriately.

How do I format the FireWire drive?

LabVIEW RT currently does not support formatting the external FireWire drive. Connect the drive to a desktop machine running Windows to format the drive.

Note: Windows XP supports FAT 32 partitions only up to 30GB when formatting with operating system disk tools. If you want larger contiguous partitions, remove the IDE drive from the FireWire enclosure and format the entire partition using DOS.

How can I improve my performance with external FireWire drives?

Actual performance depends on the cache on the IDE disk drive. Larger read and write caches translate to better access times. Larger block accesses also translate to better performance. For optimal streaming, all data blocks should be large multiples of 512 bytes that do not exceed the cache size of the IDE disk drive in the FireWire enclosure.

10 ratings | 3.70 out of 5
Print

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/).