Add cal_isr() support
This commit is contained in:
parent
ab84453401
commit
745e7b5ac2
|
@ -30,7 +30,7 @@
|
|||
* This file is part of libmc1322x: see http://mc1322x.devl.org
|
||||
* for details.
|
||||
*
|
||||
* $Id: isr.h,v 1.1 2010/06/10 14:55:39 maralvira Exp $
|
||||
* $Id: isr.h,v 1.2 2010/11/07 14:21:59 maralvira Exp $
|
||||
*/
|
||||
|
||||
#ifndef ISR_H
|
||||
|
@ -87,6 +87,8 @@ extern void kbi5_isr(void) __attribute__((weak));
|
|||
extern void kbi6_isr(void) __attribute__((weak));
|
||||
extern void kbi7_isr(void) __attribute__((weak));
|
||||
|
||||
extern void cal_isr(void) __attribute__((weak));
|
||||
|
||||
extern void uart1_isr(void) __attribute__((weak));
|
||||
|
||||
extern void maca_isr(void) __attribute__((weak));
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
* This file is part of libmc1322x: see http://mc1322x.devl.org
|
||||
* for details.
|
||||
*
|
||||
* $Id: isr.c,v 1.1 2010/06/10 14:49:31 maralvira Exp $
|
||||
* $Id: isr.c,v 1.2 2010/11/07 14:21:59 maralvira Exp $
|
||||
*/
|
||||
|
||||
#include <mc1322x.h>
|
||||
|
@ -66,6 +66,12 @@ void irq(void)
|
|||
if(kbi_evnt(5) && (kbi5_isr != 0)) { kbi5_isr(); }
|
||||
if(kbi_evnt(6) && (kbi6_isr != 0)) { kbi6_isr(); }
|
||||
if(kbi_evnt(7) && (kbi7_isr != 0)) { kbi7_isr(); }
|
||||
|
||||
if (CRM.STATUSbits.CAL_DONE && CRM.CAL_CNTLbits.CAL_IEN && cal_isr)
|
||||
{
|
||||
CRM.STATUSbits.CAL_DONE = 0;
|
||||
cal_isr();
|
||||
}
|
||||
}
|
||||
|
||||
*INTFRC = 0; /* stop forcing interrupts */
|
||||
|
|
Loading…
Reference in a new issue