<?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>Kinetis Software Development Kit中的主题 Send custom structure over i2c</title>
    <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/Send-custom-structure-over-i2c/m-p/599265#M6099</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying to send a custom structure over i2c to a kinetis board which is acting as a slave with an interrupt triggering a callback in this scenario. I am able to run the example code which has a uint8_t buffer but I am not sure how to send a custom structure with different data types over.&amp;nbsp;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any example code out there?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 03 Feb 2017 18:34:15 GMT</pubDate>
    <dc:creator>rudasi</dc:creator>
    <dc:date>2017-02-03T18:34:15Z</dc:date>
    <item>
      <title>Send custom structure over i2c</title>
      <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/Send-custom-structure-over-i2c/m-p/599265#M6099</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying to send a custom structure over i2c to a kinetis board which is acting as a slave with an interrupt triggering a callback in this scenario. I am able to run the example code which has a uint8_t buffer but I am not sure how to send a custom structure with different data types over.&amp;nbsp;&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any example code out there?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Feb 2017 18:34:15 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/Send-custom-structure-over-i2c/m-p/599265#M6099</guid>
      <dc:creator>rudasi</dc:creator>
      <dc:date>2017-02-03T18:34:15Z</dc:date>
    </item>
    <item>
      <title>Re: Send custom structure over i2c</title>
      <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/Send-custom-structure-over-i2c/m-p/599266#M6100</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Figured it out by just type casting the data to my structure.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Feb 2017 18:47:00 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/Send-custom-structure-over-i2c/m-p/599266#M6100</guid>
      <dc:creator>rudasi</dc:creator>
      <dc:date>2017-02-03T18:47:00Z</dc:date>
    </item>
    <item>
      <title>Re: Send custom structure over i2c</title>
      <link>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/Send-custom-structure-over-i2c/m-p/599267#M6101</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, Rahul,&lt;/P&gt;&lt;P&gt;If you need complicated structure, I think you can use sprintf() function to output all variable to a buffer with char type, it is okay. If you want to output a structure, I think you can use union type structure.&lt;/P&gt;&lt;P&gt;typedef struct str_union&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;char array[];&lt;/P&gt;&lt;P&gt;union&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&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;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 04 Feb 2017 08:20:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/Kinetis-Software-Development-Kit/Send-custom-structure-over-i2c/m-p/599267#M6101</guid>
      <dc:creator>xiangjun_rong</dc:creator>
      <dc:date>2017-02-04T08:20:42Z</dc:date>
    </item>
  </channel>
</rss>

