Closed ktand closed 6 years ago
Seems to build fine for Generic STM32F103C
target. What am I missing?
WRITE_REG
is defined in CMSIS STM32F1xx Device Peripheral Access Layer Header File, stm32f1xx.h
. The same goes for all STM32Fx devices. In these files, WRITE_REG
is defined like this:
#define WRITE_REG(REG, VAL) ((REG) = (VAL))
When building the Marlin bugfix-2.0.x branch for STM32F4 I get the following error when compiling TMC2130Stepper.cpp:
.. stm32f4xx_ll_spi.h:357:57: error: macro "WRITE_REG" passed 2 arguments, but takes just 1
stm32f4xx_ll_spi.h
is included from the SPI.h
file which is included from TMC2130Stepper.cpp
.
Any chance this can get merged?
Regards, Karl
Released now in version 2.3.0.
When building for STM32 there is a name clashing between macros (
WRITE_REG
,READ_REG
etc.) defined in the TMC2130 library and the STM32 Arduino core. This PR will prefix macros in this library withTMC_
.