This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hi Ti
I want to setting the GPIO0_35 to output low in MCU2_0, I have tried to add some GPIO code, but it was not working.
diff --git a/utils/board/src/j784s4/board_j784s4_evm.c b/utils/board/src/j784s4/board_j784s4_evm.c old mode 100644 new mode 100755 index a6f846d..aac5374 --- a/utils/board/src/j784s4/board_j784s4_evm.c +++ b/utils/board/src/j784s4/board_j784s4_evm.c @@ -47,6 +47,9 @@ #include <ti/drv/enet/enet.h> #include <ti/drv/enet/examples/utils/include/enet_apputils.h> +#include <ti/drv/gpio/GPIO.h> +#include <ti/drv/gpio/soc/GPIO_soc.h> + #include <ti/board/board.h> #include <ti/board/src/j784s4_evm/include/board_cfg.h> #include <ti/board/src/j784s4_evm/include/board_pinmux.h> @@ -170,6 +173,29 @@ static EthFwBoard_Obj gEthFwBoard; extern pinmuxBoardCfg_t gEthFwPinmuxData[]; +/* GPIO Driver board specific pin configuration structure */ +GPIO_PinConfig gEthFw_gpioPinCfgs[] = +{ + GPIO_DEVICE_CONFIG(0, 35) | GPIO_CFG_OUT_LOW, +}; + +/* GPIO Driver callback functions */ +GPIO_CallbackFxn gEthFw_gpioCbFunctions[] = +{ + NULL +}; + +/* GPIO Driver configuration structure */ +GPIO_v0_Config GPIO_v0_config = +{ + gEthFw_gpioPinCfgs, + gEthFw_gpioCbFunctions, + sizeof(gEthFw_gpioPinCfgs) / sizeof(GPIO_PinConfig), + sizeof(gEthFw_gpioCbFunctions) / sizeof(GPIO_CallbackFxn), + 0, +}; + @@ -326,6 +352,11 @@ int32_t EthFwBoard_init(uint32_t flags) /* Detect expansion boards attached to main board (CPB) */ EthFwBoard_detectDBs(); + + /*Configure desay PHY reset*/ + GPIO_init(); + GPIO_write(0, 0);// GPIO35 LOW + if (!gEthFwBoard.qenetDetected) { appLogPrintf("Quad-Port Eth expansion board not detected\n"); @@ -615,3 +646,4 @@ static uint32_t EthFwBoard_getMacAddrPoolStatic(uint8_t macAddr[][ENET_MAC_ADDR_ return allocCnt; +
Hi Jeken,
do you have unlock this GPIO group? you need find the PADCONFIG1_LOCK, and unlock this.
BR,
Biao