mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-12-22 10:30:13 +00:00
m12 low power
This commit is contained in:
parent
d12df2eed3
commit
92856d8831
@ -49,6 +49,7 @@
|
||||
#define FTUNE 3
|
||||
|
||||
#define vreg_init buck_init
|
||||
#define board_init m12_init
|
||||
#include <std_conf.h>
|
||||
|
||||
#endif
|
||||
|
@ -58,3 +58,14 @@ void buck_init(void) {
|
||||
while(CRM->STATUSbits.VREG_1P8V_RDY == 0) { continue; }
|
||||
}
|
||||
|
||||
void m12_init(void) {
|
||||
/* configure pullups for low power */
|
||||
GPIO->FUNC_SEL.GPIO_63 = 3;
|
||||
GPIO->PAD_PU_SEL.GPIO_63 = 0;
|
||||
GPIO->FUNC_SEL.SS = 3;
|
||||
GPIO->PAD_PU_SEL.SS = 1;
|
||||
GPIO->FUNC_SEL.VREF2H = 3;
|
||||
GPIO->PAD_PU_SEL.VREF2H = 1;
|
||||
GPIO->FUNC_SEL.U1RTS = 3;
|
||||
GPIO->PAD_PU_SEL.U1RTS = 1;
|
||||
}
|
||||
|
@ -42,6 +42,7 @@
|
||||
|
||||
void default_vreg_init(void);
|
||||
void buck_init(void);
|
||||
void m12_init(void);
|
||||
void uart1_init(uint16_t inc, uint16_t mod, uint8_t samp);
|
||||
void uart2_init(uint16_t inc, uint16_t mod, uint8_t samp);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user