How to change the PF0100 voltage on i.MX6SABRE by I2C

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

How to change the PF0100 voltage on i.MX6SABRE by I2C

跳至解决方案
2,662 次查看
yuuki
Senior Contributor II

Dear all,

We run YOCTO Linux on MX6DL_SABRE-SDP board.

BSP: fsl-yocto-3.10.17_1.0.0

We want to change the output voltage of PMIC.
We understand the voltage of PMIC can be changed through I2C.

However, we cannot find a sample cord.
Would you teach a source code name and the place we have to refer to?

Best Reagrds,
Yuuki

标签 (1)
标记 (2)
0 项奖励
1 解答
1,430 次查看
CommunityBot
Community Manager
This an automatic process.

We are marking this post as solved, due to the either low activity or any reply marked as correct.

If you have additional questions, please create a new post and reference to this closed post.

NXP Community!

在原帖中查看解决方案

0 项奖励
4 回复数
1,431 次查看
CommunityBot
Community Manager
This an automatic process.

We are marking this post as solved, due to the either low activity or any reply marked as correct.

If you have additional questions, please create a new post and reference to this closed post.

NXP Community!
0 项奖励
1,435 次查看
HaohuaQIN
Contributor III

/sys/devices/platform/imx-i2c.1/i2c-1/1-0008/pfuze100-regulator/regulator/

root@freescale /sys/devices/platform/imx-i2c.1/i2c-1/1-0008/pfuze100-regulator/regulator$ ls

regulator.10  regulator.13  regulator.16  regulator.19  regulator.22  regulator.9

regulator.11  regulator.14  regulator.17  regulator.20  regulator.23

regulator.12  regulator.15  regulator.18  regulator.21  regulator.24

root@freescale /sys/devices/platform/imx-i2c.1/i2c-1/1-0008/pfuze100-regulator/regulator/regulator.12$ ls

device                      suspend_disk_microvolts

max_microvolts              suspend_disk_state

microvolts                  suspend_mem_microvolts

min_microvolts              suspend_mem_state

name                        suspend_standby_microvolts

num_users                   suspend_standby_state

power                       type

state                       uevent

subsystem

root@freescale /sys/devices/platform/imx-i2c.1/i2c-1/1-0008/pfuze100-regulator/regulator/regulator.12$ cat microvolts

3300000

root@freescale /sys/devices/platform/imx-i2c.1/i2c-1/1-0008/pfuze100-regulator/regulator/regulator.12$ echo 2600000 > microvolts

root@freescale /sys/devices/platform/imx-i2c.1/i2c-1/1-0008/pfuze100-regulator/regulator/regulator.12$ cat microvolts

2600000

you can use see the voltage on the boar is changed.

0 项奖励
1,435 次查看
michaelguntli
Contributor IV

 HaohuaQIN‌ what did you modify in the kernel to get permissions to modify the regulator microvolts?

We are using i.MX Linux kernel 3.14.52:

root@h5:/sys/bus/i2c/devices/1-0008/regulator/regulator.12 # cat name
SW3A
root@h5:/sys/bus/i2c/devices/1-0008/regulator/regulator.12 # cat microvolts
1225000
echo 1200000 > microvolts
/system/bin/sh: can't create microvolts: Permission denied

I found the following defines:

CONFIG_REGULATOR_VIRTUAL_CONSUMER=y
CONFIG_REGULATOR_USERSPACE_CONSUMER=y

0 项奖励
1,435 次查看
igorpadykov
NXP Employee
NXP Employee

Hi Yuuki

voltage can be set with linux regulator apis (like regulator_set_voltage),

plese refer to sect.23.3.1 Regulator APIs, and PFUZE100 regulator driver

in sect.23.4.2 Source Code Structure attached Linux Manual.

Best regards

igor

-----------------------------------------------------------------------------------------------------------------------

Note: If this post answers your question, please click the Correct Answer button. Thank you!

-----------------------------------------------------------------------------------------------------------------------

0 项奖励