Thank you for purchasing the API for the MX100/DARWIN. This user’s manual explains
the operating procedures of the API for the MX100/DARWIN. To ensure correct use,
please read this manual thoroughly before beginning operation. After reading the
manual, keep it in a convenient location for quick reference whenever a question arises
during operation.
• The contents of this manual are subject to change without prior notice as a result of
continuing improvements to the instrument’s performance and functions.
• Every effort has been made in the preparation of this manual to ensure the accuracy
of its contents. However, should you have any questions or find any errors, please
contact your nearest YOKOGAWA representative, dealer, or sales office.
• Copying or reproducing all or any part of the contents of this manual without the
permission of Yokogawa Electric Corporation is strictly prohibited.
• Use of this software on more than one computer at the same time is prohibited. Use
by more than one user is also prohibited.
• Transfer or lending of this software to any third party is prohibited.
• Yokogawa Electric Corporation provides no guarantees other than for physical
deficiencies found on the original disk upon opening the product package.
• Yokogawa Electric Corporation shall not be held responsible by any party for any
losses or damage, direct or indirect, caused by the use or any unpredictable defect of
the product.
• Please do not lose your serial number as it cannot be reissued.
• Serial numbers will not be reissued. Please keep your serial numbers in a safe place.
Overview of Functions
Trademarks
Revisions
• vigilantplant and DAQMASTER are registered trademarks of Yokogawa Electric
Corporation.
• Microsoft and Windows are registered trademarks or trademarks of Microsoft
Corporation in the United States and/or other countries.
• Adobe and Acrobat are registered trademarks or trademarks of Adobe Systems
Incorporated.
• Company and product names that appear in this manual are registered trademarks or
trademarks of their respective holders.
• The company and product names used in this manual are not accompanied by the
registered trademark or trademark symbols (® and ™).
Thank you very much for purchasing this medium containing a software program and related documentation provided by Yokogawa Electric
Corporation (hereinafter called “Yokogawa”), and the program contained, embedded, inserted or used in the medium (hereinafter called the
“Yokogawa Software Program”).
By opening this package or plastic wrapping (hereinafter called “Package”) enclosing the Yokogawa Software Program, you acknowledge that you
understand and agree to the “Terms and Conditions of the Software License” (hereinafter called “Terms and Conditions”) which is written in the
documentation and separately attached. Accordingly, the Terms and Conditions bind you.
The Yokogawa Software Program and its related documentation including ownership of copyright shall remain the exclusive property of Yokogawa
or those third parties from whom sublicensed software in the Yokogawa Software Program is licensed.
Yokogawa hereby grants you permission to use the Yokogawa Software Program on the conditions that you agree to the Terms and Conditions
before you open the Package and/or install it in or onto a computer.
IF YOU DO NOT AGREE TO THE TERMS AND CONDITIONS, YOU CANNOT OPEN THE PACKAGE, AND MUST IMMEDIATELY RETURN IT
TO YOKOGAWA OR ITS DESIGNATED PARTY.
Terms and Conditions of the Software License
Yokogawa Electric Corporation, a Japanese corporation (hereinafter called “Yokogawa”), grants permission to use this Yokogawa Software
Program (hereinafter called the “Licensed Software”) to the Licensee on the conditions that the Licensee agrees to the terms and conditions
stipulated in Article 1 hereof.
You, as the Licensee (hereinafter called “Licensee”), shall agree to the following terms and conditions for the software license (hereinafter called
the “Agreement”) based on the use intended for the Licensed Software.
Please note that Yokogawa grants the Licensee permission to use the Licensed Software under the terms and conditions herein and in no event
shall Yokogawa intend to sell or transfer the Licensed Software to the Licensee.
Licensed Software Name:API for the MX100/DARWIN
Number of License:1
Article 1 (Scope Covered by these Terms and Conditions)
1.1 The terms and conditions stipulated herein shall be applied to any Licensee who purchases the Licensed Software on the condition that the
Licensee consents to agree to the terms and conditions stipulated herein.
1.2 The “Licensed Software” herein shall mean and include all applicable programs and documentation, without limitation, all proprietary
technology, algorithms, and know-how such as a factor, invariant or process contained therein.
Article 2 (Grant of License)
2.1 Yokogawa grants the Licensee, for the purpose of single use, non-exclusive and non-transferable license of the Licensed Software with the
license fee separately agreed upon by both parties.
2.2 The Licensee is, unless otherwise agreed in writing by Yokogawa, not entitled to copy, change, sell, distribute, transfer, or sublicense the
Licensed Software.
2.3 The Licensed Software shall not be copied in whole or in part except for keeping one (1) copy for back-up purposes. The Licensee shall
secure or supervise the copy of the Licensed Software by the Licensee itself with great, strict, and due care.
2.4 In no event shall the Licensee dump, reverse assemble, reverse compile, or reverse engineer the Licensed Software so that the Licensee
may translate the Licensed Software into other programs or change it into a man-readable form from the source code of the Licensed
Software. Unless otherwise separately agreed by Yokogawa, Yokogawa shall not provide the Licensee the source code for the Licensed
Software.
2.5 The Licensed Software and its related documentation shall be the proprietary property or trade secret of Yokogawa or a third party which
grants Yokogawa the rights. In no event shall the Licensee be transferred, leased, sublicensed, or assigned any rights relating to the
Licensed Software.
2.6 Yokogawa may use or add copy protection in or onto the Licensed Software. In no event shall the Licensee remove or attempt to remove
such copy protection.
2.7 The Licensed Software may include a software program licensed for re-use by a third party (hereinafter called “Third Party Software”, which
may include any software program from affiliates of Yokogawa made or coded by themselves.) In the case that Yokogawa is granted
permission to sublicense to third parties by any licensors (sub-licensor) of the Third Party Software pursuant to different terms and conditions
than those stipulated in this Agreement, the Licensee shall observe such terms and conditions of which Yokogawa notifies the Licensee in
writing separately.
2.8 In no event shall the Licensee modify, remove or delete a copyright notice of Yokogawa and its licenser contained in the Licensed Software,
including any copy thereof.
Article 3 (Restriction of Specific Use)
3.1 The Licensed Software shall not be intended specifically to be designed, developed, constructed, manufactured, distributed or maintained for
the purpose of the following events:
a) Operation of any aviation, vessel, or support of those operations from the ground;,
b) Operation of nuclear products and/or facilities;,
c) Operation of nuclear weapons and/or chemical weapons and/or biological weapons; or
d) Operation of medical instrumentation directly utilized for humankind or the human body.
3.2 Even if the Licensee uses the Licensed Software for the purposes in the preceding Paragraph 3.1, Yokogawa has no liability to or
responsibility for any demand or damage arising out of the use or operations of the Licensed Software, and the Licensee agrees, on its own
responsibility, to solve and settle the claims and damages and to defend, indemnify or hold Yokogawa totally harmless, from or against any
liabilities, losses, damages and expenses (including fees for recalling the Products and reasonable attorney’s fees and court costs), or claims
arising out of and related to the above-said claims and damages.
Article 4 (Warranty)
4.1 The Licensee shall agree that the Licensed Software shall be provided to the Licensee on an “as is” basis when delivered. If defect(s), such
as damage to the medium of the Licensed Software, attributable to Yokogawa is found, Yokogawa agrees to replace, free of charge, any
Licensed Software on condition that the defective Licensed Software shall be returned to Yokogawa’s specified authorized service facility
within seven (7) days after opening the Package at the Licensee’s expense. As the Licensed Software is provided to the Licensee on an “as
is” basis when delivered, in no event shall Yokogawa warrant that any information on or in the Licensed Software, including without limitation,
data on computer programs and program listings, be completely accurate, correct, reliable, or the most updated.
4.2 Notwithstanding the preceding Paragraph 4.1, when third party software is included in the Licensed Software, the warranty period and terms
and conditions that apply shall be those established by the provider of the third party software.
iiIM MX190-01E
Terms and Conditions of the Software License
4.3 When Yokogawa decides in its own judgement that it is necessary, Yokogawa may from time to time provide the Licensee with Revision
upgrades and Version upgrades separately specified by Yokogawa (hereinafter called “Updates”).
4.4 Notwithstanding the preceding Paragraph 4.3, in no event shall Yokogawa provide Updates where the Licensee or any third party conducted
renovation or improvement of the Licensed Software.
4.5 THE FOREGOING WARRANTIES ARE EXCLUSIVE AND IN LIEU OF ALL OTHER WARRANTIES OF QUALITY AND PERFORMANCE,
WRITTEN, ORAL, OR IMPLIED, AND ALL OTHER WARRANTIES INCLUDING ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR
FITNESS FOR A PARTICULAR PURPOSE ARE HEREBY DISCLAIMED BY YOKOGAWA AND ALL THIRD PARTIES LICENSING THIRD
PARTY SOFTWARE TO YOKOGAWA.
4.6 Correction of nonconformity in the manner and for the period of time provided above shall be the Licensee’s sole and exclusive remedy for
any failure of Yokogawa to comply with its obligations and shall constitute fulfillment of all liabilities of Yokogawa and any third party licensing
the Third Party Software to Yokogawa (including any liability for direct, indirect, special, incidental or consequential damages) whether in
warranty, contract, tort (including negligence but excluding willful conduct or gross negligence by Yokogawa) or otherwise with respect to or
arising out of the use of the Licensed Software.
Article 5 (Infringement)
5.1 If and when any third party should demand injunction, initiate a law suit, or demand compensation for damages against the Licensee under
patent right (including utility model right, design patent, and trade mark), copy right, and any other rights relating to any of the Licensed
Software, the Licensee shall notify Yokogawa in writing to that effect without delay.
5.2 In the case of the preceding Paragraph 5.1, the Licensee shall assign to Yokogawa all of the rights to defend the Licensee and to negotiate
with the claiming party. Furthermore, the Licensee shall provide Yokogawa with necessary information or any other assistance for
Yokogawa’s defense and negotiation. If and when such a claim should be attributable to Yokogawa, subject to the written notice to
Yokogawa stated in the preceding Paragraph 5.1, Yokogawa shall defend the Licensee and negotiate with the claiming party at Yokogawa’s
cost and expense and be responsible for the final settlement or judgment granted to the claiming party in the preceding Paragraph 5.1.
5.3 When any assertion or allegation of the infringement of the third party’s rights defined in Paragraph 5.1 is made, or when at Yokogawa’s
judgment there is possibility of such assertion or allegation, Yokogawa will, at its own discretion, take any of the following countermeasures at
Yokogawa’s cost and expense.
a) To acquire the necessary right from a third party which has lawful ownership of the right so that the Licensee will be able to continue to use
the Licensed Software;
b) To replace the Licensed Software with an alternative one which avoids the infringement; or
c) To remodel the Licensed Software so that the Licensed Software can avoid the infringement of such third party’s right.
5.4 If and when Yokogawa fails to take either of the countermeasures as set forth in the preceding subparagraphs of Paragraph 5.3, Yokogawa
shall indemnify the Licensee only by paying back the price amount of the Licensed Software which Yokogawa has received from the
Licensee. THE FOREGOING PARAGRAPHS STATE THE ENTIRE LIABILITY OF YOKOGAWA AND ANY THIRD PARTY LICENSING
THIRD PARTY SOFTWARE TO YOKOGAWA WITH RESPECT TO INFRINGEMENT OF THE INTELLECTUAL PROPERTY RIGHTS
INCLUDING BUT NOT LIMITED TO, PATENT AND COPYRIGHT.
Article 6 (Liabilities)
6.1 If and when the Licensee should incur any damage relating to or arising out of the Licensed Software or service that Yokogawa has provided
to the Licensee under the conditions herein due to a reason attributable to Yokogawa, Yokogawa shall take actions in accordance with this
Agreement. However, in no event shall Yokogawa be liable or responsible for any special, incidental, consequential and/or indirect damage,
whether in contract, warranty, tort, negligence, strict liability, or otherwise, including, without limitation, loss of operational profit or revenue,
loss of use of the Licensed Software, or any associated products or equipment, cost of capital, loss or cost of interruption of the Licensee’s
business, substitute equipment, facilities or services, downtime costs, delays, and loss of business information, or claims of customers of
Licensee or other third parties for such or other damages. Even if Yokogawa is liable or responsible for the damages attributable to Yokogawa
and to the extent of this Article 6, Yokogawa’s liability for the Licensee’s damage shall not exceed the price amount of the Licensed Software
or service fee which Yokogawa has received. Please note that Yokogawa shall be released or discharged from part or all of the liability under
this Agreement if the Licensee modifies, remodels, combines with other software or products, or causes any deviation from the basic
specifications or functional specifications, without Yokogawa’s prior written consent.
6.2 All causes of action against Yokogawa arising out of or relating to this Agreement or the performance or breach hereof shall expire unless
Yokogawa is notified of the claim within one (1) year of its occurrence.
6.3 In no event, regardless of cause, shall Yokogawa assume responsibility for or be liable for penalties or penalty clauses in any contracts
between the Licensee and its customers.
Article 7 (Limit of Export)
Unless otherwise agreed by Yokogawa, the Licensee shall not directly or indirectly export or transfer the Licensed Software to any countries other
than those where Yokogawa permits export in advance.
Article 8 (Term)
This Agreement shall become effective on the date when the Licensee receives the Licensed Software and continues in effect unless or until
terminated as provided herein, or the Licensee ceases using the Licensed Software by itself or with Yokogawa’s thirty (30) days prior written notice
to the Licensee.
Article 9 (Injunction for Use)
During the term of this Agreement, Yokogawa may, at its own discretion, demand injunction against the Licensee in case that Yokogawa deems
that the Licensed Software is used improperly or under severer environments other than those where Yokogawa has first approved, or any other
condition which Yokogawa may not permit.
Article 10 (Termination)
Yokogawa, at its sole discretion, may terminate this Agreement without any notice or reminder to the Licensee if the Licensee violates or fails to
perform this Agreement. However, Articles 5, 6, and 11 shall survive even after the termination.
Article 11 (Jurisdiction)
Any dispute, controversies, or differences between the parties hereto as to interpretation or execution of this Agreement shall be resolved
amicably through negotiation between the parties upon the basis of mutual trust. Should the parties fail to agree within ninety (90) days after
notice from one of the parties to the other, both parties hereby irrevocably submit to the exclusive jurisdiction of the Tokyo District Court (main
office) in Japan for settlement of the dispute.
Article 12 (Governing Law)
This Agreement shall be governed by and construed in accordance with the laws of Japan. The Licensee expressly agrees to waive absolutely
and irrevocably and to the fullest extent permissible under applicable law any rights against the laws of Japan which it may have pursuant to the
Licensee’s local law.
Article 13 (Severability)
In the event that any provision hereof is declared or found to be illegal by any court or tribunal of competent jurisdiction, such provision shall be
null and void with respect to the jurisdiction of that court or tribunal and all the remaining provisions hereof shall remain in full force and effect.
IM MX190-01E
iii
Checking the Contents of the Package
e
Unpack the box and check the contents before operating the software. If some of the
contents are not correct, or if any items are missing or damaged, contact the dealer from
whom you purchased them.
Model
ModelName
MX190API for the MX100/DARWIN
Package Contents
CD-ROM 1 piece
API for the MX100/DARWIN
CD-ROM 1 piec
User's Manual
ivIM MX190-01E
Handling Precautions of the CD-ROM
Make sure to observe the precautions below.
WARNING
• Do not use or store the CD-ROM in a place with excessive dirt or dust.
• Do not touch the non-printed side of the CD-ROM.
Oil and sweat from the fingertips sticking to the surface can cause malfunctions.
Do not write on the CD-ROM.
• Lead from pencils and residue from erasers sticking to the surface can
also cause malfunction.
• Do not bend or scratch the CD-ROM.
Doing so will make the CD-ROM unreadable.
• Do not place objects on the CD-ROM.
Doing so can deform the CD-ROM and make it unusable.
• Do not drop from high places.
Dropping the CD-ROM can make it unusable due to breakage or deformation.
• Keep away from direct sunlight and any heating equipment.
Never use solvents such as alcohol, thinner, and Freon to clean the CD-ROM.
• Insert the CD-ROM into the CD-ROM drive with care.
• Do not eject the CD-ROM, or turn OFF or reset the PC while the CD-ROM is
being accessed.
• Store the CD-ROM in its storage case.
Do not leave the CD-ROM in the CD-ROM drive after use. Leaving the CD-ROM
out of the storage case can cause it to become dirty or deformed.
Overview of Functions
IM MX190-01E
v
How to Use This Manual
Structure of this Manual
This user’s manual consists of the following twenty-six chapters, appendix, and index.
ChTitleDescription
1 Before Using the SoftwareGives an overview of the API for the MX100/DARWIN.
2 API for MX100 - Visual C++ -Describes how to apply the API to the MX100 using Visual
3 API for MX100 - Visual C -Describes how to apply the API to the MX100 using Visual
4 API for MX100 - Visual Basic - Describes how to apply the API to the MX100 using Visual
5 Functions for the MX100 APIDescribes the details of the MX100 functions that can be
- Visual C/Visual Basic -used by Visual C and Visual Basic.
6 MX100 API Constants andDescribes the details of the constants and types for
Typesthe MX100 that can be used by Visual C++, Visual C, and
7 API for DARWINDescribes how to apply the API to DARWIN using Visual
- Visual C++ -C++. Describes the functions, program examples, and the
8 API for DARWINDescribes how to apply the API to DARWIN using Visual C.
- Visual C -Describes the functions and program examples.
9 API for DARWINDescribes how to apply the API to the DARWIN using Visual
-Visual Basic -Basic. Describes the functions and program examples.
10 Functions for the DARWIN API Describes the details of the DARWIN functions that can be
- Visual C/Visual Basic -used by Visual C and Visual Basic.
11 DARWIN Constants and Types Describes the details of the constants and types for
12 MX100 for Extended APIDescribes how to apply the extended API to the MX100
- Visual C++ -using Visual C++. Describes the functions, program
13 MX100 for Extended APIDescribes how to apply the extended API to the MX100
- Visual C -using Visual C. Describes the functions and program
14 MX100 for Extended APIDescribes how to apply the extended API to the MX100
- Visual Basic -using Visual Basic. Describes the functions and program
15 MX100 for ExtendedAPIDescribes how to apply the extended API to the MX100
- Visual Basic.NET -using Visual Basic.NET. Describes the functions and
16 MX100 for Extension APIDescribes how to apply the extendedAPI to the MX100
- Visual C# -using Visual C#. Describes the functions and program
17 Functions for the MX100Describes the details of the MX100 functions that can be
(Extended API)used by Visual C, Visual Basic, and Visual Basic.NET/C#.
- Visual C/Visual Basic/
Visual Basic.NET/C# -
Describes the PC requirements needed to run the software,
the installation procedures, and other information.
C++. Describes the functions, program examples, and the
details of the classes.
C. Describes the functions and program examples.
Basic. Describes the functions and program examples.
Visual Basic.
details of the classes.
DARWIN that can be used by Visual C++, Visual C, and
Visual Basic.
examples, and the details of the classes.
examples.
examples.
program examples.
examples.
viIM MX190-01E
How to Use This Manual
ChTitleDescription
18 MX100 Constants and TypesDescribes the details of the constants and types for the for
Extended APIMX100 that can be used by Visual C++, Visual C, Visual
- Visual Basic -Basic, and Visual Basic.NET/C#.
19 DARWIN for Extended APIDescribes how to apply the extended API to DARWIN using
- Visual C++ -Visual C++. Describes the functions and program examples.
20 DARWIN for Extended APIDescribes how to apply the extended API to DARWIN using
- Visual C -Visual C. Describes the functions and program examples.
21 DARWIN for Extended APIDescribes how to apply the extended API to DARWIN using
- Visual Basic -Visual Basic. Describes the functions and program
examples.
22 DARWIN for Extended APIDescribes how to apply the extended API to DARWIN using
- Visual Basic.NET -Visual Basic.NET. Describes the functions and program
examples.
23 DARWIN for Extended APIDescribes how to apply the extended API to DARWIN using
- Visual C# -Visual C#. Describes the functions and program examples.
24 DARWIN for Extended APIDescribes the details of the DARWIN functions that can be
25 DARWIN for Extended APIDescribes the details of the constants and types for
Constants and TypesDARWIN that can be used by Visual C++, Visual C, Visual
Basic, and Visual Basic.NET/C#.
26 Error messagesLists and explains error messages.
AppendixDescribes the terminology used by this software and the
terminology for the MX100/DARWIN.
IndexAn alphabetical index of the contents of the manual.
Overview of Functions
Scope of the Manual
OS
This manual does not cover the basic operations of Windows. For information regarding
the basic operations of Windows, see the user’s guide that came with Windows. Also,
this manual does not cover the Visual Studio environment or languages supported. See
the relevant user’s manual for information on those topics.
MX100/DARWIN
Describes only the terminology used by the API. For details on the MX100 and DARWIN,
see the relevant user’s manuals.
Manual Revision History
RevisionDescription
2Supports API R2.01
3Supports API R3.01
IM MX190-01E
vii
Sample Programs
• This manual contains sample programs for each programming language.
• The sample programs can be downloaded from the Web site below.
http://www.yokogawa.com/ns/daq/mx100/daq-mx100_01.htm
* You can access the Web site by clicking the Up-to-Date Information button on the startup
screen of the user's manual CD-ROM and then moving on to MX100 PC-Based Data
Acquisition Unit.
* URL is subject to change.
When you have accessed the Web site, click Software Download and then search for the
sample program in the screen that appears.
keyword:sample program
product category:Data Acquisition Equipment
viiiIM MX190-01E
Format Used in This Manual
Explanation of Description of Functions
The functions are explained using the following format. This format is also applied to
the description of the function members of the classes.
The name of the function.
Syntax for Visual C++ or Visual C.
autoFIFOMX
Syntax
int autoFIFOMX(DAQMX daqmx, int bAuto);
Declaration
Public Declare Function autoFIFOMX Lib "DAQMX" (ByVal daqmx As
Long, ByVal bAuto As Long) As Long
Parameters
daqmx
bAuto
Specify the device descriptor.
Specify the valid/invalid value.
Description
Sets auto control of the FIFO.
Return value
Returns an error number.
Error:
Not descriptor
No device descriptor.
Reference
CDAQMX::autoFIFO
Error that this function generates.
Declaration statement
for Visual Basic.
Description of the
parameters.
Describes the functionality of
the function and gives notes.
Description of the return value
(
see "Return value" below
Overview of Functions
).
Functions that are called when this function
is executed (see "Reference" below).
Return Value (Error Numbers)
There are three types of errors: errors generated by the function itself, errors caused
by other component functions upon execution of the main function, and
communication errors.
The errors generated by the function itself are listed in the ìError:”section.
The errors generated by one of the component functions that is called when the
main function is executed are described in the explanation of those functions
which are listed under ìReference.”Communication Errors
Communication execution errors generated when communication is performed using
the communication descriptor. A communication error is any error between error
numbers 0 and 3.
For a description of error numbers and corrective actions, see section 12.1, ìAPI
Error Messages.”
IM MX190-01E
ix
Format Used in This Manual
Reference
A function consists of multiple, simpler functions. The Reference section lists the
functions that make up a given function. This information can be used to understand
the action of the function and/or troubleshoot errors.
Functions for Visual C and Visual Basic are executed by calling the Visual C++ class
instance. Therefore, the Reference section lists the class name and the member
function name and/or the function name.
The names are listed in alphabetical order.
Program Description
Sample programs are printed in this manual in monospaced font. Note the following.
• Due to the limitation of the width of a page, a long statement is written across
multiple lines.
Terminology Reference
The terminology for the API and the terminology for the MX100 and DARWIN are
described in the appendix.
Miscellaneous
Units
K Denotes 1024.Example: 100 KB
M Denotes 1024 K.Example: 10 MB
Symbols
Note
Calls attention to information that is important for proper operation of the
software.
xIM MX190-01E
CONTENTS
Foreword ......................................................................................................................................... i
Terms and Conditions of the Software License ...............................................................................ii
Checking the Contents of the Package ..........................................................................................iv
Handling Precautions of the CD-ROM ........................................................................................... v
How to Use This Manual ................................................................................................................vi
Sample Programs......................................................................................................................... viii
Format Used in This Manual ..........................................................................................................ix
Chapter 1 Before Using the API
1.1Introduction to Functions .................................................................................................. 1-1
1.2Software Components and Features ............................................................................... 1-4
Appendix 2 DARWIN Terminology ........................................................................................App-13
Appendix 3 Calculation of the MX100 Timeout Value ...........................................................App-19
Appendix 4 API Revision History (R2.01).............................................................................. App-20
Appendix 5 API Revision History (R3.01).............................................................................. App-26
Index
xivIM MX190-01E
Chapter 1 Before Using the API
1.1Introduction to Functions
Supported Models
This software provides the API (Application Programming Interface) that supports
the MX100 and DARWIN, and the extension API that makes the main API easier to
use.
MX100:All models
DARWIN: All models (DA, DC, and DR). However, the Ethernet communication
function (Ethernet module) is required.
Supported Languages
Languages supported by the API: Visual C++, Visual C, and Visual Basic
Languages supported by the extension API:
Functions used to communicate with the MX100 via the Ethernet interface.
Setup Functions
For configuring the MX100, modules, and channels. However, CAN Bus Module
hardware settings are not supported. For hardware settings, use the software that
came with the module.
Data Retrieval Functions
• Retrieval of measured data using FIFO
Retrieves the most recently measured data via the FIFO (first-in first-out) buffer.
Also retrieves instantaneous values. The retrieval interval of instantaneous values
is 100 ms or more.
• Retrieval of measured data by channel
Retrieves the most recent measured data of the specified channel. Also retrieves
instantaneous values. The retrieval interval of instantaneous values is 100 ms or
more.
• Retrieval of setup data
Retrieves the system configuration of the MX100, network information such as the
IP address, and setup data related to channels.
• Collective retrieval of DO (digital output) data
Collectively retrieves the ON/OFF status of the DO.
• Retrieval of channel information data (channel number, etc.)
• Retrieval of AO/PWM data
Retrieves data that shows the AO/PWM channel output.
IM MX190-01E
1-1
1.1 Introduction to Functions
• Retrieval of transmission output data
Data that indicates the AO/PWM channel transmission status.
When data is retrieved, it indicates the status of the current transmission output.
When data is sent, it is the specification that controls the start and stop of the
transmission output.
Control Functions
• Date/time setting
• Setting of the backup function that saves the measured data to the CF
card, and formatting of the CF card
• Initialization and reconfiguration of the system (unit)
• Resetting of alarms (acknowledge alarm)
• Designation of the information displayed on the 7-segment LED
Utilities
Provides functions for converting measured values into character strings, retrieving
error message strings, and other utility functions.
Functions for DARWIN
The API provides functions that are equivalent to the DARWIN communication
functions. Some of the basic functions of the DARWIN communication functions are
provided as API classes (for Visual C++) or functions (for Visual Basic, Visual C,
Visual Basic.NET, and C#). Other functions can be implemented using the
commands of the DARWIN communication function.
Functions Provided by this Software
• Communication Functions
Functions used to communicate with DARWIN via the Ethernet interface.
• Setup Functions
Sets the measurement range and alarms.
• Data Retrieval Functions
• Retrieval of the measured data
Retrieves measured data in ASCII or binary format. The values are instantaneous
values.
1-2IM MX190-01E
1.1 Introduction to Functions
• Retrieval of setup data
Retrieves the setup data of the operation mode, basic setting mode, and A/D
calibration mode.
• Retrieval of channel information data (channel number, etc.)
• Control Functions
• Date/time setting
• Reconfiguring the system
• RAM clear (initialization of operation mode parameters)
• Alarm reset
• Setting mode switching
• Utilities
Provides functions for converting measured values into character strings, retrieving
error message strings, and other utility functions.
Implementing Functions Corresponding to the Commands of the DARWIN
Communication Function
1
Before Using the API
Functions corresponding to commands of the DARWIN communication function can
be implemented according to the procedure below.
• Visual C++: Create an inheritance class of CDAQDARWIN and add member
functions that execute the commands of the DARWIN communication function
using the runCommand member function.
• Visual C and Visual Basic: Create functions that execute the commands of the
DARWIN communication function using the runCommandDARWIN function.
• Visual Basic.NET/C#: Create functions that execute the commands of the
DARWIN communication function using the runCommandDA100 function of the
extension API.
Notes
• The user program needs to be recompiled and re-linked because the structure
and other aspects of the API R3.01 were changed.
IM MX190-01E
1-3
1.2Software Components and Features
Software Components
The software consists of the API and an extension API.
The software provides Visual C++ classes.
The classes are Common Class, MX100 class, and DARWIN class. The MX100
Class and DARWIN Class are derived from the Common Class.
Functions used by Visual C, Visual Basic, Visual Basic.NET, and C# are provided.
Functions for the MX100 and functions for DARWIN are also available. These
functions are executed by calling the Visual C++ class instance.
Visual C, Visual Basic
Visual Basic.NET*, C#*
MX100 functions
Visual C++
Common
class
* Visual Basic.NET and C#
Features
• Control is achieved by retrieving the handle (device descriptor) that represents the
• The API provides structures for collection of data corresponding to the function.
• This API is subordinate to the extension API. Call the API to activate. The
DARWIN functions
correspond by Extension API.
MX100
class
DARWIN
class
connection with the controlled unit. This means that, programs can be created
independently of the hardware environment of the MX100 or DARWIN.
For example, the MX100 module information structure contains the module type,
the number of channels, the scan interval, and other information related to the
module. The same structure can be used even when the same data is retrieved
using different commands and different formats.
extension API holds the current status data internally. The extension API can
describe a program without using a structure.
1-4IM MX190-01E
1.2 Software Components and Features
Files Included
The software consists of the files listed below.
TypeExtensionDescription
Executable module.dllExecutable files.
Include file.hInclude file for Visual C and Visual C++.
Library file.libFiles linked in Visual C and Visual C++.
Standard module for Visual Basic.basFiles containing definitions for Visual
API viewer text file.txtFiles containing functions, types, and
Standard module for Visual Basic.NET.vbFiles containing definitions for Visual
Standard module for C#.csFiles containing definitions for C#.
1
Before Using the API
Basic.
constants for Visual Basic in text
format. Can be used by the API Viewer of
Visual Studio.
Basic.NET.
IM MX190-01E
1-5
1.3Operating Environment
PC (Personal Computer)
The software can be used by installing the API on a PC that meets the conditions
below.
Note
• No limitation is placed on the CPU, memory, and hard disk. However, the performance
of the software depends on them.
• At least 10 MB of free space on the hard disk is required for installing the API.
Operating System
One of the following operating systems must be running.
• Windows NT 4.0 SP3 or later
• Windows 2000
• Windows XP
• Windows Vista Home Premium
• Windows Vista Business
CD-ROM Drive
Used to install the API.
Mouse
Mouse supported by the OS.
Display
Display supported by the OS.
Communication Port
Ethernet port supported by the OS. The TCP/IP protocol must be installed.
Supported Languages
• Visual C++• Visual Basic.NET (extended API only)
• Visual C•C# (extended API only)
• Visual Basic
User Development Environment
A supported language must be installed and functional.
You must use Visual Studio 6.0 SP5 or later. The functions of this software are not
guaranteed when used with other platforms.
Visual C/ Visual C++ in Visual Studio 2005 or later is not compatible with the time_t
type.
For Visual Studio 2005, specify the Preprocessor Definition as USE_32BIT_TIME_T
under Properties > C/C++ > Preprocessor.
1-6IM MX190-01E
1.3 Operating Environment
MX100
No limitations in particular.
DARWIN
DA100, DC100, DR130, DR230, or DR240
The Ethernet communication function (Ethernet module) is required.
1
Before Using the API
IM MX190-01E
1-7
1.4Installation
Procedure
1. Turn ON the PC and allow the operating system to start.
Note
Close memory resident programs such as virus protection programs before installation.
2. Insert the CD-ROM containing the software into the CD-ROM drive.
3. After a few moments, the DAQMASTER DARWIN MXAPI window and the Install
Shield Wizard window appear. Next, the following screen appears. Follow the
instructions on the screen.
If the DAQMASTER DARWIN MXAPI window does not appear, carry out the
procedure below.
Click My Computer and double-click the CD-ROM icon. Double-click the Disk 1
icon and double-click Setup.exe in the folder. The DAQMASTER DARWIN MXAPI
window and the Install Shield Wizard window appear. Then, the following screen
appears. Follow the instructions on the screen.
Note
• Reinstalling the Software
If you carry out step 3 on a PC that has the software already installed, a window for
confirming the file deletion opens. Click OK to delete the software. Then, carry out step
3 to reinstall the software.
• You can uninstall the API by double-clicking Add/Remove Programs in the Windows
Control Panel.
1-8IM MX190-01E
Chapter 2 MX100 - Visual C++ -
2.1MX100 Class
The API consists of the MX100/DARWIN Common Class and the class dedicated to
the MX100 (see the figure below).
CDAQChInfo
• CDAQMXChID
• CDAQMXChInfo
• CDAQMXChConfig
CDAQDataInfo
• CDAQMXDataInfo
CDAQDateTime
• CDAQMXDateTime
CDAQHandler
• CDAQMX
• CDAQMXChConfigData
• CDAQMXConfig
• CDAQMXDOData
• CDAQMXNetInfo
• CDAQMXSegment
• CDAQMXStatus
• CDAQMXSysInfo
• CDAQMXBalanceData
• CDAQMXBalanceResult
• CDAQMXOutputData
• CDAQMXAOPWMData
• CDAQMXTransmit
: Class common to the MX100
and the DARWIN.
•
: Class dedicated to the MX100.
2
MX100 -Visual C++
CDAQChInfo Class
Base class for storing the channel information data.
CDAQDataInfo Class
Base class for storing the measured data.
CDAQDateTime Class
Base class for storing the time information data.
CDAQHandler Class
Handler base class for performing communications with the instrument (MX100/
DARWIN).
CDAQMX Class
Class derived from the CDAQHandler class. Provides functions for the MX100.
IM MX190-01E
2-1
2.1 MX100 Class
CDAQMXAOPWMData
Class for storing the AO/PWM data on the MX100. It is a wrapper class of the
MXAOPWMData structure.
CDAQMXBalanceData
Class for storing the initial balance data on the MX100. It is a wrapper class of the
MXBalanceData structure.
CDAQMXBalanceResult
Class for storing the initial balance results on the MX100. It is a wrapper class of the
MXBalanceResult structure.
CDAQMXChConfig Class
Class derived from the CDAQMXChID class. Class for storing the channel setup
data. It is a wrapper class of the MXChConfig structure.
CDAQMXChConfigData class
Class for storing the channel setup data for all the channels. It is a wrapper class of
the MXChConfigData structure.
CDAQMXChID Class
Class derived from the CDAQChInfo class. Class for storing channel ID information.
It is a wrapper class of the MXChID structure.
CDAQMXChInfo Class
Class derived from the CDAQMXChID class. Class for storing the channel
information data. It is a wrapper class of the MXChInfo structure.
CDAQMXConfig Class
Class for storing the setup data. It is a wrapper class of the MXChConfigData
structure.
CDAQMXDataInfo Class
Class derived from the CDAQDataInfo class. Class for storing the measured data. It
is a wrapper class of the MXDataInfo structure.
CDAQMXDateTime Class
Class derived from the CDAQDateTime class. Class for storing time information
data. It is a wrapper class of the MXDateTime structure.
2-2IM MX190-01E
CDAQMXDOData Class
Class for storing the DO data. It is a wrapper class of the MXDOData structure.
2.1 MX100 Class
CDAQMXNetInfo Class
Class for storing the network information data. It is a wrapper class of the MXNetInfo
structure.
CDAQMXOutputData
Class for storing the output channel data of the MX100. It is a wrapper class of the
MXOutputData structure.
CDAQMXSegment Class
Class for storing the display pattern of the 7-segment LED. It is a wrapper class of
the MXSegment structure.
CDAQMXStatus Class
Class for storing the MX100 status data. It is a wrapper class of the MXStatus
structure.
CDAQMXSysInfo Class
Class for storing the system configuration data of the MX100. It is a wrapper class of
the MXSystemInfo structure.
2
MX100 -Visual C++
CDAQMXTransmit
Class for storing the transmission output data of the MX100. It is a wrapper class of
the MXTransmit structure.
IM MX190-01E
2-3
2.2Correspondence between the Functions and
Class/Member Functions - MX100 -
This section indicates the correspondence between the functions that the software
supports and the class.
Communication Functions
FunctionClass and Member Function
Connect to the MX100.CDAQMX::open
Disconnect from the MX100.CDAQMX::close
Set the communication timeout.CDAQMX::setTimeOut
Note
Setting of the communication timeout is not recommended because unexpected
disconnection may occur due to the conflict with the timeout time when data is retrieved.
Control Functions
Starting/Stopping the FIFO
FunctionClass and Member Function
Start the FIFOCDAQMX::startFIFO
Stop the FIFOCDAQMX::stopFIFO
Set auto control of the FIFOCDAQMX::autoFIFO
Other Controls
FunctionFIFOClass and Member Function
Set time information on the MX100 as theStopCDAQMX::setDateTime
number of seconds from the reference
date/time (Jan. 1, 1970).
Turn ON/OFF data saving to the CF cardContinueCDAQMX::setBackup
(data backup).
CF write modeStopCDAQMXSysInfo:
setCFWriteMode
Format the CF card.StopCDAQMX::formatCF
• Reconfigure the system of the unit.StopCDAQMX::initSystem
• Initialize the system of the unit.Stop
• Reset alarms (alarm ACK) of the unit.Continue
The FIFO column in the table indicates the FIFO operation when the function is
executed while FIFO is running.
Stop: The FIFO stops when the function is executed.
Continue: The FIFO continues even when the function is executed.
With the backup settings, the CF write mode represents a partial change of the
collectively obtained data. After changing the data, it must be sent all together.
Note
If the auto control of the FIFO is enabled, the FIFO is automatically resumed when the
FIFO is stopped due to an execution of a function.
2-4IM MX190-01E
2.2 Correspondence between the Functions and Class/Member Functions - MX100
Setup Functions
Collective Setup
FunctionFIFOClass and Member Function
Configure the setup data collectivelyStopCDAQMX::setConfig
Set the DO (Digital Output) data collectivelyContinueCDAQMX::setDOData
Set the basic settings collectivelyStopCDAQMX::setMXConfig
Set the 7-segment LED displayContinueCDAQMX::setSegment
Transmit AO/PWM dataContinueCDAQMX::setAOPWMData
Send transmission output dataContinueCDAQMX::setTransmit
Set initial balance dataStopCDAQMX::setBalance
Set output channel dataStopCDAQMX::setOutput
Initial balance dataExecuteStopCDAQMX::runBalance
ResetStopCDAQMX::resetBalance
For a description of the FIFO column in the table, see the explanation given in
“Other Controls” on the previous page. With Visual Basic, setting data cannot be
handled collectively.
2
MX100 -Visual C++
IM MX190-01E
2-5
2.2 Correspondence between the Functions and Class/Member Functions - MX100
Setup Changes
FunctionClass and Member Function
Range setting SKIP (not used)CDAQMXConfig::setSKIP
DC voltage inputCDAQMXConfig::setVOLT
Thermocouple inputCDAQMXConfig::setTC
RTD inputCDAQMXConfig::setRTD
Digital input (DI)CDAQMXConfig::setDI
Difference computation between channelsCDAQMXConfig::setDELTA
Remote RJCCDAQMXConfig::setRRJC
ResistanceCDAQMXConfig::setRES
StrainCDAQMXConfig::setSTRAIN
AOCDAQMXConfig::setAO
PWMCDAQMXConfig::setPWM
PulseCDAQMXConfig::setPULSE
CommunicationCDAQMXConfig::setCOM
Set the unit name of the channel.CDAQMXChID::setUnit
Set the channel tag.CDAQMXChID::setTag
Set a comment for the channel.CDAQMXChID::setComment
Set the alarm.CDAQMXChConfig::setAlarm
Set the RJC used on the channel.CDAQMXChConfig::setRJCType
Set the filter on the channel.CDAQMXChConfig::setFilter
Set the burnout detection action.CDAQMXChConfig::setBurnout
Set the alarm to be assigned to the DO channelCDAQMXChConfig::setRefAlarm
to which an alarm output was specified.
(To set a DO channel to alarm output, use the
setDOType function member.)
Sets the chattering filter on the channel.CDAQMXChConfig::setChatFilter
Set the scan interval.CDAQMXConfig::setInterval
Set the temperature unit.CDAQMXConfig::setTempUnit
Set the ID number of the unit.CDAQMXSysInfo::setUnitNo
Set the timeout value (the time from the disconnection to CDAQMXSysInfo::setCFTimeout
the start of saving to the CF card. For the calculation
method of the timeout value, see appendix 3.
Select the signal type to be assigned to the DO channel. CDAQMXConfig::setDOType
Select the signal type to be assigned to the AO channel. CDAQMXConfig::setAOType
Select the signal type to be assigned to the PWM ch.CDAQMXConfig::setPWMType
Set the output channel data type.CDAQMXOutputData::setOutputType
Set the output value when the output data powerCDAQMXOutputData::setChoice
supply is ON and an error occurs.
Set the PWM output channel pulse intervalCDAQMXOutputData::setPulstime
(integral multiplication factor).
Set the signal type to be assigned to the DO channel.CDAQMXConfig::setDOType
Change a portion of the DO data.CDAQMXDOData::setDO
Change a portion of the AO/PWM data.CDAQMXAOPWMData::setAOPWM
Change a portion of the initial balance data.CDAQMXBalanceData::setBalance
Change a portion of the transmission output data.CDAQMXTransmit::setTransmit
2-6IM MX190-01E
2.2 Correspondence between the Functions and Class/Member Functions - MX100
Note
• To change the settings, use CDAQMX::getConfig to retrieve the setup data, use the
setup change function member to modify the settings, and use CDAQMX::setConfig to
set the data to the MX100 collectively.
• For DO data, after modifying the contents of CDAQMXDOData with the setup change
function member, use CDAQMX::setDOData to set the data on the MX100 collectively.
• For AO/PWM data, after modifying the contents of CDAQMXAOPWMData with the setup change
function member, use CDAQMX::setAOPWMData to set the data on the MX100 collectively.
• For transmission data, after modifying the contents of CDAQMXTransmit with the setup change
function member, use CDAQMX::setTransmit to set the data on the MX100 collectively.
Data Retrieval Functions
Retrieval of System Status Data and System Configuration Data
FunctionClass and Member Function
Get system status data.CDAQMX::getStatusData
Get system configuration data.CDAQMX::getSystemConfig
Retrieval of Setup Data
2
MX100 -Visual C++
FunctionClass and Member Function
Get the setup data collectively.CDAQMX::getConfig
Get basic settings collectively.CDAQMX::getMXConfig
Declare the retrieval of the setup data.CDAQMX::talkConfig
Retrieves setup data other than the channel setup data.
Get channel setup data.CDAQMX::getChConfig
Function used to retrieve channel setup data after declaring
the retrieval of setup data using the talkConfig function member.
Retrieval of DO Data
FunctionClass and Member Function
Get the DO data collectively.CDAQMX::getDOData
Retrieval of Channel Information Data
FunctionClass and Member Function
Declare the retrieval of the channel information data.CDAQMX::talkChInfo
Get channel information data.CDAQMX::getChInfo
Retrieval of Measured Data (Channel Designation)
FunctionClass and Member Function
Get the most recent data range of the specified channel. CDAQMX::getChDataNo
Declare the retrieval of the measured data of theCDAQMX::talkChData
specified channel. Declare the retrieval of the
instantaneous values of the specified channel.
Get the time information of the specified channelCDAQMX::getTimeData
for each data number.
Get the measured data of the specified channel.CDAQMX::getChData
IM MX190-01E
2-7
Loading...
+ 1234 hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.