AnsweredAssumed Answered

Watchdog IRQ issue in Mac57d5MB

Question asked by prashant sathe on Jul 22, 2016
Latest reply on Jul 28, 2016 by prashant sathe



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




Thanks in advance,