From 370483abaf71bc3a3e141f5664e029133a254e96 Mon Sep 17 00:00:00 2001 From: sergio Date: Fri, 31 Jan 2020 07:10:42 +0300 Subject: [PATCH 1/2] Support for disable printing version information at start-up https://github.com/nodemcu/nodemcu-firmware/issues/3021 --- app/include/user_config.h | 20 ++++++++++++++++++++ app/lua/lua.c | 2 ++ 2 files changed, 22 insertions(+) diff --git a/app/include/user_config.h b/app/include/user_config.h index dbb3447e4e..73eacd7d87 100644 --- a/app/include/user_config.h +++ b/app/include/user_config.h @@ -22,6 +22,26 @@ //#define BIT_RATE_AUTOBAUD +// At start-up firmware details like: +// +// NodeMCU 3.0.1.0 +// branch: +// commit: +// release: +// release DTS: +// SSL: false +// build type: integer +// LFS: 0x0 +// modules: file,gpio,net,node,rtctime,sntp,tmr,uart,wifi +// build 2020-01-27 17:39 powered by Lua 5.1.4 on SDK 3.0.2(824dc80) +// +// will be printed to serial console. While it's very helpful for bug reports +// and good for development, it may be unwanted for non-interactive serial +// devices. + +//#define DISABLE_STARTUP_BANNER + + // Three separate build variants are now supported. The main difference is in the // processing of numeric data types. If LUA_NUMBER_INTEGRAL is defined, then // all numeric calculations are done in integer, with divide being an integer diff --git a/app/lua/lua.c b/app/lua/lua.c index 80afc690b2..bf01c625fa 100644 --- a/app/lua/lua.c +++ b/app/lua/lua.c @@ -245,7 +245,9 @@ static int pmain (lua_State *L) { input_setup(LUA_MAXINPUT, get_prompt(L, 1)); lua_input_string(" \n", 2); /* queue CR to issue first prompt */ +#if !defined(DISABLE_STARTUP_BANNER) print_version(L); +#endif /* and last of all, kick off application initialisation */ if (init[0] == '@') From 5f85ebf5fb27b81e08799fc91b33aa5a9000a3d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20St=C3=B6r?= Date: Sun, 9 Feb 2020 16:58:07 +0100 Subject: [PATCH 2/2] Update user_config.h --- app/include/user_config.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/include/user_config.h b/app/include/user_config.h index 73eacd7d87..eb68edd5e1 100644 --- a/app/include/user_config.h +++ b/app/include/user_config.h @@ -35,7 +35,7 @@ // modules: file,gpio,net,node,rtctime,sntp,tmr,uart,wifi // build 2020-01-27 17:39 powered by Lua 5.1.4 on SDK 3.0.2(824dc80) // -// will be printed to serial console. While it's very helpful for bug reports +// will be printed to serial console. While it's mandatory for bug reports // and good for development, it may be unwanted for non-interactive serial // devices.