This commit is contained in:
Andrey Gusakov 2023-06-24 18:07:16 -04:00 committed by Andrey
parent a103960186
commit 74e6e184df
2 changed files with 5 additions and 2 deletions

View File

@ -28,6 +28,8 @@ const char* getCriticalErrorMessage(void) {
void checkLastBootError() {
#if EFI_BACKUP_SRAM
auto sramState = getBackupSram();
if (sramState == NULL)
return;
switch (sramState->Cookie) {
case ErrorCookie::FirmwareError:
@ -82,6 +84,9 @@ void logHardFault(uint32_t type, uintptr_t faultAddress, port_extctx* ctx, uint3
TURN_FATAL_LED();
#if EFI_BACKUP_SRAM
auto sramState = getBackupSram();
if (sramState == NULL)
return;
sramState->Cookie = ErrorCookie::HardFault;
sramState->FaultType = type;
sramState->FaultAddress = faultAddress;

View File

@ -31,8 +31,6 @@
#define _CHIBIOS_HAL_CONF_
#define _CHIBIOS_HAL_CONF_VER_7_1_
#include "mcuconf.h"
#include "rusefi_halconf.h"
#include "../../cfg/halconf_community.h"