PWM Signals

  • Hello !


    For our application we want to use the PWM signal. According to the hardware documentation there are 2 PWM output pins :


    * FS Bus J4 Pin 15 - PWM
    * LVDS J12 PIN 25 - BL PWM


    As LVDS is not equipped on my version of the NetDCU I tried to figure out how I can enable the PWM signal on the FS Bus - unfortunately without success.


    Is it possible to use the PWM signal wired to the J4 connector ? Or is it some kind of misuse of the FS Bus ?


    Kind regards


    Volker

  • Hello,


    with multiplatform-linux-f+s-V2.0 you can access backlight brightness for display by:


    Code
    1. # cat /sys/class/backlight/pwm-backlight.0/actual_brightness
    2. 255
    3. # echo 0 > /sys/class/backlight/pwm-backlight.0/brightness


    To use PIFPWM pin (TOUT1 - FS Bus J4 Pin 15) you need to apply attached patch. This will create a pwm-backlight.1 entry in sysfs.
    You can change duty by adjust the brightness value from 0 to 255. To setup frequency you can adjust respective value (.pwm_period_ns) in mach-netdcu14.c and recompile:

    Code
    1. static struct platform_pwm_backlight_data netdcu14_fsbus-pwm_data = {
    2. .pwm_id = 1,
    3. .pwm_period_ns = 1000,
    4. };


    For next release we will provide functionality to setup frequency by SYSFS.


    Please find Activate-TOUT1-PWM.1-via-backlight-system.patch attached to this post.

  • Possible that my 'hurray' was a little bit too early.


    Currently we have considerable problems getting the PWM signal from TOUT1 - FS Bus J4 Pin 15 even though we apparently applied the patch (otherwise we wouldn't see the according entry '/sys/class/backlight/pwm-backlight.1' in the filesystem).


    Any ideas what may affect the stability of this signal ?


    Do we only have to modify the entry /sys/class/backlight/pwm-backlight.1/brightness or is there something else we may have missed ?


    Kind Regards,


    Volker

  • Any updates about this issue ?


    We have ongoing problems with PWM signal from TOUT1 - FS Bus J4, especially a colleague of mine tried to activate the signal and failed too.


    To activate the signal we applied the patch and executed the following commands


    Code
    1. echo 128 > /sys/class/backlight/pwm-backlight.1/brightness
    2. echo 1 > /sys/class/backlight/pwm-backlight.1/bl_power


    Any help would be highly appreciated


    Kind Regards,


    Volker


    BTW: You mentioned the 'next release'. Is there a release planned in the near future ?

  • The PWM signal is meant for display backlight brightness in the first place. However the display is blanked after a few minutes by default, if no input (mouse, keyboard) is occurring. This also deactivates the backlight. Maybe you don't see the PWM signal because the display is blanked (switched off)?


    Then some settings to decativate display blanking may be necessary. These can be found here for example.

    F&S Elektronik Systeme GmbH
    As this is an international forum, please try to post in English.
    Da dies ein internationales Forum ist, bitten wir darum, Beiträge möglichst in Englisch zu verfassen.