Home  Contents

v4kf:chipExecute

V4kf Core4 Lua Event System

SYNOPSIS

#include <v4kf.lh>
rdrhandle:chipExecute(apdu[, socket])

DESCRIPTION

Sends an APDU block to a smartcard for processing.

The card must have been activated by calling v4kf:chipActivate before it can be read.

When running against a regular chip card, then the command can only be used if the reader is in the Locked state, which secures the chip card against removal during operation.

Alternatively, the command can be run on a SAM card by specifying a non-zero socket number. The value selects the SAM socket to access (1..N, depending on the number of SAM sockets installed.)

While this state processes, the reader is in the Processing state and v4kf:isProcessing() returns true. The reader returns to the previous state on completion.

The command returns immediately. Actual execution of any reader operation is done within the event loop.

The RAPDU returned by the chip is provided with the v4kf.processingComplete() callback.

NOTES

APDU and RAPDU are terms from the ISO/IEC 7816-4 chip card specification. The driver sends and receives the APDU data verbatim and does not modify it in any way. There is a Wikipedia article about the APDU.

The EMV standard for Credit Cards is based on ISO/IEC 7816-4. Specifications for EMV are available for free download from EMVCo.

A short introduction is available from Wikipedia.

SEE ALSO