ADD: cmdlf autocorrelations, also gives a hint to how many bytes the possible correlation is.

CHG: "LF SEARCH 1 U" didn't work since the strcmp was too short. Increased length of check.
FIX: @marshmellows fix for faulty em410xdecoding of length less than 64.
This commit is contained in:
iceman1001 2015-03-18 20:32:53 +01:00
commit 251d07dbfb
2 changed files with 36 additions and 3 deletions

View file

@ -142,6 +142,7 @@ uint8_t Em410xDecode(uint8_t *BitStream, size_t *size, size_t *startIdx, uint32_
for (uint8_t extraBitChk=0; extraBitChk<5; extraBitChk++){
errChk = preambleSearch(BitStream+extraBitChk+*startIdx, preamble, sizeof(preamble), size, startIdx);
if (errChk == 0) return 0;
if (*size<64) return 0;
if (*size>64) FmtLen = 22;
idx = *startIdx + 9;
for (i=0; i<FmtLen; i++){ //loop through 10 or 22 sets of 5 bits (50-10p = 40 bits or 88 bits)