<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>i.MX ProcessorsのトピックIMX8MN EVK GPIO in yocto linux</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/IMX8MN-EVK-GPIO-in-yocto-linux/m-p/1723896#M212654</link>
    <description>&lt;P&gt;Hi, I'm having problems to configure and set gpio on the yocto linux with the imx8mn evk.&lt;BR /&gt;Having LEDs connected to pins 19 (ECSPI2_MOSI GPIO5_IO11) and 40 (SAI5_RXC GPIO3_IO20) of J1003.&lt;BR /&gt;With a MCUXpresso build for the M7 launched from u-boot LEDs are blinking.&lt;BR /&gt;Now trying with linux ...&lt;BR /&gt;&lt;BR /&gt;When trying to set pin 40 with 'gpioset gpiochip3 20=1'&lt;BR /&gt;I get the error: gpioset: invalid line value: 'gpiochip3'&lt;BR /&gt;&lt;BR /&gt;Same Problem was for the mini at:&lt;BR /&gt;&lt;A href="https://community.nxp.com/t5/i-MX-Processors/gpioset-not-working-when-adding-kernel-modules-in-yocto-project/m-p/1620855?profile.language=ja" target="_blank"&gt;https://community.nxp.com/t5/i-MX-Processors/gpioset-not-working-when-adding-kernel-modules-in-yocto-project/m-p/1620855?profile.language=ja&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;But following the tips there was not solving the issue.&lt;BR /&gt;&lt;BR /&gt;So the steps I did are:&lt;BR /&gt;&lt;BR /&gt;--- edit the device tree dtsi ---&lt;BR /&gt;&amp;gt; cd to imx-yocto-bsp&lt;BR /&gt;&amp;gt; DISTRO=fsl-imx-wayland MACHINE=imx8mn-lpddr4-evk source imx-setup-release.sh -b imx8nlpd4_build&lt;BR /&gt;&amp;gt; bitbake -c devshell virtual/kernel&lt;/P&gt;&lt;P&gt;(in new devshell window:)&lt;BR /&gt;&amp;gt; gedit .arch/arm64/boot/dts/freescale/imx8mn-evk.dtsi&lt;BR /&gt;@micfil set status to disabled&lt;/P&gt;&lt;P&gt;down @ &amp;amp;iomuxc adding:&lt;BR /&gt;/delete-node/ pinctrl_pdm;&lt;BR /&gt;pinctrl_hog: hoggrp {&lt;BR /&gt;fsl,pins = &amp;lt;&lt;BR /&gt;MX8MN_IOMUXC_SAI5_RXC_GPIO3_IO20 0x11&lt;BR /&gt;&amp;gt;;&lt;BR /&gt;};&lt;BR /&gt;close gedit&lt;BR /&gt;&amp;gt; make dtbs&lt;BR /&gt;&amp;gt; exit&lt;/P&gt;&lt;P&gt;bitbake imx-image-core&lt;BR /&gt;flash created wic to sd-card and boot&lt;BR /&gt;&lt;BR /&gt;--- trying on the device ---&lt;BR /&gt;&amp;gt; gpiodetect&lt;BR /&gt;gpiochip0 [30200000.gpio] (32 lines)&lt;BR /&gt;gpiochip1 [30210000.gpio] (32 lines)&lt;BR /&gt;gpiochip2 [30220000.gpio] (32 lines)&lt;BR /&gt;gpiochip3 [30230000.gpio] (32 lines)&lt;BR /&gt;gpiochip4 [30240000.gpio] (32 lines)&lt;BR /&gt;gpiochip5 [2-0020] (16 lines)&lt;/P&gt;&lt;P&gt;&amp;gt; gpioset gpiochip3 20=1&lt;BR /&gt;gpioset: invalid line value: 'gpiochip3'&lt;/P&gt;&lt;P&gt;&amp;gt; cat /sys/kernel/debug/gpio&lt;BR /&gt;gpiochip0: GPIOs 0-31, parent: platform/30200000.gpio, 30200000.gpio:&lt;BR /&gt;gpio-13 ( |ir-receiver ) in hi IRQ ACTIVE LOW&lt;BR /&gt;gpio-15 ( |cd ) in lo IRQ ACTIVE LOW&lt;/P&gt;&lt;P&gt;gpiochip1: GPIOs 32-63, parent: platform/30210000.gpio, 30210000.gpio:&lt;BR /&gt;gpio-42 ( |reset ) out hi ACTIVE LOW&lt;BR /&gt;gpio-51 ( |regulator-usdhc2 ) out hi&lt;/P&gt;&lt;P&gt;gpiochip2: GPIOs 64-95, parent: platform/30220000.gpio, 30220000.gpio:&lt;BR /&gt;gpio-80 ( |yellow:status ) out hi&lt;/P&gt;&lt;P&gt;gpiochip3: GPIOs 96-127, parent: platform/30230000.gpio, 30230000.gpio:&lt;BR /&gt;gpio-118 ( |PHY reset ) out hi ACTIVE LOW&lt;/P&gt;&lt;P&gt;gpiochip4: GPIOs 128-159, parent: platform/30240000.gpio, 30240000.gpio:&lt;BR /&gt;gpio-144 ( |scl ) out lo&lt;BR /&gt;gpio-145 ( |sda ) in lo&lt;BR /&gt;gpio-146 ( |scl ) out lo&lt;BR /&gt;gpio-147 ( |sda ) in lo&lt;BR /&gt;gpio-149 ( |wlf,mute ) out hi ACTIVE LOW&lt;/P&gt;&lt;P&gt;gpiochip5: GPIOs 496-511, parent: i2c/2-0020, 2-0020, can sleep:&lt;BR /&gt;gpio-497 ( |regulator-audio-boar) out hi&lt;BR /&gt;&lt;BR /&gt;--- disable the sound driver ---&lt;BR /&gt;bitbake -c menuconfig virtual/kernel&lt;/P&gt;&lt;P&gt;deselect Device Drivers - Sound card support&lt;BR /&gt;save as .config and exit&lt;/P&gt;&lt;P&gt;bitbake imx-image-core&lt;BR /&gt;extract &amp;lt;build&amp;gt;/tmp/deploy/images/imx8mn-lpddr4-evk/imx-image-core-imx8mn-lpddr4-evk-&amp;lt;date&amp;gt;.wic.zst&lt;BR /&gt;and write the .wic to sd-card&lt;/P&gt;&lt;P&gt;On the device still the same problem:&lt;BR /&gt;&amp;gt; gpioset gpiochip3 20=1&lt;BR /&gt;gpioset: invalid line value: 'gpiochip3'&lt;BR /&gt;&lt;BR /&gt;Is there something wrong with my changes or something missing?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 15 Sep 2023 11:22:29 GMT</pubDate>
    <dc:creator>k_specka</dc:creator>
    <dc:date>2023-09-15T11:22:29Z</dc:date>
    <item>
      <title>IMX8MN EVK GPIO in yocto linux</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/IMX8MN-EVK-GPIO-in-yocto-linux/m-p/1723896#M212654</link>
      <description>&lt;P&gt;Hi, I'm having problems to configure and set gpio on the yocto linux with the imx8mn evk.&lt;BR /&gt;Having LEDs connected to pins 19 (ECSPI2_MOSI GPIO5_IO11) and 40 (SAI5_RXC GPIO3_IO20) of J1003.&lt;BR /&gt;With a MCUXpresso build for the M7 launched from u-boot LEDs are blinking.&lt;BR /&gt;Now trying with linux ...&lt;BR /&gt;&lt;BR /&gt;When trying to set pin 40 with 'gpioset gpiochip3 20=1'&lt;BR /&gt;I get the error: gpioset: invalid line value: 'gpiochip3'&lt;BR /&gt;&lt;BR /&gt;Same Problem was for the mini at:&lt;BR /&gt;&lt;A href="https://community.nxp.com/t5/i-MX-Processors/gpioset-not-working-when-adding-kernel-modules-in-yocto-project/m-p/1620855?profile.language=ja" target="_blank"&gt;https://community.nxp.com/t5/i-MX-Processors/gpioset-not-working-when-adding-kernel-modules-in-yocto-project/m-p/1620855?profile.language=ja&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;But following the tips there was not solving the issue.&lt;BR /&gt;&lt;BR /&gt;So the steps I did are:&lt;BR /&gt;&lt;BR /&gt;--- edit the device tree dtsi ---&lt;BR /&gt;&amp;gt; cd to imx-yocto-bsp&lt;BR /&gt;&amp;gt; DISTRO=fsl-imx-wayland MACHINE=imx8mn-lpddr4-evk source imx-setup-release.sh -b imx8nlpd4_build&lt;BR /&gt;&amp;gt; bitbake -c devshell virtual/kernel&lt;/P&gt;&lt;P&gt;(in new devshell window:)&lt;BR /&gt;&amp;gt; gedit .arch/arm64/boot/dts/freescale/imx8mn-evk.dtsi&lt;BR /&gt;@micfil set status to disabled&lt;/P&gt;&lt;P&gt;down @ &amp;amp;iomuxc adding:&lt;BR /&gt;/delete-node/ pinctrl_pdm;&lt;BR /&gt;pinctrl_hog: hoggrp {&lt;BR /&gt;fsl,pins = &amp;lt;&lt;BR /&gt;MX8MN_IOMUXC_SAI5_RXC_GPIO3_IO20 0x11&lt;BR /&gt;&amp;gt;;&lt;BR /&gt;};&lt;BR /&gt;close gedit&lt;BR /&gt;&amp;gt; make dtbs&lt;BR /&gt;&amp;gt; exit&lt;/P&gt;&lt;P&gt;bitbake imx-image-core&lt;BR /&gt;flash created wic to sd-card and boot&lt;BR /&gt;&lt;BR /&gt;--- trying on the device ---&lt;BR /&gt;&amp;gt; gpiodetect&lt;BR /&gt;gpiochip0 [30200000.gpio] (32 lines)&lt;BR /&gt;gpiochip1 [30210000.gpio] (32 lines)&lt;BR /&gt;gpiochip2 [30220000.gpio] (32 lines)&lt;BR /&gt;gpiochip3 [30230000.gpio] (32 lines)&lt;BR /&gt;gpiochip4 [30240000.gpio] (32 lines)&lt;BR /&gt;gpiochip5 [2-0020] (16 lines)&lt;/P&gt;&lt;P&gt;&amp;gt; gpioset gpiochip3 20=1&lt;BR /&gt;gpioset: invalid line value: 'gpiochip3'&lt;/P&gt;&lt;P&gt;&amp;gt; cat /sys/kernel/debug/gpio&lt;BR /&gt;gpiochip0: GPIOs 0-31, parent: platform/30200000.gpio, 30200000.gpio:&lt;BR /&gt;gpio-13 ( |ir-receiver ) in hi IRQ ACTIVE LOW&lt;BR /&gt;gpio-15 ( |cd ) in lo IRQ ACTIVE LOW&lt;/P&gt;&lt;P&gt;gpiochip1: GPIOs 32-63, parent: platform/30210000.gpio, 30210000.gpio:&lt;BR /&gt;gpio-42 ( |reset ) out hi ACTIVE LOW&lt;BR /&gt;gpio-51 ( |regulator-usdhc2 ) out hi&lt;/P&gt;&lt;P&gt;gpiochip2: GPIOs 64-95, parent: platform/30220000.gpio, 30220000.gpio:&lt;BR /&gt;gpio-80 ( |yellow:status ) out hi&lt;/P&gt;&lt;P&gt;gpiochip3: GPIOs 96-127, parent: platform/30230000.gpio, 30230000.gpio:&lt;BR /&gt;gpio-118 ( |PHY reset ) out hi ACTIVE LOW&lt;/P&gt;&lt;P&gt;gpiochip4: GPIOs 128-159, parent: platform/30240000.gpio, 30240000.gpio:&lt;BR /&gt;gpio-144 ( |scl ) out lo&lt;BR /&gt;gpio-145 ( |sda ) in lo&lt;BR /&gt;gpio-146 ( |scl ) out lo&lt;BR /&gt;gpio-147 ( |sda ) in lo&lt;BR /&gt;gpio-149 ( |wlf,mute ) out hi ACTIVE LOW&lt;/P&gt;&lt;P&gt;gpiochip5: GPIOs 496-511, parent: i2c/2-0020, 2-0020, can sleep:&lt;BR /&gt;gpio-497 ( |regulator-audio-boar) out hi&lt;BR /&gt;&lt;BR /&gt;--- disable the sound driver ---&lt;BR /&gt;bitbake -c menuconfig virtual/kernel&lt;/P&gt;&lt;P&gt;deselect Device Drivers - Sound card support&lt;BR /&gt;save as .config and exit&lt;/P&gt;&lt;P&gt;bitbake imx-image-core&lt;BR /&gt;extract &amp;lt;build&amp;gt;/tmp/deploy/images/imx8mn-lpddr4-evk/imx-image-core-imx8mn-lpddr4-evk-&amp;lt;date&amp;gt;.wic.zst&lt;BR /&gt;and write the .wic to sd-card&lt;/P&gt;&lt;P&gt;On the device still the same problem:&lt;BR /&gt;&amp;gt; gpioset gpiochip3 20=1&lt;BR /&gt;gpioset: invalid line value: 'gpiochip3'&lt;BR /&gt;&lt;BR /&gt;Is there something wrong with my changes or something missing?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 15 Sep 2023 11:22:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/IMX8MN-EVK-GPIO-in-yocto-linux/m-p/1723896#M212654</guid>
      <dc:creator>k_specka</dc:creator>
      <dc:date>2023-09-15T11:22:29Z</dc:date>
    </item>
    <item>
      <title>Re: IMX8MN EVK GPIO in yocto linux</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/IMX8MN-EVK-GPIO-in-yocto-linux/m-p/1725322#M212776</link>
      <description>&lt;P&gt;please try to set "gpiochip2 20=1". not gpiochip3.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;FYI. &lt;A href="https://variwiki.com/index.php?title=MX8M_GPIO" target="_blank"&gt;https://variwiki.com/index.php?title=MX8M_GPIO&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Sep 2023 07:46:45 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/IMX8MN-EVK-GPIO-in-yocto-linux/m-p/1725322#M212776</guid>
      <dc:creator>jimmychan</dc:creator>
      <dc:date>2023-09-19T07:46:45Z</dc:date>
    </item>
  </channel>
</rss>

