<?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:  CAN communication at 1 Mb/s in S12 / MagniV Microcontrollers</title>
    <link>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/CAN-communication-at-1-Mb-s/m-p/1006048#M16931</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Radek used older version of the calculator where I programmed the sample point as close as possible&amp;nbsp; to 50%. Moreover, I am not sure whether he used the right version. There was some error I can not remember.&lt;/P&gt;&lt;P&gt;Here is a calculation he probably used (after my call with him):&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_2.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/99749iE40CBF1AFB64B134/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_2.png" alt="pastedImage_2.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want to follow changes you can change Propagation delay of the interface, bus length, sample point,...the changes are clearly visible in the right part of the table -&amp;gt; length of segment changes.&lt;/P&gt;&lt;P&gt;If I use TJA1040 propagation delay 255ns, different bus length and &lt;STRONG&gt;sample point 80%&lt;/STRONG&gt; then relations between values change.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_7.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/99918i873E98853E944EEF/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_7.png" alt="pastedImage_7.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So that's the reason.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note:&amp;nbsp; You can see better oscillator must be used in the second case.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Ladislav&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 28 Jan 2020 13:22:05 GMT</pubDate>
    <dc:creator>lama</dc:creator>
    <dc:date>2020-01-28T13:22:05Z</dc:date>
    <item>
      <title>CAN communication at 1 Mb/s</title>
      <link>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/CAN-communication-at-1-Mb-s/m-p/1006047#M16930</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 a 9s12XEQ384 running on a 5 MHz resonator and I have CAN communication using TJA1040 and TJA1042 that works at 250 Kb/s and 500 Kb/s.&lt;BR /&gt;I now need to make it work at 1 Mb/s.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can see that I need to change my 5 MHz resonator to a 8 MHz resonator.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now the settings for CAN_BTR0 and CAN_BTR1 is where I am confused.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For 250 Kb/s I have&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#define&amp;nbsp;&amp;nbsp; &amp;nbsp;BTR0_250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;0x41&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// 5 MHz reference&lt;BR /&gt;#define&amp;nbsp;&amp;nbsp;&amp;nbsp; BTR1_250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x34&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// Sample at 4 / 5 = 80%&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for 500 Kb/s I have&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#define&amp;nbsp;&amp;nbsp; &amp;nbsp;BTR0_500&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;0xC0&lt;/STRONG&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// Suggested by Radek - Works&lt;BR /&gt;#define &amp;nbsp;&amp;nbsp; BTR1_500&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x34&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// Suggested by Radek - Works&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When I use your CAN calculator (ver 7) I get&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#define&amp;nbsp;&amp;nbsp; &amp;nbsp;BTR0_1000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x40&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // 8 MHz reference&lt;BR /&gt;#define&amp;nbsp;&amp;nbsp; &amp;nbsp;BTR1_1000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x94&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;// 3 samples / bit&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But when I go back to using a 5 MHz resonator on the calculator it says&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For 250 Kb/s&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#define&amp;nbsp;&amp;nbsp; &amp;nbsp;BTR0_250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;0x41&lt;/STRONG&gt;&lt;BR /&gt;#define &amp;nbsp;&amp;nbsp; BTR1_250&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x16&amp;nbsp;&amp;nbsp; &amp;nbsp;or &amp;nbsp;&amp;nbsp; &amp;nbsp;0x96&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for 500 Kb/s&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;#define&amp;nbsp;&amp;nbsp; &amp;nbsp;BTR0_500&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;STRONG&gt;0x40&lt;/STRONG&gt;&lt;BR /&gt;#define&amp;nbsp;&amp;nbsp;&amp;nbsp; BTR1_500&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0x16&amp;nbsp;&amp;nbsp; &amp;nbsp;or &amp;nbsp;&amp;nbsp; &amp;nbsp;0x96&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now I have confirmed the 250 and 500 KB/s as working using CAN_BTR1 = 0x34&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So which is correct?&amp;nbsp; And should I use the above for 1 Mb/s ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;BR /&gt;Wade Whitehorn&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Jan 2020 10:59:01 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/CAN-communication-at-1-Mb-s/m-p/1006047#M16930</guid>
      <dc:creator>dastek</dc:creator>
      <dc:date>2020-01-28T10:59:01Z</dc:date>
    </item>
    <item>
      <title>Re:  CAN communication at 1 Mb/s</title>
      <link>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/CAN-communication-at-1-Mb-s/m-p/1006048#M16931</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Radek used older version of the calculator where I programmed the sample point as close as possible&amp;nbsp; to 50%. Moreover, I am not sure whether he used the right version. There was some error I can not remember.&lt;/P&gt;&lt;P&gt;Here is a calculation he probably used (after my call with him):&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_2.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/99749iE40CBF1AFB64B134/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_2.png" alt="pastedImage_2.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want to follow changes you can change Propagation delay of the interface, bus length, sample point,...the changes are clearly visible in the right part of the table -&amp;gt; length of segment changes.&lt;/P&gt;&lt;P&gt;If I use TJA1040 propagation delay 255ns, different bus length and &lt;STRONG&gt;sample point 80%&lt;/STRONG&gt; then relations between values change.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_7.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/99918i873E98853E944EEF/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_7.png" alt="pastedImage_7.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So that's the reason.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note:&amp;nbsp; You can see better oscillator must be used in the second case.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Ladislav&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Jan 2020 13:22:05 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S12-MagniV-Microcontrollers/CAN-communication-at-1-Mb-s/m-p/1006048#M16931</guid>
      <dc:creator>lama</dc:creator>
      <dc:date>2020-01-28T13:22:05Z</dc:date>
    </item>
  </channel>
</rss>

