C language interface – ThingMagic Mercury API v1.23.0 User Manual

Page 95

Advertising
background image

C Language Interface

95

C Language Interface

The C language interface is designed primarily to provide support for embedded systems.
The structure of the interface is designed to provide a pseudo object-oriented
programming model that mimics the Java and .NET interfaces as much as possible. The
C API will work similarly as the other languages, as described in the previous sections of
the Guide, with mostly language syntax and semantics differences. It uses similarly
named API calls (e.g. substitute TMR_* for Reader.*) in C for all the operations outlined in
the API Guide, and they will be used in the same manner.

In order to best support embedded systems it avoids large memory buffers and dynamic
memory allocation (where possible, interfaces are created so that if dynamic allocation is
available, the user can take advantage of it without difficulty and), has several memory-
saving features including the ability to build only a subset of the API (strip out unused
protocols, advanced features, etc.).

The following section will provide details to help understand the unique aspects of the C
interface as compared to Java and .NET, and how to build C API applications for
embedded systems.

Note

Currently the C API does not support the RQLReader interface and cannot
be used to control Mercury4/5 and Astra readers, only SerialReaders (M5e
and M5e-C, M6e, USB, Vega) and Astra-EX/M6 v4.9.2 and later.

Note

Requires GCC v4.4.2 or newer

Note

The C API is not supported on Windows for the M6 and Astra-EX.

Advertising