ADD: Started to add a "LF GUARD CLONE/SIM" functionality. *not working* all thats needed now is fixing the transformation from FacilityCode/CardNumber -> raw data for t55x7.

This commit is contained in:
iceman1001 2016-02-27 19:47:10 +01:00
commit 50564be0f8
6 changed files with 284 additions and 31 deletions

View file

@ -40,7 +40,6 @@ int usage_lf_pyramid_sim(void) {
return 0;
}
// Works for 26bits.
int GetPyramidBits(uint32_t fc, uint32_t cn, uint8_t *pyramidBits) {
@ -60,10 +59,8 @@ int GetPyramidBits(uint32_t fc, uint32_t cn, uint8_t *pyramidBits) {
wiegand_add_parity(pre+80, wiegand, 24);
// add paritybits (bitsource, dest, sourcelen, paritylen, parityType (odd, even,)
size_t s = addParity(pre+8, pyramidBits+8, 102, 8, 1);
//printf(" %d |", s);
addParity(pre+8, pyramidBits+8, 102, 8, 1);
// add checksum
uint8_t csBuff[13];
for (uint8_t i = 0; i < 13; i++)