Revert "lua on f407 (#2646)"

This reverts commit e8855263
This commit is contained in:
rusefillc 2021-05-09 18:25:50 -04:00
parent e885526308
commit 540bb8e327
13 changed files with 25 additions and 29 deletions

View File

@ -14,7 +14,7 @@ endif
# disable some modules to shrink bootloader binary
DDEFS += -DEFI_BOOTLOADER
DDEFS += -DHAL_USE_EXT=FALSE -DHAL_USE_ICU=FALSE -DHAL_USE_PWM=FALSE -DHAL_USE_RTC=FALSE -DEF_LUA=FALSE
DDEFS += -DHAL_USE_EXT=FALSE -DHAL_USE_ICU=FALSE -DHAL_USE_PWM=FALSE -DHAL_USE_RTC=FALSE
#disable ChibiOS flsah driver and prevent header from include
DDEFS += -DHAL_USE_FLASH=FALSE
@ -62,7 +62,7 @@ endif
# Enable this if you want link time optimizations (LTO)
ifeq ($(USE_LTO),)
USE_LTO = yes
USE_LTO = no
endif
# If enabled, this option allows to compile the application in THUMB mode.

View File

@ -740,6 +740,10 @@
/* Port-specific settings (override port settings defaulted in chcore.h). */
/*===========================================================================*/
#undef ENABLE_PERF_TRACE
#define ENABLE_PERF_TRACE FALSE
#define TRACE_BUFFER_LENGTH 1
#endif /* CHCONF_H */
/** @} */

View File

@ -378,7 +378,6 @@
#define EFI_UART_ECHO_TEST_MODE FALSE
#define EXTREME_TERM_LOGGING FALSE
#define EFI_PRINTF_FUEL_DETAILS FALSE
#define ENABLE_PERF_TRACE FALSE
#define RAM_UNUSED_SIZE 1
#define CCM_UNUSED_SIZE 1

View File

@ -741,6 +741,10 @@
/* Port-specific settings (override port settings defaulted in chcore.h). */
/*===========================================================================*/
#undef ENABLE_PERF_TRACE
#define ENABLE_PERF_TRACE FALSE
#define TRACE_BUFFER_LENGTH 1
#endif /* CHCONF_H */
/** @} */

View File

@ -344,7 +344,6 @@
#define EFI_UART_ECHO_TEST_MODE FALSE
#define EXTREME_TERM_LOGGING FALSE
#define EFI_PRINTF_FUEL_DETAILS FALSE
#define ENABLE_PERF_TRACE FALSE
#define RAM_UNUSED_SIZE 1
#define CCM_UNUSED_SIZE 1

View File

@ -2,7 +2,7 @@
export PROJECT_BOARD=microrusefi
export PROJECT_CPU=ARCH_STM32F4
export EXTRA_PARAMS="-DHW_CHECK_MODE=TRUE -DANALOG_HW_CHECK_MODE=TRUE -DHW_CHECK_ALAWAYS_STIMULATE=TRUE -DSHORT_BOARD_NAME=mre_f4 -DRAMDISK_INVALID"
export EXTRA_PARAMS="-DHW_CHECK_MODE=TRUE -DANALOG_HW_CHECK_MODE=TRUE -DHW_CHECK_ALAWAYS_STIMULATE=TRUE -DSHORT_BOARD_NAME=mre_f4"
export DEFAULT_ENGINE_TYPE=-DDEFAULT_ENGINE_TYPE=MRE_BOARD_NEW_TEST

View File

@ -264,17 +264,12 @@
// F42x has more memory, so we can:
// - use compressed USB MSD image (requires 32k of memory)
// - use perf trace (requires ~16k of memory)
// - use Lua interpreter (requires ~20k of memory)
#ifdef EFI_IS_F42x
#define EFI_USE_COMPRESSED_INI_MSD
#define ENABLE_PERF_TRACE TRUE
#define EFI_LUA TRUE
#else
// small memory F40x can't fit perf trace
#define ENABLE_PERF_TRACE FALSE
#endif
#ifndef EFI_LUA
#define EFI_LUA TRUE
#define EFI_LUA FALSE
#endif
#ifndef EFI_ENGINE_SNIFFER

View File

@ -53,5 +53,5 @@
#define EFI_USE_COMPRESSED_INI_MSD
#undef ENABLE_PERF_TRACE
#define ENABLE_PERF_TRACE TRUE
#undef EFI_LUA
#define EFI_LUA TRUE

View File

@ -32,5 +32,5 @@
// H7 has dual bank, so flash on its own (low priority) thread so as to not block any other operations
#define EFI_FLASH_WRITE_THREAD TRUE
#undef ENABLE_PERF_TRACE
#define ENABLE_PERF_TRACE TRUE
#undef EFI_LUA
#define EFI_LUA TRUE

View File

@ -702,7 +702,7 @@ void initEngineContoller(DECLARE_ENGINE_PARAMETER_SUFFIX) {
* UNUSED_SIZE constants.
*/
#ifndef RAM_UNUSED_SIZE
#define RAM_UNUSED_SIZE 2000
#define RAM_UNUSED_SIZE 4000
#endif
#ifndef CCM_UNUSED_SIZE
#define CCM_UNUSED_SIZE 300

View File

@ -244,8 +244,7 @@ void startLua() {
return;
}
strncpy(interactiveCmd, str, sizeof(interactiveCmd) - 1);
interactiveCmd[sizeof(interactiveCmd) - 1] = '\0';
strncpy(interactiveCmd, str, sizeof(interactiveCmd));
interactivePending = true;
});

View File

@ -12,20 +12,11 @@
#include "efitime.h"
#include "os_util.h"
#ifndef ENABLE_PERF_TRACE
#error ENABLE_PERF_TRACE must be defined!
#endif
#ifndef TRACE_BUFFER_LENGTH
#define TRACE_BUFFER_LENGTH 2048
#endif /* TRACE_BUFFER_LENGTH */
// Disable the buffer if we're not enabled at all
#if !ENABLE_PERF_TRACE
#undef TRACE_BUFFER_LENGTH
#define TRACE_BUFFER_LENGTH 1
#endif
enum class EPhase : char
{
Start,

View File

@ -16,6 +16,11 @@
#define CHPRINTF_USE_FLOAT TRUE
#if !defined(ENABLE_PERF_TRACE) || defined(__DOXYGEN__)
// looks like this value could not be defined in efifeatures.h - please define either externally or just change the value here
#define ENABLE_PERF_TRACE TRUE
#endif /* ENABLE_PERF_TRACE */
#if !defined(_FROM_ASM_)
#include "obd_error_codes.h"
#endif /* _FROM_ASM_ */