Closed brackendawson closed 2 years ago
@brackendawson I may be running into this issue. My test board seems to lock up after a while. It may be due to a not so solid connection. I will try to solder a solid connection tomorrow.
BTW, is there any way to clear the lockup? Restarting doesn't seem to help, and I think it may also be locked in a state of thinking a process is running when it's not actually running, which keeps it from updating the system.
I was never able to clear a lockup caused by bad connections using the reset line, or even by attempting to power cycle the '522 IC. It sips power from it's I/O lines and hold whatever latched state it's in. I've only cleared it by a full power cycle.
Not going to fix this since the code is no longer used.
Since soldering the wires on, the door has become stable, this leads me to believe that the issue has been bad connections on data/power pins causing a lockup of the SPI master/slave.
The goodpath polling interaction of the IC makes it impossible to distinguish no tag present from IC not responding.
Either change that to break out more status, or add a periodic poll of some status register to see if the IC is still working. If it is not, the reset line is connected to GPIO, reset it. If that fails, we may escalate to a reload of the SPI module or a reboot. Or some SPI module level recovery if there is any.