:- include('pcsc/muscle'). start :- scard_establish_context, scard_connect, % print ATR data scard_status(_, Atr), print('ATR: '), print_hex_list(Atr), nl, % enable trace scard_enable_verbose(true), ( Commande = [0,0xA4,4,0,0x0A,0xA0,0,0,0,0x62,3,1,0x0C,6,1], scard_transmit(Commande, _Reponse, _Sw, _Time) -> true ; print('Application error in transmit Select Applet'), nl ), print('Réponse : '), print(_Reponse), nl, print('SW : '), print(_Sw), nl, ( Commande = [0,0,0,0], scard_transmit(Commande, _Reponse, _Sw, _Time) -> true ; print('Application error in transmit APDU de test'), nl ), print('Réponse : '), print(_Reponse), nl, print('SW : '), print(_Sw), nl. :- initialization(start).