- // ISO 14443 APDU frame: PCB [CID] [NAD] APDU CRC PCB=0x02
- memcpy(data + 1, datain, datainlen);
- data[0] = 0x02; // bnr,nad,cid,chn=0; i-block(0x00)
- data[0] += iso14_pcb_blocknum; // add block number (bnr)
-
- datalen = datainlen + 1;
-
- ComputeCrc14443(CRC_14443_A, data, datalen, &first, &second);
- data[datalen++] = first;
- data[datalen++] = second;
-