高通平台中,控制PM8150L的GPIO_08输出PWM的adb指令是什么
时间: 2024-05-16 09:17:51 浏览: 46
ADC0808控制PWM输出
控制PM8150L的GPIO_08输出PWM的adb指令为:
```
adb shell "echo 2 > /sys/class/gpio/export"
adb shell "echo out > /sys/class/gpio/gpio2/direction"
adb shell "echo 1 > /sys/class/gpio/gpio2/value"
adb shell "echo timer > /sys/class/pwm/pwmchip0/export"
adb shell "echo 500000 > /sys/class/pwm/pwmchip0/pwm0/period"
adb shell "echo 250000 > /sys/class/pwm/pwmchip0/pwm0/duty_cycle"
adb shell "echo 1 > /sys/class/pwm/pwmchip0/pwm0/enable"
```
其中,period和duty_cycle的值可以根据具体情况进行修改。
阅读全文