<?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>topic Re: LPC55x I2C Flexcomm2 PIO1_27 in LPC Microcontrollers</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1644293#M52380</link>
    <description>&lt;P&gt;Hi&amp;nbsp;xiangjun, thank you for the reply. For reference the code is being run on lpc55s28-evk. The pin config code was generated using MCUXpresso config tool v12.1&lt;/P&gt;&lt;P&gt;I have attempted to use the suggested code to no improvement.&lt;/P&gt;&lt;P&gt;Here is the original non-working config and the modified working config&lt;/P&gt;&lt;P&gt;not working&lt;BR /&gt;============================&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;/*!
 * @brief Select Digital mode.: Enable Digital mode. Digital input is enabled. */
#define PIO1_24_DIGIMODE_DIGITAL 0x01u
/*!
 * @brief Selects pin function.: Alternative connection 1. */
#define PIO1_24_FUNC_ALT1 0x01u
/*!
 * @brief Select Digital mode.: Enable Digital mode. Digital input is enabled. */
#define PIO1_27_DIGIMODE_DIGITAL 0x01u
/*!
 * @brief Selects pin function.: Alternative connection 1. */
#define PIO1_27_FUNC_ALT1 0x01u


    IOCON-&amp;gt;PIO[1][24] = ((IOCON-&amp;gt;PIO[1][24] &amp;amp;
                          /* Mask bits to zero which are setting */
                          (~(IOCON_PIO_FUNC_MASK | IOCON_PIO_DIGIMODE_MASK)))

                         /* Selects pin function.
                          * : PORT124 (pin F6) is configured as FC2_RXD_SDA_MOSI_DATA. */
                         | IOCON_PIO_FUNC(PIO1_24_FUNC_ALT1)

                         /* Select Digital mode.
                          * : Enable Digital mode.
                          * Digital input is enabled. */
                         | IOCON_PIO_DIGIMODE(PIO1_24_DIGIMODE_DIGITAL));


    IOCON-&amp;gt;PIO[1][27] = ((IOCON-&amp;gt;PIO[1][27] &amp;amp;
                          /* Mask bits to zero which are setting */
                          (~(IOCON_PIO_FUNC_MASK | IOCON_PIO_DIGIMODE_MASK)))

                         /* Selects pin function.
                          * : PORT127 (pin E8) is configured as FC2_RTS_SCL_SSEL1. */
                         | IOCON_PIO_FUNC(PIO1_27_FUNC_ALT1)

                         /* Select Digital mode.
                          * : Enable Digital mode.
                          * Digital input is enabled. */
                         | IOCON_PIO_DIGIMODE(PIO1_27_DIGIMODE_DIGITAL));&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;============================&lt;/P&gt;&lt;P&gt;working&lt;BR /&gt;============================&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;/*!
 * @brief Select Digital mode.: Enable Digital mode. Digital input is enabled. */
#define PIO1_24_DIGIMODE_DIGITAL 0x01u
/*!
 * @brief Selects pin function.: Alternative connection 1. */
#define PIO1_24_FUNC_ALT1 0x01u
/*!
 * @brief Select Digital mode.: Enable Digital mode. Digital input is enabled. */
#define PIO1_27_DIGIMODE_DIGITAL 0x01u
/*!
 * @brief Selects pin function.: Alternative connection 1. */
