hitag2 write (#310)

Usage is similar to hitagS write: lf hitag write 24 KEY pagenumber 32bitvalue
* added changlelog entry
This commit is contained in:
Henrik Johansson 2017-07-05 20:16:54 +02:00 committed by pwpiwi
commit 52244230d3
6 changed files with 763 additions and 398 deletions

View file

@ -1051,7 +1051,12 @@ void UsbPacketReceived(uint8_t *packet, int len)
ReadHitagS((hitag_function)c->arg[0],(hitag_data*)c->d.asBytes);
break;
case CMD_WR_HITAG_S://writer for Hitag tags args=data to write,page and key or challenge
WritePageHitagS((hitag_function)c->arg[0],(hitag_data*)c->d.asBytes,c->arg[2]);
if ((hitag_function)c->arg[0] < 10) {
WritePageHitagS((hitag_function)c->arg[0],(hitag_data*)c->d.asBytes,c->arg[2]);
}
else if ((hitag_function)c->arg[0] >= 10) {
WriterHitag((hitag_function)c->arg[0],(hitag_data*)c->d.asBytes, c->arg[2]);
}
break;
#endif