- Linux MultiMedia Studio Computer Accessories User Manual

Mint v4 PC Programming Guide
36
MN1278 05.2001
The Mint Interface Library provides all of the functionality that is available in the Mint programming language.
Motion applications can be written on the host PC by calling functions from the Mint Interface Library. When a
function is called, the Mint Interface Library communicates with the controller and calls the specified function
directly on the controller. The Mint functionality is still being performed by the controller but it has been
initiated directly by a host application. The real-time elements of Mint are still run on the controller but the
sequencing can be controlled by the host application.
The following diagram shows the architecture, known as Immediate Command Mode:
Controller
Mint
Host I/F
Terminal/
Comms
MINT Motion Library
Servo
Loop
Profiler
x N
x N
ICM
Device
Driver
Host
MIL
Figure 4-1: Immediate Command Mode Interface
Immediate Command Mode (ICM) is the method that allows Mint motion functions to be called from a host
application, bypassing Mint.
Calling functions from the host is particularly useful if there is a large amount of processing to do (i.e. calculation
of multi-axis paths) as the host can do the processing and send the commands to the controller. Note that these
functions can be used in conjunction with a Mint program. For example a Mint program handles the I/O and the
host calculates the path and sends it to the controller using setVectorA().
The Immediate Command Mode interface can also be used for testing applications to be compiled by a C31
compiler and run on NextMove. This is described in Mint v4 Embedded Programming Guide.
There is a one to one correlation between Mint commands and Mint Interface Library Functions. For example,
within a Mint program, the MOVER keyword is used to create a relative positional move on an axis.
MOVER.0 = 10
The Mint Interface Library function for this is setMoveR.
setMoveR (0, 10)
The keyword has been prefixed with set. Almost all Mint keywords are available in the Mint Interface Library.
The will be prefixed with set for writes, get for reads and do for commands.