- UsbCommand * resp = WaitForResponseTimeout(CMD_ACK, 3000);\r
-\r
- if (resp == NULL) return 1;\r
- if ((resp->arg[0] & 0xff) != 0x01) return 2;\r
- *key = bytes_to_num(resp->d.asBytes, 6);\r
+ UsbCommand resp;\r
+ if (!WaitForResponseTimeout(CMD_ACK,&resp,3000)) return 1;\r
+ if ((resp.arg[0] & 0xff) != 0x01) return 2;\r
+ *key = bytes_to_num(resp.d.asBytes, 6);\r