diff --git a/examples/ws2812esp32rmt/CMakeLists.txt b/examples/ws2812esp32rmt/CMakeLists.txt index 77b014ed0..11cb695b3 100644 --- a/examples/ws2812esp32rmt/CMakeLists.txt +++ b/examples/ws2812esp32rmt/CMakeLists.txt @@ -21,7 +21,7 @@ if(CONFIG_EXAMPLES_WS2812_ESP32_RMT) nuttx_add_application( NAME - ws2812esp32rmt + ${CONFIG_EXAMPLES_WS2812_ESP32_RMT_PROGNAME} PRIORITY ${CONFIG_EXAMPLES_WS2812_ESP32_RMT_PRIORITY} STACKSIZE diff --git a/examples/ws2812esp32rmt/Kconfig b/examples/ws2812esp32rmt/Kconfig index 60245d7be..abfa97ddc 100644 --- a/examples/ws2812esp32rmt/Kconfig +++ b/examples/ws2812esp32rmt/Kconfig @@ -12,6 +12,13 @@ config EXAMPLES_WS2812_ESP32_RMT if EXAMPLES_WS2812_ESP32_RMT +config EXAMPLES_WS2812_ESP32_RMT_PROGNAME + string "Program Name" + default "ws2812esp32" + ---help--- + This is the name of the program that will be used when the NSH ELF + program is installed. + config EXAMPLES_WS2812_ESP32_RMT_PRIORITY int "Task Priority" default 100 diff --git a/examples/ws2812esp32rmt/Makefile b/examples/ws2812esp32rmt/Makefile index f2d6a8e2e..8f34feee0 100644 --- a/examples/ws2812esp32rmt/Makefile +++ b/examples/ws2812esp32rmt/Makefile @@ -22,7 +22,7 @@ include $(APPDIR)/Make.defs # MTD R/W buffer test Example -PROGNAME = ws2812esp32rmt +PROGNAME = $(CONFIG_EXAMPLES_WS2812_ESP32_RMT_PROGNAME) PRIORITY = $(CONFIG_EXAMPLES_WS2812_ESP32_RMT_PRIORITY) STACKSIZE = $(CONFIG_EXAMPLES_WS2812_ESP32_RMT_STACKSIZE) MODULE = $(CONFIG_EXAMPLES_WS2812_ESP32_RMT) diff --git a/examples/ws2812esp32rmt/ws2812esp32rmt_main.c b/examples/ws2812esp32rmt/ws2812esp32rmt_main.c index 60657cf83..4f1c7f986 100644 --- a/examples/ws2812esp32rmt/ws2812esp32rmt_main.c +++ b/examples/ws2812esp32rmt/ws2812esp32rmt_main.c @@ -163,7 +163,8 @@ int main(int argc, FAR char *argv[]) if (fd < 0) { fprintf(stderr, - "ws2812esp32rmt: open %s failed: %d\n", + "%s: open %s failed: %d\n", + argv[0], dev_name, errno); goto errout_with_dev;