工具与软件:
大家好!
我们如何在 U-Boot 中重写/重新配置 OMAP2 I2C 驱动程序 OMAP24xx_i2c.c、以便对 I2C 读取访问执行"重复启动"(SR)而不是"停止启动"(P-S)?
我知道源代码中有以下提示:
/* * i2c_read: Function now uses a single I2C read transaction with bulk transfer * of the requested number of bytes (note that the 'i2c md' command * limits this to 16 bytes anyway). If CONFIG_I2C_REPEATED_START is * defined in the board config header, this transaction shall be with * Repeated Start (Sr) between the address and data phases; otherwise * Stop-Start (P-S) shall be used (some I2C chips do require a P-S). * The address (reg offset) may be 0, 1 or 2 bytes long. * Function now reads correctly from chips that return more than one * byte of data per addressed register (like TI temperature sensors), * or that do not need a register address at all (such as some clock * distributors). */
但我尝试过它、但它不起作用。 还有一些其他更改我尝试不起作用。 I2C 驱动程序和硬件模块始终执行 P-S 而不是 Sr.
下图显示了我们希望的实现方式-绿色圆圈:

谢谢!
BR
Stefan