pcsc-lite 1.9.9
Functions
prothandler.c File Reference

This handles protocol defaults, PTS, etc. More...

#include "config.h"
#include <string.h>
#include "misc.h"
#include "pcscd.h"
#include "debuglog.h"
#include "readerfactory.h"
#include "prothandler.h"
#include "atrhandler.h"
#include "ifdwrapper.h"
#include "eventhandler.h"

Go to the source code of this file.

Functions

DWORD PHSetProtocol (struct ReaderContext *rContext, DWORD dwPreferred, UCHAR ucAvailable, UCHAR ucDefault)
 Determine which protocol to use.
 

Detailed Description

This handles protocol defaults, PTS, etc.

Definition in file prothandler.c.

Function Documentation

◆ PHSetProtocol()

DWORD PHSetProtocol ( struct ReaderContext rContext,
DWORD  dwPreferred,
UCHAR  ucAvailable,
UCHAR  ucDefault 
)

Determine which protocol to use.

SCardConnect has a DWORD dwPreferredProtocols that is a bitmask of what protocols to use. Basically, if T=N where N is not zero will be used first if it is available in ucAvailable. Otherwise it will always default to T=0.

IFDSetPTS() is always called so that the driver can initialise its data

Definition at line 60 of file prothandler.c.