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.

OMAP - Disabling/Delaying LCD Sleep Mode

Other Parts Discussed in Thread: OMAP3530

Hi there,

In terms of hardware, I have an OMAP3530 Mistral Board (rev. G). 

In terms of software, I have it configured to boot off of MMC (SD card) to run a graphical application.  In that sense, I've re-built u-boot, the kernel, and am using the stock ramdisk image from the SDK.

When I run my graphical application (and even when I run the stock omap-demo), after about 30 seconds, the LCD powers down.. i.e. goes into sleep mode.  Is there a way for me to disable that functionality, or to at least extend it to be a much larger number (i.e. 600 seconds)?

I've noticed that using the stylus doesn't appear to wake it up.. only hitting return on my serial console (most likely caused by the UART IRQ).

I've looked around at various threads, specifically looking under 'Power Management', but haven't been able to locate anything that seems to relate to the LCD timeout.  I've looked at the kernel options, but nothing there.  I'm aware that the LCD initialization is performed by u-boot, and I tried pawing through the u-boot code (lcd.c), but saw nothing obvious there either.

Any help would be greatly appreciated.

Thanks and Regards,

Peter Sienkewicz

p.s. If there is any other pertinent information I'd need to include (be it hardware or software), I'd be happy to include it.

 

 

  • Peter,

    Depending on which build of Linux you are using you can try the following...

    echo 0 > /sys/power/fb_timeout_value

    BR,

    Steve

  • Hi Steve,

    Thanks for the quick reply.

    I take it '0' disables the timeout, and any other number would change the value?  So I could set it to, say, 600?

    I tried creating the file on the running OMAP board and got the following error:

     

    root@omap3evm:~# ls -al /sys/power/fb_timeout_value
    ls: /sys/power/fb_timeout_value: No such file or directory

     

    ... although that directory does exist:

     

    root@omap3evm:~# ls -al /sys/power/
    drwxr-xr-x    2 root     root            0 Sep 11 16:17 .
    drwxr-xr-x   12 root     root            0 Jan  1  1970 ..
    -rw-r--r--    1 root     root         4096 Sep 11 16:17 clocks_off_while_idle
    -rw-r--r--    1 root     root         4096 Sep 11 16:17 enable_off_mode
    -rw-r--r--    1 root     root         4096 Sep 11 16:17 sleep_while_idle
    -rw-r--r--    1 root     root         4096 Sep 11 16:17 sr_vdd1_autocomp
    -rw-r--r--    1 root     root         4096 Sep 11 16:17 sr_vdd2_autocomp
    -rw-r--r--    1 root     root         4096 Sep 11 16:17 state
    -rw-r--r--    1 root     root         4096 Sep 11 16:17 voltage_off_while_idle

     

    Any idea why I'd see that error?

    The linux build is:

    root@omap3evm:~# uname -a
    Linux omap3evm 2.6.29-rc3-omap1 #1 Mon Jan 11 14:44:57 EST 2010 armv7l unknown

    CPU Info:

    root@omap3evm:~# cat /proc/cpuinfo
    Processor       : ARMv7 Processor rev 3 (v7l)
    BogoMIPS        : 499.92
    Features        : swp half thumb fastmult vfp edsp neon
    CPU implementer : 0x41
    CPU architecture: 7
    CPU variant     : 0x1
    CPU part        : 0xc08
    CPU revision    : 3

    Hardware        : OMAP3 EVM
    Revision        : 0020
    Serial          : 0000000000000000
    root@omap3evm:~#

     

    Looking at the loop mounted ramdisk, it looks like there is no '/sys/power' directory before boot.  Would it break things if the '/sys/power' directory were created in the ramdisk before boot?

    Thanks again,

    Peter Sienkewicz

  • Sorry.. the error I got was:

     

    root@omap3evm:~# echo 0 > /sys/fb_timeout_value
    -sh: can't create /sys/power/fb_timeout_value: nonexistent directory

  • Peter,

    Sorry, I am now at the limit of my experience with this.

    The /sys/ entries are not really file system files in the normal sense and are used to access hardware features in a somewhat flexible manner hence does not really exist in the ram disk per-se.

    I don't know enough about the various builds to know which versions this should work on and which it doesn't. Obviously yours doesn't :(

    Sorry I can't help much more.

    BR,

    Steve

  • Hi Steve,

    Do you know where I could find a build of linux that would support this capability?  If I got the latest kernel/ramdisk from the TI website, would that be sufficient?

    Or do you know any other way do go about doing the same thing, without creating /dev/power/fb_timeout_value?  By modifying the source directly?

    Or finally, if you're not quite sure moving forward, do you know of anybody who's done this before that you could refer me to?

    Thanks again,

    Peter

  • Hi Steve,

    Another thought.. if I disabled Power Management in the kernel, would that disbale this behavour?

    Finally.. just wanted to thank you for your help on all this ... much appreciated.

    Peter

     

  • Peter,

    You could try disabling power management if you don't explicitly need it.

    I will see if I can find out more information for you, but the Linux builds are not really my forte.

    You are more than welcome :) Hopefully I can actually be useful at the end of all this !!

    BR,

    Steve

  • Hi Steve,

    I tried disabling 'power management' in the kernal, and after doing so, the LCD still goes into sleep mode. 

    Please let me know if you find any other information on the matter.

    Thanks again!

    Peter

  • Peter,

    OK, try this...

    100 > /sys/devices/platform/omapfb/sleep_timeout

    which should change the timeout from the default of 20 seconds to 100 seconds.

    Supposedly this is described in the Migration Guide which should be included somewhere in the PSP release. I can't confirm this at the moment since I have not looked at the release.

    Steve K. gave me this answer, so thanks Steve :)

    BR,

    Stev

  • Steve,

    You forgot the echo in front of the 100

    echo 100 >/sys/devices/platform/omapfb/sleep_timeout

    Would set the timeout to 100 seconds instead of the default 20 secondis.

    Steve K.

  • ooops, should pay more attention to cut and paste !! :)

  • Hi Steve,

    That worked.. Thanks a million!!!

    Regards

    Peter Sienkewicz

  • Excellent.

    I can go home now that I have actually achieved something :)

    BR,

    Steve