Watchdog IRQ issue in Mac57d5MB

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

Watchdog IRQ issue in Mac57d5MB

Jump to solution
3,783 Views
prashantsathe
Contributor III

Hi,

 

I am trying to get an Irq from watch dog timeout but unable to do so. Could be please point out my error.

 

Below is the code snippet.

 

void watchdogtest()

{

  /*Enable watch-dog*/

    enable_irq (INT_SWT_0 - MAC57D54H_FIRST_USER_IRQ);

    route_interrupt (INT_SWT_0 - MAC57D54H_FIRST_USER_IRQ, 0x03);

 

  SWT_0.SR.R = 0x0000c520;

  SWT_0.SR.R = 0x0000d928;

  SWT_0.CR.B.WEN = 0;

  SWT_0.TO.R = 0x500;

  SWT_0.CR.B.ITR = 1;

  SWT_0.CR.B.FRZ = 0;

 

 

  SWT_0.CR.B.WEN = 1;

  SWT_0.CR.B.SLK = 1;

 

  uPrintf("In a While Loop...\n");

  while(1); //

}

 

vector 122 is corresponds to SWT0

#define    VECTOR_122      default_isr_test  /*default_isr_test is dummy function to test an IRQ*/

clock SIRC is enabled .

 

and below is the register value corresponding to SWT0

 

156244_156244.pngpastedImage_1.png

 

 

Thanks in advance,

 

-Prashant

Labels (1)
1 Solution
3,275 Views
lukaszadrapa
NXP TechSupport
NXP TechSupport

Not sure what's wrong. I can see that also on computer connected to public net even if I'm not logged in. Is this link working on your side?

https://community.nxp.com/servlet/JiveServlet/download/816656-1-390566/halo-standby.zip

I will try to attach it again to this post with extension renamed from zip to aaa. Maybe it's caused by your firewall or something like that.

View solution in original post

10 Replies
3,274 Views
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi,

there's simple example in this thread:

SIRC clock

It could solve your problem.

Regards,

Lukas

0 Kudos
Reply
3,274 Views
prashantsathe
Contributor III

Access denied ..

Access to this place or content is restricted. If you think this is a mistake, please contact your administrator or the person who directed you here.

0 Kudos
Reply
3,274 Views
lukaszadrapa
NXP TechSupport
NXP TechSupport

Sorry, I didn't realize it is restricted item. Example is attached...

Lukas

0 Kudos
Reply
3,274 Views
prashantsathe
Contributor III

There is no attachment please check once again. And is it related to SIRC clk enable ? If yes then i have already enabled the clk as mentioned in previous mail . please check

pastedImage_0.png

0 Kudos
Reply
3,274 Views
lukaszadrapa
NXP TechSupport
NXP TechSupport

Can you already see the attachment in my previous post? It seems that it is not visible immediately...

The example is related also to watchdog.

Lukas

0 Kudos
Reply
3,274 Views
prashantsathe
Contributor III

No, it is not still visible. can we have other way please. waiting for your quick reply ..

0 Kudos
Reply
3,276 Views
lukaszadrapa
NXP TechSupport
NXP TechSupport

Not sure what's wrong. I can see that also on computer connected to public net even if I'm not logged in. Is this link working on your side?

https://community.nxp.com/servlet/JiveServlet/download/816656-1-390566/halo-standby.zip

I will try to attach it again to this post with extension renamed from zip to aaa. Maybe it's caused by your firewall or something like that.

3,275 Views
prashantsathe
Contributor III

Yes, Problem is solved now.

lukaszadrapa​ Thanks for your support.

Cheers,

-Prashant

0 Kudos
Reply
3,275 Views
prashantsathe
Contributor III
0 Kudos
Reply
3,275 Views
prashantsathe
Contributor III

BTW, if you are talking about enabling SIRC clk then we have already have below code at start up which is used to enable the SIRC.

    /* Turn on FXOSC, SIRC and SXOSC - can integrate this into enable PLL step - leaving separate for now during testing */

    MC_ME.DRUN_MC.R = 0x00130030;

    MC_ME.MCTL.R    = 0x30005AF0;

    MC_ME.MCTL.R    = 0x3000A50F;

let me know if it is different ..

-Prashant

0 Kudos
Reply