I have an STM32MP processor that needs ARM Trusted Firmware for communicating with the PMIC. But when I flashing the STM32MP processor with the firmware, I get an error that the I2C device is not ready.
The reason why the I2C device is not ready, is because it has the wrong pin configuration. The pin configuration is PZ4 and PZ5 for SDA and SCL. I need to change them to PF14 and PF15 inside the ARM Trusted Firmware before I compile. How can I achieve that?
The I2C device can be initilized, no problem there, but I get the error ERROR("I2C device not readyn");
.
ret = stm32_i2c_init(i2c, &i2c_init);
if (ret != 0) {
ERROR("Cannot initialize I2C %x (%d)n",
i2c->i2c_base_addr, ret);
panic();
}
if (!stm32_i2c_is_device_ready(i2c, pmic_i2c_addr, 1,
I2C_TIMEOUT_BUSY_MS)) {
ERROR("I2C device not readyn");
panic();
}
Code from: ARM Trusted Hardware PMIC
The reference manual: STM32MP