<?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>LPC MicrocontrollersのトピックRe: problems with UI</title>
    <link>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1284564#M45231</link>
    <description>&lt;P&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I see that you use LPCXpressos55S69 board, on the board, the P0_29/P0_30 are connected to P8 on the board.&lt;/SPAN&gt; If you want to use the uart0 receiver function, you have to disable the switch by closing the P1.&lt;/P&gt;
&lt;P&gt;Pls connect the P8 signals to scope and check if there is uart0 transmitting signal on the FC0_USART_TXD 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;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="xiangjun_rong_0-1622443479411.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/145859i01AD8624869AE928/image-size/medium?v=v2&amp;amp;px=400" role="button" title="xiangjun_rong_0-1622443479411.png" alt="xiangjun_rong_0-1622443479411.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&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_1-1622443692799.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/145860iD3BEA838DBCE3E1D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="xiangjun_rong_1-1622443692799.png" alt="xiangjun_rong_1-1622443692799.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 31 May 2021 06:49:52 GMT</pubDate>
    <dc:creator>xiangjun_rong</dc:creator>
    <dc:date>2021-05-31T06:49:52Z</dc:date>
    <item>
      <title>problems with UI</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1283746#M45190</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I can't seem to get the UART to work. I have a pin on the TX on my scope. It is always high at 4V.&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is my UART init&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;void USART_Init(USART_Type *base, const usart_config_t *config, uint32_t srcClock_Hz)&lt;BR /&gt;{&lt;BR /&gt;/* Check arguments */&lt;BR /&gt;assert(!((NULL == base) || (NULL == config) || (0 == srcClock_Hz)));&lt;/P&gt;&lt;P&gt;uint32_t instance = USART_GetInstance(base);&lt;/P&gt;&lt;P&gt;CLOCK_EnableClock(s_usartClock[instance]);&lt;/P&gt;&lt;P&gt;RESET_PeripheralReset(s_usartRest[instance]);&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;/* Setup configuration and enable USART to configure other register. */&lt;BR /&gt;base-&amp;gt;CFG = USART_CFG_PARITYSEL(config-&amp;gt;parityMode) | USART_CFG_STOPLEN(config-&amp;gt;stopBitCount) |&lt;BR /&gt;USART_CFG_SYNCEN(config-&amp;gt;syncMode &amp;gt;&amp;gt; 1) | USART_CFG_DATALEN(config-&amp;gt;bitCountPerChar) |&lt;BR /&gt;USART_CFG_LOOP(config-&amp;gt;loopback) | USART_CFG_SYNCMST(config-&amp;gt;syncMode) | USART_CFG_ENABLE_MASK;&lt;/P&gt;&lt;P&gt;// /* Setup the USART transmit and receive. */&lt;BR /&gt;// USART_EnableTx(base, config-&amp;gt;enableTx);&lt;BR /&gt;// USART_EnableRx(base, config-&amp;gt;enableRx);&lt;/P&gt;&lt;P&gt;if (config-&amp;gt;enableTx)&lt;BR /&gt;{&lt;BR /&gt;/* empty and enable txFIFO */&lt;BR /&gt;base-&amp;gt;FIFOCFG |= USART_FIFOCFG_EMPTYTX_MASK | USART_FIFOCFG_ENABLETX_MASK;&lt;BR /&gt;/* setup trigger level */&lt;BR /&gt;base-&amp;gt;FIFOTRIG &amp;amp;= ~(USART_FIFOTRIG_TXLVL_MASK);&lt;BR /&gt;base-&amp;gt;FIFOTRIG |= USART_FIFOTRIG_TXLVL(config-&amp;gt;txWatermark);&lt;BR /&gt;/* enable trigger interrupt */&lt;BR /&gt;base-&amp;gt;FIFOTRIG |= USART_FIFOTRIG_TXLVLENA_MASK;&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;/* empty and enable rxFIFO */&lt;BR /&gt;if (config-&amp;gt;enableRx)&lt;BR /&gt;{&lt;BR /&gt;base-&amp;gt;FIFOCFG |= USART_FIFOCFG_EMPTYRX_MASK | USART_FIFOCFG_ENABLERX_MASK;&lt;BR /&gt;/* setup trigger level */&lt;BR /&gt;base-&amp;gt;FIFOTRIG &amp;amp;= ~(USART_FIFOTRIG_RXLVL_MASK);&lt;BR /&gt;base-&amp;gt;FIFOTRIG |= USART_FIFOTRIG_RXLVL(config-&amp;gt;rxWatermark);&lt;BR /&gt;/* enable trigger interrupt */&lt;BR /&gt;base-&amp;gt;FIFOTRIG |= USART_FIFOTRIG_RXLVLENA_MASK;&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;// //select the desirecd flexcom by writing to the pselid&lt;BR /&gt;// SYSCON-&amp;gt;PRESETCTRLX[0] = SYSCON_AHBCLKCTRL1_FC0(1); //enable clock for FC)&lt;BR /&gt;//&lt;BR /&gt;// //configure the fifos&lt;BR /&gt;// //uart receive data AHBCLKCCRTRL1 - set it to the flexxcomm&lt;BR /&gt;// SYSCON-&amp;gt;AHBCLKCTRLX[1] = SYSCON_AHBCLKCTRL1_FC0(1); //enable clock for FC)&lt;/P&gt;&lt;P&gt;base-&amp;gt;BRG = 9600U / config-&amp;gt;baudRate_Bps;&lt;BR /&gt;//base-&amp;gt;OSR = USART_OSR_VALUE;&lt;/P&gt;&lt;P&gt;/* Enables the clock for the I/O controller.: Enable Clock. */&lt;BR /&gt;CLOCK_EnableClock(kCLOCK_Iocon);&lt;/P&gt;&lt;P&gt;//pin config&lt;BR /&gt;uint32_t uart_pin_config = ( 0x1 | //pin function 1&lt;BR /&gt;/* No addition pin function */&lt;BR /&gt;(0x0 &amp;lt;&amp;lt; IOCON_PIO_MODE_SHIFT) |/* Standard mode, output slew rate control is enabled */&lt;BR /&gt;(0x0 &amp;lt;&amp;lt; IOCON_PIO_SLEW_SHIFT) |&lt;BR /&gt;/* Enables digital function */&lt;BR /&gt;(0x1 &amp;lt;&amp;lt; IOCON_PIO_DIGIMODE_SHIFT));&lt;BR /&gt;IOCON-&amp;gt;PIO[0][29] = uart_pin_config;&lt;/P&gt;&lt;P&gt;/* PORT0 PIN30 (coords: 94) is configured as FC0_TXD_SCL_MISO_WS */&lt;BR /&gt;IOCON-&amp;gt;PIO[0][30] = uart_pin_config;&lt;/P&gt;&lt;P&gt;base-&amp;gt;FIFOCFG |= USART_FIFOCFG_ENABLETX_MASK;&lt;BR /&gt;base-&amp;gt;FIFOCFG |= USART_FIFOCFG_ENABLERX_MASK;&lt;/P&gt;&lt;P&gt;//pending interupt&lt;BR /&gt;/* Enable RX interrupt. */&lt;BR /&gt;EnableIRQ(FLEXCOMM0_IRQn);&lt;BR /&gt;//NVIC_EnableIRQ();&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;This is how I am setting it up in main&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;//flexcomm clock attach 12 MHz clock to FLEXCOMM0 (debug console)&lt;BR /&gt;CLOCK_AttachClk(kFRO12M_to_FLEXCOMM0);&lt;/P&gt;&lt;P&gt;RESET_ClearPeripheralReset(kFC0_RST_SHIFT_RSTn);&lt;/P&gt;&lt;P&gt;//peripheral select and lock flexcomm interface ID register&lt;BR /&gt;FLEXCOMM0-&amp;gt;PSELID = FLEXCOMM_PSELID_PERSEL(0x01) | FLEXCOMM_PSELID_LOCK_MASK;&lt;/P&gt;&lt;P&gt;USART_GetDefaultConfig(&amp;amp;config);&lt;BR /&gt;config.baudRate_Bps = BOARD_DEBUG_UART_BAUDRATE;&lt;BR /&gt;config.enableTx = true;&lt;BR /&gt;config.enableRx = true;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;USART_Init(USART, &amp;amp;config, USART_CLK_FREQ);&lt;/P&gt;&lt;P&gt;/* Send string out. */&lt;BR /&gt;USART_WriteBlocking(USART, testString, (sizeof(testString) - 1));&lt;/P&gt;&lt;P&gt;while (1)&lt;BR /&gt;{&lt;BR /&gt;USART_ReadBlocking(USART, &amp;amp;ch, 1);&lt;BR /&gt;USART_WriteBlocking(USART, &amp;amp;ch, 1);&lt;BR /&gt;}&lt;/P&gt;&lt;/BLOCKQUOTE&gt;</description>
      <pubDate>Thu, 27 May 2021 23:36:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1283746#M45190</guid>
      <dc:creator>ida</dc:creator>
      <dc:date>2021-05-27T23:36:35Z</dc:date>
    </item>
    <item>
      <title>Re: problems with UI</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1283923#M45202</link>
      <description>&lt;P&gt;Hi, Ida,&lt;/P&gt;
