Example: Demo.cpp - ICP DAS USA I-8091 User Manual

2-axis stepping/servo motor control card
Hide thumbs Also See for I-8091:
Table of Contents

Advertisement

I-8091 User Manual
return i8092;
default:
Print("Slot %d = No Card\r\n",SlotNum);
return NOCARD;
};
Delay(500);
};
}

4.2 Example: DEMO.cpp

//---------------------------------------------------------------------------
// demo.cpp for I-8091 card
//
// This program can test all of following command
// ----------------------I-8091 testing kit-----------------------------------
// (0)Exit
// (1)i8091_RESET_SYSTEM
// (2)i8091_SET_VAR
// (3)i8091_SET_DEFDIR
// (4)i8091_SET_MODE
// (5)i8091_SET_SERVO_ON
// (6)i8091_SET_NC
// (7)i8091_STOP_X
// (8)i8091_STOP_Y
// (9)i8091_STOP_ALL
//
//
The output pulse amount can be monitored from i8090 card. When directly
//
connect the CW/PULSE, CCW/DIR of i8091 to i8090. The encoder value
//
can be shown on the LED display. Its format as following.
//
ex:
0.2 1 2 8 : X-axis encoder value
//
5 3.4 0 2 : Y-axis encoder value
//
1 0 0.1 0 : Z-axis encoder value
//
the dot(.) stands for which axis.
//--------------------------------------------------------------------
4.3 Example:DEMO1.cpp
//--------------------------------------------------------------------
// demo1.cpp for I-8091 card
//
// This a simple program to test I-8091 command
//
i8091_INTP_LINE()
//
i8091_INTP_LINE02()
//--------------------------------------------------------------------
http://www.icpdas.com
(A)i8091_IS_X_STOP
(B)i8091_IS_Y_STOP
(C)i8091_LIMIT_X
(D)i8091_LIMIT_Y
(E)i8091_LSP_ORG
(F)i8091_HSP_ORG
(G)i8091_LSP_PULSE_MOVE
(H)i8091_HSP_PULSE_MOVE
(I)i8091_LSP_MOVE
(J)i8091_HSP_MOVE
2-40
Version 2.0
(K)i8091_CSP_MOVE
(L)i8091_SLOW_DOWN
(M)i8091_SLOW_STOP
(N)i8091_INTP_PULSE
(O)i8091_INTP_LINE
(P)i8091_INTP_LINE02
(Q)i8091_CIRCLE02
(R)i8091_ARC02
(S)User Define Testing
04/2003
ICPDAS

Advertisement

Table of Contents
loading

Table of Contents