?? portfunc.c
字號:
//**************************************************************************
// Port Functions for the FE427
//
// Stefan Schauer
// Texas Instruments Freising
// Date Comments
// =====================
// 08/22/03 Code Starts for FE427
//**************************************************************************
#include "device.h"
#include "display.h"
#include "emeter.h"
// ************************************************************
// Definitions & Declarations
// ************************************************************
// ************************************************************
// functions forward declarations
// ************************************************************
// ************************************************************
// functions
// ************************************************************
//====================================================================
/**
* Interrupt service routine for Port 2.
*
*/
#ifdef __IAR_SYSTEMS_ICC__
#if __VER__ < 200
interrupt[PORT2_VECTOR] void port2_isr(void)
#else
#pragma vector=PORT2_VECTOR
__interrupt void port2_isr( void )
#endif
#endif
#ifdef __CROSSWORKS__
void port1_isr(void) __interrupt[PORT2_VECTOR]
#endif
{
// Test if S2 was pressed
if (P2IFG & 0x08)
{
P2IFG &= ~0x08; //clear int. flag
P2IE &= ~0x08; //disable interrupt
// Restart measurement (set Embedded Signal Processing into "Measurement" mode)
SD16CTL |= SD16REFON; // Switch Reference oon
ESPCTL &= ~ESPSUSP; // Set ESP into Active Mode
// Startmeasurement (set Embedded Signal Processing into "Measurement" mode)
// ensure that it is not in measurement or calibration mode,
if ((RET0 & 0x8000) == 0)
{
// Set Embedded Signal Processing into "Idle" mode
MBOUT1= modeMEASURE; // modeMEASURE;
MBOUT0= mSET_MODE;
}
OP_Mode = measure;
LPM3_EXIT;
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -