Part Number: AM3352
Tool/software: Linux
I am using VAR-SOM-AM33 device with kernel (3.14.26) and device tree provided by Varisce in Yocto Daisy image (Variscite FTP). My wish is to use PWM device with passive buzzer and for this I want to change device tree configuration for PWM-backlight and use buzzer on this PIN instead of backlight. What I can not understand is why PWM-backlight is not working immediately without any changes in device tree. I followed instructions for controlling backlight (AM335x_PWM_Driver's_Guide), output voltage on LCD connector j29 PIN #3 is 3V, but PWM is not working (tested with oscilloscope).
Device tree Kernel 3.14.26:
backlight_pins {
pinctrl-single,pins = <0x19c 0x4>;
};
backlight {
compatible = "pwm-backlight";
pwms = <0x53 0x0 0xc350 0x1>;
brightness-levels = <0x0 0x3a 0x3d 0x42 0x4b 0x5a 0x7d 0xaa 0xff>;
default-brightness-level = <0x8>;
power-supply = <0x54>;
};
epwmss@48304000 {
compatible = "ti,am33xx-pwmss";
reg = <0x48304000 0x10>;
ti,hwmods = "epwmss2";
#address-cells = <0x1>;
#size-cells = <0x1>;
status = "okay";
ranges = <0x48304100 0x48304100 0x80 0x48304180 0x48304180 0x80 0x48304200 0x48304200 0x80>;
ecap@48304100 {
compatible = "ti,am33xx-ecap";
#pwm-cells = <0x3>;
reg = <0x48304100 0x80>;
ti,hwmods = "ecap2";
status = "okay";
linux,phandle = <0x53>;
phandle = <0x53>;
};
ehrpwm@48304200 {
compatible = "ti,am33xx-ehrpwm";
#pwm-cells = <0x3>;
reg = <0x48304200 0x80>;
ti,hwmods = "ehrpwm2";
status = "disabled";
};
};
fixedregulator@4 {
compatible = "regulator-fixed";
regulator-name = "vdd_bl";
gpio = <0x2f 0x2 0x0>;
regulator-always-on;
regulator-boot-on;
enable-active-high;
linux,phandle = <0x54>;
phandle = <0x54>;
};
If I do the same with new Yocto image and Kernel 4.4.19 output voltage on LCD connector j29 PIN #3 is 3V and PWM is working without problem (tested with oscilloscope).
Device tree Kernel 4.4.19:
backlight_pins {
pinctrl-single,pins = <0x150 0x3>;
linux,phandle = <0x4f>;
phandle = <0x4f>;
};
backlight {
compatible = "pwm-backlight";
pwms = <0x61 0x0 0xc350 0x0>;
brightness-levels = <0x0 0x3a 0x3d 0x42 0x4b 0x5a 0x7d 0xaa 0xff>;
default-brightness-level = <0x8>;
};
epwmss@48300000 {
compatible = "ti,am33xx-pwmss";
reg = <0x48300000 0x10>;
ti,hwmods = "epwmss0";
#address-cells = <0x1>;
#size-cells = <0x1>;
status = "okay";
ranges = <0x48300100 0x48300100 0x80 0x48300180 0x48300180 0x80 0x48300200 0x48300200 0x80>;
ecap@48300100 {
compatible = "ti,am33xx-ecap";
#pwm-cells = <0x3>;
reg = <0x48300100 0x80>;
interrupts = <0x1f>;
interrupt-names = "ecap0";
status = "disabled";
};
pwm@48300200 {
compatible = "ti,am33xx-ehrpwm";
#pwm-cells = <0x3>;
reg = <0x48300200 0x80>;
clocks = <0x4e>;
clock-names = "tbclk";
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <0x4f>;
linux,phandle = <0x61>;
phandle = <0x61>;
};
};
Could someone please help me to understand why PWM-Backlight with old device tree and kernel is not working and maybe give me some direction what I have to change in device tree to use passive buzzer on this PIN.
Thanks!