# MTCMS Library Enumerations and Structures

The MTCMS Library uses the following constants and data structures.

#### MTConnectionType Values <a href="#id-6.1_mtconnectiontype_values" id="id-6.1_mtconnectiontype_values"></a>

Device connection types:

```
enum MTConnectionType
{
        USB, IP,
                Serial
};
```

#### MTConnectionState Values

Device connection states:

<pre><code>enum MTConnectionState
{
<strong>    Disconnected, 
</strong><strong>    Connecting,
</strong><strong>    Error, 
</strong><strong>    Connected, 
</strong><strong>    Disconnecting
</strong>};
</code></pre>

#### MTDeviceInformation

Device information structure:

```
struct MTDeviceInformation
{
    const char* Id; 
    const char* Name; 
    const char* Address;
    const char* ProductId;
};
```

#### MTCMSMessage

MTCMSMessage structure:

```
struct MTCMSMessage
{
    int messageType; 
    int applicationID; 
    int commandID;
    int resultCode; 
    int dataTag;
    const unsigned char* data; 
    int dataLength;
    const unsigned char* messageBytes; 
    int messageBytesLength;
};
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://developer.magtek.com/hardware/oem-readers-and-components/oem-readers/odynamo/documentation/programmers-manuals/common-message-structure-mtcms-programmers-reference-manual-c++/mtcms-library-enumerations-and-structures.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
