MPC5643l External Interrupt 0 Cause Device Reset

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MPC5643l External Interrupt 0 Cause Device Reset

1,012 Views
giovannivaccaro
Contributor I

Hello

 I have a problem that an unexplained reset hapenning when a external interrupt triggered.

I trying to set interrupt on IRQO on falling edge event.

After the falling edge event is occurred i can check the     SIU.ISR.B.EIF0 register that is high but interrupt doesn't occurred and an unexplained reset hapenning .

Someone can help me?

Thank you.

0 Kudos
Reply
6 Replies

795 Views
petervlna
NXP TechSupport
NXP TechSupport

Hello Giovanni,

I will try to guide you.

First you can check RGM (reset generation module) registers DES and FES for reset source.

Then you can read FCCU module NCFS and CFS registers for fault details is the fault is latched in FCCU.

Could you please share values of these registers?

Peter

0 Kudos
Reply

795 Views
giovannivaccaro
Contributor I

Hello Peter

Following my configuration:

 RGM.FES.R = 0xFFFF;

RGM.DES.R is not configured;

FCCU peripherals:

FCCU.NCFS_CFG0.R = 0x0000AAAA;

FCCU.NCFS_CFG1.R = 0x00000000;

  FCCU.CFS_CFG0.R = 0xAAAAAAAA;

 FCCU.CFS_CFG1.R = 0xAA82800A;

After interrupt occurred i can see that micro goes in starvation, in fact i can read "illegal instruction" and from the pc register i can see that it jumps from an instruction to another one like if is inside a while loop

Thanks for support.

0 Kudos
Reply

795 Views
petervlna
NXP TechSupport
NXP TechSupport

Hi,

I have asked you for values of status registers.

And you are posting me configuration registers. This makes no sense.

Show me value of status register after reset occurs:

RGM. FES

RGM. DES

FCCU. NCFS and CFS

Peter

0 Kudos
Reply

795 Views
giovannivaccaro
Contributor I

Hello peter

I'm sorry, but i didn't unsterdand what you meant.

Following the values that you asked after reset occurs:

RGM.FES 0x0000;

RGM.DES 0x0001; ( A power-on event has occurred);

FCCU. NCFS0 =0x00000000;

FCCU. NCFS1 =0x00000000;

FCCU. NCFS2 =0x00000000;

FCCU. NCFS3 =0x00000000;

FCCU. CFS0=0x00000000;

FCCU. CFS1=0x00000000;

FCCU. CFS2=0x00000000;

FCCU. CFS3=0x00000000;

thank you for support

0 Kudos
Reply

795 Views
petervlna
NXP TechSupport
NXP TechSupport

From your description I can see no unexplained reset happen. Only Power on Reset.

Are you clearing RGM. DES and FES during code startup? (reset sources analyzes)

Customers usually analyze the reset sources during startup to prevent any unexpected behavior. And then clear RGM DES and FES. So after next reset they can read the last reset value to have the clear view on what caused last reset.

Peter

0 Kudos
Reply

795 Views
giovannivaccaro
Contributor I

follwing complete FCCU configuration

