From 68c89856c1fc310ad0d75ae1df9d000704e87c8a Mon Sep 17 00:00:00 2001 From: Tomasz Kramkowski Date: Sat, 21 Jan 2017 14:55:27 +0000 Subject: Init commit --- reg/pmc.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 reg/pmc.h (limited to 'reg/pmc.h') diff --git a/reg/pmc.h b/reg/pmc.h new file mode 100644 index 0000000..4aef0be --- /dev/null +++ b/reg/pmc.h @@ -0,0 +1,27 @@ +#ifndef LIB_REG_PMC_H +#define LIB_REG_PMC_H + +#include + +#define PMC_LVDSC1 REG_8(0x4007D000) /* Low Voltage Detect Status And Control 1 register */ +#define LVDSC1_LVDF 7 /* Low-Voltage Detect Flag */ +#define LVDSC1_LVDACK 6 /* Low-Voltage Detect Acknowledge */ +#define LVDSC1_LVDIE 5 /* Low-Voltage Detect Interrupt Enable */ +#define LVDSC1_LVDRE 4 /* Low-Voltage Detect Reset Enable */ +#define LVDSC1_LVDV 0 /* Low-Voltage Detect Voltage Select */ +#define LVDSC1_LVDV_M (uint8_t)(BITS(2) << LVDSC1_LVDV) + +#define PMC_LVDSC2 REG_8(0x4007D001) /* Low Voltage Detect Status And Control 2 register */ +#define LVDSC2_LVWF 7 /* Low-Voltage Warning Flag */ +#define LVDSC2_LVWACK 6 /* Low-Voltage Warning Acknowledge */ +#define LVDSC2_LVWIE 5 /* Low-Voltage Warning Interrupt Enable */ +#define LVDSC2_LVWV 0 /* Low-Voltage Warning Voltage Select */ +#define LVDSC2_LVWV_M (uint8_t)(BITS(2) << LVDSC2_LVWV) + +#define PMC_REGSC REG_8(0x4007D002) /* Regulator Status And Control register */ +#define REGSC_BGEN 4 /* Bandgap Enable In VLPx Operation */ +#define REGSC_ACKISO 3 /* Acknowledge Isolation */ +#define REGSC_REGONS 2 /* Regulator In Run Regulation Status */ +#define REGSC_BGBE 1 /* Bandgap Buffer Enable */ + +#endif /* LIB_REG_PMC_H */ -- cgit v1.2.3-54-g00ecf