Apalis imx6 temperature sensor linux device-tree

Hi, I’m the Toradex AI Assistant. The Toradex Support team will follow up with you shortly!

Did you like my answer?

:+1: :-1:


Hello,

To address the issue of reading the SoM temperature on your Apalis iMX6Q after upgrading to BSP version 5, you’ll need to ensure that your device tree is correctly configured to enable the temperature sensor. The temperature sensor on the i.MX 6 series is typically accessed through the Industrial Input/Output (IIO) framework, with readings available under the sysfs path /sys/bus/iio/devices/iio:device0/in_temp8_input.

Here are the steps you can follow:

  1. Verify Device Tree Configuration:

    • Ensure the thermal sensor node is correctly defined in your device tree. Look for a node under the thermal-zones section that references the appropriate sensor. It might look something like this:
      thermal-zones {
          cpu-thermal {
              polling-delay-passive = <1000>;
              polling-delay = <5000>;
              thermal-sensors = <&thermal_sensor>;
              ...
          };
      };
      
    • Make sure the thermal-sensors property points to the correct sensor node.
  2. Check Kernel Configuration:

    • Confirm that the necessary kernel modules for IIO and thermal management are enabled, such as CONFIG_THERMAL and CONFIG_IIO.
  3. Recompile and Deploy:

    • After making changes to the device tree, recompile it and deploy the updated binary to your device.
  4. Test the Temperature Reading:

    • Once the device tree is correctly configured and deployed, check the temperature reading using:
      cat /sys/bus/iio/devices/iio:device0/in_temp8_input
      

If the issue persists, double-check the device tree bindings and ensure all necessary drivers are loaded at boot. This should help restore the temperature reading functionality on your Apalis iMX6Q module.

Best regards,
Toradex AI Assistant

Please, also check if these links can help you solve your problem:

Temperature Sensor (Linux) | Toradex Developer Center.