<?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のトピックRe: [iMX6SL] [GPIO] How to use the GPIO from userspace</title>
    <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454236#M70701</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;gt; It would be great if someone can point me out to the values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't have the manual for the chip you have, so I'm looking in the IMX6SDLRM manual, which is similar, but different.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When trying to find stuff in a Reference Manual with over 5000 pages, "Search" is your friend.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So search for "EPDC_DATA07" or "GPIO1_IO14" in the Reference Manual and you'll soon end up looking at relevant tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then you're looking to get to the right section of the IOMUX Controller chapter, and find the register referenced above.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In my manual, for a register like "IOMUXC_SW_PAD_CTL_PAD_EIM_RW", 0x110b0 would mean:&lt;/P&gt;&lt;P&gt;- 0x1****: Hysteresys&lt;/P&gt;&lt;P&gt;- 0x*1***: PUS=00 (100k pulldown), PUE=0, PKE=1 (KEEP enabled, PULL not)&lt;/P&gt;&lt;P&gt;- 0x**0**: ODE=0, not open-drain&lt;/P&gt;&lt;P&gt;- 0x***b0: Medium Speed, 40 ohm, slow slew&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is disappointing that they're using "magic hex numbers" rather than using proper definitions for these bitfields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is what those definitions look like in Linux.2.6.35 for the i.MX53:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="c++" __jive_macro_name="code" class="jive_macro_code jive_text_macro _jivemacro_uid_14401146761709051" data-renderedposition="428_8_1234_224" jivemacro_uid="_14401146761709051" modifiedtitle="true"&gt;&lt;P&gt;#define MX53_GPIO_PAD_CTRL&amp;nbsp; (PAD_CTL_PKE | PAD_CTL_PUE |&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; PAD_CTL_DSE_HIGH | PAD_CTL_PUS_22K_UP)
#define TX53_SDHC_PAD_CTRL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (PAD_CTL_HYS | PAD_CTL_DSE_HIGH |&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; PAD_CTL_SRE_FAST | PAD_CTL_PUS_100K_DOWN)


&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* I2C */
&amp;nbsp;&amp;nbsp;&amp;nbsp; NEW_PAD_CTRL(MX53_PAD_EIM_D28__I2C1_SDA, MX53_GPIO_PAD_CTRL),
&amp;nbsp;&amp;nbsp;&amp;nbsp; NEW_PAD_CTRL(MX53_PAD_EIM_D21__I2C1_SCL, MX53_GPIO_PAD_CTRL),

