# MTSCRA Class Methods - 1 - 10

After creating an instance of the MTSCRA class in your custom software project, use the methods described in this section to communicate with SCRA device.

#### requestDeviceList <a href="#id-4.1_requestdevicelist" id="id-4.1_requestdevicelist"></a>

This method initiates the discovery of devices that are visible to the host using the specified connection interface. The DeviceListReceived() event will provide information regarding the available devices once the discovery process is completed.

public void requestDeviceList(MTConnectionType connectionType)

Parameters:

<table data-header-hidden><thead><tr><th width="186.66668701171875" valign="top"></th><th valign="top"></th></tr></thead><tbody><tr><td valign="top">Parameter</td><td valign="top">Description</td></tr><tr><td valign="top"><p> </p><p> </p><p> </p><p> </p><p>connectionType</p></td><td valign="top">MTConnectionType value: MTConnectionType.Audio, MTConnectionType.BLE, MTConnectionType.BLEEMV, MTConnectionType.Bluetooth, MTConnectionType.USB, MTConnectionType.Serial, MTConnectionType.Net, MTConnectionType.Net_TLS12, MTConnectionType.Net_TLS12_Trust_All</td></tr></tbody></table>

Return Value: None

#### setConnectionType <a href="#id-4.2_setconnectiontype" id="id-4.2_setconnectiontype"></a>

This method sets the connection type of the device.

public void setConnectionType(MTConnectionType connectionType)

Parameters:

<table data-header-hidden><thead><tr><th width="172.66668701171875" valign="top"></th><th valign="top"></th></tr></thead><tbody><tr><td valign="top">Parameter</td><td valign="top">Description</td></tr><tr><td valign="top"><p> </p><p> </p><p> </p><p> </p><p>connectionType</p></td><td valign="top">MTConnectionType value: MTConnectionType.Audio, MTConnectionType.BLE, MTConnectionType.BLEEMV, MTConnectionType.Bluetooth, MTConnectionType.USB, MTConnectionType.Serial, MTConnectionType.Net, MTConnectionType.Net_TLS12, MTConnectionType.Net_TLS12_Trust_All</td></tr></tbody></table>

The following table shows the connection types supported by the various programming interfaces:

<table data-header-hidden><thead><tr><th valign="top"></th><th width="71.33331298828125" valign="top"></th><th width="99.33331298828125" valign="top"></th><th width="98.66668701171875" valign="top"></th><th width="96.66668701171875" valign="top"></th><th width="67.33331298828125" valign="top"></th><th width="91.00006103515625" valign="top"></th></tr></thead><tbody><tr><td valign="top">Connection Type / Programming Interface</td><td valign="top">Audio</td><td valign="top">Bluetooth LE</td><td valign="top">Bluetooth LE EMV</td><td valign="top">Bluetooth</td><td valign="top">USB</td><td valign="top">UART</td></tr><tr><td valign="top">.NET Framework</td><td valign="top">X</td><td valign="top">X</td><td valign="top">X</td><td valign="top"> </td><td valign="top">X</td><td valign="top">X</td></tr><tr><td valign="top">Universal Windows Platform</td><td valign="top"> </td><td valign="top"> </td><td valign="top"> </td><td valign="top"> </td><td valign="top">X</td><td valign="top"> </td></tr></tbody></table>

The following table shows the connection types supported by the various SCRA devices:

<table data-header-hidden><thead><tr><th width="200.66668701171875" valign="top"></th><th valign="top"></th></tr></thead><tbody><tr><td valign="top">Connection Type</td><td valign="top">SCRA Device</td></tr><tr><td valign="top">Audio</td><td valign="top">aDynamo uDynamo</td></tr><tr><td valign="top">Bluetooth LE</td><td valign="top">DynaMAX</td></tr><tr><td valign="top">Bluetooth LE EMV</td><td valign="top">eDynamo tDynamo</td></tr><tr><td valign="top">Bluetooth</td><td valign="top">BulleT</td></tr><tr><td valign="top"><p> </p><p> </p><p> </p><p>USB</p></td><td valign="top"><p>BulletT DynaMag DynaMAX eDynamo mDynamo DynaWave tDynamo</p><p>iDynamo 5 Gen III</p></td></tr><tr><td valign="top">Serial</td><td valign="top">DynaWave</td></tr></tbody></table>

