+// SPDX-License-Identifier: MIT
+
/*
Original Copyright 2020 Claude Schwarz
Code reorganized and rewritten by
*(gpio + 7) = (REG_DATA << PIN_A0);
*(gpio + 7) = 1 << PIN_RD;
- while (*(gpio + 13) & (1 << PIN_TXN_IN_PROGRESS))
- ;
-
unsigned int value = *(gpio + 13);
+ while ((value=*(gpio + 13)) & (1 << PIN_TXN_IN_PROGRESS))
+ ;
*(gpio + 10) = 0xffffec;
*(gpio + 7) = (REG_DATA << PIN_A0);
*(gpio + 7) = 1 << PIN_RD;
- while (*(gpio + 13) & (1 << PIN_TXN_IN_PROGRESS))
- ;
-
unsigned int value = *(gpio + 13);
+ while ((value=*(gpio + 13)) & (1 << PIN_TXN_IN_PROGRESS))
+ ;
*(gpio + 10) = 0xffffec;