diff options
| author | Valeriy Van <[email protected]> | 2018-03-02 11:37:19 +0100 |
|---|---|---|
| committer | Valeriy Van <[email protected]> | 2018-03-02 11:37:19 +0100 |
| commit | bea1115ff1b37864a6a3940a0f4b7334c80cb225 (patch) | |
| tree | e9ba1fc29fa2353afa0df13e202f1cdc9c1fc2ee | |
| parent | b9c2acba8721541e3a295e57f44b4504ab9e8d52 (diff) | |
Uses const UINT8_MAX for max value of uint8_t type; Fixes loop condition.
| -rw-r--r-- | bsp/stm32f429-armfly/drivers/drv_ft5x06.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bsp/stm32f429-armfly/drivers/drv_ft5x06.c b/bsp/stm32f429-armfly/drivers/drv_ft5x06.c index 4506795177..70be723c50 100644 --- a/bsp/stm32f429-armfly/drivers/drv_ft5x06.c +++ b/bsp/stm32f429-armfly/drivers/drv_ft5x06.c @@ -157,7 +157,7 @@ static int ft5x06_dump(void) DEBUG_PRINTF("[FTS] Touch Chip\r\n"); - for (i = 0; i <= 255; i++) + for (i = 0; i < UINT8_MAX; i++) { _ft5x06_read(i, ®_value, 1); |