#define PIO1_27_FUNC_ALT1 0x01u

    IOCON-&amp;gt;PIO[1][24] = ((IOCON-&amp;gt;PIO[1][24] &amp;amp;
                          /* Mask bits to zero which are setting */
                          (~(IOCON_PIO_FUNC_MASK | IOCON_PIO_DIGIMODE_MASK)))

                         /* Selects pin function.
                          * : PORT124 (pin F6) is configured as FC2_RXD_SDA_MOSI_DATA. */
                         | IOCON_PIO_FUNC(PIO1_24_FUNC_ALT1)

                         /* Select Digital mode.
                          * : Enable Digital mode.
                          * Digital input is enabled. */
                         | IOCON_PIO_DIGIMODE(PIO1_24_DIGIMODE_DIGITAL));


    IOCON-&amp;gt;PIO[1][25] = ((IOCON-&amp;gt;PIO[1][25] &amp;amp;
                          /* Mask bits to zero which are setting */
                          (~(IOCON_PIO_FUNC_MASK | IOCON_PIO_DIGIMODE_MASK)))

                         /* Selects pin function.
                          * : PORT127 (pin E8) is configured as FC2_RTS_SCL_SSEL1. */
                         | IOCON_PIO_FUNC(PIO1_27_FUNC_ALT1)

                         /* Select Digital mode.
                          * : Enable Digital mode.
                          * Digital input is enabled. */
                         | IOCON_PIO_DIGIMODE(PIO1_27_DIGIMODE_DIGITAL));&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;============================&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
    <pubDate>Thu, 04 May 2023 06:01:07 GMT</pubDate>
    <dc:creator>lsl</dc:creator>
    <dc:date>2023-05-04T06:01:07Z</dc:date>
    <item>
      <title>LPC55x I2C Flexcomm2 PIO1_27</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1643353#M52360</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I2C on Flexcomm2 using PIO1_24 as SDA and&amp;nbsp;PIO1_27 as SCL results in a non-functional setup, while&amp;nbsp;I2C on Flexcomm2 using PIO1_24 as SDA and&amp;nbsp;PIO1_25 as SCL results in a functional setup.&lt;/P&gt;&lt;P&gt;Why does it not function with&amp;nbsp;PIO1_27, while the MCU config tool indicates legitimate setup?&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Wed, 03 May 2023 03:00:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1643353#M52360</guid>
      <dc:creator>lsl</dc:creator>
      <dc:date>2023-05-03T03:00:48Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55x I2C Flexcomm2 PIO1_27</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1644213#M52378</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;First of all,l I suppose that you use LPC551x/LPC55S1x processor, regarding your question that you can not function the PIO1_27 as FC2_SCL, I suppose that you do not configure the pin PIO1_27 correctly.&lt;/P&gt;
&lt;P&gt;Pls try to use the code in pin_mux.c in SDK example like:&lt;/P&gt;
&lt;P&gt;/* Enables the clock for the IOCON block. 0 = Disable; 1 = Enable.: 0x01u */&lt;BR /&gt;CLOCK_EnableClock(kCLOCK_Iocon);&lt;/P&gt;
&lt;P&gt;//PIO1_27 FC2_RTS_SCL_SSEL1&lt;/P&gt;
&lt;P&gt;#define IOCON_PIO_FUNC1 1&lt;/P&gt;
&lt;P&gt;#define IOCON_PIO_OPENDRAIN_EI 0x200&lt;/P&gt;
&lt;P&gt;const uint32_t PIO1_27 = (/* Pin is configured as PIO1_27 */&lt;BR /&gt;IOCON_PIO_FUNC1 |&lt;BR /&gt;/* Selects pull-up function */&lt;BR /&gt;IOCON_PIO_MODE_PULLUP |&lt;BR /&gt;/* Input function is not inverted */&lt;BR /&gt;IOCON_PIO_INV_DI |&lt;BR /&gt;/* Enables digital function */&lt;BR /&gt;IOCON_PIO_DIGITAL_EN |&lt;BR /&gt;/* Input filter disabled */&lt;BR /&gt;IOCON_PIO_INPFILT_OFF |&lt;BR /&gt;/* Standard mode, output slew rate control is enabled */&lt;BR /&gt;IOCON_PIO_SLEW_STANDARD |&lt;BR /&gt;/* Open drain is disabled */&lt;BR /&gt;IOCON_PIO_OPENDRAIN_EI);&lt;BR /&gt;&lt;BR /&gt;IOCON_PinMuxSet(IOCON, 1, 27, PIO1_27 );&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Pls have a try.&lt;/P&gt;
&lt;P&gt;If you still have problem, pls check the IOCON-&amp;gt;PIO[1][27] register in debugger.&lt;/P&gt;
&lt;P&gt;I suppose that you have to connect a 10K ohm pull-up register for the PIO1_27 pin.&lt;/P&gt;
&lt;P&gt;Hope it can help you&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 04 May 2023 03:40:53 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1644213#M52378</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2023-05-04T03:40:53Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55x I2C Flexcomm2 PIO1_27</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1644293#M52380</link>
      <description>&lt;P&gt;Hi&amp;nbsp;xiangjun, thank you for the reply. For reference the code is being run on lpc55s28-evk. The pin config code was generated using MCUXpresso config tool v12.1&lt;/P&gt;&lt;P&gt;I have attempted to use the suggested code to no improvement.&lt;/P&gt;&lt;P&gt;Here is the original non-working config and the modified working config&lt;/P&gt;&lt;P&gt;not working&lt;BR /&gt;============================&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;/*!
 * @brief Select Digital mode.: Enable Digital mode. Digital input is enabled. */
