.

Memory

Overview

Overview

The Memory block is used for inputs other than those provided by the standard input blocks. Any internal variable on the controller can be used as a MechaWare input using the Memory block.

The Memory Address defines the input internal variable location The data type of the internal variable can be float (32 bits) , double (64 bits), integer (32 bits) and Long integer (64 bits).

The configuration values for this block are as follows:

 
Motor Address

Memory Address.

Defines location of the internal input variable. Format is Hexidecimal.

Data Type

Data Type.

Defines the data type of the internal variable memory being written to.

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.
User Data 0 Application-specific data. See User Data Storage.
User Data 1 Application-specific data. See User Data Storage.

 

Matlab/Simulink

Simulink Interface

mem sim1

The Memory Address of the Memory specifies which memory location is read to obtain the input. The address is in hexadecimal format. Addresses for input variables can be obtained using VM3.

The block has two user data fields (User Data 0, User Data 1) to store application-specific data for convenient storage and retrieval. See User Data Storage for details.

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:

mem sim2
 

Double-click on the Memory block to open the Block Parameters window.

 

C++ API

MEMORYBlock

Declaration

Public Method

 
MEMORYBlock&   MEMORY();
  Required Header: mechaware.h

Description

The MEMORY block is used for inputs other than those provided by the standard input blocks. Any internal variable on the controller can be used as a MechaWare input using the Memory block. See the Overview for details.

 
long MEMORY().Address

Memory Address of the input internal variable.

long MEMORY().DataType

Data type of the input internal variable.

Methods

Block Methods

 

See Also

MemoryOut
Memory Out User Buffer

 

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