.

Test Input

Overview

Overview

The Test Input block is used to input a user buffer’s contents into a MechaWare block. Each Test Input block is connected to a single 32-bit user buffer register for integer and float outputs and two 32-bit registers for double and long integer types. These registers overlap with the buffer used by Memory In User Buffer, Memory Out User Buffer, and Scope blocks. Each model has a set of 16 of these input registers.

The Test Point Number defines the user buffer location that will be accessed by this block. The data types that are input to the block from the user buffer are float (32 bits), double (64 bits), integer (32 bits) or Long integer (64 bits). If the data being accessed from the user buffer is 64 bits, odd user buffer numbers should be specified, and the next even test input should not be used.

The user buffer location read by the block is determined by the following formula:

Index  = (Model Number * 32) + Test Point Number

So, a Test Input block in Model 2 with a Test Point Number of 6 will read its input from User Buffer[70].

The following parameters are used to configure this block at load time:

Test Point Number

The number of the register within model’s set of 16 user buffer registers.

Data Type

Data Type.

Defines the data type of the data being accessed in the user buffer.

0 = float (32 bits)
1 = double (64 bits)
2 = short integer (16 bits)
3 = integer (32 bits)
4 = long integer (64 bits)

Subsample Code

A code which determines the schedule for updating this block (every sample, even samples only, etc.) See Subsampling.


Matlab/Simulink

Simulink Interface

The output of the Test Input block is a single value from the user buffer. This block has no inputs.

The Test Point Number determines which of the model’s 16 user buffer registers are used as the source of data for the block.

The block’s update schedule is determined by the Subsample Code (See Subsampling). The following Parameter Dialog Box can be opened by double-clicking on the block in a Simulink Model:

C++ API

C++ API

The Test Input block is used to direct input from the user buffer. This block has no configurable parameters.

See Also

Memory
Output
Noise Generator MemoryOut
Actual Position Memory Out User Buffer
Command Position Scope
Error Feedback
Memory User Buffer Reset Status
Command Acceleration Test In
Command Velocity Test Out

 

       Legal Notice  |  Tech Email  |  Feedback
      
Copyright ©
2001-2012 Motion Engineering