![shequ.stmicroelectronics.cn](./template/st_v1/static/img/logo2.png)
你好我的板子基于stm32mp135f-dk板子来设计的,使用buildroot编译(st/2023.02.2),通过修改开发板的设备树来实现我的功能(buildroot-external-st/board/stmicroelectronics/stm32mp1/linux-dts/stm32mp135f-dk-mx.dts)。 我一共使用了3路i2c,i21,i2c3和i2c5 设备树添加如下 &i2c1{ pinctrl-names = "default", "sleep"; pinctrl-0 = <&i2c1_pins_mx>; pinctrl-1 = <&i2c1_sleep_pins_mx>; //status = "okay"; status = "okay"; / USER CODE BEGIN i2c1 / i2c-scl-rising-time-ns = <170>; i2c-scl-falling-time-ns = <5>; clock-frequency = <100000>; /delete-property/ dmas; /delete-property/ dma-names; //pcf8563@51{ // compatible = "nxp,pcf8563"; // reg = <0x51>; // status = "okay"; //}; }; &i2c3{ pinctrl-names = "default", "sleep"; pinctrl-0 = <&i2c3_pins_mx>; pinctrl-1 = <&i2c3_sleep_pins_mx>; status = "okay"; / USER CODE BEGIN i2c1 / i2c-scl-rising-time-ns = <170>; i2c-scl-falling-time-ns = <5>; clock-frequency = <100000>; /delete-property/ dmas; /delete-property/ dma-names; pcf8563@51{ compatible = "nxp,pcf8563"; reg = <0x51>; status = "okay"; }; }; &i2c5{ pinctrl-names = "default", "sleep"; pinctrl-0 = <&i2c5_pins_mx>; pinctrl-1 = <&i2c5_sleep_pins_mx>; status = "okay"; / USER CODE BEGIN i2c5 / i2c-scl-rising-time-ns = <170>; i2c-scl-falling-time-ns = <5>; ... 但编译下载到板子上发现并没有i2c3下的设备枚举过程 然后在i2c/busses/i2c-stm32f7.c中增加log打印(stm32f7_i2c_probe的进入) diff --git a/drivers/i2c/busses/i2c-stm32f7.c b/drivers/i2c/busses/i2c-stm32f7.c index 7bb4a4af4..db6957db7 100644 --- a/drivers/i2c/busses/i2c-stm32f7.c +++ b/drivers/i2c/busses/i2c-stm32f7.c @@ -2092,6 +2092,7 @@ static int stm32f7_i2c_probe(struct platform_device pdev) struct reset_control rst; dma_addr_t phy_addr; int irq_error, irq_event, ret;
编译烧录通过dmesg查看只有i2c1和i2c5有正常probe,而i2c3没有probe dmesg | grep hgs[ 3.629664] hgs begin stm32f7_i2c_probe [ 3.632602] stm32f7-i2c 40012000.i2c: hgs stm32f7_i2c_probe [ 3.702230] hgs begin stm32f7_i2c_probe [ 3.708457] stm32f7-i2c 4c006000.i2c: hgs stm32f7_i2c_probe 请问如果让i2c3正常probe |
如何使用STM32CubeMX修改STM32Cube_FW_MP2_V1.0.0固件中的项目例程引脚?
OpenSTLinxu 编译失败
STM32MP135 bitbake 编译st-example-image-qtwayland镜像失败
Secure secret provisioning
STM32MP157D的LCD屏幕问题
使用STM32CubeIDE建的MP257F工程会出现大量缺库现象提示
stm32mp257fai3 能否在uboot阶段同时启动m核与a核?
STM32MP135F-DK如何移植ubuntu?
STM32MP157
ov5640图像显示乱彩屏
你好,i2c3默认是安全外设,需要配置OP-TEE设备树将其改为非安全可读写外设,参考配置如下,编译更新OP-TEE后,重启系统,再检查Linux下能否识别。
各位大佬,有人能帮忙看看吗
[md]多谢 按这样已解决