Skip to content

Commit 57d3de2

Browse files
authored
Merge pull request RfidResearchGroup#2589 from douniwan5788/style
style
2 parents 617ae0c + f049b56 commit 57d3de2

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

armsrc/hitagS.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ static void hitag_send_bit(int bit, bool ledcontrol) {
179179
while (AT91C_BASE_TC0->TC_CV < T0 * 32) {};
180180

181181
LOW(GPIO_SSC_DOUT);
182-
while (AT91C_BASE_TC0->TC_CV < T0 * 64) {};
182+
while (AT91C_BASE_TC0->TC_CV < T0 * 64) {};
183183

184184
} else {
185185
// AC coding -_-_
@@ -311,7 +311,7 @@ static void hitag_reader_send_bit(int bit, bool ledcontrol) {
311311
if (ledcontrol) LED_A_ON();
312312
// Reset clock for the next bit
313313
AT91C_BASE_TC0->TC_CCR = AT91C_TC_SWTRG;
314-
while (AT91C_BASE_TC0->TC_CV != 0);
314+
while (AT91C_BASE_TC0->TC_CV != 0) {};
315315

316316
// Binary puls length modulation (BPLM) is used to encode the data stream
317317
// This means that a transmission of a one takes longer than that of a zero
@@ -356,7 +356,8 @@ static void hitag_reader_send_frame(const uint8_t *frame, size_t frame_len, bool
356356
}
357357
// send EOF
358358
AT91C_BASE_TC0->TC_CCR = AT91C_TC_SWTRG;
359-
while (AT91C_BASE_TC0->TC_CV != 0);
359+
while (AT91C_BASE_TC0->TC_CV != 0) {};
360+
360361
HIGH(GPIO_SSC_DOUT);
361362

362363
// Wait for 4-10 times the carrier period
@@ -372,7 +373,6 @@ static void hts_stop_clock(void) {
372373
}
373374

374375
static void hts_init_clock(void) {
375-
376376
// Enable Peripheral Clock for
377377
// Timer Counter 0, used to measure exact timing before answering
378378
// Timer Counter 1, used to capture edges of the tag frames
@@ -407,7 +407,7 @@ static void hts_init_clock(void) {
407407

408408
// synchronized startup procedure
409409
// In theory, with MCK/32, we shouldn't be waiting longer than 32 instruction statements, right?
410-
while (AT91C_BASE_TC0->TC_CV != 0) {}; // wait until TC0 returned to zero
410+
while (AT91C_BASE_TC0->TC_CV != 0) {}; // wait until TC0 returned to zero
411411

412412
// reset timestamp
413413
timestamp_high = 0;

client/src/cmdlf.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1588,7 +1588,7 @@ static bool check_chiptype(bool getDeviceData) {
15881588

15891589
// Hitag S
15901590
if (read_hts_uid() == PM3_SUCCESS) {
1591-
PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("Hitag S / 82xx"));
1591+
PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("Hitag 1/S / 82xx"));
15921592
PrintAndLogEx(HINT, "Hint: try " _YELLOW_("`lf hitag hts`") " commands");
15931593
retval = true;
15941594
goto out;

client/src/cmdlfhitaghts.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -631,4 +631,3 @@ int CmdLFHitagS(const char *Cmd) {
631631
clearCommandBuffer();
632632
return CmdsParse(CommandTable, Cmd);
633633
}
634-

common/commonutil.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -544,6 +544,7 @@ void reverse_arraybytes_copy(uint8_t *arr, uint8_t *dest, size_t len) {
544544
}
545545
}
546546

547+
// TODO: consider overlap, Implement _membitmovebb
547548
size_t concatbits(uint8_t *dst, size_t dstskip, const uint8_t *src, size_t srcstart, size_t srclen) {
548549
// erase dstbuf bits that will be overriden
549550
dst[dstskip / 8] &= 0xFF - ((1 << (7 - (dstskip % 8) + 1)) - 1);

0 commit comments

Comments
 (0)