<?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>CodeWarrior for MCUのトピックRe: Interrupt routine from code for S08PT60-EVK Eval Board not being called</title>
    <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1385804#M15629</link>
    <description>&lt;P&gt;-&lt;/P&gt;&lt;P&gt;Hi Jun,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your reply.&amp;nbsp; It's seems I made a mistake in remembering what I did.&amp;nbsp; Apparently I started out with the example code for the &lt;SPAN&gt;S08PT60-EVK, "S08PT60-EVK Example Codes"&amp;nbsp;&lt;/SPAN&gt;from here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.nxp.com/design/development-boards/freedom-development-boards/adaptors/evaluation-kit-for-s08p-mcus:S08PT60-EVK" target="_blank"&gt;https://www.nxp.com/design/development-boards/freedom-development-boards/adaptors/evaluation-kit-for-s08p-mcus:S08PT60-EVK&lt;/A&gt;&lt;/P&gt;&lt;P&gt;unzipped and imported it into CodeWarrior 10.7 and then the compile error that I got was, "mingw-32-make:&amp;nbsp; *** No rule to make target C:\...".&lt;/P&gt;&lt;P&gt;I believe I then downloaded the example code from the S08P-Lite Example Board and tried to reconstruct a project from there.&lt;/P&gt;&lt;P&gt;Maybe if we fix the target setting error for the original S08PT60-EVK, that might be the best way to go.&lt;/P&gt;&lt;P&gt;Thanks so much!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rick&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 13 Dec 2021 17:35:14 GMT</pubDate>
    <dc:creator>RickStranberg</dc:creator>
    <dc:date>2021-12-13T17:35:14Z</dc:date>
    <item>
      <title>Interrupt routine from code for S08PT60-EVK Eval Board not being called</title>
      <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1385056#M15627</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;We recently purchased the S08PT60-EVK evaluation board as we are looking to use the S08PT60.&amp;nbsp; I have CodeWarrior V10.7.&amp;nbsp; It appears that the example project and code may have designed for a previous version of CodeWarrior.&lt;/P&gt;&lt;P&gt;I ended up copying all of the .c and .h files from the example code directories devices-&amp;gt;common, devices-&amp;gt;drivers, and devices-&amp;gt;platform into the corresponding source and header file directories within the Codewarrior 10.7 project.&amp;nbsp; The project compiles and runs albeit barely.&lt;/P&gt;&lt;P&gt;The code in question is the ITIM1 interrupt service routine after main routine:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;/************************************************************************
*       main - Program main entry point                                                                         *
*************************************************************************/
void main(void) 
{
    uint8_t i = 0;
    
    
 //   volatile unsigned char dummy;
 //   unsigned short uiCount;
    
    //Initialise system including clocks
    //Watchdog: disabled
    //FEE: BUS clock 16MHz
    //Serial terminal: SCI2 baudrate 115200
    Sys_Init();
    EnableInterrupts;

    printf("\n-- S08PT60-EVK OOBE BEGINS--\n");
    printf("\n");

    LED_Init();
    LED_Test();
    
    //Initialise MTIM1, 1ms interrupt interval, used for 1ms time delay
    MTIM1_Init();
    
    //Initialise MTIM2 to generate PWM
	FTM2_Init();
	
    //Initialise I2C PTA2/3 used for FXOS8700CQ write/read
    Accel_I2C_Init();
    FXOS8700CQ_Test();
    
    //while (1);
}


