mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-12-18 04:18:10 +00:00
c3112fd83d
Because CTPM dislikes being polled when no touches are seen, keeps resetting, and maybe freezes once in a while. This is very likely a fix for #334. Before, we would simply read the touch registers on every loop. Now we first check whether the interrupt line is down, which indicates that the CTPM has data to tell us. Tracking the `touching` flag is necessary, as sometimes we don't poll frequently enough to catch the TOUCH_END event before interrupt line goes up again. The `last_packet` handling miiight not be necessary - AFAICT, the CTPM has some sort of buffer and always returns TOUCH_START at first and TOUCH_END at last. Still, better safe than sorry. |
||
---|---|---|
.. | ||
boardloader | ||
bootloader | ||
extmod | ||
firmware | ||
prodtest | ||
reflash | ||
trezorhal | ||
unix | ||
vendorheader |