Configurations
Configurations copied to clipboard
[BUG] Unable to build Malyan/M200 v1 example configuration according to its README.md
Bug Description
Exactly following the instructions from the README.md, without any changes to the example configs, I am unable to finish the building process due to the following error:
In file included from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\cores\arduino/stm32/clock.h:43,
from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\cores\arduino/wiring_time.h:23,
from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\cores\arduino/wiring.h:38,
from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\cores\arduino/Arduino.h:36,
from C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\HAL\shared\Marduino.h:36,
from C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\HAL\STM32\HAL.h:28,
from C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\HAL\HAL.h:30,
from C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\inc\MarlinConfig.h:31,
from C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\HAL\STM32\HAL.cpp:27:
C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\HAL\STM32\HAL.cpp: In static member function 'static void MarlinHAL::init()':
C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\cores\arduino/stm32/stm32_def.h:58:17: error: the value of 'SystemCoreClock' is not usable in a constant expression
58 | #define F_CPU SystemCoreClock
| ^~~~~~~~~~~~~~~
C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\HAL\STM32\HAL.cpp:70:27: note: in expansion of macro 'F_CPU'
70 | constexpr int cpuFreq = F_CPU;
| ^~~~~
In file included from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\system/Drivers/CMSIS/Device/ST/STM32F1xx/Include/stm32f103xb.h:133,
from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\system/Drivers/CMSIS/Device/ST/STM32F1xx/Include/stm32f1xx.h:131,
from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\cores\arduino/stm32/stm32_def.h:28,
from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\cores\arduino/stm32/clock.h:43,
from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\cores\arduino/wiring_time.h:23,
from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\cores\arduino/wiring.h:38,
from C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\cores\arduino/Arduino.h:36,
from C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\HAL\shared\Marduino.h:36,
from C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\HAL\STM32\HAL.h:28,
from C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\HAL\HAL.h:30,
from C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\inc\MarlinConfig.h:31,
from C:\Users\User\Downloads\Marlin-bugfix-2.1.x\Marlin\src\HAL\STM32\HAL.cpp:27:
C:\Users\User\AppData\Local\Arduino15\packages\STM32\hardware\stm32\1.9.0\system/Drivers/CMSIS/Device/ST/STM32F1xx/Include/system_stm32f1xx.h:51:17: note: 'uint32_t SystemCoreClock' is not const
51 | extern uint32_t SystemCoreClock; /*!< System Clock Frequency (Core Clock) */
| ^~~~~~~~~~~~~~~
This error happens on both the suggested (now deprecated) STM32 Cores versions 1.8 and 1.9 (1.7 fails on a different error) and on the latest STM32 2.4.0.
I have tested both the 2.1 stable and 2.1 bugfix/nightly branches/configs.
Configuration Files
Required: Include a ZIP file containing Configuration.h
and Configuration_adv.h
.
Unmodified configs straight from the repo, repacked into a zip:
Marlin.zip
Steps to Reproduce
Simply follow the installation instructions from the Maylan/M200 v1 README.md.
Expected behavior: A completed build.
Actual behavior: No completed build.
Additional Information
Full build log: marlinfull.log
EDIT: The same issue also happens in 2.0.9.5 it seems.