Skip to Main Content Skip to Search
Product Documentation

MPL PATI Incremental Encoder - MPL PATI Incremental Encoder block

Library

xPC Target Library for MPL

General Description

This block has one input port and one output port.

To keep the counting mode set to normal mode, just connect a constant block with the value 0 to the M input.

Block Parameters

Channel pair

From the list, choose a pair of sequential channels for the incremental encoder. Both channels must be in the same group of 16. For example, 1+2, 2+3, or 18+19. If you want to use channels 16 or 32, their sequential partners are 1 and 17, for example, 16+1 and 32+17.

Channel priority

From the list, select Low, Medium, or High priority. This has a small effect on the order that individual timers are serviced. See the MPC555 TPU documentation for more information.

Initial count

The initial count specifies the initial value for the encoder count register when the model starts executing.

Output range

From the list, choose one of the following. This block converts the output to doubles.

  • signed [-32768 +32767]

    Interprets the 16-bit count as a signed quantity. This places the discontinuity far from the 0 origin. Counting up from 32767 goes to -32768 on the next count.

  • unsigned [0 65535]

    Interprets the 16-bit count as an unsigned quantity. This places the discontinuity at the origin, where counting up from 65535 goes to 0 on the next count.

Sample time

Enter the base sample time or a multiple of the base sample time.

PCI slot

If only one board of this type is in the target PC, enter

-1 

to automatically locate the board.

If two or more boards of this type are in the target PC, enter the bus number and the PCI slot number of the board associated with this driver block. Use the format [BusNumber, SlotNumber]. To determine the bus number and the PCI slot number, type

getxpcpci
  


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