- return_code = iso14443a_select_card(uid, &card_select_info, NULL);
- if (return_code != 1) {
- return 1;
+ return_code = iso14443a_select_card(uid, &card_select_info, NULL, true, 0, false);
+ if (return_code == 1) {
+ // send the PPS request
+ ReaderTransmit((uint8_t *)pps, sizeof(pps), NULL);
+ return_code = ReaderReceive(pps_response, pps_response_par);
+ if (return_code != 3 || pps_response[0] != 0xD0) {
+ return return_code == 0 ? 2 : return_code;
+ }
+ Dbprintf("ISO 14443 Type A");
+ iso_type = 'a';
+ return 0;