&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* CSPI (LCD) */
&amp;nbsp;&amp;nbsp;&amp;nbsp; NEW_PAD_CTRL(MX53_PAD_SD1_CMD__CSPI_MOSI, TX53_SDHC_PAD_CTRL),
&amp;nbsp;&amp;nbsp;&amp;nbsp; NEW_PAD_CTRL(MX53_PAD_SD1_CLK__CSPI_SCLK, TX53_SDHC_PAD_CTRL),&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is easy to make this understandable in "C". Maybe the "magic numbers" are one of the disadvantages of the Device Tree. It may be too primitive as a "language" to allow a clear description of the hardware.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 21 Aug 2015 00:13:47 GMT</pubDate>
    <dc:creator>TomE</dc:creator>
    <dc:date>2015-08-21T00:13:47Z</dc:date>
    <item>
      <title>[iMX6SL] [GPIO] How to use the GPIO from userspace</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454234#M70699</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have IMX6SLEVK.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to toggle a free GPIO i.e. &lt;STRONG&gt;GPIO1_14&lt;/STRONG&gt; from userspace &lt;STRONG&gt;/sys/class/gpio&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But when I export this &lt;STRONG&gt;GPIO1_14&lt;/STRONG&gt; by the below steps, I do not see the values getting to '&lt;STRONG&gt;1&lt;/STRONG&gt;':&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;EM&gt;echo 14 &amp;gt; /sys/class/gpio/export&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; echo out &amp;gt; /sys/class/gpio/gpio14/direction&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; echo 1 &amp;gt; /sys/class/gpio/gpio14/value&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please do let me know if I need to do anything else for the same.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am probing the &lt;STRONG&gt;MX6SL_PAD_EPDC_D7_GPIO_1_14&lt;/STRONG&gt; pad on the board.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I went through the below discussion:&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.nxp.com/message/441354"&gt;Re: Using GPIO's on IMX6 SLEVK&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I wrote a kernel module exporting the GPIO1_14, but I am getting seg_fault for the same probably because I need to get a virtual address for this GPIO1_14.&lt;/P&gt;&lt;P&gt;But I am not sure how to get this address in kernel code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2015 07:53:21 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454234#M70699</guid>
      <dc:creator>bhayani_sunny</dc:creator>
      <dc:date>2015-08-20T07:53:21Z</dc:date>
    </item>
    <item>
      <title>Re: [iMX6SL] [GPIO] How to use the GPIO from userspace</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454235#M70700</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am able to configure the GPIO from userspace from &lt;STRONG&gt;/sys/class/gpio&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I did changes in the &lt;STRONG&gt;arch/arm/boot/dts/imx6sl-evk.dts&lt;/STRONG&gt; file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I added the below lines in the &lt;STRONG&gt;hoggrp&lt;/STRONG&gt; for &lt;STRONG&gt;iomuxc&lt;/STRONG&gt; group:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;MX6SL_PAD_EPDC_D7__GPIO1_IO14&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;0x110b0&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;MX6SL_PAD_EPDC_D6__GPIO1_IO13&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;0x110b0&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But can anybody please let me know, what the above values mean. Because I tried to use this pins with the values --&amp;gt;0x1b0b0 and 0x80000000, but it was not working for me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then I referred to the BSP Porting Guide for iMX6SL and there it is mentioned that the values corresponds to Hysteresis, Pull up/Pull down, etc but I am not able to see exact bit mappings for the above values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It would be great if someone can point me out to the values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Aug 2015 13:38:49 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454235#M70700</guid>
      <dc:creator>bhayani_sunny</dc:creator>
      <dc:date>2015-08-20T13:38:49Z</dc:date>
    </item>
    <item>
      <title>Re: [iMX6SL] [GPIO] How to use the GPIO from userspace</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454236#M70701</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;gt; It would be great if someone can point me out to the values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't have the manual for the chip you have, so I'm looking in the IMX6SDLRM manual, which is similar, but different.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When trying to find stuff in a Reference Manual with over 5000 pages, "Search" is your friend.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So search for "EPDC_DATA07" or "GPIO1_IO14" in the Reference Manual and you'll soon end up looking at relevant tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then you're looking to get to the right section of the IOMUX Controller chapter, and find the register referenced above.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In my manual, for a register like "IOMUXC_SW_PAD_CTL_PAD_EIM_RW", 0x110b0 would mean:&lt;/P&gt;&lt;P&gt;- 0x1****: Hysteresys&lt;/P&gt;&lt;P&gt;- 0x*1***: PUS=00 (100k pulldown), PUE=0, PKE=1 (KEEP enabled, PULL not)&lt;/P&gt;&lt;P&gt;- 0x**0**: ODE=0, not open-drain&lt;/P&gt;&lt;P&gt;- 0x***b0: Medium Speed, 40 ohm, slow slew&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is disappointing that they're using "magic hex numbers" rather than using proper definitions for these bitfields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is what those definitions look like in Linux.2.6.35 for the i.MX53:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE __default_attr="c++" __jive_macro_name="code" class="jive_macro_code jive_text_macro _jivemacro_uid_14401146761709051" data-renderedposition="428_8_1234_224" jivemacro_uid="_14401146761709051" modifiedtitle="true"&gt;&lt;P&gt;#define MX53_GPIO_PAD_CTRL&amp;nbsp; (PAD_CTL_PKE | PAD_CTL_PUE |&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; PAD_CTL_DSE_HIGH | PAD_CTL_PUS_22K_UP)
#define TX53_SDHC_PAD_CTRL&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (PAD_CTL_HYS | PAD_CTL_DSE_HIGH |&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; PAD_CTL_SRE_FAST | PAD_CTL_PUS_100K_DOWN)