Return Value: None

#### setAddress <a href="#id-4.3_setaddress" id="id-4.3_setaddress"></a>

This method sets the address of the device.

public void setAddress(string deviceAddress)

Parameters:

<table data-header-hidden><thead><tr><th valign="top"></th><th valign="top"></th></tr></thead><tbody><tr><td valign="top">Parameter</td><td valign="top">Description</td></tr><tr><td valign="top">deviceAddress</td><td valign="top">String value of the address.</td></tr></tbody></table>

Return Value: None

#### setDeviceID <a href="#id-4.4_setdeviceid" id="id-4.4_setdeviceid"></a>

This method sets the device ID.

public void setDeviceID(string deviceID)

Parameters:

<table data-header-hidden><thead><tr><th width="139.33331298828125" valign="top"></th><th valign="top"></th></tr></thead><tbody><tr><td valign="top">Parameter</td><td valign="top">Description</td></tr><tr><td valign="top">deviceID</td><td valign="top">String value of the device ID.</td></tr></tbody></table>

Return Value: None

#### openDevice <a href="#id-4.5_opendevice" id="id-4.5_opendevice"></a>

This method opens connection to the device. If you use the MagTek Universal Windows SDK and USB Card reader with PID 0011, please refer to section 2.5 How to remove POS HID Magnetic Stripe Reader.

public void openDevice()

Parameters: None&#x20;

Return Value: None

#### closeDevice <a href="#id-4.6_closedevice" id="id-4.6_closedevice"></a>

This method closes the connection to the device.

public void closeDevice()

Parameters: None&#x20;

Return Value: None

#### isDeviceConnected <a href="#id-4.7_isdeviceconnected" id="id-4.7_isdeviceconnected"></a>

This method returns whether the device is connected or not.

public bool isDeviceConnected()

Parameters: None Return Value:

Return true if the device is connected. Otherwise, return false.

#### isDeviceEMV <a href="#id-4.8_isdeviceemv" id="id-4.8_isdeviceemv"></a>

This method returns whether the device supports EMV or not.

public bool isDeviceEMV()

Parameters: None Return Value:

Return true if EMV is supported by the device. Otherwise, return false.

#### isDeviceOEM <a href="#id-4.9_isdeviceoem" id="id-4.9_isdeviceoem"></a>

This method returns whether the device is an OEM device or not.

public bool isDeviceOEM()

Parameters: None Return Value:

Return true if device is OEM. Otherwise, return false.

#### getMaskedTracks <a href="#id-4.10_getmaskedtracks" id="id-4.10_getmaskedtracks"></a>

Get stored masked tracks data. If decodable track data exists for a given track, it is located in the Masked Track Data field that corresponds to the track number. The length of each Masked Track Data field is fixed at 112 bytes, but the length of valid data in each field is determined by the Masked Track Data Length field that corresponds to the track number. Masked Track Data located in positions greater than indicated in the Masked Track Data Length field are undefined and should be ignored.

The Masked Track Data is decoded and converted to ASCII and then it is masked. The Masked Track Data includes all data starting with the start sentinel and ending with the end sentinel. Much of the data is masked; a specified mask character is sent instead of the actual character read from the track. Which characters are masked depends on the format of the card. Only ISO/ABA (Financial Cards with Format Code B) and AAMVA cards are selectively masked; all other card types are either entirely masked or sent totally in the clear. There is a separate masking property for ISO/ABA cards and AAMVA cards. See the ISO Track Masking property and the AAMVA Track Masking property for more information. See *99875475* for a description on how ISO/ABA and AAMVA cards are identified.

Each of these properties allows the application to specify masking details for the Primary Account Number and Driver’s License / ID Number (DL/ID#), the masking character to be used, and whether a correction should be applied to make the Mod 10 9 (Luhn algorithm) digit at the end of the number be correct.

public string getMaskedTracks()

Parameters: None Return Value:

Return stored masked tracks data string.


---

# 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/card-readers/magnetic-stripe-readers/idynamo-5-gen-iii/documentation/developers-manuals/programmers-manual-.net-pcl/mtscra-class-methods/mtscra-class-methods-1-10.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.
