FIX: an error that I introduced to the csetblock command with wrong length of crc calcs.

CHG:  variable name in csetblock change.  just trying to be consistant.
ADD:  code clean up in hf 14a,  added some help text methods.
This commit is contained in:
iceman1001 2015-11-10 11:45:45 +01:00
commit 0956e0dba5
4 changed files with 61 additions and 61 deletions

View file

@ -1092,8 +1092,8 @@ void MifareCSetBlock(uint32_t arg0, uint32_t arg1, uint8_t *datain){
OnErrorMagic(4);
};
memcpy(data, datain, sizeof(data));
AppendCrc14443a(data, sizeof(data));
memcpy(data, datain, 16);
AppendCrc14443a(data, 16);
ReaderTransmit(data, sizeof(data), NULL);
if ((ReaderReceive(receivedAnswer, receivedAnswerPar) != 1) || (receivedAnswer[0] != 0x0a)) {
@ -1118,8 +1118,6 @@ void MifareCGetBlock(uint32_t arg0, uint32_t arg1, uint8_t *datain){
uint8_t workFlags = arg0;
uint8_t blockNo = arg1;
Dbprintf("ICE :: CGetBlocks Flags %02x", workFlags);
// variables
uint8_t data[MAX_MIFARE_FRAME_SIZE];
uint8_t receivedAnswer[MAX_MIFARE_FRAME_SIZE];