summaryrefslogtreecommitdiff
path: root/ports
diff options
context:
space:
mode:
authormicroDev <70126934+microDev1@users.noreply.github.com>2020-11-04 21:20:24 +0530
committermicroDev <70126934+microDev1@users.noreply.github.com>2020-11-04 21:20:24 +0530
commitfe6bfde590fc325c984c679825024241afd23a5f (patch)
tree48e1462f1b78b901acd8e4ae6434cad222c5ecb1 /ports
parent4438050f794edea5c6a3f919964908800dd6b522 (diff)
move pcnt handler
Diffstat (limited to 'ports')
-rw-r--r--ports/esp32s2/Makefile2
-rw-r--r--ports/esp32s2/peripherals/pcnt_handler.c (renamed from ports/esp32s2/pcnt_handler.c)2
-rw-r--r--ports/esp32s2/peripherals/pcnt_handler.h (renamed from ports/esp32s2/pcnt_handler.h)6
3 files changed, 5 insertions, 5 deletions
diff --git a/ports/esp32s2/Makefile b/ports/esp32s2/Makefile
index 6dbbf58d4..56f0d46a3 100644
--- a/ports/esp32s2/Makefile
+++ b/ports/esp32s2/Makefile
@@ -173,7 +173,6 @@ SRC_C += \
background.c \
fatfs_port.c \
mphalport.c \
- pcnt_handler.c \
bindings/espidf/__init__.c \
boards/$(BOARD)/board.c \
boards/$(BOARD)/pins.c \
@@ -189,6 +188,7 @@ SRC_C += \
lib/utils/pyexec.c \
lib/utils/stdout_helpers.c \
lib/utils/sys_stdio_mphal.c \
+ peripherals/pcnt_handler.c \
peripherals/pins.c \
peripherals/rmt.c \
supervisor/shared/memory.c
diff --git a/ports/esp32s2/pcnt_handler.c b/ports/esp32s2/peripherals/pcnt_handler.c
index 56fb0f21c..5a0cc9a7c 100644
--- a/ports/esp32s2/pcnt_handler.c
+++ b/ports/esp32s2/peripherals/pcnt_handler.c
@@ -42,7 +42,7 @@ void pcnt_handler_init(pcnt_config_t* pcnt_config) {
pcnt_state[i] = PCNT_UNIT_ACTIVE;
break;
} else if (i == 3) {
- mp_raise_RuntimeError(translate("No PCNT unit free"));
+ mp_raise_RuntimeError(translate("All PCNT units in use"));
}
}
diff --git a/ports/esp32s2/pcnt_handler.h b/ports/esp32s2/peripherals/pcnt_handler.h
index 4bdaee1b8..f44ee1f83 100644
--- a/ports/esp32s2/pcnt_handler.h
+++ b/ports/esp32s2/peripherals/pcnt_handler.h
@@ -24,12 +24,12 @@
* THE SOFTWARE.
*/
-#ifndef MICROPY_INCLUDED_ESP32S2_PCNT_HANDLER_H
-#define MICROPY_INCLUDED_ESP32S2_PCNT_HANDLER_H
+#ifndef MICROPY_INCLUDED_ESP32S2_PERIPHERALS_PCNT_HANDLER_H
+#define MICROPY_INCLUDED_ESP32S2_PERIPHERALS_PCNT_HANDLER_H
#include "driver/pcnt.h"
extern void pcnt_handler_init(pcnt_config_t* pcnt_config);
extern void pcnt_handler_deinit(pcnt_unit_t* unit);
-#endif // MICROPY_INCLUDED_ESP32S2_PCNT_HANDLER_H
+#endif // MICROPY_INCLUDED_ESP32S2_PERIPHERALS_PCNT_HANDLER_H