#define PIO1_24_DIGIMODE_DIGITAL 0x01u
/*!
 * @brief Selects pin function.: Alternative connection 1. */
#define PIO1_24_FUNC_ALT1 0x01u
/*!
 * @brief Select Digital mode.: Enable Digital mode. Digital input is enabled. */
#define PIO1_27_DIGIMODE_DIGITAL 0x01u
/*!
 * @brief Selects pin function.: Alternative connection 1. */
#define PIO1_27_FUNC_ALT1 0x01u


    IOCON-&amp;gt;PIO[1][24] = ((IOCON-&amp;gt;PIO[1][24] &amp;amp;
                          /* Mask bits to zero which are setting */
                          (~(IOCON_PIO_FUNC_MASK | IOCON_PIO_DIGIMODE_MASK)))

                         /* Selects pin function.
                          * : PORT124 (pin F6) is configured as FC2_RXD_SDA_MOSI_DATA. */
                         | IOCON_PIO_FUNC(PIO1_24_FUNC_ALT1)

                         /* Select Digital mode.
                          * : Enable Digital mode.
                          * Digital input is enabled. */
                         | IOCON_PIO_DIGIMODE(PIO1_24_DIGIMODE_DIGITAL));


    IOCON-&amp;gt;PIO[1][27] = ((IOCON-&amp;gt;PIO[1][27] &amp;amp;
                          /* Mask bits to zero which are setting */
                          (~(IOCON_PIO_FUNC_MASK | IOCON_PIO_DIGIMODE_MASK)))

                         /* Selects pin function.
                          * : PORT127 (pin E8) is configured as FC2_RTS_SCL_SSEL1. */
                         | IOCON_PIO_FUNC(PIO1_27_FUNC_ALT1)

                         /* Select Digital mode.
                          * : Enable Digital mode.
                          * Digital input is enabled. */
                         | IOCON_PIO_DIGIMODE(PIO1_27_DIGIMODE_DIGITAL));&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;============================&lt;/P&gt;&lt;P&gt;working&lt;BR /&gt;============================&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;/*!
 * @brief Select Digital mode.: Enable Digital mode. Digital input is enabled. */
#define PIO1_24_DIGIMODE_DIGITAL 0x01u
/*!
 * @brief Selects pin function.: Alternative connection 1. */
#define PIO1_24_FUNC_ALT1 0x01u
/*!
 * @brief Select Digital mode.: Enable Digital mode. Digital input is enabled. */
#define PIO1_27_DIGIMODE_DIGITAL 0x01u
/*!
 * @brief Selects pin function.: Alternative connection 1. */
