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.

AM625: 使用配置GPIO

Part Number: AM625

在uboot启动阶段控制GPIO,在uboot源码/board/ti/evm.c文件中加入如下

#define AM62X_GPIO0_BASE 0x00600000
#define AM62X_GPIO_DIR01_OFFSET 0x10
#define AM62X_GPIO_SET_DATA01_OFFSET 0x18

val = readl(AM62X_GPIO0_BASE + AM62X_GPIO_DIR01_OFFSET);
val &= ~(1 << 1);
writel(val, AM62X_GPIO0_BASE + AM62X_GPIO_DIR01_OFFSET);
writel((1 << 1), AM62X_GPIO0_BASE + AM62X_GPIO_SET_DATA01_OFFSET);

在哪可以查询到gpio的具体方向偏移地址和数据地址。如想配置GPIO1_12引脚?