<?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>MPC5xxxのトピックRe: Problem with sending and receiving extended CAN frames</title>
    <link>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1330804#M19002</link>
    <description>&lt;P&gt;Short question about the EACEN bit. If it's set to 1, there should be not comparision with the received IDE bit, like in the initial post, right?&lt;/P&gt;&lt;P&gt;From reference manual (page 1725):&lt;/P&gt;&lt;P&gt;If the CAN_CTRL2[EACEN] bit is negated, the IDE bit of Mailbox is always compared with the IDE bit of the incoming&lt;BR /&gt;frame.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 27 Aug 2021 06:06:39 GMT</pubDate>
    <dc:creator>BenMW</dc:creator>
    <dc:date>2021-08-27T06:06:39Z</dc:date>
    <item>
      <title>Problem with sending and receiving extended CAN frames</title>
      <link>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1329405#M18989</link>
      <description>&lt;P&gt;I'm using the MPC5748G, and I am trying to send and receive an extended CAN frame and it doesn't work.&lt;BR /&gt;&lt;BR /&gt;I modified the provided example and use two boards to check. Sending standard frames works - I have issues only with extended frames.&lt;/P&gt;&lt;P&gt;Does anybody have any suggestions on what could be wrong? Are there any extra registers I need to take into consideration?&lt;BR /&gt;&lt;BR /&gt;The board that sends the CAN frame:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt; uint32_t len = 60;
 uint8_t data_2[60] = "weewweewpcslksdlkmqwkmqwpmpdqwmcposkpokmdsapmodapodasmpoasd";
uitn32_t messageId = 2;

/* Set information about the data to be sent
     *  - 60 byte in length
     *  - Extendend message ID
     *  - Bit rate switch enabled to use a different bitrate for the data segment
     *  - Flexible data rate enabled
     *  - Use zeros for FD padding
     */
    flexcan_data_info_t dataInfo =
    {
            .data_length = len,
            .msg_id_type = FLEXCAN_MSG_ID_EXT,
            .enable_brs  = false,
            .fd_enable   = true,
            .fd_padding  = 0U
    };

    /* Configure TX message buffer with index TX_MSG_ID and TX_MAILBOX*/
    FLEXCAN_DRV_ConfigTxMb(INST_CANCOM1, mailbox, &amp;amp;dataInfo, messageId);

    /* Execute send non-blocking */
    FLEXCAN_DRV_Send(INST_CANCOM1, mailbox, &amp;amp;dataInfo, messageId, data);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The receiving board:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="c"&gt;   /* Set information about the data to be received
     */
    flexcan_data_info_t dataInfo =
    {
            .data_length = 1U,
            .msg_id_type = FLEXCAN_MSG_ID_EXT,
            .enable_brs  = false,
            .fd_enable   = true,
            .fd_padding  = 0U
    };
    /* Configure RX message buffer with index RX_MSG_ID and RX_MAILBOX */
    FLEXCAN_DRV_ConfigRxMb(INST_CANCOM1, RX_MAILBOX, &amp;amp;dataInfo, RX_MSG_ID);

    /* clear the EACEN bit to recevie standard and extended IDE */
    CAN_0-&amp;gt;CTRL2 |= CAN_CTRL2_EACEN(1);

    /* set the Mask to receive all the messages     */
    FLEXCAN_DRV_SetRxMbGlobalMask(INST_CANCOM1, 0 ,0);


     flexcan_msgbuff_t recvBuff;
     /* Start receiving data in RX_MAILBOX. */
     FLEXCAN_DRV_Receive(INST_CANCOM1, RX_MAILBOX, &amp;amp;recvBuff);


      /* wait for the successful transmission of data */
        if(FLEXCAN_DRV_GetTransferStatus(INST_CANCOM1, RX_MAILBOX) == STATUS_SUCCESS){
            PINS_DRV_TogglePins(PTH, 0x2000); //toggle PH13
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 25 Aug 2021 12:49:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1329405#M18989</guid>
      <dc:creator>pmrlcbtcphtzjdq</dc:creator>
      <dc:date>2021-08-25T12:49:19Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with sending and receiving extended CAN frames</title>
      <link>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1329988#M18995</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;does extended frames mean frame with extended ID or CAN FD frame?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;CAN_0-&amp;gt;CTRL2 |= CAN_CTRL2_EACEN(1) sets EACEN bit, to clear it use&amp;nbsp;CAN_0-&amp;gt;CTRL2 &amp;amp;= ~CAN_CTRL2_EACEN(1);&lt;BR /&gt;If set it enables IDE and RTR bit compare with corresponding mask bits.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Check used masking scheme (MCR[IRMQ), if set use individual masking registers.&lt;/P&gt;
&lt;P&gt;If you cannot send a message check ECR/ESR1 registers.&lt;/P&gt;
&lt;P&gt;BR, Petr&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 26 Aug 2021 04:57:32 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1329988#M18995</guid>
      <dc:creator>PetrS</dc:creator>
      <dc:date>2021-08-26T04:57:32Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with sending and receiving extended CAN frames</title>
      <link>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1330804#M19002</link>
      <description>&lt;P&gt;Short question about the EACEN bit. If it's set to 1, there should be not comparision with the received IDE bit, like in the initial post, right?&lt;/P&gt;&lt;P&gt;From reference manual (page 1725):&lt;/P&gt;&lt;P&gt;If the CAN_CTRL2[EACEN] bit is negated, the IDE bit of Mailbox is always compared with the IDE bit of the incoming&lt;BR /&gt;frame.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 27 Aug 2021 06:06:39 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1330804#M19002</guid>
      <dc:creator>BenMW</dc:creator>
      <dc:date>2021-08-27T06:06:39Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with sending and receiving extended CAN frames</title>
      <link>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1330856#M19004</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;as per the RM&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="PetrS_0-1630048930654.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/154303iFC7E1A8942330366/image-size/medium?v=v2&amp;amp;px=400" role="button" title="PetrS_0-1630048930654.png" alt="PetrS_0-1630048930654.png" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;PetrS_0-1630048930654.png&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="PetrS_1-1630048939260.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/154304i4122B14156C1BE2D/image-size/medium?v=v2&amp;amp;px=400" role="button" title="PetrS_1-1630048939260.png" alt="PetrS_1-1630048939260.png" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;PetrS_1-1630048939260.png&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;If EACEN is set then bit30 of the mask register says if the IDE bit is don't care or not.&lt;BR /&gt;The same is valid for individual masking registers, if used.&lt;/P&gt;
&lt;P&gt;BR, Petr&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 27 Aug 2021 07:25:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1330856#M19004</guid>
      <dc:creator>PetrS</dc:creator>
      <dc:date>2021-08-27T07:25:42Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with sending and receiving extended CAN frames</title>
      <link>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1330863#M19005</link>
      <description>&lt;P&gt;Ok, thanks! After setting the RX mask with enabled bit 30, enter freeze mode, enable EACEN bit and exit freeze mode it works as expected&lt;/P&gt;</description>
      <pubDate>Fri, 27 Aug 2021 07:38:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MPC5xxx/Problem-with-sending-and-receiving-extended-CAN-frames/m-p/1330863#M19005</guid>
      <dc:creator>BenMW</dc:creator>
      <dc:date>2021-08-27T07:38:33Z</dc:date>
    </item>
  </channel>
</rss>

