> For the complete documentation index, see [llms.txt](https://sandbox-docs.verifone.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://sandbox-docs.verifone.com/s-adk-5.1-programmers-guide/readme/modules/group__sdicrd.md).

# Card reader interface

[Data Structures](#nested-classes) | [Functions](#func-members)

|                 |                                                                             |
| --------------- | --------------------------------------------------------------------------- |
| Data Structures |                                                                             |
| struct          | [SDIClient::TECOptions](#structvfisdi_1_1_s_d_i_client_1_1_t_e_c_options)   |
| struct          | [SDIClient::PluginResult](#structvfisdi_1_1_s_d_i_client_1_1_plugin_result) |

|           |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Functions |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| int       | [crdDetect](#ga8bec880c02a24ab758781862e535f6e6) (unsigned char tec, const [TECOptions](#structvfisdi_1_1_s_d_i_client_1_1_t_e_c_options) \&options, bool allow\_cancel, unsigned timeout\_ms, unsigned char \&tec\_out, [EMVTxn](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/structvfisdi_1_1_e_m_v_txn.md) \&emv\_out, const [bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5) \&appid=[bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5)(), unsigned char syncCard=0, unsigned char manual\_mode=0, const std::string \&format="", [bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5) \*plugin\_result=0) |
| int       | [crdDetect](#gac199163d2bc95feb16f8728301d5f067) (unsigned char tec, const [TECOptions](#structvfisdi_1_1_s_d_i_client_1_1_t_e_c_options) \&options, bool allow\_cancel, unsigned timeout\_ms, unsigned char \&tec\_out, [EMVTxn](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/structvfisdi_1_1_e_m_v_txn.md) \&emv\_out, std::vector< [PluginResult](#structvfisdi_1_1_s_d_i_client_1_1_plugin_result) > \&plugin\_result, const [bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5) \&appid=[bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5)(), unsigned char syncCard=0, unsigned char manual\_mode=0, const std::string \&format="", int removal\_timeout\_ms=-1)                                               |
| int       | [crdWaitForRemoval](#gaaa397799fb53215c5b5febbf78d4be54) (unsigned short timeout=0)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| int       | [crdStartDetect](#ga8bc5cd034d411e399f34a04030df30d5) (unsigned char tec, const [TECOptions](#structvfisdi_1_1_s_d_i_client_1_1_t_e_c_options) \&options, unsigned timeout, bool use\_cb=false, const [bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5) \&appid=[bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5)(), unsigned char syncCard=0)                                                                                                                                                                                                                                                                                                                                                                                                 |
| int       | [crdStartDetect](#ga20b2d4e611c8174a7c1caf9495236694) (unsigned char tec, const [TECOptions](#structvfisdi_1_1_s_d_i_client_1_1_t_e_c_options) \&options, unsigned timeout, bool use\_cb, const [bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5) \&appid, unsigned char syncCard, int removal\_timeout\_ms=-1)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| int       | [crdPollDetect](#ga832f6042c3fff724257309aa8f5b4cf2) (unsigned char \&tec\_out, [EMVTxn](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/structvfisdi_1_1_e_m_v_txn.md) \&emv\_out, [bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5) \*plugin\_result=0)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| int       | [crdStopDetect](#ga0fde18f23d79784cd57999cebd88a47e) ()                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| int       | [crdAddTechnology](#gadd5984f4ff1e0ed900d076c9cf2f3583) (unsigned char tec, const [TECOptions](#structvfisdi_1_1_s_d_i_client_1_1_t_e_c_options) \&options, const [bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5) \&appid=[bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5)(), unsigned char syncCard=0)                                                                                                                                                                                                                                                                                                                                                                                                                                     |
| int       | [crdRemoveTechnology](#ga3b6f80ede08e6b3496d31e17a661f714) (unsigned char tec)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| int       | [crdProvideCallbackResponse](#ga3cc73177ae72e9d3e4b05b2195ab7325) ([EMVTxn](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/structvfisdi_1_1_e_m_v_txn.md) \&in)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |

### DetailedDescription <a href="#detailed-description" id="detailed-description"></a>

***

### DataStructure Documentation <a href="#data-structure-documentation" id="data-structure-documentation"></a>

### vfisdi::SDIClient::TECOptions <a href="#structvfisdi_1_1_s_d_i_client_1_1_t_e_c_options" id="structvfisdi_1_1_s_d_i_client_1_1_t_e_c_options"></a>

struct vfisdi::SDIClient::TECOptions

technology selection options

|                |                       |                                                                                                                                                       |
| -------------- | --------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
| Data Fields    |                       |                                                                                                                                                       |
| unsigned char  | ctlsOptions           | see [EMVCtlsReaderOptions](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a6e2bd35a8ed2d0a3cd6f3867d65407c0) for emvCtlsSmartReset |
| unsigned char  | ctOptions             | see [EMVCtReaderOptions](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a7511f712094c1bc6defd81a587c42421) for emvCtSmartDetect    |
| unsigned short | msrAfterCTLSTimeout   |                                                                                                                                                       |
| unsigned short | msrAfterInsertTimeout |                                                                                                                                                       |
| unsigned       | nfcTechnology         | NFC technology bit mask, see [TECNFC](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a7517b629597bd1d709d208633e0c15b1)            |
| unsigned short | paymentTimeout        |                                                                                                                                                       |
| unsigned short | tec\_start            | see [TECStartOptions](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#af8fdc1631dd205cd2006934477f761be)                            |

### vfisdi::SDIClient::PluginResult <a href="#structvfisdi_1_1_s_d_i_client_1_1_plugin_result" id="structvfisdi_1_1_s_d_i_client_1_1_plugin_result"></a>

struct vfisdi::SDIClient::PluginResult

Plugin result entry

|                                                                                                                                                          |              |                                    |
| -------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------ | ---------------------------------- |
| Data Fields                                                                                                                                              |              |                                    |
| short                                                                                                                                                    | id           | plugin ID or -1 if unknown         |
| unsigned short                                                                                                                                           | responseCode | response code or 0x9100 if unknown |
| [bytevector](https://github.com/verifoneone/verifone-git-book-adk/tree/ADK5.1_staging/classvfisdi_1_1_s_d_i_client.md#a64b5be62be31dcda165d2c6c3c262fb5) | responseData | plugin response data               |

### FunctionDocumentation <a href="#function-documentation" id="function-documentation"></a>

### crdAddTechnology() <a href="#gadd5984f4ff1e0ed900d076c9cf2f3583" id="gadd5984f4ff1e0ed900d076c9cf2f3583"></a>

int crdAddTechnology

add technology to a running card detection started by crdStartDetect (23-06)

**Parameters**

\[in] **tec** bit mask of supported card technology (DFA108):1: CT smart card2: magnetic stripe4: CTLS smart card8: manual card entry \[in] **options** card technology selection options (DFA12A) \[in] **appid** optional application ID (DFA133) \[in] **syncCard** synchronous card type, 0 for undefined (DFA133)

#### Returns

SDI error code ([Result](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a28287671eaf7406afd604bd055ba4066))

### crdDetect()\[1/2] <a href="#ga8bec880c02a24ab758781862e535f6e6" id="ga8bec880c02a24ab758781862e535f6e6"></a>

int crdDetect

Detect magstripe read, smart card insertion, contactless card or manual card data entry (23-01)

**Parameters**

\[in] **tec** bit mask of supported card technology (DFA108):1: CT smart card2: magnetic stripe4: CTLS smart card8: manual card entry \[in] **options** card technology selection options (DFA12A) \[in] **allow\_cancel** if true enable cancel button (DFA109) \[in] **timeout\_ms** timeout in milliseconds, range 0..1275000ms, granularity varies from 500ms to 5s. \[out] **tec\_out** selected card technology (DFA108) \[out] **emv\_out** emv data \[in] **appid** optional application ID (DFA133->DFDB40) \[in] **syncCard** synchronous card type, 0 for undefined (DFA133->DFDB41) \[in] **manual\_mode** manual card entry mode (only considered if enabled in tec) (DFA017):0: enter PAN, expiration date and CVV1: enter PAN and expiration date2: enter only PAN \[in] **format** optional input format string for CVV \[out] **plugin\_result** plugin result of the card detect trigger, if not NULL (DFA101)

#### Returns

SDI error code ([Result](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a28287671eaf7406afd604bd055ba4066))

### crdDetect()\[2/2] <a href="#gac199163d2bc95feb16f8728301d5f067" id="gac199163d2bc95feb16f8728301d5f067"></a>

int crdDetect

Detect magstripe read, smart card insertion, contactless card or manual card data entry (23-01)

**Parameters**

\[in] **tec** bit mask of supported card technology (DFA108):1: CT smart card2: magnetic stripe4: CTLS smart card8: manual card entry \[in] **options** card technology selection options (DFA12A) \[in] **allow\_cancel** if true enable cancel button (DFA109) \[in] **timeout\_ms** timeout in milliseconds, range 0..1275000ms, granularity varies from 500ms to 5s. \[out] **tec\_out** selected card technology (DFA108) \[out] **emv\_out** emv data \[out] **plugin\_result** array containing plugin results (DFA101/FFA107) \[in] **removal\_timeout\_ms** optional card removal timeout in milliseconds for reading MSR data. Set to -1 if unused. (DFA153) \[in] **appid** optional application ID (DFA133->DFDB40) \[in] **syncCard** synchronous card type, 0 for undefined (DFA133->DFDB41) \[in] **manual\_mode** manual card entry mode (only considered if enabled in tec) (DFA017):0: enter PAN, expiration date and CVV1: enter PAN and expiration date2: enter only PAN \[in] **format** optional input format string for CVV

#### Returns

SDI error code ([Result](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a28287671eaf7406afd604bd055ba4066))

### crdPollDetect() <a href="#ga832f6042c3fff724257309aa8f5b4cf2" id="ga832f6042c3fff724257309aa8f5b4cf2"></a>

int crdPollDetect

poll for detected card (23-04)

**Parameters**

\[out] **tec\_out** selected card technology, or 0 in case no card has been found, yet (DFA108) \[out] **emv\_out** emv data \[out] **plugin\_result** plugin result of the card detect trigger, if not NULL (DFA101)

#### Returns

SDI error code ([Result](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a28287671eaf7406afd604bd055ba4066))

### crdProvideCallbackResponse() <a href="#ga3cc73177ae72e9d3e4b05b2195ab7325" id="ga3cc73177ae72e9d3e4b05b2195ab7325"></a>

int crdProvideCallbackResponse

provide callback response (23-08)

**Parameters**

\[in] **in** callback response data as EMVTxn object

#### Returns

SDI error code ([Result](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a28287671eaf7406afd604bd055ba4066))

### crdRemoveTechnology() <a href="#ga3b6f80ede08e6b3496d31e17a661f714" id="ga3b6f80ede08e6b3496d31e17a661f714"></a>

int crdRemoveTechnology

remove technology to a running card detection started by crdStartDetect (23-07)

**Parameters**

\[in] **tec** bit mask of supported card technology (DFA108):1: CT smart card2: magnetic stripe4: CTLS smart card8: manual card entry

#### Returns

SDI error code ([Result](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a28287671eaf7406afd604bd055ba4066))

### crdStartDetect()\[1/2] <a href="#ga20b2d4e611c8174a7c1caf9495236694" id="ga20b2d4e611c8174a7c1caf9495236694"></a>

int crdStartDetect

start card detection (23-03)

**Parameters**

\[in] **tec** bit mask of supported card technology (DFA108):1: CT smart card2: magnetic stripe4: CTLS smart card8: manual card entry \[in] **options** card technology selection options (DFA12A) \[in] **timeout** timeout in seconds \[in] **appid** optional application ID (DFA133) \[in] **syncCard** synchronous card type, 0 for undefined (DFA133) \[in] **use\_cb** if true trigger card callback \[in] **removal\_timeout\_ms** optional card removal timeout in milliseconds for reading MSR data. Set to -1 if unused. (DFA153)

#### Returns

SDI error code ([Result](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a28287671eaf7406afd604bd055ba4066))

### crdStartDetect()\[2/2] <a href="#ga8bc5cd034d411e399f34a04030df30d5" id="ga8bc5cd034d411e399f34a04030df30d5"></a>

int crdStartDetect

start card detection (23-03)

**Parameters**

\[in] **tec** bit mask of supported card technology (DFA108):1: CT smart card2: magnetic stripe4: CTLS smart card8: manual card entry \[in] **options** card technology selection options (DFA12A) \[in] **timeout** timeout in seconds \[in] **appid** optional application ID (DFA133) \[in] **syncCard** synchronous card type, 0 for undefined (DFA133) \[in] **use\_cb** if true trigger card callback

#### Returns

SDI error code ([Result](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a28287671eaf7406afd604bd055ba4066))

### crdStopDetect() <a href="#ga0fde18f23d79784cd57999cebd88a47e" id="ga0fde18f23d79784cd57999cebd88a47e"></a>

int crdStopDetect

stop card detection (23-05) It may be required to call crdPollDetect to get the result in case a card was inserted between the last crdPollDetect and crdStopDetect

#### Returns

SDI error code ([Result](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a28287671eaf7406afd604bd055ba4066))

### crdWaitForRemoval() <a href="#gaaa397799fb53215c5b5febbf78d4be54" id="gaaa397799fb53215c5b5febbf78d4be54"></a>

int crdWaitForRemoval

wait until the card is removed (only for contact) (23-02)

**Parameters**

\[in] **timeout** timeout in seconds

#### Returns

SDI error code ([Result](/s-adk-5.1-programmers-guide/readme/namespaces/namespacevfisdi.md#a28287671eaf7406afd604bd055ba4066))


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://sandbox-docs.verifone.com/s-adk-5.1-programmers-guide/readme/modules/group__sdicrd.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
