?? pmu.h
字號:
#ifndef __PMU_H__#define __PMU_H__//=========== Definitions ============// Sub Addr of PCF50606#define ID 0x00#define OOCS 0x01#define INT1 0x02#define INT2 0x03#define INT3 0x04#define INT1M 0x05#define INT2M 0x06#define INT3M 0x07#define OOCC1 0x08#define OOCC2 0x09#define RTCSC 0x0A#define RTCMN 0x0B#define RTCHR 0x0C#define RTCWD 0x0D#define RTCDT 0x0E#define RTCMT 0x0F#define RTCYR 0x10#define RTCSCA 0x11#define RTCMNA 0x12#define RTCHRA 0x13#define RTCWDA 0x14#define RTCDTA 0x15#define RTCMTA 0x16#define RTCTRA 0x17#define PSSC 0x18#define PWROKM 0x19#define PWROKS 0x1A#define DCDC1 0x1B#define DCDC2 0x1C#define DCDC3 0x1D#define DCDC4 0x1E#define DCDEC1 0x1F#define DCDEC2 0x20#define DCUDC1 0x21#define DCUDC2 0x22#define IOREGC 0x23#define D1REGC1 0x24#define D2REGC1 0x25#define D3REGC1 0x26#define LPREGC1 0x27#define LPREGC2 0x28#define MBCC1 0x29#define MBCC2 0x2A#define MBCC3 0x2B#define MBCS1 0x2C#define BBCC 0x2D#define ADCC1 0x2E#define ADCC2 0x2F#define ADCS1 0x30#define ADCS2 0x31#define ADCS3 0x32#define ACDC1 0x33#define BVMC 0x34#define PWMC1 0x35#define LEDC1 0x36#define LEDC2 0x37#define GPOC1 0x38#define GPOC2 0x39#define GPOC3 0x3A#define GPOC4 0x3B#define GPOC5 0x3C enum {ONKEY_DETECT= 1,ONKEY1S_DETECT,EXTONF_DETECT,ALARM_DETECT,//INT1 REG. CHGINS_DETECT,CHGRM_DETECT, //INT2 REG ADCREADY_DETECT, }; //INT3 REG //========= Function prototypes =============unsigned char power_on_check(void);unsigned char pmu_write_reg(unsigned char subaddr, unsigned char data);unsigned char pmu_read_reg(unsigned char subaddr, unsigned char *value);void pmu_BootInit(void);unsigned char pmu_OnkeyCheck(void);unsigned char detect_interrupt(void);unsigned char read_irqPort(void);void waitOnKey(void);void pmu_goStandBy(void);void pmu_goFinalize(void);void quit_discharge(void);#endif //__PMU_H__
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -