Microsoft Windows CE 3.0  


This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

The RDF_TRANSMITcallback function performs data transmissions. This callback function is mandatory.



Points to the smart card extension of the device. SmartcardExtension->MajorIoControlCodecontains IOCTL_SMARTCARD_TRANSMIT. SmartcardExtension->IoRequest.RequestBufferpoints to an SCARD_IO_REQUESTstructure followed by data to be transmitted to the card. SmartcardExtension->IoRequest.RequestBufferLengthcontains the number of bytes to be transmitted to the card. SmartcardExtension->IoRequest.ReplyBufferLengthcontains the size of the reply buffer. On output, SmartcardExtension->IoRequest.ReplyBufferpoints to the buffer that receives the SCARD_IO_REQUESTstructure, plus the result of the card, and SmartcardExtension->IoRequest.Informationreceives the actual number of bytes returned by the card, plus the size of SCARD_IO_REQUESTstructure.


When this function is called, SmartcardExtension->IoRequest.RequestBufferpoints to a SCARD_IO_REQUESTstructure followed by data to be transmitted. SCARD_IO_REQUEST has the following format:

typedef struct _SCARD_IO_REQUEST{ DWORD
dwProtocol; // Protocol identifier DWORD cbPciLength; // Protocol
Control Information Length } SCARD_IO_REQUEST, *PSCARD_IO_REQUEST,

The dwProtocol member must contain the protocol identifier that was returned by a call to IOCTL_SMARTCARD_SET_PROTOCOL.

The cbPciLength member contains the size of this structure, which is usually eight. This structure will be used mainly for future implementations.

The structure is followed by (protocol) data to be transmitted to the card. Depending on the protocol to be used for this transmission, the library offers several support functions. See SmartcardT1Request.

Note, RequestBuffer and ReplyBuffer point to the same system buffer. If you use the library function SmartcardxxRequest and SmartcardxxReply, you do not have to worry that you might overwrite the input buffer. If you do not use these functions, make a copy of the RequestBuffer before you start transmissions.

The implementation requires you to copy the SCARD_IO_REQUEST structure to the ReplyBuffer, followed by the data received from the card. Again, if you use the SmartcardxxRequest and SmartcardxxReply functions, you do not need to copy the structure because the library does this.

Return Values

This function returns an NTSTATUS value. Possible values are the following:

Value Meaning
STATUS_SUCCESS Transmission successful.
STATUS_NO_MEDIA No card is in the reader.
STATUS_IO_TIMEOUT The request has timed out.
STATUS_INVALID_DEVICE_REQUEST The protocol defined by dwProtocolis invalid.


Runs on Versions Defined in Include Link to
Windows CE OS 3.0 and later      
Note   This API is part of the complete Windows CE OS package as provided by Microsoft. The functionality of a particular platform is determined by the original equipment manufacturer (OEM) and some devices may not support this API.

 Last updated on Tuesday, July 13, 2004

© 2004 Microsoft Corporation. All rights reserved.