Included some changes of Thomas.
This commit is contained in:
parent
c724b5b9fb
commit
a95e174356
@ -863,6 +863,7 @@ char T_datif::loadRecDataFromFrame()
|
||||
//int portNr;
|
||||
bool ret;
|
||||
uint8_t uctmp; // maxai
|
||||
char ctmp;
|
||||
|
||||
ret=myDCIF->getReceivedInData(&SlaveAdr, &readSource, &readAddress, &RdDleng, receivedData);
|
||||
// retval: data valid, only one time true, true if CommandState OK and readState OK
|
||||
@ -902,7 +903,8 @@ char T_datif::loadRecDataFromFrame()
|
||||
|
||||
for (int ii=0; ii<RdDleng; ii++)
|
||||
{
|
||||
localStr.append(receivedData[ii]);
|
||||
ctmp=receivedData[ii];
|
||||
localStr.append(ctmp);
|
||||
}
|
||||
|
||||
//qDebug() << "got HW version: " << localStr;
|
||||
@ -936,7 +938,7 @@ char T_datif::loadRecDataFromFrame()
|
||||
|
||||
case CMD2DC_RdBkDCstate: //101
|
||||
//qDebug() << "got DC state " << localStr;
|
||||
localStr[8]=0;
|
||||
//localStr[8]=0;
|
||||
gpi_storeGenerals(2, localStr);
|
||||
// 0=HW 1=SW 2=State
|
||||
break;
|
||||
@ -1112,7 +1114,9 @@ char T_datif::loadRecDataFromFrame()
|
||||
case CMD2DC_RdBk_MifState: //109
|
||||
// get reader status and card type
|
||||
|
||||
gpi_storeMifReaderStateAndCardType(receivedData);
|
||||
//gpi_storeMifReaderStateAndCardType(receivedData);
|
||||
gpi_storeNewMifareCard(receivedData[0], &receivedData[1]);
|
||||
|
||||
break;
|
||||
|
||||
case CMD2DC_RdBk_MifData: //24
|
||||
@ -1216,7 +1220,7 @@ char T_datif::loadRecDataFromFrame()
|
||||
|
||||
|
||||
|
||||
// ab hier neu: XXX
|
||||
// ab hier neu: 12.4.23
|
||||
|
||||
case CMD2DC_RDBK_DEV_PARA: //14
|
||||
/*
|
||||
@ -1469,13 +1473,14 @@ char T_datif::loadRecDataFromFrame()
|
||||
|
||||
case 32: // Get current cash level (in vault)
|
||||
// bytes 0..3: amount bytes 4,5=Nr.ofCoins in vault
|
||||
|
||||
ultmp=uchar2ulong(receivedData[3],receivedData[2],receivedData[1],receivedData[0]);
|
||||
uitmp=uchar2uint(receivedData[5],receivedData[4]);
|
||||
gpi_storeCBlevel(ultmp, uitmp);
|
||||
break;
|
||||
|
||||
case 33: // Get all backuped acc. Numbers
|
||||
// 8 UINTs with acc-nr
|
||||
|
||||
|
||||
gpi_storeDCbackupAccNr(RdDleng, receivedData);
|
||||
break;
|
||||
|
||||
case 38: // Get stored account record backup
|
||||
@ -1541,7 +1546,8 @@ struct T_vaultRecord
|
||||
UCHAR endofblock[4]; // end>
|
||||
// 316 byte Block im Speicher
|
||||
*/
|
||||
|
||||
// readAddress, &RdDleng, receivedData
|
||||
gpi_storeVaultRecord(readAddress, receivedData ); // always 64byte
|
||||
break;
|
||||
|
||||
}
|
||||
@ -1644,11 +1650,15 @@ bool T_datif::verifyLineTestresponse(uint8_t RdDlen, uint8_t *receivedData)
|
||||
if (RdDlen < 16)
|
||||
return false;
|
||||
QString myStr;
|
||||
char ctmp;
|
||||
|
||||
myStr.clear();
|
||||
myStr.append("< Slave Response");
|
||||
|
||||
for (int nn=0; nn<16; nn++)
|
||||
if (myStr[nn] !=receivedData[nn])
|
||||
{
|
||||
ctmp=receivedData[nn];
|
||||
if (myStr[nn] != ctmp)
|
||||
{
|
||||
//qDebug() << " datif cmd 10: got wrong string ";
|
||||
//qDebug() << myStr;
|
||||
@ -1656,6 +1666,7 @@ bool T_datif::verifyLineTestresponse(uint8_t RdDlen, uint8_t *receivedData)
|
||||
//qDebug() << nn;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user