fix destron clone command

This commit is contained in:
Philippe Teuwen 2020-10-12 13:57:50 +02:00
parent 2ee9ea0ef3
commit 25195b3197

View file

@ -114,7 +114,7 @@ static int CmdDestronClone(const char *Cmd) {
uint8_t data_ex[12 + 24] = {0}; // ManchesterEncode need extra room
for (int i=0; i < datalen; i++) {
data_ex[i + 1] = data [i] | (oddparity8(data[i]) << 7);
data_ex[i + 1] = ~data [i] | (evenparity8(data[i]) << 7);
}
for (int i=0; i < 3; i++) {
blocks[i+1] = manchesterEncode2Bytes((data_ex[i*2]<<8)+data_ex[i*2+1]);