mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-20 05:13:46 -07:00
adjustments
This commit is contained in:
parent
652bf0c94b
commit
732c012be7
3 changed files with 13 additions and 4 deletions
|
@ -2672,8 +2672,10 @@ void ReaderIso14443a(PacketCommandNG *c) {
|
||||||
uint8_t buf[PM3_CMD_DATA_SIZE] = {0x00};
|
uint8_t buf[PM3_CMD_DATA_SIZE] = {0x00};
|
||||||
uint8_t par[MAX_PARITY_SIZE] = {0x00};
|
uint8_t par[MAX_PARITY_SIZE] = {0x00};
|
||||||
|
|
||||||
if ((param & ISO14A_CONNECT))
|
if ((param & ISO14A_CONNECT)) {
|
||||||
|
iso14_pcb_blocknum = 0;
|
||||||
clear_trace();
|
clear_trace();
|
||||||
|
}
|
||||||
|
|
||||||
set_tracing(true);
|
set_tracing(true);
|
||||||
|
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
# define FWT_TIMEOUT_14B 35312
|
# define FWT_TIMEOUT_14B 35312
|
||||||
#endif
|
#endif
|
||||||
#ifndef ISO14443B_DMA_BUFFER_SIZE
|
#ifndef ISO14443B_DMA_BUFFER_SIZE
|
||||||
# define ISO14443B_DMA_BUFFER_SIZE 256
|
# define ISO14443B_DMA_BUFFER_SIZE 512 //changed this from 256
|
||||||
#endif
|
#endif
|
||||||
#ifndef RECEIVE_MASK
|
#ifndef RECEIVE_MASK
|
||||||
# define RECEIVE_MASK (ISO14443B_DMA_BUFFER_SIZE-1)
|
# define RECEIVE_MASK (ISO14443B_DMA_BUFFER_SIZE-1)
|
||||||
|
@ -37,7 +37,7 @@
|
||||||
|
|
||||||
// Guard Time (per 14443-2)
|
// Guard Time (per 14443-2)
|
||||||
#ifndef TR0
|
#ifndef TR0
|
||||||
# define TR0 0
|
# define TR0 32 //this value equals 8 ETU = 32 ssp clk (w/ 424 khz)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Synchronization time (per 14443-2)
|
// Synchronization time (per 14443-2)
|
||||||
|
@ -261,6 +261,10 @@ static void CodeIso14443bAsTag(const uint8_t *cmd, int len) {
|
||||||
// 80/fs < TR1 < 200/fs
|
// 80/fs < TR1 < 200/fs
|
||||||
// 10 ETU < TR1 < 24 ETU
|
// 10 ETU < TR1 < 24 ETU
|
||||||
|
|
||||||
|
// Send TR1.
|
||||||
|
// 10-11 ETU * 4times samples ONES
|
||||||
|
for (int i = 0; i < 10; i++) { SEND4STUFFBIT(1); }
|
||||||
|
|
||||||
// Send SOF.
|
// Send SOF.
|
||||||
// 10-11 ETU * 4times samples ZEROS
|
// 10-11 ETU * 4times samples ZEROS
|
||||||
for (int i = 0; i < 10; i++) { SEND4STUFFBIT(0); }
|
for (int i = 0; i < 10; i++) { SEND4STUFFBIT(0); }
|
||||||
|
@ -307,7 +311,7 @@ static void CodeIso14443bAsTag(const uint8_t *cmd, int len) {
|
||||||
//for(i = 0; i < 10; i++) { ToSendStuffBit(0); }
|
//for(i = 0; i < 10; i++) { ToSendStuffBit(0); }
|
||||||
|
|
||||||
// why this?
|
// why this?
|
||||||
for (int i = 0; i < 40; i++) { SEND4STUFFBIT(1); }
|
for (int i = 0; i < 2; i++) { SEND4STUFFBIT(1); }
|
||||||
//for(i = 0; i < 40; i++) { ToSendStuffBit(1); }
|
//for(i = 0; i < 40; i++) { ToSendStuffBit(1); }
|
||||||
|
|
||||||
// Convert from last byte pos to length
|
// Convert from last byte pos to length
|
||||||
|
|
|
@ -118,6 +118,9 @@ void MifareDesfireGetInformation() {
|
||||||
set_tracing(true);
|
set_tracing(true);
|
||||||
iso14443a_setup(FPGA_HF_ISO14443A_READER_LISTEN);
|
iso14443a_setup(FPGA_HF_ISO14443A_READER_LISTEN);
|
||||||
|
|
||||||
|
// reset the pcb_blocknum,
|
||||||
|
pcb_blocknum = 0;
|
||||||
|
|
||||||
// card select - information
|
// card select - information
|
||||||
if (!iso14443a_select_card(NULL, &card, NULL, true, 0, false)) {
|
if (!iso14443a_select_card(NULL, &card, NULL, true, 0, false)) {
|
||||||
if (DBGLEVEL >= DBG_ERROR) DbpString("Can't select card");
|
if (DBGLEVEL >= DBG_ERROR) DbpString("Can't select card");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue