<?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: Calling c functions from assembly file in codewarrior for MCF5485 Coldfire in ColdFire/68K Microcontrollers and Processors</title>
    <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Calling-c-functions-from-assembly-file-in-codewarrior-for/m-p/653034#M13174</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Assembly language programs can call the functions written in either C or assembly language. From within the assembly language instructions, you can call the C functions. For example, if the C function definition is:&lt;/P&gt;&lt;P&gt;int&amp;nbsp; my_c_func ( int&amp;nbsp; i)&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;&amp;nbsp;return&amp;nbsp; i++;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the assembly language calling statement should be:&lt;/P&gt;&lt;P&gt;jsr _my_c_func&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 13 Mar 2017 08:36:33 GMT</pubDate>
    <dc:creator>miduo</dc:creator>
    <dc:date>2017-03-13T08:36:33Z</dc:date>
    <item>
      <title>Calling c functions from assembly file in codewarrior for MCF5485 Coldfire</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Calling-c-functions-from-assembly-file-in-codewarrior-for/m-p/653032#M13172</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="padding: 0px; min-;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am working with "CodeWarrior for MCU Version: 10.6" for MCF5485 coldfire .&lt;/P&gt;&lt;P&gt;I have some functions in my C-File. I have to call those function in the .s file.&lt;/P&gt;&lt;P style="padding: 0px; min-;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could you please give me the procedure to call the functions and to pass the parameters.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2017 20:22:56 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Calling-c-functions-from-assembly-file-in-codewarrior-for/m-p/653032#M13172</guid>
      <dc:creator>preetuabraham</dc:creator>
      <dc:date>2017-02-20T20:22:56Z</dc:date>
    </item>
    <item>
      <title>Re: Calling c functions from assembly file in codewarrior for MCF5485 Coldfire</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Calling-c-functions-from-assembly-file-in-codewarrior-for/m-p/653033#M13173</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Search this forum for "calling c from assembly" and see if any of them help.I gave up counting at ONE HUNDRED. You should search before posting (and if you have searched and found nothing, say so, and detail why your problem is different from the previous ones).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Watch out that the ABI changed after CW 7.2, so any examples prior to that (MOST examples are prior to that) won't work on later CW versions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I only know the ABI for gcc, and that's different to CW.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Why do you need to call C from Assembly? It is usually always better to get from Assembly into C ASAP and then stay there.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Tom&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2017 00:17:17 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Calling-c-functions-from-assembly-file-in-codewarrior-for/m-p/653033#M13173</guid>
      <dc:creator>TomE</dc:creator>
      <dc:date>2017-02-21T00:17:17Z</dc:date>
    </item>
    <item>
      <title>Re: Calling c functions from assembly file in codewarrior for MCF5485 Coldfire</title>
      <link>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Calling-c-functions-from-assembly-file-in-codewarrior-for/m-p/653034#M13174</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Assembly language programs can call the functions written in either C or assembly language. From within the assembly language instructions, you can call the C functions. For example, if the C function definition is:&lt;/P&gt;&lt;P&gt;int&amp;nbsp; my_c_func ( int&amp;nbsp; i)&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;&amp;nbsp;return&amp;nbsp; i++;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the assembly language calling statement should be:&lt;/P&gt;&lt;P&gt;jsr _my_c_func&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 Mar 2017 08:36:33 GMT</pubDate>
      <guid>https://community.nxp.com/t5/ColdFire-68K-Microcontrollers/Calling-c-functions-from-assembly-file-in-codewarrior-for/m-p/653034#M13174</guid>
      <dc:creator>miduo</dc:creator>
      <dc:date>2017-03-13T08:36:33Z</dc:date>
    </item>
  </channel>
</rss>

