<?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中的主题 [imx8mm] Not able to access GPIO through sysfs</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/imx8mm-Not-able-to-access-GPIO-through-sysfs/m-p/1334340#M179518</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am working on a custom board based on imx8mm + Yocto . I am not able to access the GPIOs through sysfs. I have a button connected to GPIO5_IO0 and LED connected to GPIO1_IO23. I am trying to turn the LED on when the button is pressed from user-space.&amp;nbsp; It is not working.&lt;/P&gt;&lt;P&gt;I am able to export the GPIO pin in sysfs. I can change the entry in the value, it is reflecting properly. But no changes on the device. Also when the button is presses, I expect the value to change. But not happening.&lt;/P&gt;&lt;P&gt;Although I managed to access the LED through Linux driver, and I am trying to access the button using one of the existing driver.&lt;/P&gt;&lt;P&gt;I have tried similar thing with imx8mm evk + Android default image.&lt;/P&gt;&lt;P&gt;Tried to export the gpio connected to LED. It is not creating any directory.&lt;/P&gt;&lt;P&gt;evk_8mm:/sys/class/gpio # echo 80 &amp;gt; export&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1|evk_8mm:/sys/class/gpio # ls&lt;/P&gt;&lt;P&gt;export&amp;nbsp;&amp;nbsp;&amp;nbsp; gpiochip128 gpiochip496 gpiochip96&lt;/P&gt;&lt;P&gt;gpiochip0 gpiochip32&amp;nbsp; gpiochip64&amp;nbsp; unexport&lt;/P&gt;&lt;P&gt;Tried to change the brightness.&lt;/P&gt;&lt;P&gt;evk_8mm:/sys/class/leds/status # echo 1 &amp;gt; brightness&lt;/P&gt;&lt;P&gt;There is no change in LED brightness.&lt;/P&gt;&lt;P&gt;Any idea why we are not able to access the GPIO through sysfs ?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Avijit&lt;/P&gt;</description>
    <pubDate>Thu, 02 Sep 2021 20:34:39 GMT</pubDate>
    <dc:creator>avijitnsec</dc:creator>
    <dc:date>2021-09-02T20:34:39Z</dc:date>
    <item>
      <title>[imx8mm] Not able to access GPIO through sysfs</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/imx8mm-Not-able-to-access-GPIO-through-sysfs/m-p/1334340#M179518</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am working on a custom board based on imx8mm + Yocto . I am not able to access the GPIOs through sysfs. I have a button connected to GPIO5_IO0 and LED connected to GPIO1_IO23. I am trying to turn the LED on when the button is pressed from user-space.&amp;nbsp; It is not working.&lt;/P&gt;&lt;P&gt;I am able to export the GPIO pin in sysfs. I can change the entry in the value, it is reflecting properly. But no changes on the device. Also when the button is presses, I expect the value to change. But not happening.&lt;/P&gt;&lt;P&gt;Although I managed to access the LED through Linux driver, and I am trying to access the button using one of the existing driver.&lt;/P&gt;&lt;P&gt;I have tried similar thing with imx8mm evk + Android default image.&lt;/P&gt;&lt;P&gt;Tried to export the gpio connected to LED. It is not creating any directory.&lt;/P&gt;&lt;P&gt;evk_8mm:/sys/class/gpio # echo 80 &amp;gt; export&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1|evk_8mm:/sys/class/gpio # ls&lt;/P&gt;&lt;P&gt;export&amp;nbsp;&amp;nbsp;&amp;nbsp; gpiochip128 gpiochip496 gpiochip96&lt;/P&gt;&lt;P&gt;gpiochip0 gpiochip32&amp;nbsp; gpiochip64&amp;nbsp; unexport&lt;/P&gt;&lt;P&gt;Tried to change the brightness.&lt;/P&gt;&lt;P&gt;evk_8mm:/sys/class/leds/status # echo 1 &amp;gt; brightness&lt;/P&gt;&lt;P&gt;There is no change in LED brightness.&lt;/P&gt;&lt;P&gt;Any idea why we are not able to access the GPIO through sysfs ?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Avijit&lt;/P&gt;</description>
      <pubDate>Thu, 02 Sep 2021 20:34:39 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/imx8mm-Not-able-to-access-GPIO-through-sysfs/m-p/1334340#M179518</guid>
      <dc:creator>avijitnsec</dc:creator>
      <dc:date>2021-09-02T20:34:39Z</dc:date>
    </item>
    <item>
      <title>Re: [imx8mm] Not able to access GPIO through sysfs</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/imx8mm-Not-able-to-access-GPIO-through-sysfs/m-p/1334376#M179521</link>
      <description>&lt;P&gt;Hi Avijit&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;may be useful to look at below link&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.nxp.com/t5/i-MX-Processors/how-does-it-control-the-GPIO-as-input-output-in-DTS/td-p/1319972" target="_blank"&gt;https://community.nxp.com/t5/i-MX-Processors/how-does-it-control-the-GPIO-as-input-output-in-DTS/td-p/1319972&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best regards&lt;BR /&gt;igor&lt;/P&gt;</description>
      <pubDate>Thu, 02 Sep 2021 23:27:51 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/imx8mm-Not-able-to-access-GPIO-through-sysfs/m-p/1334376#M179521</guid>
      <dc:creator>igorpadykov</dc:creator>
      <dc:date>2021-09-02T23:27:51Z</dc:date>
    </item>
    <item>
      <title>Re: [imx8mm] Not able to access GPIO through sysfs</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/imx8mm-Not-able-to-access-GPIO-through-sysfs/m-p/1334816#M179547</link>
      <description>&lt;P&gt;GPIO5_IO00 should be either 5*32+0 = 160 or (5-1)*32+0=128, depending on what is GPIOx block numbering in your i.MX, counting from 0 (GPIO0 is the first) or counting from 1 (GPIO1 is the first).&amp;nbsp;So either 160 or 128, but you do&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;evk_8mm:/sys/class/gpio # echo 80 &amp;gt; export&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Sep 2021 11:30:22 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/imx8mm-Not-able-to-access-GPIO-through-sysfs/m-p/1334816#M179547</guid>
      <dc:creator>kef2</dc:creator>
      <dc:date>2021-09-03T11:30:22Z</dc:date>
    </item>
  </channel>
</rss>

