Skip to content

Commit 39d461d

Browse files
committed
Centralize PHY define and drop RTL8201 LED flag
Move `PHY_TYPE=$(ENET_PHY)` into shared `DEFINES` in `firmware-template-gd32/lib/Rules.mk` and remove it from `COPS` so PHY selection is handled consistently through the define list. Also remove `RTL8201F_LED1_LINK_ALL` from the Art-Net pixel multi and E1.31 DMX multi build configs to stop forcing that PHY-specific LED behavior in those targets.
1 parent 9c6b054 commit 39d461d

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

firmware-template-gd32/lib/Rules.mk

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ $(info $$ENET_PHY [${ENET_PHY}])
2121
SRCDIR=src src/gd32 $(EXTRA_SRCDIR)
2222

2323
DEFINES:=$(addprefix -D,$(DEFINES))
24+
DEFINES+=-DPHY_TYPE=$(ENET_PHY)
2425

2526
include ../common/make/gd32/Board.mk
2627
include ../common/make/gd32/Mcu.mk
@@ -29,7 +30,7 @@ include ../common/make/gd32/Validate.mk
2930

3031
INCLUDES+=-I../lib-configstore/include -I../lib-board/include -I../lib-flash/include -I../lib-flashcode/include
3132

32-
COPS=-DGD32 -D$(FAMILY_UCA) -D$(LINE_UC) -D$(MCU) -D$(BOARD) -DPHY_TYPE=$(ENET_PHY)
33+
COPS=-DGD32 -D$(FAMILY_UCA) -D$(LINE_UC) -D$(MCU) -D$(BOARD)
3334
COPS+=$(strip $(DEFINES) $(MAKE_FLAGS) $(VALIDATE_FLAGS) $(INCLUDES))
3435
COPS+=$(strip $(ARMOPS) $(CMSISOPS))
3536
COPS+=-Os -nostartfiles -ffreestanding -nostdlib

0 commit comments

Comments
 (0)