clearCommandBuffer();
SendCommand(&c);
UsbCommand resp;
- WaitForResponse(CMD_ACK,&resp);
+ WaitForResponse(CMD_ACK, &resp);
iso14a_card_select_t card;
memcpy(&card, (iso14a_card_select_t *)resp.d.asBytes, sizeof(iso14a_card_select_t));
c.arg[2] = 13560000 / 1000 / (8*16) * timeout; // timeout in ETUs (time to transfer 1 bit, approx. 9.4 us)
}
- if(power)
+ if(power) {
c.arg[0] |= ISO14A_NO_DISCONNECT;
-
- if(datalen>0)
+ }
+
+ if(datalen>0) {
c.arg[0] |= ISO14A_RAW;
-
- if(topazmode)
+ }
+
+ if(topazmode) {
c.arg[0] |= ISO14A_TOPAZMODE;
+ }
// Max buffer is USB_CMD_DATA_SIZE
datalen = (datalen > USB_CMD_DATA_SIZE) ? USB_CMD_DATA_SIZE : datalen;