打开pwm15
echo 0 > /sys/class/pwm/pwmchip2/export
设置频率1khz
echo 1000000 > /sys/class/pwm/pwmchip2/pwm0/period
设置占空比 10%
echo 100000 > /sys/class/pwm/pwmchip2/pwm0/duty_cycle
开始pwm
echo 1 > /sys/class/pwm/pwmchip2/pwm0/enable
关闭pwm
echo 0 > /sys/class/pwm/pwmchip2/pwm0/enable
echo 0 > /sys/class/pwm/pwmchip2/unexport