This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM335x EVM LCD powering off

In using the AM335x EVM I've noticed that after some time of inactivity the LCD seems to turn itself off. I need to disable this functionality so I poked around a bit trying to find out why it was doing this in the first place.

When I was reading on the LCDC Driver's Guide: http://processors.wiki.ti.com/index.php/AM335x_LCD_Controller_Driver%27s_Guide

I saw this line:

"Framebuffer console blankes out after blanking interval....Default blankinterval is 10 minutes"

And in there it stated that "unblanking" can happen with this command:

$echo "0" > /sys/class/graphics/fb0/blank

And if I want to keep it permanently "unblanked" I can append to the boot arguments consoleblank=0. I gave this a try updating my boot command to:

U-Boot# setenv mmc_args 'run bootargs_defaults;setenv bootargs ${bootargs} root=${mmc_root} rootfstype=${mmc_root_fs_type} ip=169.254.0.2 consoleblank=0'

But when I do this it seems the LCD comes up powered off... I've also noted when the screen goes off echoing "0" to fb0/blank doesn't seem to do anything.. whereas echoing "4" seems to turn it back on (the screen slowly turns on, almost fading on)

Are these the correct commands? Should "0" in fact be turning ON the display? If so why am I not seeing that effect?

  • Hi Mike,

    I'm testing this on the AM335x GP EVM board using SDK v7 and everything seems to work as intended.

    echo "4" > /sys/class/graphics/fb0/blank -> Framebuffer console on display blanks
    echo "0" > /sys/class/graphics/fb0/blank -> Framebuffer console on display unblanks
    Adding "consoleblank=0" to the kernel bootargs. -> The display is on and framebuffer console is unblanked when the board boots up. I didn't wait for 10 minutes to see if it will blank afterwards.

    Which version of the SDK are you using?

    Best regards,
    Miroslav

  • Miroslav,

        Maybe I'm looking for the wrong thing. When I have something on the display, for example if I launch a Qt application then kill it (just the image is up there), after some amount of time (minutes) the display goes blank. Are you aware of this behavior and what might be the cause of it?

    -Mike

  • Mike,

    Are you using SDK 6 or 7?

    Do you have a console hooked up?  Do you either see anything print out in the terminal window or perhaps see any clues with "dmesg"?  I haven't really explored it yet, but one other thought might be that it's a more generic power management feature, e.g. the device is trying to suspend or something due to inactivity?

    Brad

  • Mike,

    I was able to see the screen automatically turn off when running the Chameleon demo for a long period of time.  This specific test was using SDK 6.00 with the base file system plus graphics manually added on top:

    • /etc/init.d/335x-demo
    • /opt/gfxsdkdemos/ogles2/OGLES2ChameleonMan -qaf=100000

    After the screen had blanked and the program terminated I was able to bring it back using the documented command:

    • echo "0" > /sys/class/graphics/fb0/blank

    I'm currently running a test where I added consoleblank=0 to my bootargs.  I should have an update in a few minutes regarding whether it worked as expected.

    Brad

  • Mike,

    The test went as expected.  Can you run "cat /proc/cmdline" to verify that the consoleblank=0 is truly getting passed to the kernel as expected?  For comparison sake I see the following in my system:

    console=ttyO0,115200n8 root=/dev/mmcblk0p2 ro rootfstype=ext3 rootwait ip=none consoleblank=0

    Furthermore, I tried running another test where I blank and unblank the console during operation:

    • /opt/gfxsdkdemos/ogles2/OGLES2ChameleonMan -qaf=10000 &
    • echo "4" > /sys/class/graphics/fb0/blank
    • echo "0" > /sys/class/graphics/fb0/blank

    The screen transitions to blank/unblank were sharp.  I did not notice the "fade" that you initially mentioned.

    Brad

  • I'd like to add this tidbit here in case a newbie like myself stumbles onto this thread:

    In order to pass "consoleblank=0" to the kernel, I created uEnv.txt in the boot partition (NOT rootfs/boot) and added the line:

    optargs="consoleblank=0"

    With that added, cat /proc/cmdline does indeed show consoleblank=0:

    console=ttyO0,115200n8 consoleblank=0 root=/dev/mmcblk0p2 ro rootfstype=ext4 rootwait

    I don't know if this will work with a more complicated uEnv.txt or other boot settings, but this did work for me starting from the vanilla SD card created by create-sdcard.sh in SDK8.