&lt;P&gt;First of all, can you tell us the part number you are using?&lt;/P&gt;
&lt;P&gt;Secondly, I have not seen the pin assignment code for the FlexComm module as usart, pls tell us the usart_TX/usart_RX pin number. Generally, it is the code like:&lt;/P&gt;
&lt;P&gt;void BOARD_InitPins(void)&lt;BR /&gt;{&lt;BR /&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;const uint32_t port0_pin29_config = (/* Pin is configured as FC0_RXD_SDA_MOSI */&lt;BR /&gt;IOCON_PIO_FUNC1 |&lt;BR /&gt;/* No addition pin function */&lt;BR /&gt;IOCON_PIO_MODE_INACT |&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_DI);&lt;BR /&gt;/* PORT0 PIN29 (coords: B13) is configured as FC0_RXD_SDA_MOSI */&lt;BR /&gt;IOCON_PinMuxSet(IOCON, 0U, 29U, port0_pin29_config);&lt;/P&gt;
&lt;P&gt;const uint32_t port0_pin30_config = (/* Pin is configured as FC0_TXD_SCL_MISO */&lt;BR /&gt;IOCON_PIO_FUNC1 |&lt;BR /&gt;/* No addition pin function */&lt;BR /&gt;IOCON_PIO_MODE_INACT |&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_DI);&lt;BR /&gt;/* PORT0 PIN30 (coords: A2) is configured as FC0_TXD_SCL_MISO */&lt;BR /&gt;IOCON_PinMuxSet(IOCON, 0U, 30U, port0_pin30_config);&lt;/P&gt;
&lt;P&gt;}&lt;/P&gt;
&lt;P&gt;Thirdly, pls comment the receiving part like this so that you can test only the usart_TX pin&lt;/P&gt;
&lt;P&gt;while (1)&lt;BR /&gt;{&lt;BR /&gt;//USART_ReadBlocking(USART, &amp;amp;ch, 1);&lt;BR /&gt;USART_WriteBlocking(USART, &amp;amp;ch, 1);&lt;BR /&gt;}&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&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;</description>
      <pubDate>Fri, 28 May 2021 06:42:28 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1283923#M45202</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2021-05-28T06:42:28Z</dc:date>
    </item>
    <item>
      <title>Re: problems with UI</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1284335#M45223</link>
      <description>&lt;P&gt;&amp;nbsp;Hi&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using the LPCXpressos55S69 board. I am probing the TX pin output on P2 on the board.&lt;/P&gt;</description>
      <pubDate>Fri, 28 May 2021 23:43:37 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1284335#M45223</guid>
      <dc:creator>ida</dc:creator>
      <dc:date>2021-05-28T23:43:37Z</dc:date>
    </item>
    <item>
      <title>Re: problems with UI</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1284337#M45224</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;    /* Enables the clock for the I/O controller.: Enable Clock. */
    CLOCK_EnableClock(kCLOCK_Iocon);

    //pin config
    uint32_t uart_pin_config = (  0x1  | //pin function 1
                                 /* No addition pin function */
                                 (0x0 &amp;lt;&amp;lt; IOCON_PIO_MODE_SHIFT) |
                                 /* Standard mode, output slew rate control is enabled */
                                 (0x0 &amp;lt;&amp;lt; IOCON_PIO_SLEW_SHIFT) |
                                 /* Enables digital function */
                                 (0x1 &amp;lt;&amp;lt; IOCON_PIO_DIGIMODE_SHIFT));
    IOCON-&amp;gt;PIO[0][29] = uart_pin_config;

    /* PORT0 PIN30 (coords: 94) is configured as FC0_TXD_SCL_MISO_WS */
    IOCON-&amp;gt;PIO[0][30] = uart_pin_config;&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 28 May 2021 23:48:20 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1284337#M45224</guid>
      <dc:creator>ida</dc:creator>
      <dc:date>2021-05-28T23:48:20Z</dc:date>
    </item>
    <item>
      <title>Re: problems with UI</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1284564#M45231</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I see that you use LPCXpressos55S69 board, on the board, the P0_29/P0_30 are connected to P8 on the board.&lt;/SPAN&gt; If you want to use the uart0 receiver function, you have to disable the switch by closing the P1.&lt;/P&gt;
&lt;P&gt;Pls connect the P8 signals to scope and check if there is uart0 transmitting signal on the FC0_USART_TXD 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;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="xiangjun_rong_0-1622443479411.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/145859i01AD8624869AE928/image-size/medium?v=v2&amp;amp;px=400" role="button" title="xiangjun_rong_0-1622443479411.png" alt="xiangjun_rong_0-1622443479411.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&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_1-1622443692799.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/145860iD3BEA838DBCE3E1D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="xiangjun_rong_1-1622443692799.png" alt="xiangjun_rong_1-1622443692799.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 31 May 2021 06:49:52 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1284564#M45231</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2021-05-31T06:49:52Z</dc:date>
    </item>
    <item>
      <title>Re: problems with UI</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1285580#M45249</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Sorry I misread the board. Yes I was always probing P8 and the TX pin. I've now added the jumper to P1. It now shows me the TX pin (next to ground) is 0 v always. Don't see it change at all.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jun 2021 18:35:29 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1285580#M45249</guid>
      <dc:creator>ida</dc:creator>
      <dc:date>2021-06-01T18:35:29Z</dc:date>
    </item>
    <item>
      <title>Re: problems with UI</title>
      <link>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1286046#M45254</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;Can you use the example in the SDK package? if you select uart, the example use uart0 module.&lt;/P&gt;
&lt;P&gt;BR&lt;/P&gt;
&lt;P&gt;XiangJun Rong&lt;/P&gt;</description>
      <pubDate>Wed, 02 Jun 2021 10:21:41 GMT</pubDate>
      <guid>https://community.nxp.com/t5/LPC-Microcontrollers/problems-with-UI/m-p/1286046#M45254</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2021-06-02T10:21:41Z</dc:date>
    </item>
  </channel>
</rss>

