Objects Relationships

Objects Relationships

Introduction | Object List | Bitmap | Array of Object Numbers
Using Lists, Bitmaps, & Arrays | Application-MPI-Controller Interface

Introduction

To create a motion application, you create objects, link them in relationships (associate them), and provide the desired parameters for motion.

There are three ways that you can associate one object with another object:

 
  • Using an object List
  • Using bitmap
  • Using an array of object numbers

Objects using bitmaps or an array of numbers must all be present physically on the same controller, while objects on an object list can come from different controllers (such as objects on the EventMgr control list).

Three Ways to Associate Objects with Objects

Object.When to Use

List

an ordered list

Use a List 
when the order of the objects to be associated is important, OR when some of the objects reside on different controllers.

Bitmap

an un-ordered list

Use a bitmap 
when the order of the objects is not important, AND the objects must all reside on the same controller (same Control object).

Array of object numbers

an ordered list

Use an array of object numbers 
when the order of the objects is important, AND the objects must all reside on the same controller (same Control object).

Object List

Use an object list to associate objects when ordering is required, such as the Axis list maintained by a Motion object. For example, when using a Motion object, a list of Axes 0, 1, 2 is not the same as a list of Axes 0, 2, 1. Such a distinction is not available when using an object map. Refer to the List methods for Motion, Notify, Sequence and EventMgr objects.

This object:Can have object lists of:
MotionAxes
NotifyEvents
EventMgrControls
Notify objects
SequenceCommands

Bitmap

An object map is a bitmap, where each numbered bit represents the presence or absence of the correspondingly numbered object. You can order the objects in the bitmap from numeric low-to-high or high-to-low, but there is no other meaningful capability for ordering objects with an object map.

Another consideration with object maps is that all objects specified in the map and the object (that those objects are being associated with) must be resident on the same controller (Control object).

Note: Although the MPI allows an Axis to be associated with a Motion without regard to the controller (Control), the XMP implementation of the MPI does not allow this.

Object maps tend to be used to associate low-level objects that:

 
  • must all reside on the same controller (Control)
  • and the order in which the objects are ordered does not matter

Note that the objects specified in the bitmap may be associated with another object, without those objects having to be created and deleted. A goal of the MPI has been to minimize the need to create and delete objects, especially objects that are just used for configuration. For example, an MPI application that uses the default configuration doesn't have to create Filter or Motor objects, yet the application can still configure an Axis, by calling mpiAxisFilterMapSet(...), where the Filters are specified by the bitmap.

Object Maps for Objects

This object:Has associated object maps of:
Filter

Axes
Motors

AxisFilters
Motors
MotorFilters
Axes
Adcs

Array of Object Numbers

The MPI provides a third means of associating objects, by using object numbers. Object numbers should be used when ordering is required, and all the resources arelocated on the same controller.

Using List, Bitmaps, & Arrays

Application-MPI-Controller Interface

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值