Hi,
i need help about the smatcard
i write this function and work fine
but i need the function for read and write
thanks
HB_FUNC( PCSC_NAME )
{
LONG rv;
SCARDCONTEXT hContext;
LPTSTR mszReaders;
SCARDHANDLE hCard;
DWORD dwReaders, dwActiveProtocol, dwRecvLength;
rv = SCardEstablishContext(SCARD_SCOPE_SYSTEM, NULL, NULL, &hContext);
#ifdef SCARD_AUTOALLOCATE
dwReaders = SCARD_AUTOALLOCATE;
rv = SCardListReaders(hContext, NULL, (LPTSTR)&mszReaders, &dwReaders);
#else
rv = SCardListReaders(hContext, NULL, NULL, &dwReaders);
mszReaders = calloc(dwReaders, sizeof(char));
rv = SCardListReaders(hContext, NULL, mszReaders, &dwReaders);
#endif
if (SCARD_S_SUCCESS != rv)
{
hb_retc( "noPCSC" );
}
if (SCARD_S_SUCCESS == rv)
{
hb_retc( mszReaders );
}
rv = SCardReleaseContext(hContext);
}