Other Parts Discussed in Thread: SYSCONFIG
Tool/software:
Hi everyone,
I'm working on a project using the F28P65x device and SysConfig v1.23.1.
I need to configure GPIO10 so that it can be used either as a regular GPIO or as an ePWM output (EPWM6A) at runtime. The idea is to switch between the two functions during execution using:
GPIO_setPinConfig(GPIO_RELAY_GPIO_PIN_CONFIG); GPIO_setPinConfig(ePWM_RELAY_EPWMA_PIN_CONFIG);
Ideally, I'd like to define the pinmux options in SysConfig like this:
#define GPIO_RELAY_GPIO_PIN_CONFIG GPIO_10_GPIO10 #define ePWM_RELAY_EPWMA_PIN_CONFIG GPIO_10_EPWM6_A
However, SysConfig throws a resource conflict error when both are defined because GPIO10 is shared between these two functions. I understand why this happens, but I would like a clean way to generate both pinmux defines, while still being in control of which one is applied at runtime through GPIO_setPinConfig().

My Question:
Is there a supported way in SysConfig to define multiple alternate functions for a single pin (in this case GPIO10), such that the generated code provides both configuration macros, but lets me decide at runtime which one to apply?
Or is the only workaround to define one function in SysConfig and manually write the other configuration in code?
Thanks in advance for any guidance or best practices on handling this scenario!
Best regards,
Sebastian