diff options
Diffstat (limited to 'rfid_proto_mifare_ul.c')
-rw-r--r-- | rfid_proto_mifare_ul.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/rfid_proto_mifare_ul.c b/rfid_proto_mifare_ul.c index adac9cc..9e5363f 100644 --- a/rfid_proto_mifare_ul.c +++ b/rfid_proto_mifare_ul.c @@ -52,7 +52,8 @@ mful_read(struct rfid_protocol_handle *ph, unsigned int page, tx[0] = MIFARE_UL_CMD_READ; tx[1] = page & 0xff; - ret = ph->l2h->l2->fn.transcieve(ph->l2h, tx, sizeof(tx), rx_buf, + ret = ph->l2h->l2->fn.transcieve(ph->l2h, RFID_14443A_FRAME_REGULAR, + tx, sizeof(tx), rx_buf, &real_rx_len, MIFARE_UL_READ_FWT, 0); if (ret < 0) @@ -76,10 +77,8 @@ mful_write(struct rfid_protocol_handle *ph, unsigned int page, unsigned int rx_len = sizeof(rx); int ret; -#if 0 if (tx_len != 4 || page > MIFARE_UL_PAGE_MAX) return -EINVAL; -#endif tx[0] = MIFARE_UL_CMD_WRITE; tx[1] = page & 0xff; @@ -87,8 +86,9 @@ mful_write(struct rfid_protocol_handle *ph, unsigned int page, for (i = 0; i < 4; i++) tx[2+i] = tx_data[i]; - ret = ph->l2h->l2->fn.transcieve(ph->l2h, tx, sizeof(tx), rx, - &rx_len, MIFARE_UL_WRITE_FWT, 0); + ret = ph->l2h->l2->fn.transcieve(ph->l2h, RFID_14443A_FRAME_REGULAR, + tx, sizeof(tx), rx, &rx_len, + MIFARE_UL_WRITE_FWT, 0); if (ret < 0) return ret; |