From 33ed748004ccd3a538c3761839dc3634516baea3 Mon Sep 17 00:00:00 2001 From: alextrical <35117191+alextrical@users.noreply.github.com> Date: Sun, 5 Mar 2023 22:28:50 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Fix=20Flash=20EEPROM=20for=20STM?= =?UTF-8?q?32G0B1CB=20(#25469)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Marlin/src/pins/stm32g0/pins_BTT_EBB42_V1_1.h | 2 +- .../MARLIN_BTT_EBB42_V1_1/variant_MARLIN_BTT_EBB42_V1_1.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/Marlin/src/pins/stm32g0/pins_BTT_EBB42_V1_1.h b/Marlin/src/pins/stm32g0/pins_BTT_EBB42_V1_1.h index cdd85a6d75..3de67ea8d5 100644 --- a/Marlin/src/pins/stm32g0/pins_BTT_EBB42_V1_1.h +++ b/Marlin/src/pins/stm32g0/pins_BTT_EBB42_V1_1.h @@ -44,7 +44,7 @@ #define FLASH_EEPROM_EMULATION #endif #define EEPROM_PAGE_SIZE (0x800UL) // 2K - #define EEPROM_START_ADDRESS (0x0801F800UL) + #define EEPROM_START_ADDRESS (0x8000000UL + (STM32_FLASH_SIZE) * 1024UL - (EEPROM_PAGE_SIZE) * 1UL) #define MARLIN_EEPROM_SIZE EEPROM_PAGE_SIZE #endif diff --git a/buildroot/share/PlatformIO/variants/MARLIN_BTT_EBB42_V1_1/variant_MARLIN_BTT_EBB42_V1_1.h b/buildroot/share/PlatformIO/variants/MARLIN_BTT_EBB42_V1_1/variant_MARLIN_BTT_EBB42_V1_1.h index ff75bc1e48..9373e2fa3b 100644 --- a/buildroot/share/PlatformIO/variants/MARLIN_BTT_EBB42_V1_1/variant_MARLIN_BTT_EBB42_V1_1.h +++ b/buildroot/share/PlatformIO/variants/MARLIN_BTT_EBB42_V1_1/variant_MARLIN_BTT_EBB42_V1_1.h @@ -155,6 +155,8 @@ #define SERIAL_UART_INSTANCE 4 #endif +#define FLASH_BANK_NUMBER FLASH_BANK_1 + // Default pin used for generic 'Serial' instance // Mandatory for Firmata #ifndef PIN_SERIAL_RX