Hi,
i tried to run the adt7420 sample demo with frdm_mcxw board, but the print message is "sensor: device not ready.“ after i flashed the image into the target .
the hardware setup like below picture for reference
anliu114036_0-1786010612902.png
i think the hardware wiring is ok which i followed below description.
anliu114036_1-1786010728607.png
and you can find the overlay file which i added the board folder like below
anliu114036_2-1786010818065.png
i also attached the build log file which can help get more information from it. can you check it and help solve the issue
Hello, hope you are doing well.
From the image you shared, it looks like you are working with a KW47-LOC board, could you please confirm this is the right device?
Which Zephyr repo and version you are working with? As you may know, the KW47-LOC board is not directly supported on Zephyr, only the frdm-mcxw72 is. That said, since the chips are compatible, you can work with the frdm-mcxw72 examples and modify the overlay file to adapt it to the KW47-LOC board pins.
Checking your overlay configuration, the KW47-LOC board only supports the LPI2C1 module, so you will have to enable the lpi2c1 node in your overlay instead. For the SCL and SDA pins, these are defined in frdm_mcxw72-pinctrl.dtsi as PTB4 and PTB5 for I2C1, I would recommend keeping those since they match the KW47-LOC pins. In order for J2 pin 6 to connect to the target MCU pin PTB4, place J24 2-3 shorted.
Refer to UM12114 for the MikroBUS I2C pinout:
Pin 2: INT (Hardware interrupt) on WUU0_P12/PTC7
Pin 5: SCL (I2C clock) on I2C1_SCL
Pin 6: SDA (I2C data) on I2C1_SDA
Please also confirm that you have the following configurations enabled in your prj.conf file:
CONFIG_I2C=y
CONFIG_SENSOR=y
CONFIG_ADT7420=y
Best regards,
Ana Sofia.
Hi Ana
Thanks for your support. Yes, I did work with a KW47-LOC board and try to run the frdm-mcxw72 examples on this board, the Zephyr repo version is v4.4.1.
After change the overlay file from I2C0 into I2C1, it looks the ADT7420 device initialize is ok, but this sensor is still can't read out the right temperature , you can see below print message from the serial monitor.
anliu114036_0-1786427779708.png
here is the latest overlay file and prj.conf file content.
anliu114036_1-1786427965565.png
anliu114036_3-1786428011874.png
Best regards
Liu Wei