Skip to Main Content Skip to Search
Product Documentation

Analog Input Frame Driver Blocks

Introduction

The following UEI PowerDAQ board series have Analog Input frame driver blocks:

In frame-based mode, the boards for these driver blocks send interrupts to the xPC Target software. The xPC Target model is executed when each frame completes on the board. For proper use of the UEI frame driver blocks, note the IRQ values for each UEI board in the model and configure those boards appropriately with the model Configuration Parameters dialog.

Notes on Master and Slave Boards

Before you begin, observe the following usage notes for the UEI boards in a master/slave configuration:

Interrupt Numbers

This topic describes how you determine the interrupt number to which the board is set. The methods vary depending on your hardware configuration.

This topic includes

Single UEI Board

If you have one UEI board for your target machine, that board is the master.

  1. Insert the UEI board in a slot of your target machine.

  2. Reboot the target machine.

  3. On the host computer, open the model that you want to use with the UEI board.

  4. In the Simulink > Configuration Parameters dialog box, select the xPC Target options node.

  5. In the Real-time interrupt source parameter, select Auto (PCI only).

  6. From the I/O board generating the interrupt list, select the value UEI-MFx. This specifies that the UEI MFx board generates the interrupt.

  7. For the PCI slot (-1: autosearch) or ISA base address parameter, enter the same PCI address as for the UEI MFx Frame block PCI slot parameter. Enter -1 (for autodetection) if this is the only UEI board in the target system.

  8. Click OK and save the model.

Guidelines for Multiple UEI Boards

If you have two or more UEI boards in a master/slave configuration, use the following procedure. Note which UEI board you want to use as the master.

  1. Insert a board into the target machine.

  2. Reboot the target machine.

  3. On the host computer, open the model that you want to use with the multiple UEI boards.

  4. In the Simulink > Configuration Parameters dialog box, select the xPC Target options node.

  5. In the Real-time interrupt source parameter, select Auto (PCI only).

  6. From the I/O board generating the interrupt list, select the value UEI-MFx. This specifies that the UEI MFx board generates the interrupt.

  7. From a MATLAB Command Window running on the host computer, type

    getxpcpci all
  8. Note the slot numbers for the UEI boards.

  9. Determine the slot number for the master board.

  10. For the PCI slot (-1: autosearch) or ISA base address parameter, enter the bus and the slot number of the master board. Use the format [bus, slot].

  11. Click OK and save the model.

IRQ Source Block

If the UEI A/D frame block is in a Function-Call Subsystem called from an IRQ Source block,

  1. In the model, select the IRQ Source block.

  2. From the IRQ line number list, select Auto (PCI only).

  3. From the I/O board generating the interrupt list, select the value UEI-MFx. This specifies that a UEI MFx board generates the interrupt.

  4. For the PCI slot (-1: autosearch) or ISA base address parameter, enter the same PCI address as for the UEI MFx Frame block PCI slot (-1: autosearch) parameter.

    • Only enter -1 (for autodetection) if this is the only UEI board in the target system.

    • If more than one UEI board is or will be in the target system, enter the bus and slot number using the format [bus, slot].

  5. Click OK.

  6. Repeat this procedure for each IRQ Source block calling separate subsystems.

Example Models

Example models that illustrate the use of UEI frame driver blocks are in the xpcdemos directory. Correct operation of these models requires that the interrupt source be set correctly in the simulation parameters dialog.

Note that these examples use the UEI PD2-MF-16-333/16H driver block. Replace the block as appropriate for your target system.

  


Related Products & Applications

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.

 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS