summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Teachman <mike.teachman@gmail.com>2019-10-22 10:25:37 -0700
committerDamien George <damien.p.george@gmail.com>2019-10-23 13:31:13 +1100
commitf301170c7cb50fdb9250a6e4b89682f9c0e543cb (patch)
tree302f0065dc2f09d7a20bd9d4227703b8b946340d
parent079cc940a68b3b3b9d47d4402267393a528a0477 (diff)
esp32/machine_hw_spi: Fix exception msg when host is already in use.
When a SPI bus is initialized with a SPI host that is currently in use the exception msg incorrectly indicates "SPI device already in use". The mention of "device" in the exception msg is confusing because the error is about trying to use a SPI host that is already claimed. A better exception msg is "SPI host already in use".
-rw-r--r--ports/esp32/machine_hw_spi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ports/esp32/machine_hw_spi.c b/ports/esp32/machine_hw_spi.c
index 2f63a32d4..af47711aa 100644
--- a/ports/esp32/machine_hw_spi.c
+++ b/ports/esp32/machine_hw_spi.c
@@ -205,7 +205,7 @@ STATIC void machine_hw_spi_init_internal(
return;
case ESP_ERR_INVALID_STATE:
- mp_raise_msg(&mp_type_OSError, "SPI device already in use");
+ mp_raise_msg(&mp_type_OSError, "SPI host already in use");
return;
}