//MTIM1 is used for delay 1 milliseconds
interrupt VectorNumber_Vmtim1 void  Mtim1_ISR(void)
{
	LED0_On();
    DisableInterrupts;
    if(MTIM1_SC_TOF)
    {
        // clear the flag
        MTIM1_SC_TOF = 0;	
    }
    g_delay_1ms_done = 1;
    EnableInterrupts;
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The Mtim1_ISR(void) never gets called.&amp;nbsp; I tested it as can be seen by putting a LED0_On() at the beginning of it (LED0_On() works elsewhere turning a RED LED on).&lt;/P&gt;&lt;P&gt;There's a couple of things - since this project is sort of a mish mash, where does the function&amp;nbsp;Mtim1_ISR(void) get registered to be the actual MTIM1 interrupt routine?&amp;nbsp; I'm assuming it's by&amp;nbsp; using " VectorNumber_Vmtim1".&amp;nbsp; If that's not correct, what is the correct way?&lt;/P&gt;&lt;P&gt;I'm attaching my project so that you can possibly see any issues with how the project is structured.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks so much!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Rick&lt;/P&gt;</description>
      <pubDate>Fri, 10 Dec 2021 20:57:57 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1385056#M15627</guid>
      <dc:creator>RickStranberg</dc:creator>
      <dc:date>2021-12-10T20:57:57Z</dc:date>
    </item>
    <item>
      <title>Re: Interrupt routine from code for S08PT60-EVK Eval Board not being called</title>
      <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1385456#M15628</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Your zip file is not downloadable.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;But, According to your words "&lt;SPAN&gt;copying all of the .c and .h files from the example code directories&lt;/SPAN&gt;",&amp;nbsp; Which "sample code" do you refer to? could you please send me the link?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The &lt;SPAN&gt;Mtim1 vector number is 20. can you please check vectors.c file if&amp;nbsp;Mtim1 vector is defined?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Have a nice day,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Jun Zhang&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 13 Dec 2021 08:03:44 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1385456#M15628</guid>
      <dc:creator>ZhangJennie</dc:creator>
      <dc:date>2021-12-13T08:03:44Z</dc:date>
    </item>
    <item>
      <title>Re: Interrupt routine from code for S08PT60-EVK Eval Board not being called</title>
      <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1385804#M15629</link>
      <description>&lt;P&gt;-&lt;/P&gt;&lt;P&gt;Hi Jun,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for your reply.&amp;nbsp; It's seems I made a mistake in remembering what I did.&amp;nbsp; Apparently I started out with the example code for the &lt;SPAN&gt;S08PT60-EVK, "S08PT60-EVK Example Codes"&amp;nbsp;&lt;/SPAN&gt;from here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.nxp.com/design/development-boards/freedom-development-boards/adaptors/evaluation-kit-for-s08p-mcus:S08PT60-EVK" target="_blank"&gt;https://www.nxp.com/design/development-boards/freedom-development-boards/adaptors/evaluation-kit-for-s08p-mcus:S08PT60-EVK&lt;/A&gt;&lt;/P&gt;&lt;P&gt;unzipped and imported it into CodeWarrior 10.7 and then the compile error that I got was, "mingw-32-make:&amp;nbsp; *** No rule to make target C:\...".&lt;/P&gt;&lt;P&gt;I believe I then downloaded the example code from the S08P-Lite Example Board and tried to reconstruct a project from there.&lt;/P&gt;&lt;P&gt;Maybe if we fix the target setting error for the original S08PT60-EVK, that might be the best way to go.&lt;/P&gt;&lt;P&gt;Thanks so much!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rick&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 13 Dec 2021 17:35:14 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1385804#M15629</guid>
      <dc:creator>RickStranberg</dc:creator>
      <dc:date>2021-12-13T17:35:14Z</dc:date>
    </item>
    <item>
      <title>Re: Interrupt routine from code for S08PT60-EVK Eval Board not being called</title>
      <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1386033#M15630</link>
      <description>&lt;P&gt;Rick&lt;/P&gt;
&lt;P&gt;when we open the default demo code with CodeWarrior, we need to do clean it first then build. Thus there is no build error. I have tested it.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ZhangJennie_0-1639453874403.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/165038i3F1B597878E4A80E/image-size/medium?v=v2&amp;amp;px=400" role="button" title="ZhangJennie_0-1639453874403.png" alt="ZhangJennie_0-1639453874403.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;But this set of code is for EVK board, if you don't use this board, you need to check if the interrupt is triggered on HW side.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Jun Zhang&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 14 Dec 2021 03:53:46 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1386033#M15630</guid>
      <dc:creator>ZhangJennie</dc:creator>
      <dc:date>2021-12-14T03:53:46Z</dc:date>
    </item>
    <item>
      <title>Re: Interrupt routine from code for S08PT60-EVK Eval Board not being called</title>
      <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1386624#M15631</link>
      <description>&lt;P&gt;Hi Jun,&lt;/P&gt;&lt;P&gt;Thanks for your reply.&amp;nbsp;&lt;/P&gt;&lt;P&gt;It turned out to be a project configuration issue.&amp;nbsp; When I download&amp;nbsp;S08PT60-EVK Example Codes it unzips into 2 folders:&amp;nbsp; 'devices' and 's08pt60_evk' - which is the project folder.&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;After I copied the project to the local directory in which I would be working, I mistakenly put the devices folder &lt;EM&gt;within&lt;/EM&gt;&amp;nbsp;the s08pt60_evk.&amp;nbsp; After realizing the mistake, I started the project creation process again with leaving the devices folder at the same directory level as s08pt60_evk.&amp;nbsp; The project then compiled.&lt;/P&gt;&lt;P&gt;However I noticed that the project only "recognized" the 'common' and 'drivers' folder underneath the 'devices' folder.&amp;nbsp; It also did not recognize other folders underneath the 'drivers' folder.&lt;/P&gt;&lt;P&gt;I subsequently decided I wanted to use some of the functions in the s08pt60_evk_board.c file which was under the 'platform' directory under 'devices'.&lt;/P&gt;&lt;P&gt;So I then copied the 'platform' directory' into the 'devices' directory underneath the project.&amp;nbsp; I also copied the needed adc folder and files along with the tsi folders and files into the 'devices' folder which the s08pt60_evk_board.c file needs.&amp;nbsp;&lt;/P&gt;&lt;P&gt;However, codewarrioir will not recognize the files and folders that I added.&amp;nbsp; See screenshot:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Non-recognized_files.png" style="width: 625px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/165170i3044DB29896C096D/image-size/large?v=v2&amp;amp;px=999" role="button" title="Non-recognized_files.png" alt="Non-recognized_files.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;How do I get CodeWarrior to "recognize" the added folders/files?&lt;/P&gt;&lt;P&gt;Thanks so much.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rick&lt;/P&gt;</description>
      <pubDate>Tue, 14 Dec 2021 17:10:05 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1386624#M15631</guid>
      <dc:creator>RickStranberg</dc:creator>
      <dc:date>2021-12-14T17:10:05Z</dc:date>
    </item>
    <item>
      <title>Re: Interrupt routine from code for S08PT60-EVK Eval Board not being called</title>
      <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1386871#M15632</link>
      <description>&lt;P&gt;Rick&lt;/P&gt;
&lt;P&gt;You need to make sure the file path is included in project path settings.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ZhangJennie_0-1639538997035.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/165225i29434789964B0CF5/image-size/medium?v=v2&amp;amp;px=400" role="button" title="ZhangJennie_0-1639538997035.png" alt="ZhangJennie_0-1639538997035.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;DIV id="tinyMceEditorZhangJennie_0" class="mceNonEditable lia-copypaste-placeholder"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Jun Zhang&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 15 Dec 2021 03:30:13 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1386871#M15632</guid>
      <dc:creator>ZhangJennie</dc:creator>
      <dc:date>2021-12-15T03:30:13Z</dc:date>
    </item>
    <item>
      <title>Re: Interrupt routine from code for S08PT60-EVK Eval Board not being called</title>
      <link>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1387313#M15633</link>
      <description>&lt;P&gt;Ahhh, thank you, Jun!&lt;/P&gt;&lt;P&gt;Also, to my original question "Interrupt routine ..... not being called", I figured out the issue for it.&amp;nbsp; &amp;nbsp;In the code section in main,&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;    LED_Init();
    LED_Test();
    
    //Initialise MTIM1, 1ms interrupt interval, used for 1ms time delay
    MTIM1_Init();&lt;/LI-CODE&gt;&lt;P&gt;the LED_Test() function was &lt;EM&gt;before&lt;/EM&gt; the interrupt was set up.&amp;nbsp; MTIM1_Init();&lt;/P&gt;&lt;P&gt;Thanks again for your help!&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rick&lt;/P&gt;</description>
      <pubDate>Wed, 15 Dec 2021 13:09:06 GMT</pubDate>
      <guid>https://community.nxp.com/t5/CodeWarrior-for-MCU/Interrupt-routine-from-code-for-S08PT60-EVK-Eval-Board-not-being/m-p/1387313#M15633</guid>
      <dc:creator>RickStranberg</dc:creator>
      <dc:date>2021-12-15T13:09:06Z</dc:date>
    </item>
  </channel>
</rss>

