mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-14 10:37:23 -07:00
chg: i2c fixes. all working.
chg: 'sc info' now prints url to atr decoder. chg: 'sc reader' has more options A, S
This commit is contained in:
parent
0d8e3160f8
commit
714de99f82
5 changed files with 104 additions and 81 deletions
|
@ -894,14 +894,14 @@ int CmdHF14ACmdRaw(const char *cmd) {
|
|||
if ((cmd[i]>='0' && cmd[i]<='9') ||
|
||||
(cmd[i]>='a' && cmd[i]<='f') ||
|
||||
(cmd[i]>='A' && cmd[i]<='F') ) {
|
||||
buf[strlen(buf)+1]=0;
|
||||
buf[strlen(buf)]=cmd[i];
|
||||
buf[strlen(buf)+1] = 0;
|
||||
buf[strlen(buf)] = cmd[i];
|
||||
i++;
|
||||
|
||||
if (strlen(buf)>=2) {
|
||||
sscanf(buf,"%x",&temp);
|
||||
data[datalen]=(uint8_t)(temp & 0xff);
|
||||
*buf=0;
|
||||
if (strlen(buf) >= 2) {
|
||||
sscanf(buf, "%x", &temp);
|
||||
data[datalen] = (uint8_t)(temp & 0xff);
|
||||
*buf = 0;
|
||||
if (++datalen >= sizeof(data)){
|
||||
if (crc)
|
||||
PrintAndLogEx(NORMAL, "Buffer is full, we can't add CRC to your data");
|
||||
|
@ -914,7 +914,7 @@ int CmdHF14ACmdRaw(const char *cmd) {
|
|||
return 0;
|
||||
}
|
||||
|
||||
if (crc && datalen>0 && datalen < sizeof(data)-2) {
|
||||
if (crc && datalen > 0 && datalen < sizeof(data)-2) {
|
||||
uint8_t first, second;
|
||||
if (topazmode) {
|
||||
compute_crc(CRC_14443_B, data, datalen, &first, &second);
|
||||
|
@ -989,7 +989,7 @@ static int waitCmd(uint8_t iSelect) {
|
|||
PrintAndLogEx(WARNING, "Can't select card.");
|
||||
}
|
||||
} else {
|
||||
PrintAndLogEx(NORMAL, "received %i bytes:", len);
|
||||
PrintAndLogEx(NORMAL, "received %i bytes", len);
|
||||
}
|
||||
|
||||
if (!len)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue