Skip to content

Commit

Permalink
🔨 Other env improvements
Browse files Browse the repository at this point in the history
Co-Authored-By: Michael <[email protected]>
  • Loading branch information
thinkyhead and mlee12382 committed Sep 24, 2024
1 parent e6e0489 commit e847913
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 16 deletions.
5 changes: 0 additions & 5 deletions ini/features.ini
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,6 @@ HAS_MARLINUI_HD44780 = build_src_filter=+<src/lcd/HD44780>
HAS_MARLINUI_U8GLIB = marlinfirmware/[email protected]
build_src_filter=+<src/lcd/dogm>
HAS_(FSMC|SPI|LTDC)_TFT = build_src_filter=+<src/lcd/tft_io>
HAS_LTDC_TFT = build_src_filter=+<src/HAL/STM32/tft/tft_ltdc.cpp>
HAS_FSMC_TFT = build_src_filter=+<src/HAL/STM32/tft/tft_fsmc.cpp> +<src/HAL/STM32F1/tft/tft_fsmc.cpp>
HAS_SPI_TFT = build_src_filter=+<src/HAL/STM32/tft/tft_spi.cpp> +<src/HAL/STM32F1/tft/tft_spi.cpp> +<src/HAL/LPC1768/tft/tft_spi.cpp>
HAS_TFT_XPT2046 = build_src_filter=+<src/HAL/STM32/tft/xpt2046.cpp> +<src/HAL/STM32F1/tft/xpt2046.cpp> +<src/HAL/LPC1768/tft/xpt2046.cpp>
TFT_TOUCH_DEVICE_GT911 = build_src_filter=+<src/HAL/STM32/tft/gt911.cpp>
I2C_EEPROM = build_src_filter=+<src/HAL/shared/eeprom_if_i2c.cpp>
SOFT_I2C_EEPROM = SlowSoftI2CMaster, SlowSoftWire=https://github.com/felias-fogg/SlowSoftWire/archive/f34d777f39.zip
SPI_EEPROM = build_src_filter=+<src/HAL/shared/eeprom_if_spi.cpp>
Expand Down
4 changes: 4 additions & 0 deletions ini/lpc176x.ini
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ build_flags = ${common.build_flags} -DU8G_HAL_LINKS -DPLATFORM_M997_SUPPO
#-funwind-tables
#-mpoke-function-name
build_src_flags = -std=gnu++20 -Wno-volatile
custom_marlin.USES_LIQUIDCRYSTAL = arduino-libraries/LiquidCrystal@~1.0.7
custom_marlin.NEOPIXEL_LED = Adafruit NeoPixel=https://github.com/p3p/Adafruit_NeoPixel/archive/1.5.0.zip
custom_marlin.HAS_SPI_TFT = build_src_filter=+<src/HAL/LPC1768/tft/tft_spi.cpp>
custom_marlin.HAS_TFT_XPT2046 = build_src_filter=+<src/HAL/LPC1768/tft/xpt2046.cpp>

#
# NXP LPC176x ARM Cortex-M3
Expand Down
6 changes: 6 additions & 0 deletions ini/stm32-common.ini
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ build_unflags = -std=gnu++11
build_src_filter = ${common.default_src_filter} +<src/HAL/STM32> -<src/HAL/STM32/tft> +<src/HAL/shared/backtrace>
extra_scripts = ${common.extra_scripts}
pre:buildroot/share/PlatformIO/scripts/stm32_serialbuffer.py
custom_marlin.HAS_LTDC_TFT = build_src_filter=+<src/HAL/STM32/tft/tft_ltdc.cpp>
custom_marlin.HAS_FSMC_TFT = build_src_filter=+<src/HAL/STM32/tft/tft_fsmc.cpp>
build_flags=-DHAL_SRAM_MODULE_ENABLED
custom_marlin.HAS_SPI_TFT = build_src_filter=+<src/HAL/STM32/tft/tft_spi.cpp>
custom_marlin.HAS_TFT_XPT2046 = build_src_filter=+<src/HAL/STM32/tft/xpt2046.cpp>
custom_marlin.TFT_TOUCH_DEVICE_GT911 = build_src_filter=+<src/HAL/STM32/tft/gt911.cpp>

#
# STM32 board based on a variant.
Expand Down
7 changes: 5 additions & 2 deletions ini/stm32f1-maple.ini
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
# HAL/STM32F1 Common Environment values
#
[STM32F1_maple]
platform = ststm32@~12.1
platform = ststm32@~15.4.1
board_build.core = maple
build_flags = !python buildroot/share/PlatformIO/scripts/STM32F1_build_flags.py
${common.build_flags} -DARDUINO_ARCH_STM32 -DMAPLE_STM32F1 -DPLATFORM_M997_SUPPORT
Expand All @@ -32,12 +32,15 @@ build_src_filter = ${common.default_src_filter} +<src/HAL/STM32F1> -<src/HAL/ST
lib_ignore = SPI, FreeRTOS701, FreeRTOS821
lib_deps = ${common.lib_deps}
SoftwareSerialM
platform_packages = tool-stm32duino
platform_packages = tool-stm32duino, [email protected]
extra_scripts = ${common.extra_scripts}
pre:buildroot/share/PlatformIO/scripts/fix_framework_weakness.py
pre:buildroot/share/PlatformIO/scripts/stm32_serialbuffer.py
buildroot/share/PlatformIO/scripts/custom_board.py
buildroot/share/PlatformIO/scripts/offset_and_rename.py
custom_marlin.HAS_SPI_TFT = build_src_filter=+<src/HAL/STM32F1/tft/tft_spi.cpp>
custom_marlin.HAS_TFT_XPT2046 = build_src_filter=+<src/HAL/STM32F1/tft/xpt2046.cpp>
custom_marlin.HAS_FSMC_TFT = build_src_filter=+<src/HAL/STM32F1/tft/tft_fsmc.cpp>

#
# Generic STM32F103RC environment
Expand Down
6 changes: 3 additions & 3 deletions ini/stm32f1.ini
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ build_flags = ${env:STM32F103RC_btt.build_flags}
-DUSBD_IRQ_PRIO=5
-DUSBD_IRQ_SUBPRIO=6
-DUSBD_USE_CDC_MSC
build_unflags = ${common_stm32.build_unflags} -DUSBD_USE_CDC
build_unflags = ${env:STM32F103RC_btt.build_unflags} -DUSBD_USE_CDC

#
# Panda Pi V2.9 - Standalone (STM32F103RC)
Expand All @@ -83,8 +83,8 @@ build_flags = ${common_STM32F103RC_variant.build_flags}
-DTIMER_SERVO=TIM1
board_build.offset = 0x5000
board_upload.offset_address = 0x08005000
lib_deps =
markyue/[email protected]
lib_deps = markyue/[email protected]

#
# MKS Robin (STM32F103ZET6)
# Uses HAL STM32 to support Marlin UI for TFT screen with optional touch panel
Expand Down
13 changes: 7 additions & 6 deletions ini/stm32f4.ini
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ extends = Anet_ET4
board_build.encode = firmware.srec
board_build.offset = 0x10000
board_upload.offset_address = 0x08010000
extra_scripts = ${stm32_variant.extra_scripts}
extra_scripts = ${Anet_ET4.extra_scripts}
buildroot/share/PlatformIO/scripts/openblt.py

#
Expand Down Expand Up @@ -497,7 +497,8 @@ build_flags = ${stm_flash_drive.build_flags} ${stm32f4_I2C1.build_flags}
extends = env:mks_robin_nano_v3_usb_flash_drive
build_flags = ${env:mks_robin_nano_v3_usb_flash_drive.build_flags}
-DUSBD_USE_CDC_MSC
build_unflags = -DUSBD_USE_CDC
build_unflags = ${env:mks_robin_nano_v3_usb_flash_drive.build_unflags}
-DUSBD_USE_CDC

#
# MKS Robin Nano V3_1
Expand Down Expand Up @@ -626,7 +627,7 @@ extends = TH3D_EZBoard_V2
board_build.encode = firmware.bin
board_build.offset = 0xC000
board_upload.offset_address = 0x0800C000
extra_scripts = ${stm32_variant.extra_scripts}
extra_scripts = ${TH3D_EZBoard_V2.extra_scripts}
buildroot/share/PlatformIO/scripts/openblt.py

[mks_robin_nano_v1_3_f4_common]
Expand All @@ -647,19 +648,19 @@ upload_protocol = jlink
#
[env:mks_robin_nano_v1_3_f4]
extends = mks_robin_nano_v1_3_f4_common
build_flags = ${stm32_variant.build_flags}
build_flags = ${mks_robin_nano_v1_3_f4_common.build_flags}
-DMCU_STM32F407VE -DENABLE_HWSERIAL3 -DSTM32_FLASH_SIZE=512
-DTIMER_SERVO=TIM2 -DTIMER_TONE=TIM3 -DSS_TIMER=4
-DHAL_SD_MODULE_ENABLED -DHAL_SRAM_MODULE_ENABLED
build_unflags = ${stm32_variant.build_unflags}
build_unflags = ${mks_robin_nano_v1_3_f4_common.build_unflags}
-DUSBCON -DUSBD_USE_CDC

#
# MKS/ZNP Robin Nano V1.3 with native USB mod
#
[env:mks_robin_nano_v1_3_f4_usbmod]
extends = mks_robin_nano_v1_3_f4_common
build_flags = ${stm32_variant.build_flags}
build_flags = ${mks_robin_nano_v1_3_f4_common.build_flags}
-DMCU_STM32F407VE -DSTM32_FLASH_SIZE=512
-DTIMER_SERVO=TIM2 -DTIMER_TONE=TIM3 -DSS_TIMER=4
-DHAL_SD_MODULE_ENABLED -DHAL_SRAM_MODULE_ENABLED
Expand Down

0 comments on commit e847913

Please sign in to comment.