#define PIO1_27_FUNC_ALT1 0x01u

    IOCON-&amp;gt;PIO[1][24] = ((IOCON-&amp;gt;PIO[1][24] &amp;amp;
                          /* Mask bits to zero which are setting */
                          (~(IOCON_PIO_FUNC_MASK | IOCON_PIO_DIGIMODE_MASK)))

                         /* Selects pin function.
                          * : PORT124 (pin F6) is configured as FC2_RXD_SDA_MOSI_DATA. */
                         | IOCON_PIO_FUNC(PIO1_24_FUNC_ALT1)

                         /* Select Digital mode.
                          * : Enable Digital mode.
                          * Digital input is enabled. */
                         | IOCON_PIO_DIGIMODE(PIO1_24_DIGIMODE_DIGITAL));


    IOCON-&amp;gt;PIO[1][25] = ((IOCON-&amp;gt;PIO[1][25] &amp;amp;
                          /* Mask bits to zero which are setting */
                          (~(IOCON_PIO_FUNC_MASK | IOCON_PIO_DIGIMODE_MASK)))

                         /* Selects pin function.
                          * : PORT127 (pin E8) is configured as FC2_RTS_SCL_SSEL1. */
                         | IOCON_PIO_FUNC(PIO1_27_FUNC_ALT1)

                         /* Select Digital mode.
                          * : Enable Digital mode.
                          * Digital input is enabled. */
                         | IOCON_PIO_DIGIMODE(PIO1_27_DIGIMODE_DIGITAL));&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;============================&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
      <pubDate>Thu, 04 May 2023 06:01:07 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1644293#M52380</guid>
      <dc:creator>lsl</dc:creator>
      <dc:date>2023-05-04T06:01:07Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55x I2C Flexcomm2 PIO1_27</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1644361#M52385</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;Pls refer to the IOCON module, I suppose that you have to set the OD bit(bit 9) and the DIGIMODE bit(bit 8), and connect external pull-up resistor.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="xiangjun_rong_0-1683183409842.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/221671iF8B914D1ACADB4F7/image-size/medium?v=v2&amp;amp;px=400" role="button" title="xiangjun_rong_0-1683183409842.png" alt="xiangjun_rong_0-1683183409842.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Pls have a try&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 04 May 2023 06:59:14 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1644361#M52385</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2023-05-04T06:59:14Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55x I2C Flexcomm2 PIO1_27</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1644828#M52398</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hi&amp;nbsp;xiangjun, thank you for the reply.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I have attempted to use the suggested pin settings to no improvement.&lt;/SPAN&gt;&lt;/P&gt;&lt;PRE&gt;/* Enables the clock for the IOCON block. 0 = Disable; 1 = Enable.: 0x01u */
CLOCK_EnableClock(kCLOCK_Iocon);

//PIO1_27 FC2_RTS_SCL_SSEL1

#define IOCON_PIO_FUNC1 1

#define IOCON_PIO_OPENDRAIN_EI 0x200

const uint32_t PIO1_27 = (/* Pin is configured as PIO1_27 */
IOCON_PIO_FUNC1 |
/* Selects pull-up function */
IOCON_PIO_MODE_PULLUP |
/* Input function is not inverted */
IOCON_PIO_INV_DI |
/* Enables digital function */
IOCON_PIO_DIGITAL_EN |
/* Input filter disabled */
IOCON_PIO_INPFILT_OFF |
/* Standard mode, output slew rate control is enabled */
IOCON_PIO_SLEW_STANDARD |
/* Open drain is disabled */
IOCON_PIO_OPENDRAIN_EI);

IOCON_PinMuxSet(IOCON, 1, 27, PIO1_27 );&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
      <pubDate>Thu, 04 May 2023 15:49:44 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1644828#M52398</guid>
      <dc:creator>lsl</dc:creator>
      <dc:date>2023-05-04T15:49:44Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55x I2C Flexcomm2 PIO1_27</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1645155#M52408</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I think the pin configuration is correct.&lt;/P&gt;
&lt;P&gt;On the LPC5528-EVK board, the PIO1_27 is connected to the codec, I do not know if it takes effect on the feature of PIO1_27, pls remove the R24 and have a try.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="xiangjun_rong_0-1683254615794.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/221887i3B9851D34F7F0B0F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="xiangjun_rong_0-1683254615794.png" alt="xiangjun_rong_0-1683254615794.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Hope it can help you&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 May 2023 02:45:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1645155#M52408</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2023-05-05T02:45:12Z</dc:date>
    </item>
    <item>
      <title>Re: LPC55x I2C Flexcomm2 PIO1_27</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1646524#M52447</link>
      <description>&lt;P&gt;Hi&amp;nbsp;XiangJun,&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;this was the issue. It now functions.&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 08 May 2023 16:57:06 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/LPC55x-I2C-Flexcomm2-PIO1-27/m-p/1646524#M52447</guid>
      <dc:creator>lsl</dc:creator>
      <dc:date>2023-05-08T16:57:06Z</dc:date>
    </item>
  </channel>
</rss>

