summaryrefslogtreecommitdiffhomepage
path: root/source/pmic.h
blob: 06ac9fb383d6362ef0782acf1639270ac89d970b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
/*
 *       pmic.h
 *
 *       Copyright (C) 2018, 2019 Mind Chasers Inc.
 *
 *   Licensed under the Apache License, Version 2.0 (the "License");
 *   you may not use this file except in compliance with the License.
 *   You may obtain a copy of the License at
 *
 *       http://www.apache.org/licenses/LICENSE-2.0
 *
 *   Unless required by applicable law or agreed to in writing, software
 *   distributed under the License is distributed on an "AS IS" BASIS,
 *   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *   See the License for the specific language governing permissions and
 *   limitations under the License.
 *
 */


#ifndef SOURCES_PMIC_H_
#define SOURCES_PMIC_H_

#define PMIC_VERSION 	0
#define PMIC_PGOODZ		1
#define PMIC_MASK		2
#define PMIC_REG_CTRL	3
#define PMIC_CON_CTRL	4
#define PMIC_CON_CTRL2	5
#define PMIC_DEFCORE	6
#define PMIC_DEFSLEW	7
#define PMIC_LDO_CTRL	8

// PMIC_PGOODZ
#define PGOODZ_LDO1		2

// PMIC_REG_CTRL
#define LDO1_ENABLE		0x02
#define LDO2_ENABLE		0x04
#define VDDC3_ENABLE	0x08
#define VDDC2_ENABLE	0x10
#define VDDC1_ENABLE	0x20

// PMIC_LDO_CTRL
// LDO2 = 2.5V, LD01 = 1.1V
#define LDO1_1_1V		1
#define	LDO2_2_5V		4

#endif /* SOURCES_PMIC_H_ */