Motion Parameters. ADLINK Technology PCI-8136M

Add to My manuals
107 Pages

advertisement

Motion Parameters. ADLINK Technology PCI-8136M | Manualzz

5.11 Motion Parameters

@Name

_8136_M_Set_System_Param – Set motion cycle time and speed

_8136_M_Set_IO_Active – Enable/disable motion I/O

_8136_M_Switch_Logic – Set motion I/O's logic

_8136_A_Set_Source – Switch DAC source

_8136_M_Set_Feedback – Set axis0~2 encoder feedback on/off

@Description

_8136_M_Set_System_Param:

This function is for users to choose motion system's maximum speed and motion loop's cycle time. The following table shows the choices in PCI-8136. There are six types for speed selection, 32k,

64k, 128k, 256k, 512k, and 1024k. The corresponding pulse width for these speeds are 32us, 16us, 8us, 4us, 2us, and 1us. If users use pulse type motor driver, please make sure your specification.

The cycle time for motion loop is adjustable only for 512k and

1024k. The other speed types have fixed cycle time. The corresponding cycle time for 32k, 64k, 128k, 256k are 32.768ms,

16.384ms, 8.192ms and 4.096ms. Windows NT system is not a real time system so please choose the most suitable and stable cycle time for your system.

_8136_M_Set_IO_Active

This function enables PEL/MEL/ALM/ORG checking when sending pulses. For example, one user needs to use axis0 and axis 1 for motion control. He must use this function to enable

PEL/MEL/ALM/ORG checking for these two axes. If not , these

I/Os can be us ed for general purpose I/O.

_8136_M_Switch_Logic

This function is for setting three I/O types, ORG, EL, ALM, for generating interrupt or doing their particular job. These I/O may be active high or low. Use this function to set their logic properly if you use interrupt functions or motion function.

_8136_A_Set_Source

When users use one axis for closed loop motion control by

C_Initial(). The DA channel is used for generating V command from motion pattern. This function can switch this axis for general purpose DA channel or closed loop control mode.

Motion Libra

• 85

_8136_M_Set_Feedback

When users are using absolute position control motion functions,

PCI-8136M will read current position counter value for calculating next position. If users don't connect any feedback device, they can use this function to disable external feedback. Then the absolute function will be valid. There are only first three axes supports these functions. The other three axes must connect feedback device if they are using absolute position motion functions.

@ Syntax

C/C++ (DOS, Windows 95/98/NT/2000)

I16 _8136_M_Switch_Logic(I16 CardNo,I16 Home_Logic, I16

EL_Logic, I16 ALM_Logic)

I16 _8136_M_Set_IO_Active(I16 CardNo, I16 AxisNo, I16 Control)

I16 _8136_M_Set_System_Param(I16 CardNo, I16 Speed, I16

CycleTime)

I16 _8136_A_Set_Source(I16 CardNo,I16 Channel,I16 Source)

I16 _8136_M_Set_Feedback(I16 CardNo, I16 AxisNo, I16

FBControl)

Visual Basic 5.0 or higher

B_8136_M_Switch_Logic (ByVal CardNo As Integer,ByVal

Home_Logic As Integer,ByVal EL_Logic As Integer, ByVal

ALM_Logic As Integer) As Integer

B_8136_M_Set_IO_Active(ByVal CardNo As Integer, ByVal

AxisNo As Integer, ByVal Control As Integer) As Integer

B_8136_M_Set_System_Param(ByVal CardNo As Integer, ByVal

Speed As Integer, ByVal CycleTime As Integer) As Integer

B_8136_A_Set_Source(ByVal CardNo As Integer, ByVal Channel

As Integer, ByVal Source As Integer)

B_8136_M_Set_Feedback(ByVal CardNo As Integer, ByVal

AxisNo As Integer, ByVal FBControl As Integer) As Integer

@ Argument

CardNo: card number designated to set (Range 0 ~ 3)

AxisNo: axis number designated to set (Range 0~5)

Source: select DAC source, 0 is from DAC buffer and 1 is from motion command

Home_Logic: 0 is for active low and 1 is for active high

EL_Logic: 0 is for active low and 1 is for active high

ALM_Logic: 0 is for active low and 1 is for active high

Control: 0 is for general purpose and 1 is for motion axis

FBControl: only for axis0 to 2, 0 means disable feedback device and 1 means enable feedback device

Speed: select motion axis maximum speed

0 = 32k

1 = 64k

86

• Motion Library

2 = 128k

3 = 256k

4 = 512k

5 = 1024k

CycleTime: select motion cycle time

0 = 1.024ms (for 1024k only)

1 = 2.048ms (for 512k and 1024k only)

3 = 4.096ms (for 256, 512k and 1024k only)

@ Return Code

ERR_RangeError

ERR_NoError

Motion Libra

• 87

advertisement

Related manuals

advertisement

Table of contents