how to fix smart card reader resource manager is not runing in python code using pyscard and ACS120 reader?

syariffortask 0 Reputation points
2024-05-09T09:20:34.6566667+00:00

i run this program code,but i got error message "Failed to establish context: The Smart Card Resource Manager is not running. (0x8010001D)", and i have already run scardSvr
service

can microsoft help for this problem please?

from smartcard.Exceptions import NoCardException
from smartcard.System import readers
from smartcard.util import toHexString
import sys

for reader in readers():
    try:
        connection = reader.createConnection()
        connection.connect()
        print(reader, toHexString(connection.getATR()))
    except NoCardException:
        print(reader, 'no card inserted')

if 'win32' == sys.platform:
    print('press Enter to continue')
    sys.stdin.read(1)
Windows 10
Windows 10
A Microsoft operating system that runs on personal computers and tablets.
10,763 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
8,371 questions
0 comments No comments
{count} votes