<?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>S32 Design StudioのトピックS32R274 LIN  UART  can't send</title>
    <link>https://community.nxp.com/t5/S32-Design-Studio/S32R274-LIN-UART-can-t-send/m-p/812368#M3584</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a question about S32R274，I Send characters without interrupts But the program stays where the function is sent。Because I used the radar SDK, so LIN interrupt function mapping and interrupt priority I used the part of the radar SDK&lt;/P&gt;&lt;P&gt;Below is my initialization code and send code：&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;void uartCfgLIN(uint32_t baud_rate)&lt;BR /&gt;{&lt;BR /&gt; rsdkIsrRegisterParam_t irqStruct;&lt;/P&gt;&lt;P&gt;irqStruct.irqExecCore = RSDK_CURRENT_CORE;&lt;BR /&gt; irqStruct.pIrqHandler = &amp;amp;LIN1_rx_isr;&lt;BR /&gt; irqStruct.irqPriority = 7;&lt;BR /&gt; // SIUL Setup&lt;BR /&gt; SIUL2.MSCR[59].R = 0x12870002; // PAD59 / PD11 (BGA257, A13) SSS = 2 = LIN1_TXD&lt;BR /&gt; SIUL2.MSCR[95].R = 0x008C0000; // PAD95 / PF15 (BGA257, J17) input&lt;BR /&gt; SIUL2.IMCR[63].R = 3; // PAD95 / PF15 (BGA257, J17) SSS = 3 = LIN1_RXD&lt;/P&gt;&lt;P&gt;// UART Initialization&lt;BR /&gt; LINFlexD_1.LINCR1.R = 1; // exit sleep mode and enter initialization mode&lt;BR /&gt; baudRateSetupLIN(baud_rate, LINPS_CLK); // set desired baud rate&lt;BR /&gt; LINFlexD_1.UARTCR.R = 1; // enable UART mode first&lt;BR /&gt; LINFlexD_1.UARTCR.R = 0x00000033; // keep UART mode, WL = 01 = 8 bit word length, no parity control, transmitter&amp;amp;receiver enable, Tx&amp;amp;Rx buffer mode enable&lt;BR /&gt; LINFlexD_1.UARTSR.R = 0x0000FFFF; // clear all flags&lt;BR /&gt; LINFlexD_1.LINCR1.R = 0; // leave initialization mode, enter normal mode&lt;BR /&gt; RsdkRegisterIntcHandler(INTC_IRQ_OFFSET_LINFLEXD1_RX,&amp;amp;irqStruct);&lt;BR /&gt; LINFlexD_1.LINIER.R = 0x00000004; // disaable data transmission and enable reception interrupt&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;void my_putchar(char data)&lt;BR /&gt;{&lt;BR /&gt; LINFlexD_1.BDRL.R = data; // transmit data&lt;BR /&gt; while(LINFlexD_1.UARTSR.B.DTFTFF == 0 ); // wait for transmission complete&lt;BR /&gt; LINFlexD_1.UARTSR.R = 2; // clear DTF flag&lt;BR /&gt;}&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 07 Nov 2018 07:49:03 GMT</pubDate>
    <dc:creator>wanglongfeilf</dc:creator>
    <dc:date>2018-11-07T07:49:03Z</dc:date>
    <item>
      <title>S32R274 LIN  UART  can't send</title>
      <link>https://community.nxp.com/t5/S32-Design-Studio/S32R274-LIN-UART-can-t-send/m-p/812368#M3584</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a question about S32R274，I Send characters without interrupts But the program stays where the function is sent。Because I used the radar SDK, so LIN interrupt function mapping and interrupt priority I used the part of the radar SDK&lt;/P&gt;&lt;P&gt;Below is my initialization code and send code：&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;void uartCfgLIN(uint32_t baud_rate)&lt;BR /&gt;{&lt;BR /&gt; rsdkIsrRegisterParam_t irqStruct;&lt;/P&gt;&lt;P&gt;irqStruct.irqExecCore = RSDK_CURRENT_CORE;&lt;BR /&gt; irqStruct.pIrqHandler = &amp;amp;LIN1_rx_isr;&lt;BR /&gt; irqStruct.irqPriority = 7;&lt;BR /&gt; // SIUL Setup&lt;BR /&gt; SIUL2.MSCR[59].R = 0x12870002; // PAD59 / PD11 (BGA257, A13) SSS = 2 = LIN1_TXD&lt;BR /&gt; SIUL2.MSCR[95].R = 0x008C0000; // PAD95 / PF15 (BGA257, J17) input&lt;BR /&gt; SIUL2.IMCR[63].R = 3; // PAD95 / PF15 (BGA257, J17) SSS = 3 = LIN1_RXD&lt;/P&gt;&lt;P&gt;// UART Initialization&lt;BR /&gt; LINFlexD_1.LINCR1.R = 1; // exit sleep mode and enter initialization mode&lt;BR /&gt; baudRateSetupLIN(baud_rate, LINPS_CLK); // set desired baud rate&lt;BR /&gt; LINFlexD_1.UARTCR.R = 1; // enable UART mode first&lt;BR /&gt; LINFlexD_1.UARTCR.R = 0x00000033; // keep UART mode, WL = 01 = 8 bit word length, no parity control, transmitter&amp;amp;receiver enable, Tx&amp;amp;Rx buffer mode enable&lt;BR /&gt; LINFlexD_1.UARTSR.R = 0x0000FFFF; // clear all flags&lt;BR /&gt; LINFlexD_1.LINCR1.R = 0; // leave initialization mode, enter normal mode&lt;BR /&gt; RsdkRegisterIntcHandler(INTC_IRQ_OFFSET_LINFLEXD1_RX,&amp;amp;irqStruct);&lt;BR /&gt; LINFlexD_1.LINIER.R = 0x00000004; // disaable data transmission and enable reception interrupt&lt;BR /&gt;}&lt;/P&gt;&lt;P&gt;void my_putchar(char data)&lt;BR /&gt;{&lt;BR /&gt; LINFlexD_1.BDRL.R = data; // transmit data&lt;BR /&gt; while(LINFlexD_1.UARTSR.B.DTFTFF == 0 ); // wait for transmission complete&lt;BR /&gt; LINFlexD_1.UARTSR.R = 2; // clear DTF flag&lt;BR /&gt;}&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Nov 2018 07:49:03 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32-Design-Studio/S32R274-LIN-UART-can-t-send/m-p/812368#M3584</guid>
      <dc:creator>wanglongfeilf</dc:creator>
      <dc:date>2018-11-07T07:49:03Z</dc:date>
    </item>
  </channel>
</rss>