&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* I2C */
&amp;nbsp;&amp;nbsp;&amp;nbsp; NEW_PAD_CTRL(MX53_PAD_EIM_D28__I2C1_SDA, MX53_GPIO_PAD_CTRL),
&amp;nbsp;&amp;nbsp;&amp;nbsp; NEW_PAD_CTRL(MX53_PAD_EIM_D21__I2C1_SCL, MX53_GPIO_PAD_CTRL),

&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* CSPI (LCD) */
&amp;nbsp;&amp;nbsp;&amp;nbsp; NEW_PAD_CTRL(MX53_PAD_SD1_CMD__CSPI_MOSI, TX53_SDHC_PAD_CTRL),
&amp;nbsp;&amp;nbsp;&amp;nbsp; NEW_PAD_CTRL(MX53_PAD_SD1_CLK__CSPI_SCLK, TX53_SDHC_PAD_CTRL),&lt;/P&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It is easy to make this understandable in "C". Maybe the "magic numbers" are one of the disadvantages of the Device Tree. It may be too primitive as a "language" to allow a clear description of the hardware.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 00:13:47 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454236#M70701</guid>
      <dc:creator>TomE</dc:creator>
      <dc:date>2015-08-21T00:13:47Z</dc:date>
    </item>
    <item>
      <title>Re: [iMX6SL] [GPIO] How to use the GPIO from userspace</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454237#M70702</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When GPIO pin is configured as output, it cannot be read, in general. Reading its value will produce the result you see. In order to be able to read output pins they have to be configured in a special way, I remember reading that in the Reference manual. I have not done it myself, so I can only recommend reviewing GPIO section of the Reference Manual for which bits must be set and in which registers.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Alex&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 00:32:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454237#M70702</guid>
      <dc:creator>alik</dc:creator>
      <dc:date>2015-08-21T00:32:48Z</dc:date>
    </item>
    <item>
      <title>Re: [iMX6SL] [GPIO] How to use the GPIO from userspace</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454238#M70703</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When a GPIO pin is configured as an output it is possible to read its value back by setting the SION bit of the pad.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Fabio Estevam&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 00:44:25 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454238#M70703</guid>
      <dc:creator>fabio_estevam</dc:creator>
      <dc:date>2015-08-21T00:44:25Z</dc:date>
    </item>
    <item>
      <title>Re: [iMX6SL] [GPIO] How to use the GPIO from userspace</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454239#M70704</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sunny&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MX6SL_PAD_EPDC_D7_GPIO_1_14 pad is described in&lt;/P&gt;&lt;P&gt;sect.30.4.233 Pad Control Register (IOMUXC_SW_PAD_CTL_PAD_EPDC_DATA07)&lt;/P&gt;&lt;P&gt;i.MX6SL Reference Manual (rev.1&amp;nbsp; 5/2013)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-external-small" href="http://cache.freescale.com/files/32bit/doc/ref_manual/IMX6SLRM.pdf" rel="nofollow"&gt;http://cache.freescale.com/files/32bit/doc/ref_manual/IMX6SLRM.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards&lt;/P&gt;&lt;P&gt;igor&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 01:42:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454239#M70704</guid>
      <dc:creator>igorpadykov</dc:creator>
      <dc:date>2015-08-21T01:42:48Z</dc:date>
    </item>
    <item>
      <title>Re: [iMX6SL] [GPIO] How to use the GPIO from userspace</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454240#M70705</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Igor,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for sharing the iMX6SL RM. This helped.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 05:51:08 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454240#M70705</guid>
      <dc:creator>bhayani_sunny</dc:creator>
      <dc:date>2015-08-21T05:51:08Z</dc:date>
    </item>
    <item>
      <title>Re: [iMX6SL] [GPIO] How to use the GPIO from userspace</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454241#M70706</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the pointers. It helped.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I downloaded the &lt;STRONG&gt;iMX6SL RM&lt;/STRONG&gt; which Igor has mentioned below, and then I checked my &lt;STRONG&gt;EPDC_D7&lt;/STRONG&gt; pad and looked at the Bit settings for the whole pad name i.e. &lt;STRONG&gt;MX6SL_PAD_EPDC_D7__GPIO1_IO14&lt;/STRONG&gt; and there it is mentioned what each bit or bitfields mean i.e. Hys, PKE, PKU, Speed, DSE, etc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We need to manually calculate the whole 32-bit pad value by looking at the PAD Control Register of the corresponding Pad and enter it in the &lt;STRONG&gt;DTS&lt;/STRONG&gt; file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Below is snapshot for someone trying to look for the same:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="Screenshot from 2015-08-21 11_25_42.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/53760iEAAC35DF61F4E98F/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot from 2015-08-21 11_25_42.png" alt="Screenshot from 2015-08-21 11_25_42.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot for the info.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;BR /&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 05:53:44 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454241#M70706</guid>
      <dc:creator>bhayani_sunny</dc:creator>
      <dc:date>2015-08-21T05:53:44Z</dc:date>
    </item>
    <item>
      <title>Re: [iMX6SL] [GPIO] How to use the GPIO from userspace</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454242#M70707</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&amp;gt; Thanks for sharing the iMX6SL RM. This helped.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You should have been able to find this document yourself ages ago:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-external-small" href="http://www.freescale.com/" rel="nofollow"&gt;http://www.freescale.com/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Select "Products / i.MX Application Processors":&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-external-small" href="http://www.freescale.com/webapp/sps/site/homepage.jsp?code=IMX_HOME" rel="nofollow"&gt;http://www.freescale.com/webapp/sps/site/homepage.jsp?code=IMX_HOME&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Click on i.MX6SL Link and then click on "Documentation" tab:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-external-small" href="http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6SL&amp;amp;fpsp=1&amp;amp;tab=Documentation_Tab" rel="nofollow"&gt;http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6SL&amp;amp;fpsp=1&amp;amp;tab=Documentation_Tab&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Download ALL OF the Data Sheet, Reference Manual, Errata and App Notes. Read them.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Be careful when reading the Reference Manual. It should be better than the i.MX53 one, but there will still be a lot of errors in it, especially in the section detailing the pad multiplexors. For examples of what to look out for:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-message-small" data-containerid="2004" data-containertype="14" data-objectid="426929" data-objecttype="2" href="https://community.freescale.com/message/426929#426929"&gt;https://community.freescale.com/message/426929#426929&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-message-small" data-containerid="2004" data-containertype="14" data-objectid="425415" data-objecttype="2" href="https://community.freescale.com/message/425415#425415"&gt;https://community.freescale.com/message/425415#425415&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 06:08:24 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454242#M70707</guid>
      <dc:creator>TomE</dc:creator>
      <dc:date>2015-08-21T06:08:24Z</dc:date>
    </item>
    <item>
      <title>Re: [iMX6SL] [GPIO] How to use the GPIO from userspace</title>
      <link>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454243#M70708</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Tom,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the info.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It was really useful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If possible, can you please check the below thread:&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.nxp.com/thread/366736"&gt;[iMX6SLEVK] Executable generated using arm-poky-linux-gnueabi toolchain is giving -sh: ./testApp: No such file or direct…&lt;/A&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am trying to cross compile a tool with the arm-poky 1.7 toolchain.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am able to cross compile the tool. But when I run the executable, I get "&lt;EM&gt;No such file or directory error&lt;/EM&gt;".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I had tried to cross compile a simple helloworld.c code with the same toolchain and I had got the same "&lt;EM&gt;No such file or directory error&lt;/EM&gt;". Then I found few additional compiler arguments to be given in order to cross compile and then the helloworld.c worked.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I gave the same additional compiler arguments for the tool, but the generated executable is giving error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;BR /&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 21 Aug 2015 06:53:00 GMT</pubDate>
      <guid>https://community.nxp.com/t5/i-MX-Processors/iMX6SL-GPIO-How-to-use-the-GPIO-from-userspace/m-p/454243#M70708</guid>
      <dc:creator>bhayani_sunny</dc:creator>
      <dc:date>2015-08-21T06:53:00Z</dc:date>
    </item>
  </channel>
</rss>