void fccu_init_fnc (void)
{
/*---------------------------------------------------------------------------*/
/*    FCCU Configuration Timeout register (FCCU_CFG_TO)                      */
/*    Note:The FCCU_CFG_TO register is accessible in write mode,             */
/*    in any state excluded the CONFIG state.                                */
/*---------------------------------------------------------------------------*/
    FCCU.CFG_TO.R = 0x00000006;
        /* CONFIG STATE Time Out: 4096 micro sec */

/*---------------------------------------------------------------------------*/
/*    FCCU Config State Transition                                           */
/*---------------------------------------------------------------------------*/
    FCCU_CONFIG_STATE();

/*---------------------------------------------------------------------------*/
/*    FCCU Configuration register (FCCU_CFG)                                 */
/*---------------------------------------------------------------------------*/
    FCCU.CFG.R = 0x00000E88;
            /* RCC1 Enable: Disabled */
            /* RCC0 Enable: Disabled */
            /* Safe Mode Request Timer: 0.0625 micro sec */
            /* Config Mode: Transparency */
            /* Switching Mode: Fast switching */
            /* Polarity Selection: FCCU_F[1] low, FCCU_F[0] low */
            /* Fault Output Mode: Bi - Stable */
            /* Fault Output Prescaler: 8 */
/*---------------------------------------------------------------------------*/
/*    FCCU IRQ Enable register (FCCU_IRQ_EN)                                 */
/*---------------------------------------------------------------------------*/
    FCCU.IRQ_EN.R = 0x00000000;
        /* FCCU Config Timeout Interrupt: Disable*/

/*---------------------------------------------------------------------------*/
/*    FCCU Critical Fault Configuration register (FCCU_CF_CFG0)              */
/*---------------------------------------------------------------------------*/
    FCCU.CF_CFG0.R = 0xFFFFFFFF;
        /* Fault CF0 is Software recoverable */
        /* Fault CF1 is Software recoverable */
        /* Fault CF2 is Software recoverable */
        /* Fault CF3 is Software recoverable */
        /* Fault CF4 is Software recoverable */
        /* Fault CF5 is Software recoverable */
        /* Fault CF6 is Software recoverable */
        /* Fault CF7 is Software recoverable */
        /* Fault CF8 is Software recoverable */
        /* Fault CF9 is Software recoverable */
        /* Fault CF10 is Software recoverable */
        /* Fault CF11 is Software recoverable */
        /* Fault CF12 is Software recoverable */
        /* Fault CF13 is Software recoverable */
        /* Fault CF14 is Software recoverable */
        /* Fault CF15 is Software recoverable */
        /* Fault CF16 is Software recoverable */
        /* Fault CF17 is Software recoverable */
        /* Fault CF18 is Software recoverable */
        /* Fault CF19 is Software recoverable */
        /* Fault CF20 is Software recoverable */
        /* Fault CF21 is Software recoverable */
        /* Fault CF22 is Software recoverable */
        /* Fault CF23 is Software recoverable */
        /* Fault CF24 is Software recoverable */
        /* Fault CF25 is Software recoverable */
        /* Fault CF26 is Software recoverable */
        /* Fault CF27 is Software recoverable */
        /* Fault CF28 is Software recoverable */
        /* Fault CF29 is Software recoverable */
        /* Fault CF30 is Software recoverable */
        /* Fault CF31 is Software recoverable */

/*---------------------------------------------------------------------------*/
/*    FCCU Critical Fault State Configuration register (FCCU_CFS_CFG0)       */
/*---------------------------------------------------------------------------*/
    FCCU.CFS_CFG0.R = 0xAAAAAAAA;
        /* Reset action after fault CF0 is Long Functional Reset */
        /* Reset action after fault CF1 is Long Functional Reset */
        /* Reset action after fault CF2 is Long Functional Reset */
        /* Reset action after fault CF3 is Long Functional Reset */
        /* Reset action after fault CF4 is Long Functional Reset */
        /* Reset action after fault CF5 is Long Functional Reset */
        /* Reset action after fault CF6 is Long Functional Reset */
        /* Reset action after fault CF7 is Long Functional Reset */
        /* Reset action after fault CF8 is Long Functional Reset */
        /* Reset action after fault CF9 is Long Functional Reset */
        /* Reset action after fault CF10 is Long Functional Reset */
        /* Reset action after fault CF11 is Long Functional Reset */
        /* Reset action after fault CF12 is Long Functional Reset */
        /* Reset action after fault CF13 is Long Functional Reset */
        /* Reset action after fault CF14 is Long Functional Reset */
        /* Reset action after fault CF15 is Long Functional Reset */

/*---------------------------------------------------------------------------*/
/*    FCCU Critical Fault State Configuration register (FCCU_CFS_CFG1)       */
/*---------------------------------------------------------------------------*/
    FCCU.CFS_CFG1.R = 0xAA82800A;
        /* Reset action after fault CF16 is Long Functional Reset */
        /* Reset action after fault CF17 is Long Functional Reset */
        /* Reset action after fault CF18 is No reset reaction */
        /* Reset action after fault CF19 is No reset reaction */
        /* Reset action after fault CF20 is No reset reaction */
        /* Reset action after fault CF21 is No reset reaction */
        /* Reset action after fault CF22 is No reset reaction */
        /* Reset action after fault CF23 is Long Functional Reset */
        /* Reset action after fault CF24 is Long Functional Reset */
        /* Reset action after fault CF25 is No reset reaction */
        /* Reset action after fault CF26 is No reset reaction */
        /* Reset action after fault CF27 is Long Functional Reset */
        /* Reset action after fault CF28 is Long Functional Reset */
        /* Reset action after fault CF29 is Long Functional Reset */
        /* Reset action after fault CF30 is Long Functional Reset */
        /* Reset action after fault CF31 is Long Functional Reset */

/*---------------------------------------------------------------------------*/
/*    FCCU Non Critical Fault Configuration register (FCCU_NCF_CFG0)         */
/*---------------------------------------------------------------------------*/
    FCCU.NCF_CFG0.R = 0xFFFFFFFF;
        /* Fault NCF0 is Software recoverable */
        /* Fault NCF1 is Software recoverable */
        /* Fault NCF2 is Software recoverable */
        /* Fault NCF3 is Software recoverable */
        /* Fault NCF4 is Software recoverable */
        /* Fault NCF5 is Software recoverable */
        /* Fault NCF6 is Software recoverable */
        /* Fault NCF7 is Software recoverable */
        /* Fault NCF8 is Software recoverable */
        /* Fault NCF9 is Software recoverable */
        /* Fault NCF10 is Software recoverable */
        /* Fault NCF11 is Software recoverable */
        /* Fault NCF12 is Software recoverable */
        /* Fault NCF13 is Software recoverable */
        /* Fault NCF14 is Software recoverable */
        /* Fault NCF15 is Software recoverable */
        /* Fault NCF16 is Software recoverable */
        /* Fault NCF17 is Software recoverable */
        /* Fault NCF18 is Software recoverable */
        /* Fault NCF19 is Software recoverable */
        /* Fault NCF20 is Software recoverable */
        /* Fault NCF21 is Software recoverable */
        /* Fault NCF22 is Software recoverable */
        /* Fault NCF23 is Software recoverable */
        /* Fault NCF24 is Software recoverable */
        /* Fault NCF25 is Software recoverable */
        /* Fault NCF26 is Software recoverable */
        /* Fault NCF27 is Software recoverable */
        /* Fault NCF28 is Software recoverable */
        /* Fault NCF29 is Software recoverable */
        /* Fault NCF30 is Software recoverable */
        /* Fault NCF31 is Software recoverable */

/*---------------------------------------------------------------------------*/
/*    FCCU Non Critical Fault State Configuration register (FCCU_NCFS_CFG0)  */
/*---------------------------------------------------------------------------*/
    FCCU.NCFS_CFG0.R = 0x0000AAAA;
        /* Reset action after fault NCF0 is Long Functional Reset */
        /* Reset action after fault NCF1 is Long Functional Reset */
        /* Reset action after fault NCF2 is Long Functional Reset */
        /* Reset action after fault NCF3 is Long Functional Reset */
        /* Reset action after fault NCF4 is Long Functional Reset */
        /* Reset action after fault NCF5 is Long Functional Reset */
        /* Reset action after fault NCF6 is Long Functional Reset */
        /* Reset action after fault NCF7 is Long Functional Reset */
        /* Reset action after fault NCF8 is No reset reaction */
        /* Reset action after fault NCF9 is No reset reaction */
        /* Reset action after fault NCF10 is No reset reaction */
        /* Reset action after fault NCF11 is No reset reaction */
        /* Reset action after fault NCF12 is No reset reaction */
        /* Reset action after fault NCF13 is No reset reaction */
        /* Reset action after fault NCF14 is No reset reaction */
        /* Reset action after fault NCF15 is No reset reaction */

/*---------------------------------------------------------------------------*/
/*    FCCU Non Critical Fault State Configuration register (FCCU_NCFS_CFG1)  */
/*---------------------------------------------------------------------------*/
    FCCU.NCFS_CFG1.R = 0x00000000;
        /* Reset action after fault NCF16 is No reset reaction */
        /* Reset action after fault NCF17 is No reset reaction */
        /* Reset action after fault NCF18 is No reset reaction */
        /* Reset action after fault NCF19 is No reset reaction */
        /* Reset action after fault NCF20 is No reset reaction */
        /* Reset action after fault NCF21 is No reset reaction */
        /* Reset action after fault NCF22 is No reset reaction */
        /* Reset action after fault NCF23 is No reset reaction */
        /* Reset action after fault NCF24 is No reset reaction */
        /* Reset action after fault NCF25 is No reset reaction */
        /* Reset action after fault NCF26 is No reset reaction */
        /* Reset action after fault NCF27 is No reset reaction */
        /* Reset action after fault NCF28 is No reset reaction */
        /* Reset action after fault NCF29 is No reset reaction */
        /* Reset action after fault NCF30 is No reset reaction */
        /* Reset action after fault NCF31 is No reset reaction */

/*---------------------------------------------------------------------------*/
/*    FCCU Non Critical Fault Enable register (FCCU_NCFE0)                   */
/*---------------------------------------------------------------------------*/
    FCCU.NCF_E0.R = 0x01D3FCFF;
        /* Fault NCF0 is enabled */
        /* Fault NCF1 is enabled */
        /* Fault NCF2 is enabled */
        /* Fault NCF3 is enabled */
        /* Fault NCF4 is enabled */
        /* Fault NCF5 is enabled */
        /* Fault NCF6 is enabled */
        /* Fault NCF7 is enabled */
        /* Fault NCF8 is disabled */
        /* Fault NCF9 is disabled */
        /* Fault NCF10 is enabled */
        /* Fault NCF11 is enabled */
        /* Fault NCF12 is enabled */
        /* Fault NCF13 is enabled */
        /* Fault NCF14 is enabled */
        /* Fault NCF15 is enabled */
        /* Fault NCF16 is enabled */
        /* Fault NCF17 is enabled */
        /* Fault NCF18 is disabled */
        /* Fault NCF19 is disabled */
        /* Fault NCF20 is enabled */
        /* Fault NCF21 is disabled */
        /* Fault NCF22 is enabled */
        /* Fault NCF23 is enabled */
        /* Fault NCF24 is enabled */
        /* Fault NCF25 is disabled */
        /* Fault NCF26 is disabled */
        /* Fault NCF27 is disabled */
        /* Fault NCF28 is disabled */
        /* Fault NCF29 is disabled */
        /* Fault NCF30 is disabled */
        /* Fault NCF31 is disabled */

/*---------------------------------------------------------------------------*/
/*    FCCU Non Critical Fault Timeout Enable register (FCCU_NCF_TOE)         */
/*---------------------------------------------------------------------------*/
    FCCU.NCF_TOE0.R = 0x01FBFFFF;
        /* Fault NCF0  timeout is enabled */
        /* Fault NCF1  timeout is enabled */
        /* Fault NCF2  timeout is enabled */
        /* Fault NCF3  timeout is enabled */
        /* Fault NCF4  timeout is enabled */
        /* Fault NCF5  timeout is enabled */
        /* Fault NCF6  timeout is enabled */
        /* Fault NCF7  timeout is enabled */
        /* Fault NCF8  timeout is enabled */
        /* Fault NCF9  timeout is enabled */
        /* Fault NCF10  timeout is enabled */
        /* Fault NCF11  timeout is enabled */
        /* Fault NCF12  timeout is enabled */
        /* Fault NCF13  timeout is enabled */
        /* Fault NCF14  timeout is enabled */
        /* Fault NCF15  timeout is enabled */
        /* Fault NCF16  timeout is enabled */
        /* Fault NCF17  timeout is enabled */
        /* Fault NCF18  timeout is disabled */
        /* Fault NCF19  timeout is enabled */
        /* Fault NCF20  timeout is enabled */
        /* Fault NCF21  timeout is enabled */
        /* Fault NCF22  timeout is enabled */
        /* Fault NCF23  timeout is enabled */
        /* Fault NCF24  timeout is enabled */
        /* Fault NCF25  timeout is disabled */
        /* Fault NCF26  timeout is disabled */
        /* Fault NCF27  timeout is disabled */
        /* Fault NCF28  timeout is disabled */
        /* Fault NCF29  timeout is disabled */
        /* Fault NCF30  timeout is disabled */
        /* Fault NCF31  timeout is disabled */

/*---------------------------------------------------------------------------*/
/*    FCCU Non Critical Fault Timeout register (FCCU_NCF_TO)                 */
/*---------------------------------------------------------------------------*/
    FCCU.NCF_TO.R = 0x0000FFFF;
        /* Non critical fault timeout is 4095.938 micro sec */

0 Kudos
Reply