mfc_editor_helpers.c 244 B

123456789101112
  1. #include "mfc_editor_app_i.h"
  2. uint8_t mfc_editor_calculate_uid_bcc(uint8_t* uid, uint8_t uid_len) {
  3. furi_check(uid_len > 0);
  4. uint8_t bcc = uid[0];
  5. for(int i = 1; i < uid_len; i++) {
  6. bcc ^= uid[i];
  7. }
  8. return bcc;
  9. }