User`s manual
http://www.adtechcn.com 61
Chapter VI Use of Library Functions for Motion Control
) 1. Overview of ADT-8840’s Function Library
The function Library of ADT-8840 serves as interfaces with which the user can operate the control card to realize
the corresponding functions.
) 2. Use of dynamic-link library under Windows environment
Compiled by using VC, the dynamic-link library under Windows environment is located at “development
kit\drive\dynamic link” in the disk, and suits the program language tools commonly used under the environment,
such as VB and VC.
2.1 Use from VC
(1) Create a new project;
(2) Copy the file “8840.lib” and “adt8840.h” under “development kit\VC” in the disk to the path of the newly
created project;
(3) Correct click “file view” in the “work space” of the newly created project, and select “Add Files to
Project”. In the dialogue box of inserted file, select “Library Files(.lib)” as file type, search out
“8840.lib” and select it, then click “OK” to complete the loading of static library;
(4) Add #include “adt8840.h” to the declaration part of the source program file, header file or global header
file “StdAfx.h”.
After the above four steps, the user can use the functions in the dynamic-link library.
Note: Use in VC.NET is similar to that of VC.
2.2 Use in VB
(1) Create a new project;
(2) Copy the file “adt8840.bas” under “development kit\VB” in the disk to the path of the newly created
project;
(3) Select the menu command “project\add module”, select the tab page “save now” in the dialogue box,
search out the module file “adt8840.bas” and click the button for opening;
After the above three steps, the user can use the functions in the dynamic-link library for the progam.
Note: Use through VB.NET is similar to that of VB.