<?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>S32KのトピックCreating New project : s32DS : Error clock not initializing</title>
    <link>https://community.nxp.com/t5/S32K/Creating-New-project-s32DS-Error-clock-not-initializing/m-p/1331744#M11892</link>
    <description>&lt;P&gt;Hi NXP Device support team,&lt;/P&gt;
&lt;P&gt;I am using following EVK &lt;STRONG&gt;S32K144EVB&lt;/STRONG&gt;.&lt;BR /&gt;&lt;A href="https://www.nxp.com/document/guide/get-started-with-the-s32k144evb:NGS-S32K144EVB" target="_blank" rel="noopener"&gt;https://www.nxp.com/document/guide/get-started-with-the-s32k144evb:NGS-S32K144EVB&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;I am using following S32DS version :--&lt;BR /&gt;S32 Design Studio for S32 Platform&lt;BR /&gt;&lt;STRONG&gt;Version: 3.4&lt;/STRONG&gt;&lt;BR /&gt;Build id: 201217 (Update 1&lt;/P&gt;
&lt;P&gt;I am new to S32DS. For this purpose I first tried to test already tested sample project.&lt;BR /&gt;I tested this "ftm_periodic_interrupt_s32k144" project on my EVAL board its working fine, on my board S32K144EVB.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Then i created new "S32DS Application Project". In this project I did following task :--&lt;BR /&gt;1&amp;gt; configured clock for RUN mode, core clock runing at 80 MHZ.&lt;BR /&gt;2&amp;gt; Made PORTD 15,16 pins as output.&lt;BR /&gt;3&amp;gt; Configured FTM-0 as simple up timer.&lt;/P&gt;
&lt;P&gt;I am using GDB PEMicro Interface Debugging.&lt;BR /&gt;I am getting following error when i do debugging, and execution of code is stuck at following &lt;STRONG&gt;DefaultISR&lt;/STRONG&gt; . Getting this error :--&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Initializing.
Target has been RESET and is active.
BusFault: A precise (synchronous) data access error has occurred.
Possible BusFault location: 0x4004C03C.
HardFault: A fault has been escalated to a hard fault.&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Dinesh_Guleria_1-1630321363394.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/154507i204E55A491FE9091/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Dinesh_Guleria_1-1630321363394.png" alt="Dinesh_Guleria_1-1630321363394.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;As per this error address 0x4004C03C, it seems to be memory map of PORTD, from excel sheet "&lt;STRONG&gt;S32K1xx_Memory_Map.xlsx&lt;/STRONG&gt;" :--&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Port D multiplexing control Port D 44 4 4004C000 4004CFFF&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Following is my main() routine :--&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;int main(void)
{
/* Write your code here */
/* Write your local variable definition here */
ftm_state_t state;

/* Initialize clock module */
CLOCK_SYS_Init(g_clockManConfigsArr, CLOCK_MANAGER_CONFIG_CNT, g_clockManCallbacksArr, CLOCK_MANAGER_CALLBACK_CNT);
CLOCK_SYS_UpdateConfiguration(0U, CLOCK_MANAGER_POLICY_AGREEMENT);

/* Initialize pins */
PINS_DRV_Init(NUM_OF_CONFIGURED_PINS0, g_pin_mux_InitConfigArr0);

/* Initialize FTM */
FTM_DRV_Init(INST_FLEXTIMER_MC_1, &amp;amp;flexTimer_mc_1_InitConfig_0, &amp;amp;state);

/* Initialize counter */
FTM_DRV_InitCounter(INST_FLEXTIMER_MC_1, &amp;amp;flexTimer_mc_1_TimerConfig_0);

/* Start Counter */
FTM_DRV_CounterStart(INST_FLEXTIMER_MC_1);

/* Loop */
for (;;)
{
/* Do no thing, just wait for the interrupt */
}

return exit_code;
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I debugged &amp;amp; found that error comes from this code execution in main() :--&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;PINS_DRV_Init(NUM_OF_CONFIGURED_PINS0, g_pin_mux_InitConfigArr0);&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then i check the clock settings for PORT-D &amp;amp; FTM-0. And found that clock is not set :---&lt;BR /&gt;Following register PCC_PORTD &amp;amp; PCC_FTM0, bit-30 &lt;STRONG&gt;CGC is ZERO&lt;/STRONG&gt;.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Dinesh_Guleria_0-1630321191476.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/154506i4A91C93113107E30/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Dinesh_Guleria_0-1630321191476.png" alt="Dinesh_Guleria_0-1630321191476.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Inspite of initializing my system clock this clocks are not set :--&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;/* Initialize clock module */
CLOCK_SYS_Init(g_clockManConfigsArr, CLOCK_MANAGER_CONFIG_CNT, g_clockManCallbacksArr, CLOCK_MANAGER_CALLBACK_CNT);
CLOCK_SYS_UpdateConfiguration(0U, CLOCK_MANAGER_POLICY_AGREEMENT);&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Please suggest how to get rid of this error. I have attached my sample project.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any help from your side will be appreciated.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Dinesh&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 30 Aug 2021 11:14:12 GMT</pubDate>
    <dc:creator>Dinesh_Guleria</dc:creator>
    <dc:date>2021-08-30T11:14:12Z</dc:date>
    <item>
      <title>Creating New project : s32DS : Error clock not initializing</title>
      <link>https://community.nxp.com/t5/S32K/Creating-New-project-s32DS-Error-clock-not-initializing/m-p/1331744#M11892</link>
      <description>&lt;P&gt;Hi NXP Device support team,&lt;/P&gt;
&lt;P&gt;I am using following EVK &lt;STRONG&gt;S32K144EVB&lt;/STRONG&gt;.&lt;BR /&gt;&lt;A href="https://www.nxp.com/document/guide/get-started-with-the-s32k144evb:NGS-S32K144EVB" target="_blank" rel="noopener"&gt;https://www.nxp.com/document/guide/get-started-with-the-s32k144evb:NGS-S32K144EVB&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;I am using following S32DS version :--&lt;BR /&gt;S32 Design Studio for S32 Platform&lt;BR /&gt;&lt;STRONG&gt;Version: 3.4&lt;/STRONG&gt;&lt;BR /&gt;Build id: 201217 (Update 1&lt;/P&gt;
&lt;P&gt;I am new to S32DS. For this purpose I first tried to test already tested sample project.&lt;BR /&gt;I tested this "ftm_periodic_interrupt_s32k144" project on my EVAL board its working fine, on my board S32K144EVB.&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Then i created new "S32DS Application Project". In this project I did following task :--&lt;BR /&gt;1&amp;gt; configured clock for RUN mode, core clock runing at 80 MHZ.&lt;BR /&gt;2&amp;gt; Made PORTD 15,16 pins as output.&lt;BR /&gt;3&amp;gt; Configured FTM-0 as simple up timer.&lt;/P&gt;
&lt;P&gt;I am using GDB PEMicro Interface Debugging.&lt;BR /&gt;I am getting following error when i do debugging, and execution of code is stuck at following &lt;STRONG&gt;DefaultISR&lt;/STRONG&gt; . Getting this error :--&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Initializing.
Target has been RESET and is active.
BusFault: A precise (synchronous) data access error has occurred.
Possible BusFault location: 0x4004C03C.
HardFault: A fault has been escalated to a hard fault.&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Dinesh_Guleria_1-1630321363394.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/154507i204E55A491FE9091/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Dinesh_Guleria_1-1630321363394.png" alt="Dinesh_Guleria_1-1630321363394.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;As per this error address 0x4004C03C, it seems to be memory map of PORTD, from excel sheet "&lt;STRONG&gt;S32K1xx_Memory_Map.xlsx&lt;/STRONG&gt;" :--&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;Port D multiplexing control Port D 44 4 4004C000 4004CFFF&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Following is my main() routine :--&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;int main(void)
{
/* Write your code here */
/* Write your local variable definition here */
ftm_state_t state;

/* Initialize clock module */
CLOCK_SYS_Init(g_clockManConfigsArr, CLOCK_MANAGER_CONFIG_CNT, g_clockManCallbacksArr, CLOCK_MANAGER_CALLBACK_CNT);
CLOCK_SYS_UpdateConfiguration(0U, CLOCK_MANAGER_POLICY_AGREEMENT);

/* Initialize pins */
PINS_DRV_Init(NUM_OF_CONFIGURED_PINS0, g_pin_mux_InitConfigArr0);

/* Initialize FTM */
FTM_DRV_Init(INST_FLEXTIMER_MC_1, &amp;amp;flexTimer_mc_1_InitConfig_0, &amp;amp;state);

/* Initialize counter */
FTM_DRV_InitCounter(INST_FLEXTIMER_MC_1, &amp;amp;flexTimer_mc_1_TimerConfig_0);

/* Start Counter */
FTM_DRV_CounterStart(INST_FLEXTIMER_MC_1);

/* Loop */
for (;;)
{
/* Do no thing, just wait for the interrupt */
}

return exit_code;
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I debugged &amp;amp; found that error comes from this code execution in main() :--&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;PINS_DRV_Init(NUM_OF_CONFIGURED_PINS0, g_pin_mux_InitConfigArr0);&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then i check the clock settings for PORT-D &amp;amp; FTM-0. And found that clock is not set :---&lt;BR /&gt;Following register PCC_PORTD &amp;amp; PCC_FTM0, bit-30 &lt;STRONG&gt;CGC is ZERO&lt;/STRONG&gt;.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Dinesh_Guleria_0-1630321191476.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/154506i4A91C93113107E30/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Dinesh_Guleria_0-1630321191476.png" alt="Dinesh_Guleria_0-1630321191476.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Inspite of initializing my system clock this clocks are not set :--&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;/* Initialize clock module */
CLOCK_SYS_Init(g_clockManConfigsArr, CLOCK_MANAGER_CONFIG_CNT, g_clockManCallbacksArr, CLOCK_MANAGER_CALLBACK_CNT);
CLOCK_SYS_UpdateConfiguration(0U, CLOCK_MANAGER_POLICY_AGREEMENT);&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Please suggest how to get rid of this error. I have attached my sample project.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any help from your side will be appreciated.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Dinesh&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 30 Aug 2021 11:14:12 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Creating-New-project-s32DS-Error-clock-not-initializing/m-p/1331744#M11892</guid>
      <dc:creator>Dinesh_Guleria</dc:creator>
      <dc:date>2021-08-30T11:14:12Z</dc:date>
    </item>
    <item>
      <title>Re: Creating New project : s32DS : Error clock not initializing</title>
      <link>https://community.nxp.com/t5/S32K/Creating-New-project-s32DS-Error-clock-not-initializing/m-p/1331847#M11893</link>
      <description>&lt;P&gt;Anyone who can suggest on this query ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As I am trying to create Core_clock using external oscillator .. 8 MHZ connected on this Eval board S32K144EVB&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I debugged the project &amp;amp; found&amp;nbsp; :---&lt;BR /&gt;What i found following function call return status : STATUS_ERROR :----&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;CLOCK_SYS_UpdateConfiguration()&lt;/LI-CODE&gt;
&lt;P&gt;&lt;BR /&gt;Inside this function following line gives error :--&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;ret = CLOCK_SYS_SetConfiguration(g_clockState.configTable[targetConfigIndex]);&lt;/LI-CODE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Dinesh_Guleria_0-1630336318167.png" style="width: 400px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/154527iAED9B9611E5C9163/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Dinesh_Guleria_0-1630336318167.png" alt="Dinesh_Guleria_0-1630336318167.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;It seems some issue with my configuration of clock that's why this function failing :--&lt;BR /&gt;ret = CLOCK_SYS_SetConfiguration(g_clockState.configTable[targetConfigIndex]);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please suggest what I have made wrong settings, so that i can resolve this error.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Dinesh&lt;/P&gt;</description>
      <pubDate>Mon, 30 Aug 2021 15:14:48 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Creating-New-project-s32DS-Error-clock-not-initializing/m-p/1331847#M11893</guid>
      <dc:creator>Dinesh_Guleria</dc:creator>
      <dc:date>2021-08-30T15:14:48Z</dc:date>
    </item>
    <item>
      <title>Re: Creating New project : s32DS : Error clock not initializing</title>
      <link>https://community.nxp.com/t5/S32K/Creating-New-project-s32DS-Error-clock-not-initializing/m-p/1332489#M11898</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.nxp.com/t5/user/viewprofilepage/user-id/190759"&gt;@Dinesh_Guleria&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;The CLOCK_SYS_UpdateConfiguration() function returns STATUS_ERROR here:&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;clock_S32K1xx.c&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="danielmartynek_0-1630406930035.png" style="width: 699px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/154663i086A79E1EE589908/image-dimensions/699x168?v=v2" width="699" height="168" role="button" title="danielmartynek_0-1630406930035.png" alt="danielmartynek_0-1630406930035.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;If you open HSRUN configuration, you will see that the system clock frequency in your HSRUN configuration does not meet the max allowed values.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="danielmartynek_1-1630407046269.png" style="width: 661px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/154664i4611F0B76D52E3FC/image-dimensions/661x405?v=v2" width="661" height="405" role="button" title="danielmartynek_1-1630407046269.png" alt="danielmartynek_1-1630407046269.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="danielmartynek_2-1630407092351.png" style="width: 606px;"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/154665i0014B2F14BBBAF34/image-dimensions/606x396?v=v2" width="606" height="396" role="button" title="danielmartynek_2-1630407092351.png" alt="danielmartynek_2-1630407092351.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Daniel&lt;/P&gt;</description>
      <pubDate>Wed, 01 Sep 2021 08:40:27 GMT</pubDate>
      <guid>https://community.nxp.com/t5/S32K/Creating-New-project-s32DS-Error-clock-not-initializing/m-p/1332489#M11898</guid>
      <dc:creator>danielmartynek</dc:creator>
      <dc:date>2021-09-01T08:40:27Z</dc:date>
    </item>
  </channel>
</rss>

