\part{Introduction}

The MX control system toolkit can be used as a standalone data acquisition
and control system or as a uniform API for connecting to other control
system.  The core of MX (libMx, mxserver, mxmotor, etc.) is
written in C.  However, MX also provides programming APIs for a few
other languages.  The best supported language is Python (Python 2.x for now),
which supports most of the important MX APIs in a more object-oriented
fashion.  There is also an older Tcl-based API (usingfor a subset of MX, but
the TCL API is not currently being worked on.

The programmer's guide only directly covers the C language API.  However,
the scripting APIs (Python, Tcl) generally provide one-to-one mappings
of object methods onto the lower level C functions, so this C language
guide should give you insight into how to use the similarly named
Python methods.

This guide does not provide details of the function call signatures.  The
idea is to give a high level summary of all of what is available, so that
you can then look in the \textit{mx\_*.h} header files for the function
arguments.  The header file prototypes do try to give descriptive names
for each of the function arguments.

\section{Programming Model}

The \textit{libMx} uses a quasi-object oriented C-based API.  The primary
object of MX is the C structure \textbf{MX\_RECORD}.  \textbf{MX\_RECORD}s
are used to contain information about all of the devices being managed
by an MX database such as motors, scalers, timers, multichannel analyzers,
CCD/CMOS area detectors, RS-232 ports, USB devices, etc.  
